:root {
    /* Cyber Theme Color Tokens */
    --bg-base: #060913;
    --bg-panel: rgba(10, 18, 36, 0.7);
    
    --summer-neon: #ff9f1c;
    --summer-glow: rgba(255, 159, 28, 0.3);
    --winter-neon: #00f3ff;
    --winter-glow: rgba(0, 243, 255, 0.3);
    --monsoon-neon: #10b981;
    --monsoon-glow: rgba(16, 185, 129, 0.3);

    --accent-color: var(--summer-neon);
    --accent-glow: var(--summer-glow);
    
    --border-glow: rgba(255, 255, 255, 0.08);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --font-mono: 'Roboto Mono', monospace;
    --transition-speed: 0.5s;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-base);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Sci-Fi Canvas Background */
#canvas-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
}

/* Holographic Satellite Loader */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #040710;
    z-index: 999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 0.6s ease-in-out, visibility 0.6s;
    gap: 20px;
}

.loader-radar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 2px solid var(--accent-color);
    position: relative;
    box-shadow: 0 0 20px var(--accent-glow);
    animation: radar-pulse 2s infinite linear;
}

.loader-radar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(from 0deg, transparent 40%, var(--accent-glow) 100%);
    animation: radar-spin 1.5s infinite linear;
}

@keyframes radar-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes radar-pulse {
    0%, 100% { transform: scale(0.95); opacity: 0.8; }
    50% { transform: scale(1.05); opacity: 1; }
}

.loader-text {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--accent-color);
    letter-spacing: 2px;
    text-transform: uppercase;
    text-shadow: 0 0 8px var(--accent-glow);
    text-align: center;
    padding: 0 20px;
}

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

/* Cyber Glass Cards */
.cyber-panel {
    background: var(--bg-panel);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 14px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.cyber-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-color);
    transition: background var(--transition-speed), box-shadow var(--transition-speed);
}

.cyber-panel:hover {
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Top Bar Info */
.app-layout {
    position: relative;
    z-index: 1;
    max-width: 100%;
    width: 100%;
    margin: 0;
    padding: 12px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media (min-width: 992px) {
    .app-layout {
        grid-template-columns: 290px 1fr;
    }
    .main-content {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

.header-bar {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 10px;
}

@media (min-width: 768px) {
    .header-bar {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo {
    font-size: 1.7rem;
    text-shadow: 0 0 10px var(--accent-glow);
}

.brand-title h1 {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 6px;
}

.brand-title p {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--accent-color);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.search-area {
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 480px;
    position: relative;
}

.search-field {
    flex: 1;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 8px 12px;
    color: #fff;
    font-family: inherit;
    font-size: 0.85rem;
    outline: none;
    transition: all 0.3s;
}

.search-field:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-glow);
}

.search-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

.search-btn:hover {
    border-color: var(--accent-color);
    background: var(--accent-glow);
    transform: scale(1.05);
}

/* Sidebar Panels */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Telemetry Dial Panel */
.telemetry-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.telemetry-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
    padding-bottom: 8px;
}

.satellite-status {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--accent-color);
    text-shadow: 0 0 5px var(--accent-glow);
}

.satellite-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background-color: var(--accent-color);
    box-shadow: 0 0 6px var(--accent-color);
    animation: pulse-green 1.5s infinite;
}

.current-city {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
}

.current-time {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

/* Main Circular Weather Gauge */
.weather-gauge-container {
    position: relative;
    width: 140px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.gauge-svg {
    transform: rotate(-90deg);
}

.gauge-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 8px;
}

.gauge-progress {
    fill: none;
    stroke: var(--accent-color);
    stroke-width: 8px;
    stroke-dasharray: 502;
    stroke-dashoffset: 502;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.1, 0.8, 0.25, 1);
    filter: drop-shadow(0 0 8px var(--accent-color));
}

.gauge-center-text {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.gauge-temp {
    font-size: 2.3rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: #fff;
    line-height: 1;
}

.gauge-unit {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
}

.gauge-unit:hover {
    color: #fff;
}

.weather-status-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.telemetry-grid {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 10px;
}

.telemetry-item {
    display: flex;
    align-items: center;
    gap: 6px;
    text-align: left;
}

.telemetry-item-icon {
    color: var(--accent-color);
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.telemetry-label {
    font-size: 0.65rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.telemetry-value {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 700;
}

/* 10-Day Forecast Timeline */
.forecast-10day-panel h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.forecast-10day-grid {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 12px;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-color) rgba(0, 0, 0, 0.2);
}

.forecast-10day-grid::-webkit-scrollbar {
    height: 5px;
}

.forecast-10day-grid::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.forecast-10day-grid::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    border-radius: 4px;
}

.day-card {
    flex: 0 0 90px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 10px 8px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: all 0.3s;
}

.day-card:hover {
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
    transform: scale(1.03);
}

.day-card.active {
    border-color: var(--accent-color);
    background: rgba(255, 255, 255, 0.04);
}

.day-name {
    font-weight: 700;
    font-size: 0.78rem;
}

.day-date {
    font-size: 0.65rem;
    color: var(--text-secondary);
}

.day-icon {
    width: 24px;
    height: 24px;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.day-temps {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    display: flex;
    gap: 6px;
}

.day-max {
    font-weight: 700;
    color: #fff;
}

.day-min {
    color: var(--text-secondary);
}

.day-rain-prob {
    font-size: 0.7rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Linked Real-time Temperature Converter */
.converter-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.converter-panel h3 {
    font-size: 1.1rem;
    font-weight: 700;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
    padding-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.converter-display-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 16px;
    text-align: center;
    font-family: var(--font-mono);
}

.converter-city {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.converter-val-celsius {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 10px;
    opacity: 0.9;
}

.converter-units-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 12px;
    margin-top: 8px;
}

.conv-unit-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 10px 4px;
}

.conv-unit-lbl {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.conv-unit-val {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
}

/* Season Toggles */
.season-selector {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.season-selector h3 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

.season-btn-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.season-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.season-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.season-btn.active {
    background: var(--accent-glow);
    color: #fff;
    border-color: var(--accent-color);
    box-shadow: 0 0 10px var(--accent-glow);
}

/* AI Prediction Panel */
.forecast-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.forecast-header {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@media (min-width: 768px) {
    .forecast-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.forecast-title {
    font-size: 1.3rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ai-status-badge {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
}

.ai-status-pulse {
    width: 8px;
    height: 8px;
    background-color: #10b981;
    border-radius: 50%;
    animation: pulse-green 1.5s infinite;
}

@keyframes pulse-green {
    0% { transform: scale(0.9); opacity: 0.6; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.9); opacity: 0.6; }
}

.forecast-layout {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.chart-container {
    position: relative;
    width: 100%;
    height: 150px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ai-console-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ai-console {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    padding: 8px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--accent-color);
    height: 75px;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.04);
    line-height: 1.3;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.ai-console::-webkit-scrollbar {
    width: 4px;
}

.ai-console::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.ai-advisory-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 12px;
}

.ai-advisory-title {
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    gap: 6px;
    text-shadow: 0 0 5px var(--accent-glow);
}

.ai-advisory-text {
    font-size: 0.8rem;
    line-height: 1.4;
    color: var(--text-secondary);
}

/* Suggestions dropdown */
.suggestions-list {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    width: 100%;
    background: rgba(10, 15, 30, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    list-style: none;
    overflow: hidden;
    z-index: 1000;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.suggestions-list li {
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 0.95rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}

.suggestions-list li:hover {
    background: var(--accent-glow);
    color: #fff;
}

/* Footer */
.footer {
    grid-column: 1 / -1;
    text-align: center;
    padding: 10px 0;
    color: var(--text-secondary);
    font-size: 0.8rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 12px;
}

.footer-links {
    display: flex;
    gap: 16px;
}

.footer-links a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    gap: 4px;
}

.footer-links a:hover {
    color: #fff;
}

/* Weather Radar Grid widget */
.radar-scan-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.radar-canvas-container {
    position: relative;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 16px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 8px 16px;
    height: 110px;
    overflow: hidden;
}

.radar-screen-wrapper {
    width: 94px;
    height: 94px;
    position: relative;
    flex-shrink: 0;
}

#radar-overlay {
    width: 100%;
    height: 100%;
    display: block;
}

.radar-telemetry-overlay {
    position: static;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--accent-color);
    pointer-events: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-shadow: 0 0 3px var(--accent-glow);
    flex: 1;
}

/* Day Details Expanded Panel */
.day-details-expanded {
    background: rgba(0, 0, 0, 0.4);
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 12px;
    margin-top: 10px;
    animation: fade-slide-in 0.4s ease-out;
}

@keyframes fade-slide-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.details-wrapper {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 768px) {
    .details-wrapper {
        grid-template-columns: 200px 1fr;
    }
}

.details-main-info {
    text-align: center;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
    padding-bottom: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

@media (min-width: 768px) {
    .details-main-info {
        border-bottom: none;
        border-right: 1px dashed rgba(255, 255, 255, 0.1);
        padding-bottom: 0;
        padding-right: 16px;
        justify-content: center;
    }
}

.details-date {
    font-weight: 700;
    font-size: 0.95rem;
    color: #fff;
}

.details-icon {
    width: 36px;
    height: 36px;
    color: var(--accent-color);
    filter: drop-shadow(0 0 8px var(--accent-glow));
    display: flex;
    align-items: center;
    justify-content: center;
}

.details-temp-range {
    font-family: var(--font-mono);
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
}

.details-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.details-telemetry-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    align-content: center;
}

@media (min-width: 576px) {
    .details-telemetry-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.details-tel-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: left;
}

.details-tel-lbl {
    font-size: 0.65rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 600;
}

.details-tel-val {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
}

/* Day / Night Status Indicator */
.day-night-status {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-top: -6px;
    margin-bottom: 12px;
}
