/* ============================================
   GOGLE WEATHER — Hauptstylesheet
   ============================================ */

/* ---------- VARIABLES ---------- */
:root {
  --bg: #f0f2f5;
  --bg2: #e8eaed;
  --card: rgba(255,255,255,.92);
  --card-border: rgba(255,255,255,.5);
  --card-hover: rgba(255,255,255,.98);
  --glass: rgba(255,255,255,.6);
  --glass-border: rgba(255,255,255,.3);
  --primary: #1a73e8;
  --primary-dark: #1557b0;
  --primary-light: #e8f0fe;
  --primary-glow: rgba(26,115,232,.2);
  --text: #202124;
  --text2: #5f6368;
  --text3: #9aa0a6;
  --text4: #dadce0;
  --border: #e8eaed;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.04);
  --shadow: 0 1px 4px rgba(0,0,0,.06), 0 4px 16px rgba(0,0,0,.04);
  --shadow-lg: 0 2px 12px rgba(0,0,0,.08), 0 12px 40px rgba(0,0,0,.06);
  --shadow-xl: 0 4px 24px rgba(0,0,0,.1), 0 16px 60px rgba(0,0,0,.08);
  --radius: 24px;
  --radius-lg: 28px;
  --radius-sm: 16px;
  --radius-xs: 12px;
  --font: 'Google Sans','Segoe UI',system-ui,-apple-system,sans-serif;
  --font-mono: 'Google Sans Mono','Cascadia Code',monospace;
  --header-h: 72px;
  --transition: all .3s cubic-bezier(.4,0,.2,1);
  --section-gap: 24px;
}

[data-theme="dark"] {
  --bg: #1a1a2e;
  --bg2: #16213e;
  --card: rgba(30,30,60,.92);
  --card-border: rgba(255,255,255,.08);
  --card-hover: rgba(40,40,70,.98);
  --glass: rgba(255,255,255,.08);
  --glass-border: rgba(255,255,255,.06);
  --primary: #8ab4f8;
  --primary-dark: #669df6;
  --primary-light: rgba(138,180,248,.12);
  --primary-glow: rgba(138,180,248,.15);
  --text: #e8eaed;
  --text2: #9aa0a6;
  --text3: #5f6368;
  --text4: #3c4043;
  --border: rgba(255,255,255,.1);
  --shadow-sm: 0 1px 2px rgba(0,0,0,.2);
  --shadow: 0 1px 4px rgba(0,0,0,.24), 0 4px 16px rgba(0,0,0,.16);
  --shadow-lg: 0 2px 12px rgba(0,0,0,.32), 0 12px 40px rgba(0,0,0,.2);
  --shadow-xl: 0 4px 24px rgba(0,0,0,.4), 0 16px 60px rgba(0,0,0,.24);
}

/* ---------- RESET ---------- */
*,*::before,*::after{margin:0;padding:0;box-sizing:border-box}
html{scroll-behavior:smooth;-webkit-tap-highlight-color:transparent}
body{
  font-family:var(--font);
  background:var(--bg);
  color:var(--text);
  min-height:100vh;min-height:100dvh;
  display:flex;flex-direction:column;align-items:center;
  -webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;
  line-height:1.5;overflow-x:hidden;
  transition:background .4s,color .4s;
}
img{max-width:100%;display:block}
a{color:inherit;text-decoration:none}
button{cursor:pointer;font-family:inherit}
input,button{border:none;outline:none;background:none;font-family:inherit}

/* ---------- SCROLLBAR ---------- */
::-webkit-scrollbar{width:5px;height:5px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb{background:var(--text4);border-radius:8px}
::-webkit-scrollbar-thumb:hover{background:var(--text3)}

/* ---------- UTILITY ---------- */
@keyframes fadeIn{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}
@keyframes fadeUp{from{opacity:0;transform:translateY(24px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}
@keyframes scaleIn{from{opacity:0;transform:scale(.92)}to{opacity:1;transform:scale(1)}}
@keyframes slideDown{from{opacity:0;transform:translateY(-16px)}to{opacity:1;transform:translateY(0)}}
@keyframes pulse{0%,100%{opacity:1}50%{opacity:.5}}
@keyframes shimmer{0%{background-position:-200% 0}100%{background-position:200% 0}}
@keyframes float{0%,100%{transform:translateY(0)}50%{transform:translateY(-8px)}}
@keyframes spin{to{transform:rotate(360deg)}}
@keyframes twinkle{0%,100%{opacity:.3}50%{opacity:1}}
@keyframes rainDrop{0%{transform:translateY(-10px) rotate(15deg);opacity:0}10%{opacity:1}90%{opacity:1}100%{transform:translateY(100vh) rotate(15deg);opacity:0}}
@keyframes snowFall{0%{transform:translateY(-10px) rotate(0);opacity:0}10%{opacity:1}90%{opacity:1}100%{transform:translateY(100vh) rotate(360deg);opacity:0}}
@keyframes cloudDrift{0%{transform:translateX(-100%)}100%{transform:translateX(100vw)}}
@keyframes sunGlow{0%,100%{box-shadow:0 0 40px rgba(255,200,50,.4),0 0 80px rgba(255,200,50,.2)}50%{box-shadow:0 0 60px rgba(255,200,50,.6),0 0 120px rgba(255,200,50,.3)}}

.anim-in{animation:fadeIn .5s ease forwards}
.anim-up{animation:fadeUp .6s ease forwards}
.anim-scale{animation:scaleIn .4s ease forwards}

/* ---------- HEADER ---------- */
.header{
  width:100%;
  padding:0 28px;
  display:flex;align-items:center;gap:16px;
  height:var(--header-h);
  position:sticky;top:0;z-index:1000;
  background:var(--glass);
  backdrop-filter:blur(20px) saturate(1.4);
  -webkit-backdrop-filter:blur(20px) saturate(1.4);
  border-bottom:1px solid var(--glass-border);
  transition:var(--transition);
}
.header-inner{
  display:flex;align-items:center;gap:16px;
  width:100%;max-width:1100px;margin:0 auto;
}

.logo{
  display:flex;align-items:center;gap:2px;flex-shrink:0;
  text-decoration:none;user-select:none;
  transition:transform .2s;
}
.logo:hover{transform:scale(1.02)}
.logo-text{
  font-size:22px;font-weight:700;
  letter-spacing:-.5px;line-height:1;
}
.logo-text .g{color:#4285f4}
.logo-text .o1{color:#ea4335}
.logo-text .g2{color:#fbbc04}
.logo-text .l{color:#34a853}
.logo-text .e{color:#4285f4}
.logo-sub{
  font-size:12px;color:var(--text2);font-weight:400;
  margin-left:6px;padding-left:8px;
  border-left:1.5px solid var(--border);
  line-height:1;letter-spacing:.2px;
}

/* Search */
.search-wrap{
  flex:1;position:relative;max-width:420px;margin-left:auto;
}
.search-wrap .search-icon{
  position:absolute;left:16px;top:50%;transform:translateY(-50%);
  font-size:20px;color:var(--text3);pointer-events:none;
  transition:color .2s;
}
.search-wrap input{
  width:100%;padding:10px 16px 10px 48px;
  border-radius:28px;background:var(--bg2);
  font-family:var(--font);font-size:15px;color:var(--text);
  transition:var(--transition);
}
.search-wrap input::placeholder{color:var(--text3)}
.search-wrap input:focus{background:var(--card);box-shadow:0 1px 6px rgba(0,0,0,.08)}
.search-wrap input:focus+.search-icon{color:var(--primary)}
.search-results{
  position:absolute;top:calc(100% + 8px);left:0;right:0;
  background:var(--card);border-radius:var(--radius-sm);
  box-shadow:var(--shadow-xl);backdrop-filter:blur(20px);
  max-height:360px;overflow-y:auto;display:none;z-index:200;
  border:1px solid var(--glass-border);
  animation:slideDown .25s ease;
}
.search-results.show{display:block}
.search-results .item{
  padding:14px 18px;cursor:pointer;display:flex;align-items:center;gap:12px;
  font-size:14px;transition:background .12s;
  color:var(--text);
}
.search-results .item:first-child{border-radius:var(--radius-sm) var(--radius-sm) 0 0}
.search-results .item:last-child{border-radius:0 0 var(--radius-sm) var(--radius-sm)}
.search-results .item:hover{background:var(--primary-light)}
.search-results .item .name{font-weight:500}
.search-results .item .admin{color:var(--text2);font-size:13px}
.search-results .item .country{color:var(--text3);font-size:12px}
.search-results .item .pin{color:var(--primary);font-size:18px}

/* Header actions */
.header-actions{
  display:flex;align-items:center;gap:6px;flex-shrink:0;
}
.icon-btn{
  width:40px;height:40px;border-radius:50%;
  display:flex;align-items:center;justify-content:center;
  color:var(--text2);transition:var(--transition);
  background:transparent;
}
.icon-btn:hover{background:var(--bg2);color:var(--text)}
.icon-btn .material-symbols-outlined{font-size:22px}
.icon-btn.active{color:var(--primary);background:var(--primary-light)}

/* ---------- CONTAINER ---------- */
.container{
  width:100%;max-width:1100px;
  padding:0 28px 60px;
  position:relative;
}

/* ---------- LOADING ---------- */
.loading{
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:120px 20px;gap:24px;
}
.loading-ring{width:48px;height:48px;border:3px solid var(--border);border-top-color:var(--primary);border-radius:50%;animation:spin .7s linear infinite}
.loading p{color:var(--text2);font-size:15px;animation:pulse 1.5s ease infinite}

/* ---------- ERROR ---------- */
.error-banner{
  background:#fce8e6;color:#c5221f;
  border-radius:var(--radius-sm);padding:16px 20px;
  margin-bottom:20px;display:none;align-items:center;gap:12px;
  font-size:14px;animation:slideDown .3s ease;
  border:1px solid rgba(197,34,31,.15);
}
.error-banner.show{display:flex}
.error-banner .material-symbols-outlined{font-size:22px;flex-shrink:0}

/* ---------- CURRENT WEATHER ---------- */
.weather-hero{
  position:relative;
  border-radius:var(--radius-lg);
  margin-bottom:var(--section-gap);
  overflow:hidden;
  animation:fadeUp .6s ease;
  min-height:420px;
}
.weather-hero-bg{
  position:absolute;inset:0;
  transition:background 1s ease;
  z-index:0;
}
.weather-hero-bg canvas{
  position:absolute;inset:0;
  width:100%;height:100%;
}
.weather-hero-content{
  position:relative;z-index:2;
  padding:36px 40px 32px;
  color:#fff;
  backdrop-filter:blur(2px);
}
.weather-hero-gradient{
  position:absolute;inset:0;z-index:1;
  pointer-events:none;
}

/* Hero top bar */
.hero-top{
  display:flex;justify-content:space-between;align-items:flex-start;
  margin-bottom:20px;flex-wrap:wrap;gap:12px;
}
.hero-location{
  display:flex;align-items:center;gap:8px;
}
.hero-location .name{
  font-size:15px;font-weight:500;opacity:.9;
  letter-spacing:.3px;
}
.hero-location .material-symbols-outlined{font-size:18px;opacity:.7}
.hero-location .time{font-size:13px;opacity:.6;margin-top:2px}
.hero-actions{
  display:flex;gap:6px;
}
.hero-actions .icon-btn{
  color:rgba(255,255,255,.7);width:36px;height:36px;
}
.hero-actions .icon-btn:hover{background:rgba(255,255,255,.12);color:#fff}

/* Hero main */
.hero-main{
  display:flex;align-items:flex-start;justify-content:space-between;
  gap:32px;flex-wrap:wrap;
}
.hero-left{flex:1;min-width:200px}
.hero-temp-row{
  display:flex;align-items:flex-start;gap:12px;
}
.hero-temp{
  font-size:88px;font-weight:300;line-height:1;
  letter-spacing:-3px;
}
.hero-temp .deg{font-size:36px;font-weight:200;vertical-align:super;letter-spacing:0}
.hero-icon .material-symbols-outlined{font-size:88px;font-weight:200;filter:drop-shadow(0 4px 12px rgba(0,0,0,.15))}
.hero-desc{font-size:20px;font-weight:400;opacity:.92;margin:8px 0 6px}
.hero-range{font-size:15px;opacity:.7;display:flex;align-items:center;gap:8px}
.hero-range .dot{width:3px;height:3px;background:rgba(255,255,255,.4);border-radius:50%}
.extra-info{
  display:flex;align-items:center;gap:16px;flex-wrap:wrap;
  margin-top:10px;font-size:14px;opacity:.75;
}
.extra-info span{display:flex;align-items:center;gap:4px}
.extra-info .material-symbols-outlined{font-size:16px}

/* Hero details grid */
.hero-details{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(130px,1fr));
  gap:8px;margin-top:24px;
}
.hero-detail{
  display:flex;align-items:center;gap:10px;
  padding:10px 12px;
  background:rgba(255,255,255,.1);
  border-radius:var(--radius-xs);
  border:1px solid rgba(255,255,255,.07);
  backdrop-filter:blur(8px);
  transition:background .2s;
}
.hero-detail:hover{background:rgba(255,255,255,.15)}
.hero-detail .material-symbols-outlined{font-size:20px;opacity:.8}
.hero-detail .info{display:flex;flex-direction:column}
.hero-detail .val{font-size:14px;font-weight:500}
.hero-detail .lbl{font-size:11px;opacity:.6;margin-top:1px}

/* Sunrise/set */
.sun-times{
  display:flex;align-items:center;gap:16px;
  margin-top:16px;
}
.sun-times .st-item{
  display:flex;align-items:center;gap:8px;
  font-size:13px;opacity:.8;
}
.sun-times .st-item .material-symbols-outlined{font-size:18px}
.sun-track{
  flex:1;height:2px;background:rgba(255,255,255,.2);border-radius:2px;
  position:relative;max-width:200px;
}
.sun-track .sun-progress{
  height:100%;background:rgba(255,255,255,.6);border-radius:2px;
  transition:width .5s ease;
}
.sun-track .sun-dot{
  position:absolute;top:50%;transform:translate(-50%,-50%);
  width:10px;height:10px;background:#fff;border-radius:50%;
  box-shadow:0 0 12px rgba(255,255,255,.6);
  transition:left .5s ease;
}

/* ---------- SECTION ---------- */
.section{
  animation:fadeUp .5s ease;
}
.section-header{
  display:flex;align-items:center;justify-content:space-between;
  padding:0 4px 14px;
  flex-wrap:wrap;gap:8px;
}
.section-header .left{
  display:flex;align-items:center;gap:8px;
  font-size:15px;font-weight:500;color:var(--text2);
}
.section-header .left .material-symbols-outlined{font-size:20px}
.section-header .right{display:flex;align-items:center;gap:6px}

/* ---------- GLASS CARD ---------- */
.glass-card{
  background:var(--card);
  border:1px solid var(--card-border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  backdrop-filter:blur(12px);
  transition:var(--transition);
}
.glass-card:hover{box-shadow:var(--shadow-lg)}
.glass-card .card-pad{padding:20px 24px}

/* ---------- HOURLY ---------- */
.hourly-section{margin-bottom:var(--section-gap)}
.hourly-card{
  background:var(--card);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  overflow:hidden;
  border:1px solid var(--card-border);
}

.hourly-chart-wrap{
  padding:20px 24px 0;
  height:140px;
  position:relative;
}
.hourly-chart-wrap canvas{width:100%;height:100%;display:block}

.hourly-scroll-wrap{
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
  padding:12px 16px 16px;
}
.hourly-scroll-wrap::-webkit-scrollbar{height:3px}
.hourly-scroll-wrap::-webkit-scrollbar-thumb{background:var(--text4);border-radius:4px}

.hourly-scroll{
  display:flex;gap:2px;
  min-width:100%;
}
.hourly-item{
  display:flex;flex-direction:column;align-items:center;gap:6px;
  min-width:68px;padding:8px 6px;
  flex-shrink:0;font-size:13px;color:var(--text);
  border-radius:var(--radius-xs);
  transition:background .15s;cursor:default;
}
.hourly-item:hover{background:var(--primary-light)}
.hourly-item .h-time{font-size:12px;color:var(--text2);font-weight:500}
.hourly-item .h-icon .material-symbols-outlined{font-size:22px}
.hourly-item .h-temp{font-weight:500;font-size:15px}
.hourly-item .h-precip{font-size:11px;color:var(--primary);display:flex;align-items:center;gap:2px}
.hourly-item .h-precip .material-symbols-outlined{font-size:12px}
.hourly-item.active{
  background:var(--primary-light);
  position:relative;
}
.hourly-item.active .h-time{color:var(--primary);font-weight:600}
.hourly-item.active .h-temp{color:var(--primary)}

/* ---------- DAILY ---------- */
.daily-section{margin-bottom:var(--section-gap)}
.daily-card{
  background:var(--card);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  border:1px solid var(--card-border);
  overflow:hidden;
}

.daily-list{padding:0 20px}
.daily-item{
  display:grid;
  grid-template-columns:80px 32px 1fr 80px 50px;
  align-items:center;gap:12px;
  padding:15px 0;font-size:14px;
  border-bottom:1px solid var(--border);
}
.daily-item:last-child{border-bottom:none}
.daily-item .day{font-weight:500;color:var(--text)}
.daily-item .day.today{color:var(--primary)}
.daily-item .d-icon{text-align:center}
.daily-item .d-icon .material-symbols-outlined{font-size:22px;color:var(--text2)}
.daily-item .temp-bar-wrap{display:flex;align-items:center;height:20px}
.daily-item .temp-bar-bg{width:100%;height:4px;background:var(--bg2);border-radius:4px;position:relative;overflow:hidden}
.daily-item .temp-bar-fill{position:absolute;height:100%;border-radius:4px;transition:width .4s ease}
.daily-item .temps{display:flex;justify-content:flex-end;gap:6px;font-size:14px}
.daily-item .temp-hi{font-weight:500;min-width:24px;text-align:right}
.daily-item .temp-lo{color:var(--text2);min-width:24px;text-align:right}
.daily-item .precip{color:var(--primary);font-size:13px;text-align:right;display:flex;align-items:center;gap:2px;justify-content:flex-end}
.daily-item .precip .material-symbols-outlined{font-size:13px}

/* ---------- METRICS GRID ---------- */
.metrics-section{margin-bottom:var(--section-gap)}
.metrics-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
  gap:12px;
}
.metric-card{
  background:var(--card);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  border:1px solid var(--card-border);
  padding:20px;
  transition:var(--transition);
}
.metric-card:hover{box-shadow:var(--shadow-lg)}
.metric-card .m-header{
  display:flex;align-items:center;justify-content:space-between;
  margin-bottom:12px;
}
.metric-card .m-header .m-title{
  font-size:13px;font-weight:500;color:var(--text2);display:flex;align-items:center;gap:6px;
}
.metric-card .m-header .m-title .material-symbols-outlined{font-size:18px}
.metric-card .m-header .m-value{
  font-size:22px;font-weight:500;color:var(--text);
}
.metric-card .m-chart{
  height:80px;width:100%;
}
.metric-card .m-chart canvas{width:100%;height:100%;display:block}
.metric-card .m-footer{
  font-size:12px;color:var(--text3);margin-top:8px;
}

/* ---------- WIND COMPASS ---------- */
.wind-compass-wrap{
  display:flex;align-items:center;gap:16px;
}
.wind-compass{
  width:72px;height:72px;border-radius:50%;
  background:var(--bg2);position:relative;flex-shrink:0;
}
.wind-compass .arrow{
  position:absolute;top:50%;left:50%;
  width:3px;height:28px;background:var(--primary);
  border-radius:3px;transform-origin:bottom center;
  transition:transform .5s ease;
}
.wind-compass .arrow::after{
  content:'';position:absolute;top:-6px;left:50%;transform:translateX(-50%);
  border-left:6px solid transparent;border-right:6px solid transparent;
  border-bottom:8px solid var(--primary);
}
.wind-compass .n-label{
  position:absolute;top:4px;left:50%;transform:translateX(-50%);
  font-size:9px;font-weight:600;color:var(--text3);
}
.wind-info{flex:1}
.wind-info .w-speed{font-size:24px;font-weight:500}
.wind-info .w-dir{font-size:13px;color:var(--text2)}

/* ---------- MAP ---------- */
.map-section{margin-bottom:var(--section-gap)}
.map-card{
  background:var(--card);
  border-radius:var(--radius);
  overflow:hidden;
  box-shadow:var(--shadow);
  border:1px solid var(--card-border);
}
.map-card .map-header{
  display:flex;align-items:center;justify-content:space-between;
  padding:16px 20px 12px;
  font-size:15px;font-weight:500;color:var(--text2);
  flex-wrap:wrap;gap:8px;
}
.map-card .map-header .map-controls{display:flex;align-items:center;gap:6px}
.map-card .map-header .map-controls button{
  background:var(--bg2);border:none;border-radius:20px;
  padding:6px 14px;font-family:var(--font);font-size:13px;
  color:var(--text2);cursor:pointer;transition:var(--transition);
  display:flex;align-items:center;gap:4px;
}
.map-card .map-header .map-controls button:hover{background:var(--border);color:var(--text)}
.map-card .map-header .map-controls button.active{background:var(--primary);color:#fff}
#map{height:420px;width:100%;background:var(--bg2)}
.map-card .map-footer{
  padding:10px 20px 14px;
  font-size:12px;color:var(--text3);
  display:flex;align-items:center;justify-content:space-between;
  flex-wrap:wrap;gap:4px;
}
.map-card .map-footer .legend{display:flex;align-items:center;gap:6px}
.map-card .map-footer .legend-bar{
  width:80px;height:8px;border-radius:4px;
  background:linear-gradient(90deg,rgba(0,200,0,.3),rgba(0,100,255,.6),rgba(255,0,0,.9));
}

/* ---------- AIR QUALITY ---------- */
.aqi-section{margin-bottom:var(--section-gap)}
.aqi-card{
  background:var(--card);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  border:1px solid var(--card-border);
  overflow:hidden;
}
.aqi-main{
  padding:24px;display:flex;align-items:center;gap:24px;
  flex-wrap:wrap;
}
.aqi-badge{
  width:80px;height:80px;border-radius:50%;
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  flex-shrink:0;font-weight:500;
}
.aqi-badge .aqi-num{font-size:28px;line-height:1}
.aqi-badge .aqi-lbl{font-size:10px;opacity:.8;margin-top:2px}
.aqi-info{flex:1;min-width:160px}
.aqi-info .aqi-title{font-size:16px;font-weight:500;margin-bottom:4px}
.aqi-info .aqi-desc{font-size:14px;color:var(--text2)}
.aqi-components{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(80px,1fr));
  gap:8px;padding:0 24px 20px;
}
.aqi-comp{
  text-align:center;padding:8px;
  background:var(--bg2);border-radius:var(--radius-xs);
}
.aqi-comp .c-val{font-size:16px;font-weight:500}
.aqi-comp .c-lbl{font-size:11px;color:var(--text2);margin-top:2px}

/* ---------- FAVORITES DROPDOWN ---------- */
.fav-dropdown{
  position:absolute;top:calc(100% + 8px);right:0;
  background:var(--card);border-radius:var(--radius-sm);
  box-shadow:var(--shadow-xl);backdrop-filter:blur(20px);
  border:1px solid var(--glass-border);
  min-width:240px;display:none;z-index:200;
  animation:slideDown .2s ease;
}
.fav-dropdown.show{display:block}
.fav-dropdown .fav-header{
  padding:14px 16px 10px;font-size:13px;font-weight:500;
  color:var(--text2);border-bottom:1px solid var(--border);
}
.fav-dropdown .fav-list{max-height:260px;overflow-y:auto}
.fav-dropdown .fav-item{
  padding:10px 16px;display:flex;align-items:center;justify-content:space-between;
  cursor:pointer;transition:background .12s;
}
.fav-dropdown .fav-item:hover{background:var(--primary-light)}
.fav-dropdown .fav-item .fav-name{font-size:14px;font-weight:500}
.fav-dropdown .fav-item .fav-temp{font-size:14px;color:var(--text2)}
.fav-dropdown .fav-item .fav-del{
  width:28px;height:28px;border-radius:50%;display:flex;
  align-items:center;justify-content:center;
  color:var(--text3);transition:var(--transition);cursor:pointer;background:none;border:none;
  font-family:inherit;
}
.fav-dropdown .fav-item .fav-del:hover{background:rgba(197,34,31,.1);color:#c5221f}
.fav-dropdown .fav-del .material-symbols-outlined{font-size:16px}
.fav-dropdown .fav-empty{padding:24px 16px;text-align:center;color:var(--text3);font-size:13px}

/* ---------- THEME TOGGLE ---------- */
.theme-toggle .material-symbols-outlined{transition:transform .4s}
[data-theme="dark"] .theme-toggle .material-symbols-outlined{transform:rotate(180deg)}

/* ---------- FOOTER ---------- */
.footer{
  text-align:center;padding:32px 20px 24px;
  color:var(--text2);font-size:13px;line-height:2;
  border-top:1px solid var(--border);
  width:100%;max-width:1100px;margin-top:auto;
}
.footer a{color:var(--primary);transition:color .2s}
.footer a:hover{text-decoration:underline}
.footer .brand{font-size:12px;color:var(--text3)}

/* ---------- TOAST ---------- */
.toast{
  position:fixed;bottom:24px;left:50%;transform:translateX(-50%) translateY(80px);
  background:var(--text);color:var(--bg);
  padding:12px 24px;border-radius:var(--radius-sm);
  font-size:14px;font-weight:500;
  box-shadow:var(--shadow-xl);z-index:9999;
  opacity:0;transition:all .4s cubic-bezier(.4,0,.2,1);
  pointer-events:none;
  white-space:nowrap;
}
.toast.show{opacity:1;transform:translateX(-50%) translateY(0)}

/* ---------- RESPONSIVE ---------- */
@media(max-width:900px){
  .header{padding:0 20px}
  .container{padding:0 20px 40px}
  .weather-hero-content{padding:28px 24px}
  .hero-temp{font-size:68px}
  .hero-temp .deg{font-size:28px}
  .hero-icon .material-symbols-outlined{font-size:68px}
  .hourly-chart-wrap{height:110px;padding:16px 16px 0}
  .hourly-scroll-wrap{padding:8px 12px 12px}
  #map{height:340px}
  .daily-item{grid-template-columns:70px 28px 1fr 68px 44px;gap:8px}
  .daily-list{padding:0 16px}
}
@media(max-width:640px){
  .header{padding:0 14px;gap:8px}
  .logo-text{font-size:19px}
  .logo-sub{font-size:11px;padding-left:6px;margin-left:4px}
  .search-wrap input{font-size:14px;padding:8px 12px 8px 38px}
  .search-wrap .search-icon{left:12px;font-size:18px}
  .container{padding:0 14px 32px}
  .weather-hero-content{padding:20px 18px}
  .hero-temp{font-size:52px;letter-spacing:-2px}
  .hero-temp .deg{font-size:22px}
  .hero-icon .material-symbols-outlined{font-size:48px}
  .hero-desc{font-size:17px}
  .hero-details{grid-template-columns:repeat(2,1fr);gap:6px}
  .hero-detail{padding:8px 10px}
  .hero-detail .val{font-size:13px}
  .sun-times{flex-wrap:wrap;gap:8px}
  .hourly-chart-wrap{height:90px;padding:12px 12px 0}
  .hourly-item{min-width:54px;padding:6px 4px}
  .hourly-item .h-icon .material-symbols-outlined{font-size:18px}
  .hourly-item .h-temp{font-size:13px}
  .daily-item{grid-template-columns:56px 24px 1fr 54px 36px;gap:6px;font-size:13px;padding:12px 0}
  .daily-item .d-icon .material-symbols-outlined{font-size:18px}
  .daily-item .temps{gap:4px;font-size:13px}
  .metrics-grid{grid-template-columns:1fr}
  .metric-card{padding:16px}
  .aqi-main{padding:18px;gap:16px}
  .aqi-badge{width:60px;height:60px}
  .aqi-badge .aqi-num{font-size:22px}
  .aqi-components{padding:0 18px 16px;grid-template-columns:repeat(3,1fr)}
  #map{height:240px}
  .map-card .map-header{font-size:14px}
  .map-card .map-header .map-controls button{padding:4px 10px;font-size:12px}
  .header-actions{gap:2px}
  .icon-btn{width:34px;height:34px}
  .icon-btn .material-symbols-outlined{font-size:20px}
  .weather-hero{min-height:auto;border-radius:20px}
}
@media(max-width:400px){
  .logo-text{font-size:17px;letter-spacing:-.3px}
  .logo-sub{display:none}
  .search-wrap input{font-size:13px;padding:7px 10px 7px 34px}
  .search-wrap .search-icon{font-size:16px;left:10px}
  .hero-temp{font-size:42px}
  .hero-temp .deg{font-size:18px}
  .hero-icon .material-symbols-outlined{font-size:38px}
  .hero-details{grid-template-columns:1fr 1fr}
  .hero-detail{padding:6px 8px;gap:6px}
  .hero-detail .val{font-size:12px}
  .daily-item{grid-template-columns:44px 20px 1fr 44px 30px;font-size:12px}
  .hourly-item{min-width:46px}
  .map-card .map-header{flex-direction:column;align-items:flex-start;gap:6px}
  #map{height:200px}
}

/* ---------- PRINT ---------- */
@media print{
  .header,.map-section,.footer{display:none}
  .glass-card,.daily-card,.hourly-card{box-shadow:none;border:1px solid #ddd}
  body{background:#fff}
}
