* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    transition: background 0.8s ease;
    overflow: hidden;
}

/* Dynamic backgrounds based on weather */
body.sunny {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 25%, #4facfe 75%, #00f2fe 100%);
}

body.cloudy {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #a8edea 100%);
}

body.rainy {
    background: linear-gradient(135deg, #3a6073 0%, #16222a 50%, #2980b9 100%);
}

body.snowy {
    background: linear-gradient(135deg, #e6ddd4 0%, #d5def5 50%, #ffffff 100%);
}

body.smoke, body.mist, body.haze {
    background: linear-gradient(135deg, #bdc3c7 0%, #2c3e50 50%, #95a5a6 100%);
}

body.clear {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
}

.weather-container {
    width: 100%;
    height: 100vh;
    background: rgba(255, 255, 255, 0.08);
    padding: 40px;
    backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-shadow: 
        0 8px 32px rgba(31, 38, 135, 0.37),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 -1px 0 rgba(255, 255, 255, 0.05);
    animation: fadeInUp 0.8s ease-out;
    position: relative;
    overflow: hidden;
}

.weather-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 119, 198, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
    animation: slideInDown 0.6s ease-out;
}

/* Search Container */
.search-container {
    flex: 1;
    display: flex;
    justify-content: center;
    max-width: 400px;
    margin: 0 40px;
}

.search-box {
    position: relative;
    width: 100%;
    max-width: 350px;
}

.search-box input {
    width: 100%;
    padding: 12px 45px 12px 45px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    font-weight: 400;
    outline: none;
    transition: all 0.3s ease;
}

.search-box input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-box input:focus {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    margin-top: 5px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    display: none;
}

.search-suggestions.show {
    display: block;
}

.suggestion-item {
    padding: 12px 20px;
    cursor: pointer;
    color: #2c3e50;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: background 0.2s ease;
}

.suggestion-item:hover {
    background: rgba(116, 185, 255, 0.1);
}

.suggestion-item:last-child {
    border-bottom: none;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.location {
    font-size: 32px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.98);
    margin-bottom: 6px;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    letter-spacing: -0.5px;
}

.date {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.75);
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.greeting {
    font-size: 22px;
    color: rgba(255, 255, 255, 0.98);
    text-align: right;
    margin-bottom: 6px;
    font-weight: 600;
    letter-spacing: -0.3px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.time {
    font-size: 36px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.98);
    text-align: right;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    letter-spacing: -0.5px;
}

/* Main Content */
.main-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 5px;
    flex: 0;
    animation: slideInLeft 0.8s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.main-weather {
    flex: 1;
}

.temperature-large {
    font-size: 160px;
    font-weight: 200;
    color: rgba(255, 255, 255, 0.98);
    line-height: 0.8;
    margin-bottom: 5px;
    text-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    animation: temperaturePulse 3s ease-in-out infinite;
    background: linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.8) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.temperature-large::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0;
    animation: shimmer 2s ease-in-out infinite;
}

@keyframes temperaturePulse {
    0%, 100% {
        transform: scale(1);
        filter: brightness(1);
    }
    50% {
        transform: scale(1.02);
        filter: brightness(1.1);
    }
}

@keyframes shimmer {
    0%, 100% {
        opacity: 0;
        transform: translateX(-100%);
    }
    50% {
        opacity: 1;
        transform: translateX(100%);
    }
}

.condition {
    font-size: 38px;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 30px;
    font-weight: 500;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    letter-spacing: -0.5px;
}

.weather-details {
    display: flex;
    gap: 25px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 18px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.08);
    padding: 16px 22px;
    border-radius: 30px;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.detail-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.detail-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        0 12px 24px rgba(0, 0, 0, 0.15),
        0 6px 12px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.25);
}

.detail-item:hover::before {
    left: 100%;
}

.wind-icon, .humidity-icon {
    font-size: 20px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* Current Info - Right Side */
.right-side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 20px;
    flex: 1;
    max-width: 400px;
}

.current-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 20px;
}

.current-temp {
    text-align: right;
}

.temp-value {
    font-size: 48px;
    font-weight: 300;
    color: #2c3e50;
    margin-bottom: 8px;
}

.wind-humidity {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 12px;
    color: #7f8c8d;
}

.feels-like {
    text-align: right;
    font-size: 14px;
    color: #7f8c8d;
    line-height: 1.4;
}

.condition-small {
    color: #5a6c7d;
    font-weight: 500;
}

/* Hourly Forecast */
.hourly-forecast {
    margin-bottom: 0;
    width: 100%;
}

.hourly-forecast h3 {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 20px;
    text-align: right;
}

.hourly-items {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 15px;
    max-width: 350px;
}

.hourly-item {
    background: rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    padding: 18px 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-height: 90px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.hourly-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.hourly-item:hover {
    transform: translateY(-6px) scale(1.05);
    background: rgba(255, 255, 255, 0.18);
    box-shadow: 
        0 15px 35px rgba(0, 0, 0, 0.1),
        0 5px 15px rgba(0, 0, 0, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.hourly-item:hover::before {
    opacity: 1;
}

.hour {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 10px;
    font-weight: 500;
}

.hourly-temp {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
}

.hourly-condition {
    font-size: 12px;
    color: #7f8c8d;
    font-weight: 400;
}

/* Weekly Forecast */
.weekly-forecast {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 5px 0;
    margin-top: 10px;
}

.day-item {
    min-width: 90px;
    text-align: center;
    padding: 20px 15px;
    border-radius: 20px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.day-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.day-item.active {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.day-item:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        0 12px 30px rgba(0, 0, 0, 0.1),
        0 4px 10px rgba(0, 0, 0, 0.08);
}

.day-item:hover::before,
.day-item.active::before {
    opacity: 1;
}

.day {
    font-size: 13px;
    color: #7f8c8d;
    margin-bottom: 8px;
    font-weight: 500;
}

.day-item.active .day {
    color: #2c3e50;
}

.day-temp {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 6px;
}

.day-condition {
    font-size: 11px;
    color: #7f8c8d;
    line-height: 1.2;
    font-weight: 400;
}

/* SVG Weather Icons */
.weather-icon {
    width: 24px;
    height: 24px;
    fill: currentColor;
    transition: all 0.3s ease;
}

.weather-icon.large {
    width: 48px;
    height: 48px;
}

.weather-icon.wind {
    color: #74b9ff;
}

.weather-icon.humidity {
    color: #00b894;
}

.weather-icon.temperature {
    color: #fd79a8;
}

.weather-icon:hover {
    transform: scale(1.1);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

/* Floating Animation for Weather Elements */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.floating {
    animation: float 3s ease-in-out infinite;
}

.floating:nth-child(2) {
    animation-delay: 0.5s;
}

.floating:nth-child(3) {
    animation-delay: 1s;
}

/* Stagger Animation for Day Items */
.stagger-item {
    animation: staggerFadeIn 0.6s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes staggerFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Pulse effect for active states */
.temperature-large:hover {
    animation-play-state: paused;
    transform: scale(1.05);
    filter: brightness(1.2);
}

/* Improved scrollbar for weekly forecast */
.weekly-forecast::-webkit-scrollbar {
    height: 4px;
}

.weekly-forecast::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.weekly-forecast::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.weekly-forecast::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Enhanced focus states for accessibility */
.day-item:focus,
.hourly-item:focus,
.detail-item:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Loading skeleton animation */
.loading-skeleton {
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 25%, 
        rgba(255, 255, 255, 0.2) 50%, 
        rgba(255, 255, 255, 0.1) 75%);
    background-size: 200% 100%;
    animation: loadingSkeleton 1.5s infinite;
}

@keyframes loadingSkeleton {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Weekly Forecast Container */
.weekly-forecast-container {
    margin-top: 20px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Design */
@media (max-width: 480px) {
    .weather-container {
        padding: 15px;
    }
    
    .header {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 25px;
    }
    
    .search-container {
        order: 2;
        margin: 0;
        max-width: none;
    }
    
    .greeting-time {
        order: 1;
        align-self: flex-end;
    }
    
    .location-date {
        order: 3;
        align-self: flex-start;
    }
    
    .main-content {
        flex-direction: column;
        gap: 20px;
        margin-bottom: 20px;
    }
    
    .right-side {
        align-items: flex-start;
        width: 100%;
        max-width: none;
    }
    
    .hourly-items {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
        max-width: none;
    }
    
    .temperature-large {
        font-size: 80px;
    }
    
    .condition {
        font-size: 24px;
    }
    
    .weekly-forecast {
        gap: 6px;
        overflow-x: auto;
    }
    
    .day-item {
        min-width: 80px;
        padding: 12px 8px;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .weather-container {
        padding: 20px;
    }
    
    .header {
        flex-direction: column;
        gap: 20px;
        margin-bottom: 30px;
    }
    
    .search-container {
        order: 2;
        margin: 0;
    }
    
    .main-content {
        margin-bottom: 30px;
        flex-direction: column;
        gap: 25px;
    }
    
    .right-side {
        align-items: flex-start;
        width: 100%;
        max-width: none;
    }
    
    .hourly-items {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 1fr);
        max-width: none;
    }
    
    .temperature-large {
        font-size: 120px;
    }
    
    .condition {
        font-size: 28px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .weather-container {
        padding: 40px;
    }
    
    .search-container {
        margin: 0 30px;
    }
    
    .hourly-items {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 1fr);
        gap: 15px;
        max-width: 380px;
    }
    
    .temperature-large {
        font-size: 140px;
    }
}

@media (min-width: 1025px) {
    .weather-container {
        padding: 50px 70px;
    }
    
    .search-container {
        margin: 0 50px;
    }
    
    .temperature-large {
        font-size: 160px;
    }
    
    .condition {
        font-size: 36px;
    }
    
    .hourly-items {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 1fr);
        gap: 20px;
        max-width: 420px;
    }
    
    .day-item {
        min-width: 100px;
        padding: 15px 12px;
    }
}

/* Smooth animations */
.weather-container {
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hourly-item {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hourly-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}
