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

body{
    font-family:Arial, Helvetica, sans-serif;
    background:#eef2f5;
    color:#222;
}

header{
    background:#0b4f8a;
    color:white;
    padding:25px;
}

.site-title h1{
    font-size:2.3rem;
}

.site-title p{
    margin-top:6px;
}

nav{
    background:#13395f;
    position:relative;
}

.nav-links{
    display:flex;
    flex-wrap:wrap;
}

.nav-links a{
    color:white;
    text-decoration:none;
    padding:15px 20px;
}

.nav-links a:hover{
    background:#1b5d9c;
}

.nav-toggle{
    display:none;
    flex-direction:column;
    justify-content:center;
    gap:5px;
    width:44px;
    height:44px;
    background:none;
    border:none;
    cursor:pointer;
    padding:0;
}

.nav-toggle span{
    display:block;
    height:3px;
    width:100%;
    background:white;
    border-radius:2px;
}

main{
    width:min(1200px,95%);
    margin:auto;
    padding:30px 0;
}

.card-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
    gap:20px;
    margin-top:30px;
}

.card{
    background:white;
    border-radius:8px;
    padding:20px;
    box-shadow:0 2px 8px rgba(0,0,0,.12);
}

.placeholder{
    margin-top:20px;
    padding:20px;
    background:white;
    border-left:5px solid steelblue;
}

.radar-box{
    height:600px;
    border:3px dashed #888;
    display:flex;
    align-items:center;
    justify-content:center;
    background:white;
}

footer{
    text-align:center;
    padding:20px;
    background:#13395f;
    color:white;
    margin-top:50px;
}

.dashboard{
    display:flex;
    flex-direction:column;
    gap:25px;
}

.hero{
    background:#ffffff;
    padding:25px;
    border-radius:8px;
    box-shadow:0 2px 6px rgba(0,0,0,.1);
}

.top-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(320px,1fr));
    gap:20px;
}

.bottom-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
    gap:20px;
}

.panel{
    background:white;
    padding:20px;
    border-radius:8px;
    box-shadow:0 2px 6px rgba(0,0,0,.1);
}

.big-temp{
    font-size:4rem;
    font-weight:bold;
    margin:15px 0;
}

.panel table{
    width:100%;
    border-collapse:collapse;
}

.panel td{
    padding:6px 0;
    border-bottom:1px solid #eee;
}

.radar-placeholder{
    height:450px;
    display:flex;
    align-items:center;
    justify-content:center;
    border:3px dashed #888;
    margin-top:15px;
}

.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.location-card {
    display: block;
    padding: 1.25rem;
    text-align: center;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    text-decoration: none;
    color: #2c3e50;
    font-weight: 600;
    transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.location-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* ---------- Alert Banner ---------- */

.alert-banner {
    margin-bottom: 1rem;
}

.alert {
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 0.75rem;
}

.alert-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.alert p {
    margin: 0.5rem 0 0;
}

.alert-severity {
    font-size: 0.85rem;
    font-weight: bold;
    text-transform: uppercase;
}

.alert-extreme,
.alert-severe {
    border: 2px solid #b00000;
}

.alert-moderate {
    border: 2px solid #d97706;
}

.alert-minor {
    border: 2px solid #ca8a04;
}

.hourly-alert {
    margin-top: 0.6rem;
    padding-top: 0.5rem;
    border-top: 1px solid #d97706;
    font-size: 0.7rem;
    font-weight: 600;
}

.hidden{
    display:none;
}

/* ---------------------------------------
   Forecast
--------------------------------------- */

.forecast-grid {
    display: grid;
    grid-template-columns: repeat(
        auto-fit,
        minmax(260px, 1fr)
    );
    gap: 1rem;
    margin-top: 1.5rem;
}


.forecast-card {
    background: #ffffff;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 1.25rem;
}


.forecast-card-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 1rem;
}


.forecast-card-header h3 {
    margin: 0;
}


.forecast-date {
    font-size: 0.85rem;
    color: #666;
}


.forecast-main {
    display: flex;
    align-items: center;
    gap: 1rem;
}


.forecast-icon {
    width: 64px;
    height: 64px;
}


.forecast-temperature {
    font-size: 2rem;
    font-weight: bold;
}


.forecast-summary {
    font-size: 1.05rem;
    margin: 1rem 0;
}


.forecast-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    border-top: 1px solid #eee;
    padding-top: 0.75rem;
}


.forecast-details div {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}


.forecast-details strong {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: #666;
}


.forecast-description {
    margin-top: 1rem;
    border-top: 1px solid #eee;
    padding-top: 0.75rem;
}


.forecast-description summary {
    cursor: pointer;
    font-weight: 600;
}


.forecast-description p {
    line-height: 1.5;
}


.forecast-updated {
    margin-top: 1rem;
    text-align: right;
    font-size: 0.85rem;
    color: #666;
}

.forecast-card-alert {
    border: 2px solid #d97706;
}


.forecast-alerts {
    margin: -1.25rem -1.25rem 1rem;
    padding: 0.65rem 1rem;
    background: #fff7ed;
    border-bottom: 1px solid #d97706;
    font-weight: 600;
}


.forecast-alert-label {
    font-size: 0.85rem;
}


.forecast-period {
    margin-top: 0.75rem;
    font-size: 0.8rem;
    color: #666;
    text-align: right;
}

/* ---------------------------------------
   Hourly Forecast
--------------------------------------- */

.hourly-section {
    margin-bottom: 1.5rem;
}

.section-header {
    margin-bottom: 1rem;
}

.section-subtitle {
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: #666;
}

.hourly-scroll {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    padding-bottom: 0.75rem;
    scroll-snap-type: x proximity;
}

.hourly-card {
    flex: 0 0 125px;
    padding: 1rem;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    scroll-snap-align: start;
}

.hourly-time {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.hourly-icon {
    width: 48px;
    height: 48px;
    margin: 0.25rem auto;
}

.hourly-temperature {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0.25rem 0;
}

.hourly-condition {
    min-height: 2.5em;
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.75rem;
}

.hourly-details {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.8rem;
}

.hourly-details > div {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
}

.hourly-label {
    color: #777;
}

.hourly-night {
    background: #f5f5f7;
}

.hourly-night .hourly-time {
    opacity: 0.8;
}

.hourly-chart-container {
    position: relative;
    height: 280px;
    width: 100%;
}

.hourly-chart-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.chart-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.85rem;
}

.chart-toggles label {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    cursor: pointer;
}

.wind-strip {
    display: flex;
    align-items: stretch;
    margin-top: 0.5rem;
    border-top: 1px solid #ddd;
    padding-top: 0.75rem;
}

.wind-strip-label {
    flex: 0 0 80px;
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 0.85rem;
}

.wind-hours {
    display: flex;
    flex: 1;
    overflow-x: auto;
}

.wind-hour {
    flex: 1 0 60px;
    text-align: center;
    font-size: 0.8rem;
}

.wind-arrow {
    width: 22px;
    height: 22px;
    margin: 0 auto 0.2rem;
    transform-origin: center;
}

.wind-arrow svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.wind-speed {
    font-size: 0.75rem;
    color: #666;
}

/* ---------------------------------------
   Radar
--------------------------------------- */

.radar-panel {
    overflow: hidden;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.panel-header h3 {
    margin: 0;
}

.panel-link {
    font-size: 0.85rem;
    text-decoration: none;
}

#radar-map-landing {
    width: 100%;
    height: 350px;
    border-radius: 6px;
    overflow: hidden;
}

.radar-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.radar-controls label {
    font-size: 0.85rem;
    white-space: nowrap;
}

.radar-controls input[type="range"] {
    flex: 1;
}

.radar-viewer {
    padding: 1rem;
}

.radar-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.radar-product,
.radar-opacity {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.radar-product select {
    padding: 0.35rem;
}

.radar-opacity input {
    width: 150px;
}

#radar-map-full {
    width: 100%;
    height: 650px;
    border-radius: 6px;
    overflow: hidden;
}

.radar-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
    font-size: 0.8rem;
}


/* ---------------------------------------
   Mobile Adjustments
--------------------------------------- */

@media (max-width: 700px) {

    nav{
        display:flex;
        align-items:center;
        flex-wrap:wrap;
        padding:0 10px;
    }

    .nav-toggle{
        display:flex;
        margin-left:auto;
    }

    .nav-links{
        display:none;
        flex-direction:column;
        width:100%;
    }

    .nav-links.open{
        display:flex;
    }

    .hourly-chart-header {
        flex-direction: column;
    }

    .chart-toggles {
        width: 100%;
    }

    .wind-strip-label {
        flex-basis: 55px;
    }

}