/*---- stylesheet main----*/

:root {
    --void: #0a0e1a;
    --void-light: #121829;
    --void-lighter: #1a2040;
    --navy: #1e3a5f;
    --navy-light: #2a4a6f;
    --navy-muted: #3a5a7f;
    --gold: #d4a853;
    --gold-light: #e8c97a;
    --gold-dark: #b8923e;
    --gold-glow: rgba(212, 168, 83, 0.3);
    --parchment: #f5f0e1;
    --parchment-muted: #c8c0a8;
    --text-primary: #e8e0d0;
    --text-secondary: #a09888;
    --text-muted: #6b6560;
    --heat-red: #e74c3c;
    --cold-blue: #3498db;
    --rain-blue: #2980b9;
    --storm-purple: #8e44ad;
    --sun-gold: #f1c40f;
    --success: #27ae60;
    --warning: #e67e22;
    --danger: #c0392b;
    --algeria-green: #006233;
    --algeria-red: #d21034;
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 30px;
    --radius-full: 50%;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.4);
    --shadow-gold: 0 0 30px var(--gold-glow);
    --shadow-glow: 0 0 40px rgba(212, 168, 83, 0.15);
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    --font-primary: 'Cairo', 'Tajawal', sans-serif;
    --font-display: 'Tajawal', 'Cairo', sans-serif;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box
}

html {
    scroll-behavior: smooth;
    font-size: 16px
}

body {
    font-family: var(--font-primary);
    background: var(--void);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    min-height: 100vh
}

::selection {
    background: var(--gold);
    color: var(--void)
}

::-webkit-scrollbar {
    width: 8px
}

::-webkit-scrollbar-track {
    background: var(--void-light)
}

::-webkit-scrollbar-thumb {
    background: var(--navy-muted);
    border-radius: var(--radius-full)
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold)
}

#starCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 14, 26, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 168, 83, 0.1);
    transition: transform 0.4s ease, background 0.3s ease
}

.site-header.hidden {
    transform: translateY(-100%)
}

.site-header.scrolled {
    background: rgba(10, 14, 26, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4)
}

.header-inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px
}

.brand {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    text-decoration: none;
    flex-shrink: 0
}

.brand-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    object-fit: cover;
    border: 2px solid var(--gold);
    box-shadow: 0 0 15px var(--gold-glow);
    transition: transform 0.3s ease, box-shadow 0.3s ease
}

.brand:hover .brand-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 0 25px var(--gold-glow)
}

.brand-text {
    display: flex;
    flex-direction: column
}

.brand-name {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--parchment);
    line-height: 1.2
}

.brand-tagline {
    font-size: 0.7rem;
    color: var(--gold);
    font-weight: 500;
    letter-spacing: 1px
}

.main-nav {
    display: flex;
    align-items: center
}

.nav-list {
    display: flex;
    list-style: none;
    gap: var(--space-xs)
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    position: relative;
    white-space: nowrap
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: all 0.3s ease;
    transform: translateX(50%)
}

.nav-link:hover,
.nav-link.active {
    color: var(--gold);
    background: rgba(212, 168, 83, 0.08)
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 60%
}

.header-controls {
    display: flex;
    align-items: center;
    gap: var(--space-sm)
}

.search-wrapper {
    position: relative
}

.search-input {
    width: 260px;
    padding: 0.6rem 2.5rem 0.6rem 1rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(212, 168, 83, 0.15);
    border-radius: var(--radius-xl);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 0.9rem;
    transition: all var(--transition-fast);
    outline: none
}

.search-input::placeholder {
    color: var(--text-muted)
}

.search-input:focus {
    border-color: var(--gold);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 15px var(--gold-glow);
    width: 300px
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none
}

.city-suggestions {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    background: var(--void-light);
    border: 1px solid rgba(212, 168, 83, 0.2);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    max-height: 280px;
    overflow-y: auto;
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease
}

.city-suggestions.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0)
}

.city-suggestion-item {
    padding: var(--space-sm) var(--space-md);
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background var(--transition-fast);
    font-size: 0.9rem
}

.city-suggestion-item:hover {
    background: rgba(212, 168, 83, 0.1)
}

.city-suggestion-item .city-name {
    font-weight: 600;
    color: var(--text-primary)
}

.city-suggestion-item .city-region {
    font-size: 0.8rem;
    color: var(--text-muted)
}

.icon-btn {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(212, 168, 83, 0.15);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    font-size: 1rem
}

.icon-btn:hover {
    background: rgba(212, 168, 83, 0.15);
    color: var(--gold);
    border-color: var(--gold);
    transform: scale(1.1)
}

.icon-btn:active {
    transform: scale(0.95)
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--parchment);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--space-sm)
}

.alert-banner {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    z-index: 999;
    background: linear-gradient(135deg, var(--danger), #a93226);
    color: white;
    padding: var(--space-sm) var(--space-xl);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-md);
    font-weight: 600;
    font-size: 0.95rem;
    transform: translateY(-100%);
    transition: transform 0.4s ease;
    box-shadow: var(--shadow-md)
}

.alert-banner.visible {
    transform: translateY(0)
}

.alert-banner.info {
    background: linear-gradient(135deg, var(--navy), var(--navy-light))
}

.alert-banner.warning {
    background: linear-gradient(135deg, var(--warning), #d35400)
}

.alert-banner.success {
    background: linear-gradient(135deg, var(--success), #1e8449)
}

.alert-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.3rem;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s
}

.alert-close:hover {
    opacity: 1
}

.main-content {
    position: relative;
    z-index: 1;
    padding-top: 72px
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--space-lg)
}

.hero-section {
    padding: var(--space-3xl) 0;
    position: relative;
    overflow: hidden
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: var(--space-3xl);
    align-items: center
}

.weather-cube-container {
    perspective: 1000px;
    width: 280px;
    height: 280px;
    margin: 0 auto
}

.weather-cube {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    animation: cubeRotate 20s infinite linear
}

@keyframes cubeRotate {
    0% {
        transform: rotateX(-15deg) rotateY(0deg)
    }

    100% {
        transform: rotateX(-15deg) rotateY(360deg)
    }
}

.cube-face {
    position: absolute;
    width: 280px;
    height: 280px;
    background: linear-gradient(135deg, rgba(30, 58, 95, 0.9), rgba(10, 14, 26, 0.95));
    border: 1px solid rgba(212, 168, 83, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--gold);
    backface-visibility: visible;
    border-radius: var(--radius-md);
    box-shadow: inset 0 0 30px rgba(212, 168, 83, 0.1)
}

.cube-face.front {
    transform: translateZ(140px)
}

.cube-face.back {
    transform: rotateY(180deg) translateZ(140px)
}

.cube-face.right {
    transform: rotateY(90deg) translateZ(140px)
}

.cube-face.left {
    transform: rotateY(-90deg) translateZ(140px)
}

.cube-face.top {
    transform: rotateX(90deg) translateZ(140px)
}

.cube-face.bottom {
    transform: rotateX(-90deg) translateZ(140px)
}

.cube-face .cube-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: var(--space-sm);
    font-weight: 600
}

.cube-face .cube-temp {
    font-size: 2rem;
    font-weight: 800;
    color: var(--parchment)
}

.hero-content {
    text-align: right
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    background: rgba(212, 168, 83, 0.1);
    border: 1px solid rgba(212, 168, 83, 0.2);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-xl);
    font-size: 0.85rem;
    color: var(--gold);
    margin-bottom: var(--space-lg)
}

.hero-badge .pulse {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: var(--radius-full);
    animation: pulse 2s infinite
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1)
    }

    50% {
        opacity: 0.5;
        transform: scale(1.2)
    }
}

.hero-title {
    font-family: var(--font-display);
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: var(--space-md);
    background: linear-gradient(135deg, var(--parchment), var(--gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
    max-width: 500px
}

.hero-stats {
    display: flex;
    gap: var(--space-xl);
    margin-top: var(--space-xl)
}

.hero-stat {
    text-align: center
}

.hero-stat-value {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--gold)
}

.hero-stat-label {
    font-size: 0.85rem;
    color: var(--text-muted)
}

.weather-card {
    background: linear-gradient(145deg, rgba(30, 58, 95, 0.6), rgba(10, 14, 26, 0.8));
    border: 1px solid rgba(212, 168, 83, 0.15);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px)
}

.weather-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(212, 168, 83, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
    pointer-events: none
}

.weather-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--space-lg);
    position: relative;
    z-index: 1
}

.weather-location {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs)
}

.weather-city {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--parchment)
}

.weather-country {
    font-size: 0.9rem;
    color: var(--text-muted)
}

.weather-update {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: var(--space-xs)
}

.weather-update i {
    color: var(--success)
}

.weather-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-xl);
    position: relative;
    z-index: 1
}

.weather-temp-display {
    text-align: center
}

.weather-temp {
    font-family: var(--font-display);
    font-size: 5rem;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(135deg, var(--parchment), var(--gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text
}

.weather-condition {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-top: var(--space-sm)
}

.weather-icon-main {
    font-size: 5rem;
    color: var(--gold);
    filter: drop-shadow(0 0 20px var(--gold-glow));
    animation: floatIcon 3s ease-in-out infinite
}

@keyframes floatIcon {

    0%,
    100% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(-10px)
    }
}

.weather-details-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
    position: relative;
    z-index: 1
}

.detail-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    text-align: center;
    transition: all var(--transition-fast)
}

.detail-card:hover {
    background: rgba(212, 168, 83, 0.05);
    border-color: rgba(212, 168, 83, 0.2);
    transform: translateY(-3px)
}

.detail-card-icon {
    font-size: 1.5rem;
    color: var(--gold);
    margin-bottom: var(--space-sm)
}

.detail-card-value {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--parchment)
}

.detail-card-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: var(--space-xs)
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
    position: relative
}

.section-title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--parchment);
    position: relative;
    padding-right: var(--space-lg)
}

.section-title::before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 30px;
    background: linear-gradient(180deg, var(--gold), transparent);
    border-radius: var(--radius-full)
}

.section-actions {
    display: flex;
    gap: var(--space-sm)
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    outline: none
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: var(--void);
    box-shadow: 0 4px 15px var(--gold-glow)
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px var(--gold-glow)
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    border: 1px solid rgba(212, 168, 83, 0.15)
}

.btn-secondary:hover {
    background: rgba(212, 168, 83, 0.1);
    color: var(--gold);
    border-color: var(--gold)
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid transparent
}

.btn-ghost:hover {
    color: var(--gold);
    background: rgba(212, 168, 83, 0.05)
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed
}

.hourly-section {
    padding: var(--space-3xl) 0
}

.hourly-scroll {
    overflow-x: auto;
    padding-bottom: var(--space-md);
    scrollbar-width: thin;
    scrollbar-color: var(--navy-muted) var(--void-light)
}

.hourly-scroll::-webkit-scrollbar {
    height: 6px
}

.hourly-scroll::-webkit-scrollbar-track {
    background: var(--void-light);
    border-radius: var(--radius-full)
}

.hourly-scroll::-webkit-scrollbar-thumb {
    background: var(--navy-muted);
    border-radius: var(--radius-full)
}

.hourly-container {
    display: flex;
    gap: var(--space-md);
    min-width: max-content
}

.hourly-card {
    min-width: 100px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    text-align: center;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden
}

.hourly-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--gold), transparent);
    opacity: 0;
    transition: opacity 0.3s
}

.hourly-card:hover {
    background: rgba(212, 168, 83, 0.05);
    border-color: rgba(212, 168, 83, 0.2);
    transform: translateY(-5px)
}

.hourly-card:hover::before {
    opacity: 1
}

.hourly-time {
    font-weight: 700;
    color: var(--gold);
    font-size: 0.9rem;
    margin-bottom: var(--space-sm)
}

.hourly-icon {
    font-size: 1.8rem;
    color: var(--parchment);
    margin: var(--space-sm) 0
}

.hourly-temp {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--parchment)
}

.hourly-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: var(--space-xs)
}

.forecast-section {
    padding: var(--space-3xl) 0
}

.forecast-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: var(--space-md)
}

.forecast-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    text-align: center;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden
}

.forecast-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0;
    transition: opacity 0.3s
}

.forecast-card:hover {
    background: rgba(212, 168, 83, 0.05);
    border-color: rgba(212, 168, 83, 0.2);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3)
}

.forecast-card:hover::after {
    opacity: 1
}

.forecast-day {
    font-weight: 700;
    color: var(--gold);
    font-size: 1rem;
    margin-bottom: var(--space-xs)
}

.forecast-date {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: var(--space-md)
}

.forecast-icon {
    font-size: 2.5rem;
    color: var(--parchment);
    margin: var(--space-md) 0;
    filter: drop-shadow(0 0 10px rgba(212, 168, 83, 0.2))
}

.forecast-condition {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
    min-height: 40px
}

.forecast-temps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.05)
}

.forecast-high {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--heat-red)
}

.forecast-low {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--cold-blue)
}

.sea-section {
    padding: var(--space-3xl) 0
}

.sea-card {
    background: linear-gradient(145deg, rgba(30, 58, 95, 0.5), rgba(10, 14, 26, 0.7));
    border: 1px solid rgba(212, 168, 83, 0.15);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    position: relative;
    overflow: hidden
}

.sea-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23d4a853' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
    pointer-events: none
}

.sea-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
    position: relative;
    z-index: 1
}

.sea-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    text-align: center;
    transition: all var(--transition-fast)
}

.sea-item:hover {
    background: rgba(212, 168, 83, 0.05);
    transform: translateY(-3px)
}

.sea-item-icon {
    font-size: 2.5rem;
    color: var(--cold-blue);
    margin-bottom: var(--space-sm);
    animation: waveBob 2s ease-in-out infinite
}

@keyframes waveBob {

    0%,
    100% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(-5px)
    }
}

.sea-item-value {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--parchment)
}

.sea-item-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: var(--space-xs)
}

.sea-tips {
    margin-top: var(--space-lg);
    padding-top: var(--space-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 1
}

.sea-tips-title {
    font-weight: 700;
    color: var(--gold);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    gap: var(--space-sm)
}

.sea-tips-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm)
}

.sea-tips-list li {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.9rem;
    color: var(--text-secondary)
}

.sea-tips-list li i {
    color: var(--gold);
    font-size: 0.8rem
}

.map-section {
    padding: var(--space-3xl) 0
}

.map-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    position: relative
}

.map-wrapper {
    height: 500px;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid rgba(212, 168, 83, 0.1)
}

#weatherMap {
    width: 100%;
    height: 100%
}

.map-controls {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-md);
    flex-wrap: wrap
}

.map-btn {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid rgba(212, 168, 83, 0.15);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary)
}

.map-btn:hover {
    background: rgba(212, 168, 83, 0.1);
    color: var(--gold);
    border-color: var(--gold)
}

.map-btn.active {
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: var(--void);
    border-color: var(--gold);
    box-shadow: 0 4px 15px var(--gold-glow)
}

.map-legend {
    position: absolute;
    bottom: 30px;
    left: 30px;
    background: rgba(10, 14, 26, 0.9);
    backdrop-filter: blur(10px);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    border: 1px solid rgba(212, 168, 83, 0.15);
    font-size: 0.85rem;
    z-index: 500;
    min-width: 200px
}

.map-legend h4 {
    margin-bottom: var(--space-sm);
    color: var(--gold);
    font-size: 0.9rem
}

.legend-gradient {
    height: 12px;
    border-radius: var(--radius-full);
    margin-bottom: var(--space-xs)
}

.legend-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted)
}

.stats-section {
    padding: var(--space-3xl) 0
}

.stats-tabs {
    display: flex;
    gap: var(--space-sm);
    margin-bottom: var(--space-xl);
    flex-wrap: wrap
}

.stats-tab {
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-xl);
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid rgba(212, 168, 83, 0.15);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary)
}

.stats-tab:hover {
    background: rgba(212, 168, 83, 0.1);
    color: var(--gold)
}

.stats-tab.active {
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: var(--void);
    border-color: var(--gold);
    box-shadow: 0 4px 15px var(--gold-glow)
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
    margin-bottom: var(--space-xl)
}

.stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    text-align: center;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--gold), transparent);
    opacity: 0;
    transition: opacity 0.3s
}

.stat-card:hover {
    background: rgba(212, 168, 83, 0.05);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3)
}

.stat-card:hover::before {
    opacity: 1
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-sm);
    color: var(--gold)
}

.stat-value {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--parchment)
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: var(--space-xs)
}

.stat-change {
    font-size: 0.8rem;
    margin-top: var(--space-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs)
}

.stat-change.up {
    color: var(--heat-red)
}

.stat-change.down {
    color: var(--cold-blue)
}

.chart-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    height: 450px;
    position: relative
}

.tips-section {
    padding: var(--space-3xl) 0
}

.tips-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg)
}

.tip-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden
}

.tip-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gold), var(--gold-dark));
    opacity: 0;
    transition: opacity 0.3s
}

.tip-card:hover {
    background: rgba(212, 168, 83, 0.05);
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3)
}

.tip-card:hover::before {
    opacity: 1
}

.tip-icon {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, rgba(212, 168, 83, 0.15), rgba(212, 168, 83, 0.05));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-md);
    font-size: 1.8rem;
    color: var(--gold);
    transition: all 0.3s ease
}

.tip-card:hover .tip-icon {
    transform: scale(1.15) rotate(10deg);
    background: linear-gradient(135deg, rgba(212, 168, 83, 0.25), rgba(212, 168, 83, 0.1))
}

.tip-title {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--parchment);
    margin-bottom: var(--space-sm)
}

.tip-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7
}

.tip-severity {
    display: inline-block;
    margin-top: var(--space-md);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-xl);
    font-size: 0.75rem;
    font-weight: 700
}

.tip-severity.high {
    background: rgba(231, 76, 60, 0.15);
    color: var(--heat-red)
}

.tip-severity.medium {
    background: rgba(230, 126, 34, 0.15);
    color: var(--warning)
}

.tip-severity.low {
    background: rgba(39, 174, 96, 0.15);
    color: var(--success)
}

.warnings-section {
    padding: var(--space-3xl) 0
}

.warnings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-lg)
}

.warning-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden
}

.warning-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s
}

.warning-card:hover {
    transform: translateX(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3)
}

.warning-card:hover::before {
    opacity: 1
}

.warning-card.heat::before {
    background: var(--heat-red)
}

.warning-card.cold::before {
    background: var(--cold-blue)
}

.warning-card.storm::before {
    background: var(--storm-purple)
}

.warning-card.wind::before {
    background: var(--warning)
}

.warning-card.sea::before {
    background: var(--rain-blue)
}

.warning-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-md)
}

.warning-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem
}

.warning-icon.heat {
    background: rgba(231, 76, 60, 0.15);
    color: var(--heat-red)
}

.warning-icon.cold {
    background: rgba(52, 152, 219, 0.15);
    color: var(--cold-blue)
}

.warning-icon.storm {
    background: rgba(142, 68, 173, 0.15);
    color: var(--storm-purple)
}

.warning-icon.wind {
    background: rgba(230, 126, 34, 0.15);
    color: var(--warning)
}

.warning-icon.sea {
    background: rgba(41, 128, 185, 0.15);
    color: var(--rain-blue)
}

.warning-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--parchment)
}

.warning-status {
    font-size: 0.8rem;
    color: var(--text-muted)
}

.warning-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: var(--space-md)
}

.warning-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.05)
}

.warning-time {
    font-size: 0.8rem;
    color: var(--text-muted)
}

.warning-badge {
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700
}

.warning-badge.active {
    background: rgba(231, 76, 60, 0.2);
    color: var(--heat-red)
}

.warning-badge.watch {
    background: rgba(230, 126, 34, 0.2);
    color: var(--warning)
}

.warning-badge.safe {
    background: rgba(39, 174, 96, 0.2);
    color: var(--success)
}

.news-section {
    padding: var(--space-3xl) 0
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg)
}

.news-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(212, 168, 83, 0.1);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-fast)
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(212, 168, 83, 0.2)
}

.news-image {
    height: 180px;
    overflow: hidden;
    position: relative
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease
}

.news-card:hover .news-image img {
    transform: scale(1.1)
}

.news-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(10, 14, 26, 0.9), transparent)
}

.news-content {
    padding: var(--space-lg)
}

.news-category {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: var(--space-sm)
}

.news-category.weather {
    background: rgba(212, 168, 83, 0.15);
    color: var(--gold)
}

.news-category.alert {
    background: rgba(231, 76, 60, 0.15);
    color: var(--heat-red)
}

.news-category.climate {
    background: rgba(52, 152, 219, 0.15);
    color: var(--cold-blue)
}

.news-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--parchment);
    margin-bottom: var(--space-sm);
    line-height: 1.5
}

.news-excerpt {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: var(--space-md)
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: var(--text-muted)
}

.ad-container {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(212, 168, 83, 0.2);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    text-align: center;
    margin: var(--space-xl) 0;
    position: relative
}

.ad-label {
    position: absolute;
    top: -10px;
    right: var(--space-md);
    background: var(--void);
    padding: 0 var(--space-sm);
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px
}

.ad-placeholder {
    min-height: 90px;
    display: block;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    width: 100%;
    min-height: 250px;
    overflow: hidden;
    text-align: center;
    font-size: 0.85rem
}

.ad-sidebar {
    min-height: 250px
}

.shader-container {
    width: 100%;
    height: 400px;
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin: var(--space-xl) 0;
    border: 1px solid rgba(212, 168, 83, 0.1)
}

#shaderCanvas {
    width: 100%;
    height: 100%
}

.api-status {
    position: fixed;
    bottom: 80px;
    left: 20px;
    background: rgba(10, 14, 26, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 168, 83, 0.2);
    color: var(--success);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-xl);
    font-size: 0.85rem;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-fast)
}

.api-status.error {
    color: var(--danger);
    border-color: rgba(192, 57, 43, 0.3)
}

.scroll-top {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: var(--void);
    border: none;
    border-radius: var(--radius-full);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px var(--gold-glow);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible
}

.scroll-top:hover {
    transform: scale(1.1) translateY(-3px);
    box-shadow: 0 6px 30px var(--gold-glow)
}

.site-footer {
    background: linear-gradient(180deg, var(--void-light), var(--void));
    border-top: 1px solid rgba(212, 168, 83, 0.1);
    padding: var(--space-3xl) 0 var(--space-xl);
    margin-top: var(--space-3xl);
    position: relative;
    z-index: 1
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: var(--space-3xl);
    margin-bottom: var(--space-3xl)
}

.footer-brand {
    max-width: 300px
}

.footer-brand .brand {
    margin-bottom: var(--space-md)
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.8;
    margin-bottom: var(--space-md)
}

.footer-social {
    display: flex;
    gap: var(--space-sm)
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 168, 83, 0.15);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all var(--transition-fast);
    font-size: 1rem
}

.social-link:hover {
    background: rgba(212, 168, 83, 0.15);
    color: var(--gold);
    border-color: var(--gold);
    transform: translateY(-3px)
}

.footer-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--parchment);
    margin-bottom: var(--space-lg);
    position: relative;
    padding-bottom: var(--space-sm)
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, var(--gold), transparent)
}

.footer-links {
    list-style: none
}

.footer-links li {
    margin-bottom: var(--space-sm)
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: var(--space-sm)
}

.footer-links a:hover {
    color: var(--gold);
    padding-right: var(--space-sm)
}

.footer-links a i {
    font-size: 0.7rem;
    color: var(--gold);
    opacity: 0;
    transition: opacity 0.2s
}

.footer-links a:hover i {
    opacity: 1
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    margin-bottom: var(--space-md);
    color: var(--text-secondary);
    font-size: 0.9rem
}

.footer-contact-item i {
    color: var(--gold);
    margin-top: 4px;
    font-size: 0.9rem
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: var(--space-xl);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-md)
}

.footer-copyright {
    font-size: 0.85rem;
    color: var(--text-muted)
}

.footer-copyright a {
    color: var(--gold);
    text-decoration: none
}

.footer-copyright a:hover {
    text-decoration: underline
}

.spinner {
    display: inline-block;
    width: 24px;
    height: 24px;
    border: 2px solid rgba(212, 168, 83, 0.2);
    border-top-color: var(--gold);
    border-radius: var(--radius-full);
    animation: spin 0.8s linear infinite
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.slide-up {
    animation: slideUp 0.5s ease forwards
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

@media(max-width:1200px) {
    .forecast-grid {
        grid-template-columns: repeat(4, 1fr)
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-xl)
    }
}

@media(max-width:992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center
    }

    .hero-content {
        text-align: center
    }

    .hero-subtitle {
        margin: 0 auto var(--space-xl)
    }

    .hero-stats {
        justify-content: center
    }

    .weather-cube-container {
        margin-bottom: var(--space-xl)
    }

    .forecast-grid {
        grid-template-columns: repeat(3, 1fr)
    }

    .tips-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .warnings-grid {
        grid-template-columns: 1fr
    }

    .news-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .sea-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .footer-grid {
        grid-template-columns: 1fr
    }
}

@media(max-width:768px) {
    .header-inner {
        padding: 0 var(--space-md)
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--void-light);
        padding: var(--space-md);
        border-bottom: 1px solid rgba(212, 168, 83, 0.1)
    }

    .main-nav.active {
        display: block
    }

    .nav-list {
        flex-direction: column;
        gap: var(--space-xs)
    }

    .mobile-menu-btn {
        display: block
    }

    .search-input {
        width: 180px
    }

    .search-input:focus {
        width: 200px
    }

    .hero-title {
        font-size: 2.2rem
    }

    .weather-details-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .forecast-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .stats-grid {
        grid-template-columns: 1fr
    }

    .tips-grid {
        grid-template-columns: 1fr
    }

    .news-grid {
        grid-template-columns: 1fr
    }

    .sea-grid {
        grid-template-columns: 1fr
    }

    .sea-tips-list {
        grid-template-columns: 1fr
    }

    .map-wrapper {
        height: 350px
    }

    .section-title {
        font-size: 1.4rem
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center
    }

    .footer-brand {
        max-width: 100%
    }

    .footer-social {
        justify-content: center
    }

    .footer-title::after {
        right: 50%;
        transform: translateX(50%)
    }

    .footer-links a {
        justify-content: center
    }

    .footer-contact-item {
        justify-content: center
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center
    }
}

@media(max-width:480px) {
    .forecast-grid {
        grid-template-columns: 1fr
    }

    .weather-temp {
        font-size: 3.5rem
    }

    .hero-title {
        font-size: 1.8rem
    }

    .weather-cube-container {
        width: 200px;
        height: 200px
    }

    .cube-face {
        width: 200px;
        height: 200px
    }

    .cube-face.front {
        transform: translateZ(100px)
    }

    .cube-face.back {
        transform: rotateY(180deg) translateZ(100px)
    }

    .cube-face.right {
        transform: rotateY(90deg) translateZ(100px)
    }

    .cube-face.left {
        transform: rotateY(-90deg) translateZ(100px)
    }

    .cube-face.top {
        transform: rotateX(90deg) translateZ(100px)
    }

    .cube-face.bottom {
        transform: rotateX(-90deg) translateZ(100px)
    }
}

.hidden {
    display: none !important
}

.text-center {
    text-align: center
}

.mb-0 {
    margin-bottom: 0
}

.mt-xl {
    margin-top: var(--space-xl)
}





@media (max-width:768px) {

    .header-inner {
        display: grid;
        grid-template-columns: auto 1fr auto;
        gap: 8px;
        align-items: center;
    }

    .brand-text {
        display: none;
    }

    .header-controls {
        display: flex;
        align-items: center;
        width: 100%;
        min-width: 0;
        gap: 6px;
    }

    .search-wrapper {
        flex: 1;
        min-width: 0;
    }

    .search-input {
        width: 100%;
        min-width: 0;
    }

    .search-input:focus {
        width: 100%;
    }

    #locationBtn {
        flex-shrink: 0;
        width: 38px;
        height: 38px;
    }

    .mobile-menu-btn {
        flex-shrink: 0;
    }
}

@media (max-width:480px) {

    .brand-icon {
        width: 36px;
        height: 36px;
    }

    #locationBtn {
        width: 34px;
        height: 34px;
    }

    .search-input {
        font-size: 16px;
        padding: 0.55rem 2rem 0.55rem 0.8rem;
    }
}

/* Keyboard accessibility and reduced-motion support */
:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}


/* Responsive safeguards for narrow phones and embedded ad units */
@media (max-width: 768px) {
    .header-inner { grid-template-columns: auto auto minmax(0, 1fr); gap: 8px; }
    .header-controls, .search-wrapper, .search-input, .container, .hero-grid,
    .weather-card, .weather-details-grid, .forecast-grid, .stats-grid, .tips-grid,
    .news-grid, .sea-grid, .warnings-grid, .map-wrapper, .ad-container, .ad-placeholder {
        min-width: 0; max-width: 100%;
    }
    .header-controls { width: 100%; }
    .search-input, .search-input:focus { width: 100%; }
    .weather-card { padding: var(--space-md); }
    .chart-container {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        padding: 12px;
        overflow: hidden;
    }
    .chart-container canvas {
        display: block;
        width: 100% !important;
        max-width: 100%;
    }
    .weather-card-header, .weather-main, .section-header, .hero-stats { flex-wrap: wrap; }
    .weather-location, .weather-city { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
    .hero-stat { min-width: 0; flex: 1 1 90px; }
    .ad-placeholder, ins.adsbygoogle { width: 100%; }
}
@media (max-width: 380px) {
    .header-inner { padding-inline: 10px; gap: 6px; }
    .brand-icon { width: 32px; height: 32px; }
    #locationBtn { width: 32px; height: 32px; }
    .weather-card { padding: 12px; border-radius: var(--radius-md); }
    .hero-title { font-size: 1.65rem; }
    .section-title { font-size: 1.2rem; }
}


/* Header and city search usability refinements */
.site-header.hidden {
    transform: translateY(0);
}

.city-suggestions {
    padding: 6px;
    overscroll-behavior: contain;
}

.city-suggestion-item {
    display: flex;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-primary);
    text-align: right;
    font: inherit;
    cursor: pointer;
}

.city-suggestion-item[aria-selected="true"],
.city-suggestion-item:hover {
    background: rgba(212, 168, 83, 0.14);
}

.city-suggestion-item:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: -2px;
}


.city-suggestion-status{padding:7px 12px;color:var(--text-muted);font-size:.75rem;text-align:center;border-top:1px solid rgba(255,255,255,.06)}
.city-suggestion-empty {
    padding: var(--space-md);
    color: var(--text-secondary);
    font-size: 0.88rem;
}

@media (min-width: 769px) and (max-width: 1100px) {
    .header-inner { gap: 10px; }
    .nav-link { padding-inline: 8px; font-size: 0.85rem; }
    .search-input { width: 190px; }
    .search-input:focus { width: 210px; }
}

@media (max-width: 768px) {
    .main-nav {
        max-height: calc(100dvh - 80px);
        overflow-y: auto;
        overscroll-behavior: contain;
        box-shadow: var(--shadow-lg);
    }
    .city-suggestions {
        max-height: min(280px, 45dvh);
    }
}

@media (max-width: 380px) {
    .header-inner { gap: 6px; }
    .brand-icon { width: 32px; height: 32px; }
    .search-input { padding-inline: 1.8rem 0.65rem; }
}


/* Mobile-first header hierarchy and edge-to-edge section cards */
@media (max-width: 768px) {
    .site-header {
        transform: none;
        background: rgba(10, 14, 26, 0.97);
    }

    .site-header.hidden {
        transform: none;
    }

    .header-inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "brand menu"
            "controls controls";
        align-items: center;
        gap: 8px 12px;
        width: 100%;
        height: auto;
        min-height: 0;
        padding: 9px 12px 12px;
    }

    .header-inner > .brand {
        grid-area: brand;
        justify-self: start;
        min-width: 0;
    }

    .brand-icon {
        width: 38px;
        height: 38px;
    }

    .brand-text {
        display: flex;
    }

    .brand-name {
        font-size: 0.95rem;
    }

    .brand-tagline {
        font-size: 0.62rem;
        letter-spacing: 0;
    }

    .mobile-menu-btn {
        grid-area: menu;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 42px;
        height: 42px;
        padding: 0;
        border: 1px solid rgba(212, 168, 83, 0.18);
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.045);
        font-size: 1.25rem;
    }

    .header-controls {
        grid-area: controls;
        display: flex;
        width: 100%;
        min-width: 0;
        gap: 8px;
    }

    .search-wrapper {
        flex: 1 1 auto;
        min-width: 0;
    }

    .search-input,
    .search-input:focus {
        display: block;
        width: 100%;
        min-width: 0;
        height: 44px;
        padding: 0.55rem 2.5rem 0.55rem 0.8rem;
        font-size: 16px;
    }

    .search-icon {
        right: 14px;
    }

    #locationBtn {
        flex: 0 0 44px;
        width: 44px;
        height: 44px;
        border-radius: 13px;
    }

    .main-nav {
        top: 100%;
        left: 0;
        right: 0;
        width: 100%;
        border-top: 1px solid rgba(212, 168, 83, 0.12);
        border-radius: 0 0 16px 16px;
    }

    .main-content {
        padding-top: 124px;
    }

    .alert-banner {
        top: 124px;
    }

    .container {
        width: 100%;
        max-width: 100%;
        padding-inline: 12px;
    }

    /* Nested section containers previously doubled the horizontal gutters. */
    .container .container {
        width: 100%;
        max-width: 100%;
        padding-inline: 0;
    }

    .hero-section {
        padding: 24px 0 18px;
    }

    .hero-grid {
        gap: 14px;
    }

    .hero-title {
        font-size: clamp(1.75rem, 7vw, 2.2rem);
        line-height: 1.35;
    }

    .hero-subtitle {
        max-width: 100%;
        margin-bottom: 18px;
        font-size: clamp(1rem, 4.2vw, 1.2rem);
        line-height: 1.75;
    }

    .section-actions {
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
    }

    .section-actions .btn {
        flex: 1 1 140px;
        justify-content: center;
        min-width: 0;
        padding-inline: 10px;
    }

    .hero-stats {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        align-items: start;
        gap: 8px;
        margin-top: 20px;
    }

    .hero-stat {
        min-width: 0;
        padding: 8px 4px;
        border: 1px solid rgba(212, 168, 83, 0.1);
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.025);
    }

    .hero-stat-value {
        font-size: clamp(1.15rem, 5vw, 1.55rem);
        line-height: 1.35;
        white-space: nowrap;
    }

    .hero-stat-label {
        font-size: 0.72rem;
        line-height: 1.4;
    }

    .weather-card,
    .map-container,
    .sea-card,
    .warning-card,
    .tip-card,
    .stat-card,
    .forecast-card,
    .news-card {
        min-width: 0;
        max-width: 100%;
    }

    .weather-card {
        padding: 14px;
    }

    .weather-details-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .detail-card,
    .sea-item,
    .stat-card,
    .forecast-card {
        padding: 12px 8px;
    }

    .forecast-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .stats-grid,
    .tips-grid,
    .warnings-grid,
    .news-grid,
    .sea-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .section-header {
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 16px;
    }

    .section-title {
        min-width: 0;
        font-size: 1.25rem;
        line-height: 1.45;
    }

    .hourly-section,
    .forecast-section,
    .map-section,
    .stats-section,
    .tips-section,
    .warnings-section {
        padding-block: 22px;
    }
}

@media (max-width: 380px) {
    .header-inner {
        padding-inline: 10px;
        gap: 7px 8px;
    }

    .brand-icon {
        width: 34px;
        height: 34px;
    }

    .brand-name {
        font-size: 0.88rem;
    }

    .brand-tagline {
        display: none;
    }

    .container {
        padding-inline: 9px;
    }

    .hero-stats {
        gap: 5px;
    }

    .hero-stat-value {
        font-size: 1.05rem;
    }

    .hero-stat-label {
        font-size: 0.66rem;
    }

    .forecast-grid,
    .stats-grid,
    .tips-grid,
    .warnings-grid,
    .news-grid,
    .sea-grid {
        gap: 7px;
    }
}


/* Collapse empty AdSense placements so reserved ad space never obscures page content. */
/* Hide a placement only after AdSense has completed the request and confirmed it is unfilled. */
.ad-container:has(ins.adsbygoogle[data-ad-status="unfilled"][data-adsbygoogle-status="done"]),
.ad-container:has(.ad-placeholder ins.adsbygoogle[data-ad-status="unfilled"][data-adsbygoogle-status="done"]) {
    display: none !important;
    min-height: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
}

.ad-container:has(ins.adsbygoogle[data-ad-status="unfilled"][data-adsbygoogle-status="done"]) .ad-placeholder,
.ad-container:has(.ad-placeholder ins.adsbygoogle[data-ad-status="unfilled"][data-adsbygoogle-status="done"]) .ad-placeholder {
    display: none !important;
    min-height: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}


/* Detailed current-weather metrics: compact, readable cards across screen sizes. */
.weather-details-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.detail-card {
    min-width: 0;
    overflow-wrap: anywhere;
}
.detail-card-value {
    font-size: clamp(1rem, 2.2vw, 1.3rem);
    line-height: 1.5;
}
.detail-card-label {
    line-height: 1.5;
}
@media (max-width: 768px) {
    .weather-details-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 360px) {
    .detail-card { padding: 10px 6px; }
    .detail-card-icon { font-size: 1.25rem; }
    .detail-card-value { font-size: 0.98rem; }
    .detail-card-label { font-size: 0.74rem; }
}


/* Weather risk indicators and saved locations */
.warnings-disclaimer {
    margin: -8px 0 18px;
    padding: 10px 14px;
    border: 1px solid rgba(230, 126, 34, 0.22);
    border-radius: var(--radius-md);
    background: rgba(230, 126, 34, 0.07);
    color: var(--text-secondary);
    font-size: 0.84rem;
    line-height: 1.7;
}
.warning-card.severity-high { border-color: rgba(231, 76, 60, 0.35); }
.warning-card.severity-medium { border-color: rgba(230, 126, 34, 0.28); }
.warning-card.severity-high::before { opacity: 1; background: var(--danger); }
.warning-card.severity-medium::before { opacity: 1; background: var(--warning); }
.warning-source {
    margin-top: 10px;
    color: var(--text-muted);
    font-size: 0.75rem;
    line-height: 1.6;
}
.warning-source a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.warning-empty { grid-column: 1 / -1; }
.favorite-current-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    flex: 0 0 auto;
    padding: 9px 13px;
    border: 1px solid rgba(212, 168, 83, 0.28);
    border-radius: 12px;
    background: rgba(212, 168, 83, 0.08);
    color: var(--gold-light);
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: background var(--transition-fast), border-color var(--transition-fast);
}
.favorite-current-btn:hover,
.favorite-current-btn.is-saved {
    background: rgba(212, 168, 83, 0.16);
    border-color: var(--gold);
}
.favorite-cities-panel {
    position: relative;
    z-index: 1;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid rgba(212, 168, 83, 0.14);
}
.favorite-cities-panel[hidden] { display: none !important; }
.favorite-cities-heading {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--gold-light);
    font-size: 0.9rem;
    font-weight: 700;
}
.favorite-cities-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.favorite-city-item {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    overflow: hidden;
    border: 1px solid rgba(212, 168, 83, 0.18);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.035);
}
.favorite-city-select {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 7px 10px;
    border: 0;
    background: transparent;
    color: var(--text-primary);
    text-align: right;
    font: inherit;
    cursor: pointer;
}
.favorite-city-select > span {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.35;
}
.favorite-city-select strong { font-size: 0.82rem; }
.favorite-city-select small { color: var(--text-muted); font-size: 0.68rem; }
.favorite-city-remove {
    align-self: stretch;
    width: 32px;
    border: 0;
    border-right: 1px solid rgba(212, 168, 83, 0.12);
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
}
.favorite-city-remove:hover { color: var(--danger); background: rgba(231, 76, 60, 0.08); }
@media (max-width: 600px) {
    .warnings-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
    .warning-card { padding: 16px; }
    .favorite-current-btn { padding: 8px 10px; font-size: 0.76rem; }
    .favorite-cities-list { gap: 6px; }
    .favorite-city-item { flex: 1 1 140px; }
}
@media (max-width: 380px) {
    .weather-card-header { gap: 10px; }
    .favorite-current-btn { max-width: 116px; }
    .favorite-city-item { flex-basis: 100%; }
}

/* الأقسام المتخصصة */
.specialized-section{padding:var(--space-3xl) 0;position:relative}.specialized-intro{color:var(--text-secondary);margin:-.5rem 0 var(--space-xl);max-width:760px}.specialized-location{font-size:.85rem;color:var(--gold);background:rgba(212,168,83,.09);border:1px solid rgba(212,168,83,.18);border-radius:999px;padding:.35rem .8rem}.specialized-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-lg)}.specialized-card{min-width:0;padding:var(--space-xl);border:1px solid rgba(212,168,83,.16);border-radius:var(--radius-lg);background:linear-gradient(145deg,rgba(30,58,95,.48),rgba(10,14,26,.82));box-shadow:var(--shadow-sm)}.specialized-card-head{display:flex;align-items:center;gap:var(--space-md);margin-bottom:var(--space-lg)}.specialized-icon{width:48px;height:48px;flex:0 0 48px;display:grid;place-items:center;border-radius:14px;background:rgba(212,168,83,.12);color:var(--gold);font-size:1.35rem}.specialized-card h3{font-family:var(--font-display);font-size:1.15rem;color:var(--parchment);line-height:1.45}.specialized-card-head p{font-size:.82rem;color:var(--text-muted)}.specialized-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--space-sm)}.specialized-metrics>div{min-width:0;padding:.8rem .45rem;text-align:center;border:1px solid rgba(255,255,255,.06);border-radius:var(--radius-md);background:rgba(255,255,255,.035)}.specialized-metrics strong{display:block;color:var(--gold-light);font-size:1.35rem;font-weight:800;line-height:1.5;overflow-wrap:anywhere}.specialized-metrics span{display:block;color:var(--text-muted);font-size:.72rem;line-height:1.5}.specialized-advice{margin:var(--space-md) 0 .5rem;color:var(--text-secondary);font-size:.88rem;min-height:2.8em}.specialized-source{display:block;color:var(--text-muted);font-size:.7rem;line-height:1.6}.specialized-disclaimer{margin-top:var(--space-lg);padding:var(--space-md);border-right:3px solid var(--gold-dark);background:rgba(212,168,83,.055);border-radius:var(--radius-sm);color:var(--text-muted);font-size:.8rem}.specialized-card.is-unavailable .specialized-advice{color:var(--warning)}@media(max-width:760px){.specialized-section{padding:var(--space-2xl) 0}.specialized-grid{grid-template-columns:minmax(0,1fr);gap:var(--space-md)}.specialized-card{padding:var(--space-md)}.specialized-card h3{font-size:1rem}.specialized-metrics strong{font-size:1.2rem}.specialized-metrics span{font-size:.68rem}.specialized-location{font-size:.72rem;white-space:nowrap}.specialized-section .section-header{gap:var(--space-sm);align-items:center}.specialized-section .section-title{font-size:1.35rem}}


/* توحيد عرض بطاقات التوقعات مع عرض حاوية الصفحة على الشاشات الكبيرة */
@media (min-width: 1201px) {
    .hourly-section .container,
    .forecast-section .container {
        width: 100%;
        max-width: 1400px;
        margin-inline: auto;
    }
    .hourly-container {
        display: grid;
        grid-template-columns: repeat(8, minmax(0, 1fr));
        min-width: 0;
        width: 100%;
        gap: var(--space-md);
    }
    .hourly-card {
        min-width: 0;
        width: 100%;
        padding: var(--space-md) var(--space-sm);
    }
    .forecast-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        width: 100%;
        gap: var(--space-md);
    }
    .forecast-card {
        min-width: 0;
        padding: var(--space-lg) var(--space-md);
    }
}
@media (min-width: 993px) and (max-width: 1200px) {
    .hourly-container {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        min-width: 0;
        width: 100%;
    }
    .hourly-card { min-width: 0; }
    .forecast-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}


/* Dynamic weather tips */
.tips-intro {
    margin-top: 0.35rem;
    color: var(--text-secondary);
    font-size: 0.88rem;
    line-height: 1.6;
}
.tips-live-status {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--text-muted);
    font-size: 0.78rem;
    white-space: nowrap;
}
.tips-live-status .fa-check-circle { color: var(--success); }
.tips-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
    align-items: stretch;
}
.tip-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    height: 100%;
}
.tip-card .tip-text { flex: 1; }
.tip-card.severity-high { border-color: rgba(231, 76, 60, 0.28); }
.tip-card.severity-medium { border-color: rgba(230, 126, 34, 0.24); }
.tip-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: var(--space-md);
}
.tip-card-meta .tip-severity { margin-top: 0; }
.tip-timing {
    color: var(--text-muted);
    font-size: 0.74rem;
}
.tip-card[data-tip-extra][hidden] { display: none !important; }
.tip-card-loading { min-height: 190px; }
.tips-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin-top: var(--space-lg);
}
.tips-disclaimer {
    color: var(--text-muted);
    font-size: 0.76rem;
    line-height: 1.6;
}
.tips-toggle { white-space: nowrap; }
@media (max-width: 640px) {
    .tips-section { padding: var(--space-xl) 0; }
    .tips-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-md); }
    .tip-card { padding: var(--space-lg); }
    .tips-footer { align-items: stretch; }
    .tips-footer .btn { width: 100%; justify-content: center; }
    .tips-live-status { align-self: flex-start; }
}


/* AdSense: حظر أي إعلان داخل الهيدر مع إبقاء الحاويات الإعلانية في المحتوى. */
.site-header .google-auto-placed,
.site-header ins.adsbygoogle,
.site-header iframe[id^="google_ads_iframe"],
.site-header iframe[src*="doubleclick.net"] {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    overflow: hidden !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* وحدات AdSense لا تأخذ مساحة إلا داخل حاوياتها المخصصة. */
.ad-container ins.adsbygoogle {
    display: block;
    max-width: 100%;
}


/* Live data status for the rotating weather cube. */
.weather-cube-status {
    margin: 12px auto 0;
    max-width: 320px;
    color: var(--text-muted);
    font-size: .76rem;
    line-height: 1.6;
    text-align: center;
}
.cube-face .cube-label {
    max-width: 90%;
    text-align: center;
    line-height: 1.5;
}
@media (max-width: 600px) {
    .weather-cube-container { width: 240px; height: 240px; }
    .cube-face { width: 240px; height: 240px; }
    .cube-face.front { transform: translateZ(120px); }
    .cube-face.back { transform: rotateY(180deg) translateZ(120px); }
    .cube-face.right { transform: rotateY(90deg) translateZ(120px); }
    .cube-face.left { transform: rotateY(-90deg) translateZ(120px); }
    .cube-face.top { transform: rotateX(90deg) translateZ(120px); }
    .cube-face.bottom { transform: rotateX(-90deg) translateZ(120px); }
}

/* Search-focused editorial content and contact links */
.seo-guide-section { padding: var(--space-3xl) 0; background: rgba(255,255,255,.015); border-top: 1px solid rgba(212,168,83,.12); }
.seo-guide-lead { color: var(--text-secondary); max-width: 760px; line-height: 1.9; margin: var(--space-md) 0; }
.seo-guide-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: var(--space-lg); margin: var(--space-xl) 0; }
.seo-guide-card, .seo-guide-search, .seo-guide-faq { background: rgba(255,255,255,.035); border: 1px solid rgba(212,168,83,.14); border-radius: var(--radius-md); padding: var(--space-lg); }
.seo-guide-card h3, .seo-guide-search h3, .seo-guide-faq h3 { color: var(--parchment); font-size: 1.05rem; margin-bottom: var(--space-sm); }
.seo-guide-card p, .seo-guide-search p, .seo-guide-faq details p { color: var(--text-secondary); line-height: 1.9; font-size: .94rem; }
.seo-guide-search { margin-bottom: var(--space-lg); }
.seo-guide-faq details { border-top: 1px solid rgba(255,255,255,.08); padding: var(--space-md) 0; }
.seo-guide-faq summary { color: var(--parchment); cursor: pointer; font-weight: 700; }
.seo-guide-faq details p { margin-top: var(--space-sm); }
.footer-contact-item a { color: var(--text-secondary); text-decoration: none; overflow-wrap: anywhere; }
.footer-contact-item a:hover { color: var(--gold); }
@media(max-width:640px) { .seo-guide-grid { grid-template-columns: 1fr; } }

/* روابط دليل صفحات الطقس */
.city-discovery-section{padding:var(--space-3xl) 0;background:rgba(255,255,255,.015);border-top:1px solid rgba(212,168,83,.12)}.city-discovery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--space-lg)}.city-discovery-card{display:flex;flex-direction:column;gap:.45rem;padding:1.2rem;border:1px solid rgba(212,168,83,.2);border-radius:var(--radius-md);background:rgba(255,255,255,.035);color:var(--parchment);text-decoration:none;min-width:0}.city-discovery-card strong{color:var(--gold-light)}.city-discovery-card span{color:var(--text-muted);font-size:.85rem;line-height:1.7}.city-discovery-card:hover{border-color:var(--gold)}@media(max-width:640px){.city-discovery-grid{grid-template-columns:1fr;gap:var(--space-md)}}


/* Main navigation: direct links to the three weather directories. */
.main-nav .nav-list { flex-wrap: wrap; }
.main-nav .nav-link { white-space: nowrap; }
@media (max-width: 1100px) {
    .main-nav .nav-list { gap: 6px 10px; }
    .main-nav .nav-link { font-size: .84rem; }
}

/* Image-led weather directory cards. Images are served locally from /images/. */
.city-discovery-grid { align-items: stretch; }
.city-discovery-card {
    display: flex; flex-direction: column; gap: 0; padding: 0; overflow: hidden;
    border-radius: var(--radius-lg);
    background: linear-gradient(155deg, rgba(30,58,95,.42), rgba(10,14,26,.88));
    box-shadow: var(--shadow-sm);
    transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}
.city-discovery-card:hover {
    transform: translateY(-4px); border-color: var(--gold); box-shadow: var(--shadow-md);
}
.city-discovery-image {
    position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden;
    background: rgba(255,255,255,.05);
}
.city-discovery-image::after {
    content: ""; position: absolute; inset: 45% 0 0;
    background: linear-gradient(180deg, transparent, rgba(7,12,23,.58));
    pointer-events: none;
}
.city-discovery-image img {
    display: block; width: 100%; height: 100%; object-fit: cover;
    transition: transform .45s ease;
}
.city-discovery-card:hover .city-discovery-image img { transform: scale(1.045); }
.city-discovery-content {
    display: flex; flex: 1; flex-direction: column; align-items: flex-start;
    gap: .55rem; padding: 1.1rem 1.2rem 1.2rem;
}
.city-discovery-content strong { color: var(--gold-light); font-size: 1.05rem; line-height: 1.6; }
.city-discovery-content > span:not(.city-discovery-action) {
    color: var(--text-muted); font-size: .85rem; line-height: 1.7;
}
.city-discovery-content .city-discovery-action {
    display: inline-flex; align-items: center; gap: .5rem; margin-top: auto;
    padding-top: .45rem; color: var(--gold); font-size: .82rem; font-weight: 700;
}
.city-discovery-action i { transition: transform .2s ease; }
.city-discovery-card:hover .city-discovery-action i { transform: translateX(-4px); }
@media (max-width: 640px) {
    .city-discovery-grid { grid-template-columns: minmax(0,1fr); }
    .city-discovery-card { display: grid; grid-template-columns: minmax(112px,38%) minmax(0,1fr); }
    .city-discovery-image { height: 100%; min-height: 132px; aspect-ratio: auto; }
    .city-discovery-content { justify-content: center; padding: .85rem; gap: .35rem; }
    .city-discovery-content strong { font-size: .92rem; }
    .city-discovery-content > span:not(.city-discovery-action) { font-size: .76rem; }
    .city-discovery-content .city-discovery-action { font-size: .74rem; padding-top: .25rem; }
}
@media (max-width: 360px) {
    .city-discovery-card { grid-template-columns: 104px minmax(0,1fr); }
    .city-discovery-image { min-height: 124px; }
    .city-discovery-content { padding: .7rem; }
}


/* Unified main navigation: keep desktop links on one horizontal line. */
@media (min-width: 769px) {
    .main-nav {
        flex: 0 1 auto;
        min-width: 0;
        max-width: min(56vw, 780px);
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        white-space: nowrap;
    }
    .main-nav::-webkit-scrollbar { display: none; }
    .main-nav .nav-list {
        display: flex;
        flex-wrap: nowrap;
        width: max-content;
        min-width: max-content;
        gap: 2px;
    }
    .main-nav .nav-link {
        display: block;
        padding: .48rem .58rem;
        font-size: clamp(.72rem, .78vw, .86rem);
        white-space: nowrap;
    }
}
@media (max-width: 768px) {
    .main-nav .nav-list { flex-wrap: wrap; }
    .main-nav .nav-link { white-space: nowrap; }
}


/* Accessible image-led discovery cards. */
.city-discovery-image img{object-position:center 45%;}
.city-discovery-card:focus-visible{outline:3px solid var(--gold);outline-offset:3px;}


/* Slightly larger, equal-height weather discovery cards. */
.city-discovery-grid{grid-auto-rows:1fr;align-items:stretch;}
.city-discovery-card{height:100%;min-height:340px;}
.city-discovery-image{aspect-ratio:16/10;}
.city-discovery-content{padding:1.25rem 1.3rem 1.35rem;gap:.62rem;}
@media(max-width:640px){.city-discovery-card{min-height:164px;}.city-discovery-image{min-height:150px;}}
@media(max-width:360px){.city-discovery-card{min-height:154px;}.city-discovery-image{min-height:140px;}}


/* Shared width boundary for primary ad placements across the homepage and generated pages. */
.ad-placement-wrap {
    width: min(100%, calc(100vw - 48px), 1180px);
    max-width: 100%;
    margin-inline: auto;
    padding: 0;
}

/* Consistent AdSense presentation: visible, centered and responsive without oversized blank gaps. */
.ad-container {
    width: min(100%, 970px);
    max-width: calc(100% - 24px);
    margin: clamp(18px, 3vw, 30px) auto;
    padding: 14px 16px 12px;
    overflow: hidden;
    border: 1px solid rgba(212, 168, 83, 0.28);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.035);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.ad-container {
    display: block;
    width: 100%;
    min-width: 0;
    max-width: min(970px, calc(100% - 24px));
    margin-inline: auto;
    overflow: visible;
    box-sizing: border-box;
}
.ad-container .ad-placeholder {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: clamp(90px, 18vw, 180px);
    overflow: visible;
    box-sizing: border-box;
}
.ad-container ins.adsbygoogle {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    min-height: 90px;
    margin-inline: auto;
    box-sizing: border-box;
}
.ad-container .ad-label {
    z-index: 1;
    top: -9px;
    right: 16px;
    padding: 0 9px;
    border-radius: 6px;
    background: var(--void);
}
.ad-container[data-ad-placement="footer"] {
    margin-top: clamp(22px, 3vw, 34px);
    margin-bottom: clamp(22px, 3vw, 34px);
}
@media (max-width: 600px) {
    .ad-container {
        max-width: calc(100% - 20px);
        margin-block: 16px;
        padding: 10px 8px;
        border-radius: 12px;
    }
    .ad-container .ad-placeholder {
        min-height: 90px;
    }
    .ad-container .ad-label {
        right: 10px;
    }
}


/* Five-day weather statistics: compact, readable cards on tablets and phones. */
.stats-section .stats-period-note {
    margin: -8px 0 18px;
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.6;
}
.stats-section .stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(10px, 1.5vw, 18px);
    align-items: stretch;
}
.stats-section .stat-card {
    display: flex;
    min-width: 0;
    min-height: 164px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: clamp(14px, 2vw, 22px) 12px;
    border-color: rgba(212, 168, 83, 0.2);
    border-radius: 18px;
    background: linear-gradient(155deg, rgba(30, 58, 95, 0.34), rgba(255, 255, 255, 0.025));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
}
.stats-section .stat-icon {
    display: grid;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    place-items: center;
    margin: 0;
    border: 1px solid rgba(212, 168, 83, 0.2);
    border-radius: 14px;
    background: rgba(212, 168, 83, 0.09);
    font-size: 1.25rem;
}
.stats-section .stat-value {
    max-width: 100%;
    color: var(--parchment);
    font-size: clamp(1.45rem, 2.4vw, 2rem);
    line-height: 1.25;
    font-variant-numeric: tabular-nums;
    overflow-wrap: anywhere;
}
.stats-section .stat-label {
    max-width: 100%;
    margin: 0;
    color: var(--text-secondary);
    font-size: clamp(0.76rem, 1vw, 0.9rem);
    line-height: 1.5;
    text-wrap: balance;
}
@media (max-width: 1024px) {
    .stats-section .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }
    .stats-section .stat-card { min-height: 150px; }
}
@media (max-width: 600px) {
    .stats-section { padding-block: 24px; }
    .stats-section .stats-period-note {
        margin: -4px 0 14px;
        font-size: 0.78rem;
    }
    .stats-section .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 9px;
        margin-bottom: 18px;
    }
    .stats-section .stat-card {
        min-height: 132px;
        gap: 6px;
        padding: 12px 7px;
        border-radius: 14px;
    }
    .stats-section .stat-icon {
        width: 36px;
        height: 36px;
        flex-basis: 36px;
        border-radius: 11px;
        font-size: 1.05rem;
    }
    .stats-section .stat-value { font-size: clamp(1.25rem, 6vw, 1.65rem); }
    .stats-section .stat-label { font-size: 0.74rem; }
}
@media (max-width: 360px) {
    .stats-section .stats-grid { gap: 7px; }
    .stats-section .stat-card { min-height: 124px; padding-inline: 5px; }
    .stats-section .stat-value { font-size: 1.18rem; }
    .stats-section .stat-label { font-size: 0.69rem; }
}
@media (hover: none) {
    .stats-section .stat-card:hover { transform: none; box-shadow: none; }
}


/* Mobile navigation and viewport overflow hardening. */
html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: clip;
}

.site-header,
.header-inner {
    max-width: 100%;
    min-width: 0;
}

.header-inner {
    width: 100%;
    gap: 10px;
}

.brand {
    min-width: 0;
    max-width: calc(100% - 58px);
}

.brand-text {
    min-width: 0;
}

.mobile-menu-btn {
    flex: 0 0 44px;
    width: 44px;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1002;
    touch-action: manipulation;
}

@media (max-width: 768px) {
    .header-inner {
        padding-inline: 12px;
    }

    .main-nav,
    .main-nav.active {
        position: absolute;
        top: 72px;
        inset-inline: 0;
        z-index: 1001;
        display: none;
        width: 100%;
        max-width: 100%;
        max-height: calc(100vh - 72px);
        max-height: calc(100dvh - 72px);
        min-width: 0;
        margin: 0;
        padding: 12px 14px 18px;
        overflow-x: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
        box-sizing: border-box;
        background: rgba(10, 14, 26, 0.98);
        border-top: 1px solid rgba(212, 168, 83, 0.16);
        box-shadow: 0 14px 28px rgba(0, 0, 0, 0.32);
        white-space: normal;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav .nav-list {
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;
        width: 100%;
        min-width: 0;
        gap: 4px;
    }

    .main-nav .nav-list > li {
        width: 100%;
        min-width: 0;
    }

    .main-nav .nav-link {
        display: flex;
        align-items: center;
        width: 100%;
        min-width: 0;
        padding: 11px 12px;
        white-space: normal;
        overflow-wrap: anywhere;
    }
}

@media (max-width: 360px) {
    .header-inner {
        padding-inline: 9px;
    }

    .brand-name {
        font-size: 1.16rem;
    }

    .brand-tagline {
        font-size: 0.62rem;
        letter-spacing: 0;
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
    }
}
