/* إعدادات أساسية وتصفير الهوامش */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tajawal', sans-serif;
    background: #090D16;
    color: #F8FAFC;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* الحاوية الرئيسية للتطبيق (تصميم زجاجي فاخر) */
.weather-app {
    width: 100%;
    max-width: 440px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.75), rgba(15, 23, 42, 0.9));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 28px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(56, 189, 248, 0.05);
    display: flex;
    flex-direction: column;
    gap: 22px;
}

/* الشريط العلوي المنفصل (الرأس) */
.app-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 12px;
}

.brand-name {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 3px;
    color: #38BDF8;
}

.brand-badge {
    font-size: 0.7rem;
    background: rgba(56, 189, 248, 0.1);
    color: #38BDF8;
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 600;
}

/* قسم معلومات الطقس الرئيسية */
.main-weather-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.city-name {
    font-size: 2rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 4px;
    letter-spacing: 1px;
}

.weather-condition {
    font-size: 0.9rem;
    color: #94A3B8;
    font-weight: 300;
}

.temperature-box {
    font-size: 3rem;
    font-weight: 700;
    color: #38BDF8;
    display: flex;
    align-items: flex-start;
}

.unit {
    font-size: 1.4rem;
    margin-top: 4px;
    color: #CBD5E1;
}

/* شبكة تفاصيل الطقس (رطوبة، رياح، حالة) */
.weather-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.detail-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    padding: 12px 8px;
    text-align: center;
    transition: transform 0.3s ease;
}

.detail-card:hover {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.2);
}

.detail-label {
    display: block;
    font-size: 0.75rem;
    color: #64748B;
    margin-bottom: 4px;
    font-weight: 400;
}

.detail-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: #E2E8F0;
}

/* شريط أزرار اختيار المدن */
.city-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.city-btn {
    background: rgba(30, 41, 59, 0.8);
    color: #94A3B8;
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 11px;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Tajawal', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.city-btn:hover {
    background: rgba(56, 189, 248, 0.1);
    color: #38BDF8;
    border-color: rgba(56, 189, 248, 0.3);
}

.city-btn.active {
    background: #38BDF8;
    color: #090D16;
    font-weight: 700;
    border-color: #38BDF8;
    box-shadow: 0 4px 15px rgba(56, 189, 248, 0.3);
}

/* الفوتر السفلي (الذيل) بمسافة آمنة ومرتبة داخل البطاقة */
.app-footer {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 12px;
    color: #64748B;
    font-size: 0.78rem;
}
