@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

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

/* Navigation Header - Exact same as index.html */
.main-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(30, 30, 30, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    padding: 0.8rem 0;
}

.nav-container {
    max-width: 100%;
    margin: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5rem;
    height: 60px; /* Fixed height for consistent alignment */
}

.nav-brand .nav-name {
    font-size: 1.5rem;
    font-weight: 600;
    color: #e0e0e0;
    text-decoration: none;
    display: flex;
    align-items: center;
    height: 100%;
    line-height: 1; /* Ensure consistent line height */
    margin: 0; /* Remove any default margins */
    padding: 0.5rem 0; /* Add some vertical padding */
}

.nav-brand .nav-button {
    background: transparent;
    border-radius: 12px;
    padding: 0.5rem 0.5rem; /* Small padding for compact button */
    box-shadow: none;
    transition: all 0.3s ease;
    text-decoration: none;
    color: #e0e0e0;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.nav-brand .nav-button:hover {
    color: #64b5f6;
    background: rgba(50, 50, 50, 0.8);
    box-shadow: 
        inset 2px 2px 5px rgba(0, 0, 0, 0.5),
        inset -2px -2px 5px rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.nav-brand .nav-button:active {
    transform: translateY(0);
    box-shadow: 
        inset 3px 3px 7px rgba(0, 0, 0, 0.6),
        inset -1px -1px 3px rgba(255, 255, 255, 0.03);
}

/* Body styling to match index.html */
body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 50%, #1f1f1f 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 6rem 2rem 0 2rem; /* Remove bottom padding, let footer handle spacing */
    overflow-x: auto;
    color: #e0e0e0;
    margin: 0;
}

/* Main Container - responsive to window size */
.dallas-weather-container {
    width: 100%;
    max-width: 1200px; /* Match index.html container */
    margin: 0 auto;
    padding: 0;
    flex: 1; /* Allow container to grow and push footer down */
}

/* Current Weather Section - Large Neumorphic Container */
.weather-section-large {
    margin-bottom: 2rem;
    width: 100%;
}

.weather-card-large {
    background: #2a2a2a;
    border-radius: 20px;
    padding: 0.75rem 1.5rem 3rem 1.5rem; /* Further reduced top padding from 1.5rem to 0.75rem */
    margin: 1.5rem auto;
    max-width: 1400px;
    box-shadow: 8px 8px 16px rgba(0, 0, 0, 0.4), -8px -8px 16px rgba(255, 255, 255, 0.02);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    width: 100%;
    min-height: 400px; /* Added minimum height for Current Weather section */
    display: flex;
    flex-direction: column;
}

.weather-card-large::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
}

/* Active Alerts and 5-Day Forecast Horizontal Layout */
.forecast-horizontal {
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 2rem; /* Increased spacing for wider separation */
    padding: 1rem 0;
}

.forecast-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    flex: 1;
    min-width: 120px; /* Ensure minimum width for each day */
}

.forecast-name {
    font-size: 1rem; /* Slightly smaller font */
    color: #ffffff; /* White font */
    font-weight: 600;
    margin-bottom: 0.75rem; /* Space below day name */
}

.forecast-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.forecast-temps {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
}

.forecast-high, .forecast-low {
    font-size: 0.9rem;
    font-weight: 500;
}

.forecast-divider {
    width: 1px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    margin: 0 1rem; /* Increased margin around dividers */
}

/* 5-Day Forecast Loading Text */
.weather-section-half {
    margin-bottom: 2rem;
    width: 100%;
}

.weather-card-half {
    background: #2a2a2a;
    border-radius: 20px;
    padding: 0.75rem 2rem; /* Reduced top padding from 2rem to 0.75rem */
    margin: 1.5rem auto;
    max-width: 1400px;
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.4), -5px -5px 10px rgba(255, 255, 255, 0.02);
    transition: all 0.3s ease;
    min-height: 300px; /* Added minimum height for 5-Day Forecast */
    width: 100%;
    display: flex;
    flex-direction: column;
}

/* Weather in Other Locations - 5 City Sections */
.weather-section-grid {
    margin-bottom: 2rem;
    width: 100%;
}

.weather-grid-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.weather-grid-header h3 {
    color: #e0e0e0;
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
}

.weather-grid-header i {
    color: #64b5f6;
    font-size: 1.2rem;
}

.weather-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Responsive grid */
    gap: 1rem;
    width: 100%;
}

.grid-item {
    background: #2a2a2a;
    border-radius: 15px;
    padding: 1.5rem 1rem;
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.4), -5px -5px 10px rgba(255, 255, 255, 0.02);
    transition: all 0.3s ease;
    text-align: center;
    min-height: 140px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
}

/* Refresh Section - Container for refresh button */
.refresh-section {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 1rem;
    margin-top: 1rem;
    gap: 1rem;
}

/* Refresh Button Styling */
.refresh-button {
    background: transparent;
    border: none;
    border-radius: 12px;
    padding: 0.5rem 1rem;
    color: #e0e0e0;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: none;
    transition: all 0.3s ease;
}

.refresh-button:hover {
    color: #64b5f6;
    background: rgba(50, 50, 50, 0.8);
    box-shadow: 
        inset 2px 2px 5px rgba(0, 0, 0, 0.5),
        inset -2px -2px 5px rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.refresh-button:active {
    transform: translateY(0);
    box-shadow: 
        inset 3px 3px 7px rgba(0, 0, 0, 0.6),
        inset -1px -1px 3px rgba(255, 255, 255, 0.03);
}

.refresh-button i {
    font-size: 0.7rem;
}

/* Last Updated Timestamp */
.last-updated {
    color: #80EF80;
    font-size: 0.8rem;
    font-weight: 500;
    font-style: italic;
}

/* Live Indicator */
.live-indicator {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    margin-right: 0.5rem;
}

.live-dot {
    width: 8px;
    height: 8px;
    background-color: #80EF80;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

.live-text {
    color: #80EF80;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

@keyframes pulse {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Refresh animation */
.refresh-button.spinning i {
    animation: spin 1s linear infinite;
}

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

/* Headers and Content Styling */
.weather-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.weather-header h2 {
    color: #e0e0e0;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #b0b0b0;
    font-size: 1rem;
}

.location i {
    color: #64b5f6;
}

.weather-main {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 2rem 0 0 0; /* Add top margin to move the group lower */
    padding: 0;
    flex: 1;
    gap: 10rem; /* Middle spacing between temperature and icon */
}

.temperature {
    display: flex;
    align-items: center;
    justify-content: center;
}

.temp-value {
    font-size: 7rem;
    font-weight: 700;
    color: #e0e0e0;
    line-height: 1;
}

.temp-unit {
    font-size: 3rem;
    color: #b0b0b0;
    margin-top: 0.5rem;
}

.weather-details {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 5rem;
}

.weather-detail {
    font-size: 1.1rem;
    color: #b0b0b0;
    font-weight: 500;
}

.weather-icon {
    font-size: 7rem;
    color: #FFD700;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.weather-description {
    font-size: 1.5rem;
    color: #e0e0e0;
    font-weight: 500;
}

.weather-details {
    display: flex;
    justify-content: space-around;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #b0b0b0;
    font-size: 0.9rem;
}

.detail-item i {
    color: #64b5f6;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.card-header h3 {
    color: #e0e0e0;
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
}

.card-header i {
    color: #64b5f6;
    font-size: 1.2rem;
}

/* Alert Items Styling */
.alert-item {
    background: rgba(255, 116, 108, 0.15);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    margin-bottom: 0.75rem;
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.3), -4px -4px 8px rgba(255, 116, 108, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 116, 108, 0.2);
}

.alert-item:last-child {
    margin-bottom: 0;
}

.alert-title {
    color: #e0e0e0;
    font-weight: bold;
    font-size: 1rem;
    line-height: 1.4;
}

/* Alert Severity Colors */
.alert-severity-high {
    background: rgba(255, 116, 108, 0.5); /* FF746C with 50% opacity - more solid */
    border-color: rgba(255, 116, 108, 0.7);
}

.alert-severity-medium {
    background: rgba(255, 116, 108, 0.3); /* FF746C with 30% opacity - more solid */
    border-color: rgba(255, 116, 108, 0.5);
}

.alert-severity-low {
    background: rgba(255, 116, 108, 0.2); /* FF746C with 20% opacity - more solid */
    border-color: rgba(255, 116, 108, 0.4);
}

/* Grid Item Styling */
.grid-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.grid-header i {
    color: #64b5f6;
    font-size: 1.5rem;
}

.grid-header span {
    color: #FFFFFF;
    font-size: 1rem;
    font-weight: bold;
}

.grid-content {
    margin-top: 1rem;
}

.grid-value {
    color: #e0e0e0;
    font-weight: 600;
    font-size: 1.1rem;
}

/* Loading Data Styles */
.loading-data {
    font-size: 2rem !important;
    color: #b0b0b0;
    font-weight: 500;
}

#dallas-forecast .loading-data {
    font-size: 2rem; /* Same size as Current Weather loading data */
    color: #b0b0b0;
    font-weight: 500;
}

.forecast-loading {
    font-size: 1.2rem !important;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

/* Active Weather Alerts Content */
.alerts-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex: 1;
}

.checkmark {
    color: #4CAF50;
    font-size: 2em;
    margin-bottom: 0.5rem;
}

.alerts-content p {
    color: #e0e0e0;
    margin: 0;
    font-size: 1rem;
}

.alerts-message {
    color: #4CAF50;
    font-weight: bold;
    margin: 0;
    font-size: 1.2rem;
}

/* Hover Effects */
.weather-card-large:hover,
.weather-card-half:hover,
.grid-item:hover {
    transform: translateY(-2px);
    box-shadow: 
        10px 10px 20px rgba(0, 0, 0, 0.5),
        -10px -10px 20px rgba(255, 255, 255, 0.03);
}

/* Responsive Design - Match index.html patterns */
@media (max-width: 1200px) {
    .dallas-weather-container {
        max-width: 95%;
    }
}

@media (max-width: 768px) {
    body {
        padding: 1rem;
        display: block;
        align-items: initial;
        justify-content: initial;
    }
    
    .dallas-weather-container {
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
    }
    
    .weather-main {
        flex-direction: column;
        gap: 1rem;
    }
    
    .weather-details {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .weather-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 0.75rem;
    }
    
    .temp-value {
        font-size: 3rem;
    }
    
    .weather-icon {
        font-size: 3rem;
    }
    
    .weather-header h2 {
        font-size: 1.5rem;
    }
}

.fa-microchip {
    color: #64b5f6;
}

.fa-book {
    color: #64b5f6;
}



@media (max-width: 480px) {
    .weather-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .temp-value {
        font-size: 2.5rem;
    }
    
    .weather-icon {
        font-size: 2.5rem;
    }
    
    .weather-card-large {
        padding: 1rem;
    }
    
    .weather-card-half {
        padding: 1rem;
        height: auto;
        min-height: 150px;
    }
    
    .grid-item {
        padding: 1rem 0.75rem;
        min-height: 120px;
    }
    
    .weather-header h2 {
        font-size: 1.3rem;
    }
    
    .card-header h3 {
        font-size: 1.1rem;
    }
    
    .weather-grid-header h3 {
        font-size: 1.1rem;
    }
}

/* Font Awesome Icon Colors - More specific selectors */
.grid-header .fa-microchip {
    color: #64b5f6 !important;
}

.grid-header .fa-book {
    color: #FF746C !important;
}

.grid-header .fa-building {
    color: #DBDBDC !important;
}

.grid-header .fa-ship {
    color: #C3B1E1 !important;
}

.grid-header .fa-school {
    color: #FFFAA0 !important;
}

/* Fallback selectors */
.fa-microchip {
    color: #64b5f6 !important;
}

.fa-book {
    color: #FF746C !important;
}

.fa-building {
    color: #DBDBDC !important;
}

.fa-ship {
    color: #C3B1E1 !important;
}

.fa-school {
    color: #FFFAA0 !important;
}

.city-weather {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.city-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.city-temp {
    font-size: 1.2rem;
    font-weight: 600;
    color: #e0e0e0;
}

.gg-bridge-fixed {
  display: inline-block;
  position: relative;
  width: 2em;
  height: 1em;
  vertical-align: middle;
  /* ROADWAY */
  background: linear-gradient(currentColor, currentColor) no-repeat 0 75% / 100% 0.05em;
}

/* THE TOWERS (Moved to 30% and 70% for better spacing) */
.gg-bridge-fixed::before {
  content: '';
  position: absolute;
  top: 15%;
  left: 30%;
  width: 40%;
  height: 70%;
  background: 
    linear-gradient(currentColor, currentColor) no-repeat 0 0 / 0.08em 100%,
    linear-gradient(currentColor, currentColor) no-repeat 100% 0 / 0.08em 100%;
}

/* THE THREE CABLES */
.gg-bridge-fixed::after {
  content: '';
  position: absolute;
  top: 15%;
  left: 0;
  width: 100%;
  height: 60%;
  /* 1. Left Slope: Curved up to the tower | 2. Middle Sag | 3. Right Slope: Curved up to the tower */
  background: 
    radial-gradient(ellipse at 0% 0%, transparent 69%, currentColor 70%, currentColor 75%, transparent 76%) no-repeat 0 0 / 30% 100%,
    radial-gradient(ellipse at 50% 0%, transparent 69%, currentColor 70%, currentColor 75%, transparent 76%) no-repeat 30% 0 / 40% 100%,
    radial-gradient(ellipse at 100% 0%, transparent 69%, currentColor 70%, currentColor 75%, transparent 76%) no-repeat 100% 0 / 30% 100%;
}

/* Footer */
.site-footer {
    text-align: center;
    padding: 2rem 0;
    width: 100%;
    position: relative;
    margin-top: 2rem;
}

.site-footer p {
    margin: 0;
    color: #b0b0b0;
}

.site-footer a {
    color: #64b5f6;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.site-footer a:hover {
    color: #90caf9;
    text-decoration: underline;
}