/* --- GENEL AYARLAR & ARKA PLAN --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    min-height: 100vh;
    /* Hava durumunu andıran dinamik bir gradyan */
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 50%, #6dd5ed 100%);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
}

/* --- HEADER & DİL BUTONLARI --- */
header {
    width: 100%;
    max-width: 500px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 10px 0;
}

header h1 {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Dil Seçenekleri Alanı */
header button {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 6px 12px;
    margin-left: 5px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s ease;
}

header button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* --- ANA KART (MAIN) --- */
main {
    width: 100%;
    max-width: 500px;
    background: rgba(255, 255, 255, 0.1); /* Cam efekti tabanı */
    backdrop-filter: blur(12px); /* Arka planı bulandırma */
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    margin: auto 0;
}

/* --- FORM & INPUT ELEMANLARI --- */
form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

form label {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 600;
    align-self: center;
}

/* Form içindeki anlamsız <br> etiketlerini gizliyoruz */
form br {
    display: none;
}

/* Metin Giriş Alanı */
input[type="text"] {
    width: 100%;
    padding: 14px 20px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

input[type="text"]:focus {
    background: rgba(255, 255, 255, 0.25);
    border-color: #6dd5ed;
    box-shadow: 0 0 10px rgba(109, 213, 237, 0.3);
}

/* Gönder (Submit) Butonu */
input[type="submit"] {
    width: 100%;
    padding: 14px;
    background: #6dd5ed;
    border: none;
    border-radius: 12px;
    color: #1e3c72;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(109, 213, 237, 0.4);
    margin-top: 5px;
}

input[type="submit"]:hover {
    background: #ffffff;
    color: #1e3c72;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.4);
}

input[type="submit"]:active {
    transform: translateY(0);
}

/* --- YENİ: SON ARANAN ŞEHİR ALANI --- */
#last-searched-city {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    text-align: center;
    margin-top: 5px;
    font-style: italic;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

/* --- SONUÇ ALANI (WEATHER RESULT) --- */
#weather-result {
    margin-top: 15px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    font-size: 1.05rem;
    line-height: 1.6;
    color: #ffffff;
    text-align: center;
    white-space: pre-line; /* JavaScript'teki \n alt satır komutlarını korur */
}

/* Veri henüz yüklenmediğinde boş alanların çirkin durmaması için gizleme */
#weather-result:empty, #last-searched-city:empty {
    display: none;
}

/* --- FOOTER --- */
footer {
    width: 100%;
    text-align: center;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.5;
    margin-top: 20px;
}

footer a {
    color: #6dd5ed;
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    text-decoration: underline;
    color: #ffffff;
}

/* Dil Seçim Menüsü Tasarımı */
#langSelect {
    padding: 8px 12px;
    font-size: 14px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-weight: 500;
    color: #333333;
    background-color: #ffffff;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Fareyle üzerine gelindiğinde (Hover durumu) */
#langSelect:hover {
    border-color: #007bff;
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.15);
}

/* Seçim kutusuna odaklanıldığında (Focus durumu) */
#langSelect:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
}

/* Seçeneklerin (Açılır listenin içi) tasarımı */
#langSelect option {
    padding: 10px;
    background-color: #ffffff;
    color: #333333;
}

#github, #linkedin{
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 6px 12px;
    margin-left: 5px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s ease;
}
