:root {
    /* ================= LIGHT THEME (White & Sky Blue) ================= */
    
    /* Background: Radial highlight in center, Linear fade to corners */
    --bg-gradient: radial-gradient(circle at 50% 10%, #ffffff 0%, #e0f2ff 40%, #87CEFA 100%);
    
    --nav-bg: rgba(255, 255, 255, 0.85);
    --text-color: #2c3e50;
    
    /* Glass Card Style */
    --card-bg: rgba(255, 255, 255, 0.65);
    --card-border: 1px solid rgba(255, 255, 255, 0.9);
    
    /* GLOW EFFECTS (Soft Blue Halo) */
    --card-shadow: 0 10px 40px rgba(135, 206, 250, 0.4); 
    --glow-color: rgba(135, 206, 250, 0.8);
    
    --btn-bg: linear-gradient(135deg, #ffffff, #f0f8ff);
    --section-bg: linear-gradient(to bottom, rgba(255,255,255,0), rgba(135, 206, 250, 0.2));
}

.dark-theme {
    /* ================= DARK THEME (Dark Grey & Dusty Cloud) ================= */
    
    /* Background: Deep Grey with a dusty spotlight */
    --bg-gradient: radial-gradient(circle at 50% 10%, #4b5d67 0%, #1f2833 60%, #0b0c10 100%);
    
    --nav-bg: rgba(20, 25, 30, 0.85);
    --text-color: #dbe4eb; /* Dusty Cloud White */
    
    /* Glass Card Style */
    --card-bg: rgba(30, 40, 50, 0.5);
    --card-border: 1px solid rgba(255, 255, 255, 0.08);
    
    /* GLOW EFFECTS (Dusty Cyan/Grey Neon) */
    --card-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), inset 0 0 20px rgba(75, 93, 103, 0.3);
    --glow-color: rgba(100, 200, 210, 0.6); /* Dusty Cyan Glow */
    
    --btn-bg: linear-gradient(135deg, #3a4750, #2c3e50);
    --section-bg: linear-gradient(to bottom, rgba(0,0,0,0), rgba(0, 0, 0, 0.4));
}

* {
    margin: 0;
    padding: 0;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background: var(--bg-gradient);
    background-attachment: fixed; /* Keeps gradient fixed while scrolling */
    color: var(--text-color);
    transition: background 0.8s ease, color 0.5s ease;
    min-height: 100vh;
}

/* ================= NAVIGATION ================= */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 50px;
    background: var(--nav-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    transition: background 0.5s ease;
}

.logo { 
    font-size: 24px; 
    font-weight: 700; 
    color: var(--text-color);
    text-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.nav-links { list-style: none; display: flex; gap: 20px; }
.nav-links a { 
    text-decoration: none; 
    color: var(--text-color); 
    font-weight: 500; 
    transition: 0.3s; 
    position: relative;
}

/* Nav Link Hover Glow */
.nav-links a:hover { 
    color: #87CEFA; 
    text-shadow: 0 0 8px var(--glow-color);
}

.theme-btn {
    padding: 8px 18px;
    border: 1px solid var(--text-color);
    background: transparent;
    color: var(--text-color);
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.4s ease;
}

.theme-btn:hover { 
    background: var(--text-color); 
    color: #fff; 
    box-shadow: 0 0 15px var(--glow-color); /* Glow on hover */
    border-color: transparent;
}
.dark-theme .theme-btn:hover { color: #1f2833; }

/* ================= SECTIONS ================= */
section {
    padding: 100px 20px;
    min-height: 80vh; 
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* About Section */
#about {
    padding-top: 150px; 
    min-height: 90vh;
    background-image: url(./public/1.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    /* Add a subtle overlay to make text readable over images */
    box-shadow: inset 0 -100px 100px -50px var(--nav-bg); 
}

/* Dark Theme Image Override */
.dark-theme #about {
    background-image: url(./public/2.jpg);
}

/* Content Box (Glassmorphism + Glow) */
.content-box {
    max-width: 800px;
    background: var(--card-bg);
    padding: 50px;
    border-radius: 20px;
    border: var(--card-border);
    backdrop-filter: blur(12px);
    box-shadow: var(--card-shadow); /* Dynamic Glow Shadow */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.content-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 50px var(--glow-color); /* Stronger glow on hover */
}

.content-box h2 { font-size: 40px; margin-bottom: 20px; }
.content-box p { font-size: 18px; line-height: 1.8; }

/* ================= WEATHER SECTION ================= */
#home {
    background: url(./public/3.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.dark-theme #home {
    background-image: url(./public/4.jpg);
}

.weather-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: var(--card-border);
    padding: 40px;
    border-radius: 25px;
    width: 100%;
    max-width: 450px;
    box-shadow: var(--card-shadow);
    margin: 0 auto;
    
    /* Float Animation */
    animation: float 6s ease-in-out infinite;
}

/* Input Styles with Focus Glow */
.search { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 30px; }
.search input {
    border: 1px solid transparent;
    padding: 15px 20px; 
    border-radius: 30px;
    flex: 1; 
    background: var(--btn-bg); 
    color: var(--text-color); 
    outline: none; 
    font-size: 16px;
    transition: 0.3s;
    box-shadow: inset 2px 2px 5px rgba(0,0,0,0.1);
}

.search input:focus {
    border-color: var(--glow-color);
    box-shadow: 0 0 15px var(--glow-color); /* Input Glows when typing */
}

.search button {
    border: none; 
    background: var(--btn-bg); 
    padding: 15px;
    border-radius: 50%; 
    cursor: pointer; 
    color: var(--text-color); 
    transition: 0.3s;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.search button:hover { 
    transform: scale(1.1) rotate(10deg); 
    box-shadow: 0 0 15px var(--glow-color); /* Button Glow */
}

/* Weather Info */
.weather { display: none; animation: fadeIn 0.8s ease-out; }
.weather-icon { width: 130px; filter: drop-shadow(0 0 10px rgba(0,0,0,0.2)); }
.temp { 
    font-size: 60px; 
    font-weight: 600; 
    text-shadow: 0 0 20px rgba(255,255,255,0.5); /* Text Glow */
}
.dark-theme .temp { text-shadow: 0 0 20px var(--glow-color); }

.city { font-size: 30px; font-weight: 400; margin-bottom: 5px; }
.desc { font-size: 18px; margin-bottom: 20px; text-transform: capitalize; letter-spacing: 1px; }

.details { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 0 10px; 
    margin-top: 30px; 
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 20px;
}

.col { 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    gap: 8px; 
    text-align: center;
}

.col i { font-size: 24px; color: var(--text-color); transition: 0.3s; }
.col:hover i { 
    transform: translateY(-5px); 
    text-shadow: 0 0 10px var(--glow-color); 
}

/* ================= FEATURES & DEV ================= */
#features { padding-top: 50px; }
.feature-grid { display: flex; gap: 25px; margin-top: 40px; flex-wrap: wrap; justify-content: center; }

.feature-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    padding: 35px;
    border-radius: 20px;
    width: 300px;
    border: var(--card-border);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Bouncy Transition */
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
}

/* Hover Effect: Card Lifts and Glows */
.feature-card:hover { 
    transform: translateY(-15px); 
    box-shadow: 0 20px 40px var(--glow-color);
}

/* Linear Gradient Background on Hover for Features */
.feature-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0));
    opacity: 0;
    transition: 0.3s;
}
.feature-card:hover::before { opacity: 1; }

.feature-card i { 
    font-size: 45px; 
    margin-bottom: 20px; 
    color: #87CEFA; /* Sky Blue */
    filter: drop-shadow(0 0 5px var(--glow-color));
}
.dark-theme .feature-card i { color: #dbe4eb; }

/* Developer Section */
#developer { background: var(--section-bg); }
.dev-card {
    background: var(--card-bg);
    padding: 40px;
    width: 100%;
    max-width: 500px;
    border-radius: 20px;
    border: var(--card-border);
    margin-top: 30px;
    box-shadow: var(--card-shadow);
}
.dev-img-placeholder { 
    font-size: 70px; 
    margin-bottom: 15px; 
    filter: drop-shadow(0 0 15px var(--glow-color));
}
.socials { margin-top: 20px; display: flex; justify-content: center; gap: 25px; }
.socials a { color: var(--text-color); font-size: 28px; transition: 0.3s; }
.socials a:hover { 
    color: #87CEFA; 
    transform: scale(1.2); 
    text-shadow: 0 0 15px var(--glow-color);
}

/* Footer */
footer {
    padding: 25px;
    background: var(--nav-bg);
    text-align: center;
    color: var(--text-color);
    font-size: 14px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.error { color: #ff6b6b; display: none; margin-bottom: 10px; font-weight: bold; text-shadow: 0 0 10px rgba(255, 0, 0, 0.3); }

/* ================= ANIMATIONS ================= */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .nav-links { display: none; } 
    section { padding: 80px 15px; min-height: auto; }
    #about { padding-top: 120px; }
    .content-box h2 { font-size: 28px; }
    .temp { font-size: 50px; }
}
