@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap");

:root {
  /* Color Palette */
  --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --accent-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  --glass-bg: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.2);
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.8);
  --text-muted: rgba(255, 255, 255, 0.6);
  --shadow-light: 0 8px 32px rgba(31, 38, 135, 0.37);
  --shadow-medium: 0 15px 35px rgba(31, 38, 135, 0.2);
  --shadow-heavy: 0 25px 50px rgba(31, 38, 135, 0.3);
  --border-radius: 20px;
  --border-radius-small: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  background-attachment: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.2) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
  animation: backgroundShift 20s ease-in-out infinite;
}

@keyframes backgroundShift {
  0%, 100% { 
    background: 
      radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
      radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
      radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.2) 0%, transparent 50%);
  }
  50% { 
    background: 
      radial-gradient(circle at 80% 20%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
      radial-gradient(circle at 20% 80%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
      radial-gradient(circle at 60% 60%, rgba(120, 219, 255, 0.2) 0%, transparent 50%);
  }
}

/* Floating Weather Elements */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="40" r="1.5" fill="rgba(255,255,255,0.08)"/><circle cx="40" cy="80" r="1" fill="rgba(255,255,255,0.06)"/><circle cx="90" cy="90" r="1.5" fill="rgba(255,255,255,0.1)"/><circle cx="10" cy="60" r="1" fill="rgba(255,255,255,0.08)"/><circle cx="70" cy="10" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="30" cy="50" r="1" fill="rgba(255,255,255,0.06)"/><circle cx="60" cy="70" r="1.5" fill="rgba(255,255,255,0.08)"/></svg>');
  background-size: 200px 200px;
  animation: floatingParticles 15s linear infinite;
  pointer-events: none;
  z-index: -1;
}

@keyframes floatingParticles {
  0% { transform: translateY(0) rotate(0deg); }
  100% { transform: translateY(-100px) rotate(360deg); }
}

/* Weather-specific background animations */
.weather-clouds {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  opacity: 0.3;
}

.weather-clouds::before {
  content: '☁️';
  position: absolute;
  font-size: 60px;
  top: 10%;
  left: -10%;
  animation: cloudMove1 25s linear infinite;
}

.weather-clouds::after {
  content: '☁️';
  position: absolute;
  font-size: 40px;
  top: 30%;
  right: -10%;
  animation: cloudMove2 30s linear infinite;
}

@keyframes cloudMove1 {
  0% { transform: translateX(0); }
  100% { transform: translateX(calc(100vw + 100px)); }
}

@keyframes cloudMove2 {
  0% { transform: translateX(0); }
  100% { transform: translateX(calc(-100vw - 100px)); }
}

/* Rain animation */
.weather-rain {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  opacity: 0.6;
}

.weather-rain::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: rainFall1 1s linear infinite;
}

.weather-rain::after {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.2), transparent);
  animation: rainFall2 1.2s linear infinite;
}

@keyframes rainFall1 {
  0% { transform: translateY(-100vh); }
  100% { transform: translateY(100vh); }
}

@keyframes rainFall2 {
  0% { transform: translateY(-100vh); }
  100% { transform: translateY(100vh); }
}

/* Snow animation */
.weather-snow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  opacity: 0.8;
}

.weather-snow::before {
  content: '❄️';
  position: absolute;
  font-size: 20px;
  top: -20px;
  left: 10%;
  animation: snowFall1 8s linear infinite;
}

.weather-snow::after {
  content: '❄️';
  position: absolute;
  font-size: 15px;
  top: -20px;
  left: 80%;
  animation: snowFall2 10s linear infinite;
}

@keyframes snowFall1 {
  0% { 
    transform: translateY(0) rotate(0deg); 
    opacity: 1;
  }
  100% { 
    transform: translateY(100vh) rotate(360deg); 
    opacity: 0;
  }
}

@keyframes snowFall2 {
  0% { 
    transform: translateY(0) rotate(0deg); 
    opacity: 1;
  }
  100% { 
    transform: translateY(100vh) rotate(-360deg); 
    opacity: 0;
  }
}

/* Sun rays animation */
.weather-sun {
  position: fixed;
  top: 20%;
  right: 10%;
  width: 100px;
  height: 100px;
  pointer-events: none;
  z-index: -1;
  opacity: 0.4;
}

.weather-sun::before {
  content: '☀️';
  position: absolute;
  font-size: 80px;
  animation: sunRotate 20s linear infinite;
}

@keyframes sunRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow-heavy);
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 60px rgba(31, 38, 135, 0.4);
}

/* Floating weather icons around the card */
.card::after {
  content: '🌤️';
  position: absolute;
  top: -20px;
  right: -20px;
  font-size: 30px;
  animation: floatAround 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

@keyframes floatAround {
  0%, 100% { 
    transform: translateY(0) rotate(0deg); 
    opacity: 0.6;
  }
  50% { 
    transform: translateY(-10px) rotate(180deg); 
    opacity: 0.8;
  }
}

/* Additional floating elements */
.weather-elements {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
}

.weather-elements::before {
  content: '🌡️';
  position: absolute;
  top: 15%;
  left: 5%;
  font-size: 24px;
  animation: floatUpDown 4s ease-in-out infinite;
  opacity: 0.7;
}

.weather-elements::after {
  content: '💨';
  position: absolute;
  top: 70%;
  right: 5%;
  font-size: 20px;
  animation: floatLeftRight 5s ease-in-out infinite;
  opacity: 0.6;
}

@keyframes floatUpDown {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

@keyframes floatLeftRight {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(10px); }
}

/* Weather-specific body styles */
.weather-clear {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
}

.weather-cloudy {
  background: linear-gradient(135deg, #bdc3c7 0%, #2c3e50 50%, #34495e 100%);
}

.weather-rainy {
  background: linear-gradient(135deg, #74b9ff 0%, #0984e3 50%, #6c5ce7 100%);
}

.weather-snowy {
  background: linear-gradient(135deg, #ddd6fe 0%, #a5b4fc 50%, #c7d2fe 100%);
}

.weather-stormy {
  background: linear-gradient(135deg, #2d3436 0%, #636e72 50%, #74b9ff 100%);
}

/* Enhanced rain animation for rainy weather */
.weather-rainy .weather-rain::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 2px,
      rgba(255, 255, 255, 0.1) 2px,
      rgba(255, 255, 255, 0.1) 4px
    ),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 2px,
      rgba(255, 255, 255, 0.1) 2px,
      rgba(255, 255, 255, 0.1) 4px
    );
  animation: rainPattern 0.5s linear infinite;
}

@keyframes rainPattern {
  0% { transform: translateY(-100vh); }
  100% { transform: translateY(100vh); }
}

/* Enhanced snow animation for snowy weather */
.weather-snowy .weather-snow::before {
  content: '❄️ ❄️ ❄️ ❄️ ❄️';
  position: absolute;
  top: -50px;
  left: 0;
  width: 100%;
  font-size: 16px;
  animation: snowFall1 8s linear infinite;
  white-space: nowrap;
  overflow: hidden;
}

.weather-snowy .weather-snow::after {
  content: '❄️ ❄️ ❄️ ❄️ ❄️';
  position: absolute;
  top: -50px;
  left: 0;
  width: 100%;
  font-size: 12px;
  animation: snowFall2 10s linear infinite;
  white-space: nowrap;
  overflow: hidden;
}

/* Enhanced cloud animation for cloudy weather */
.weather-cloudy .weather-clouds::before {
  content: '☁️ ☁️ ☁️';
  position: absolute;
  top: 10%;
  left: -20%;
  font-size: 50px;
  animation: cloudMove1 25s linear infinite;
  white-space: nowrap;
}

.weather-cloudy .weather-clouds::after {
  content: '☁️ ☁️';
  position: absolute;
  top: 30%;
  right: -20%;
  font-size: 40px;
  animation: cloudMove2 30s linear infinite;
  white-space: nowrap;
}

/* Enhanced sun animation for clear weather */
.weather-clear .weather-sun::before {
  content: '☀️';
  position: absolute;
  font-size: 100px;
  animation: sunRotate 20s linear infinite, sunPulse 3s ease-in-out infinite;
}

@keyframes sunPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* Interactive floating elements that respond to mouse movement */
.weather-elements {
  transition: all 0.3s ease;
}

.weather-elements:hover::before {
  animation-duration: 2s;
  transform: scale(1.2);
}

.weather-elements:hover::after {
  animation-duration: 3s;
  transform: scale(1.1);
}

/* Parallax effect for floating elements */
.weather-elements::before {
  transition: transform 0.1s ease;
}

.weather-elements::after {
  transition: transform 0.1s ease;
}

/* Add more floating weather icons */
.weather-elements {
  background-image: 
    url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text x="10" y="20" font-size="20">🌡️</text><text x="80" y="40" font-size="15">💨</text><text x="20" y="80" font-size="18">🌤️</text><text x="70" y="90" font-size="16">🌦️</text></svg>');
  background-size: 300px 300px;
  background-repeat: repeat;
  animation: floatingWeatherIcons 20s linear infinite;
}

@keyframes floatingWeatherIcons {
  0% { transform: translateY(0) translateX(0); }
  25% { transform: translateY(-20px) translateX(10px); }
  50% { transform: translateY(-10px) translateX(-10px); }
  75% { transform: translateY(-30px) translateX(5px); }
  100% { transform: translateY(0) translateX(0); }
}

/* Enhanced card animations based on weather */
.weather-clear .card {
  box-shadow: 0 25px 50px rgba(255, 215, 0, 0.2);
}

.weather-cloudy .card {
  box-shadow: 0 25px 50px rgba(108, 117, 125, 0.3);
}

.weather-rainy .card {
  box-shadow: 0 25px 50px rgba(13, 110, 253, 0.3);
}

.weather-snowy .card {
  box-shadow: 0 25px 50px rgba(108, 117, 125, 0.4);
}

.weather-stormy .card {
  box-shadow: 0 25px 50px rgba(33, 37, 41, 0.4);
}

/* Add subtle weather-themed border effects */
.weather-clear .card::before {
  background: linear-gradient(90deg, transparent, rgba(255, 215, 0, 0.3), transparent);
}

.weather-cloudy .card::before {
  background: linear-gradient(90deg, transparent, rgba(108, 117, 125, 0.3), transparent);
}

.weather-rainy .card::before {
  background: linear-gradient(90deg, transparent, rgba(13, 110, 253, 0.3), transparent);
}

.weather-snowy .card::before {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
}

.weather-stormy .card::before {
  background: linear-gradient(90deg, transparent, rgba(33, 37, 41, 0.3), transparent);
}

.search {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 1.5rem;
}

.search input {
  border: none;
  outline: none;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  color: var(--text-primary);
  padding: 16px 24px;
  height: 56px;
  border-radius: 28px;
  flex: 1;
  font-size: 16px;
  font-weight: 400;
  transition: var(--transition);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.search input::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}

.search input:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.search button, .search-btn {
  border: none;
  outline: none;
  background: var(--accent-gradient);
  border-radius: 50%;
  width: 56px;
  height: 56px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-light);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.search button:hover, .search-btn:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: var(--shadow-medium);
}

.search button:active, .search-btn:active {
  transform: translateY(0) scale(0.95);
}

.search img {
  width: 20px;
  height: 20px;
  filter: brightness(0) invert(1);
}

/* Unit Toggle Button */
.unit-toggle {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.unit-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  padding: 12px 24px;
  border-radius: 25px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.unit-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.unit-btn:hover::before {
  left: 100%;
}

.unit-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
  box-shadow: var(--shadow-light);
}

.unit-btn:active {
  transform: translateY(0);
}

/* Loading Spinner */
.loading-spinner {
  width: 48px;
  height: 48px;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top: 3px solid var(--text-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
  position: relative;
}

.loading-spinner::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-top: 2px solid var(--text-secondary);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: spin 0.8s linear infinite reverse;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading p {
  color: var(--text-secondary);
  font-size: 1rem;
  margin: 0;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.weather-icon {
  width: 120px;
  height: 120px;
  margin: 1.5rem 0;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.1));
  transition: var(--transition);
}

.weather-icon:hover {
  transform: scale(1.05) rotate(5deg);
}

.weather h1 {
  font-size: 4rem;
  font-weight: 300;
  color: var(--text-primary);
  margin: 0.5rem 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  letter-spacing: -0.02em;
}

.weather h2 {
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  letter-spacing: 0.02em;
}

.details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin: 2rem 0;
}

.additional-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.details .col,
.additional-details .col {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--border-radius-small);
  padding: 1.5rem 1rem;
  text-align: center;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.details .col::before,
.additional-details .col::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.details .col:hover::before,
.additional-details .col:hover::before {
  transform: scaleX(1);
}

.details .col:hover,
.additional-details .col:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
  box-shadow: var(--shadow-light);
}

.details .col img {
  width: 40px;
  height: 40px;
  margin-bottom: 0.5rem;
  filter: brightness(0) invert(1);
  opacity: 0.8;
}

.humidity,
.wind {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0.5rem 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.feels-like,
.pressure {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
  margin: 0.5rem 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.details .col p:last-child,
.additional-details .col p:last-child {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.weather {
  display: none;
  animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeInUp {
  from { 
    opacity: 0; 
    transform: translateY(30px) scale(0.95); 
  }
  to { 
    opacity: 1; 
    transform: translateY(0) scale(1); 
  }
}

@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.details .col:first-child {
  animation: slideInFromLeft 0.6s ease-out 0.2s both;
}

.details .col:last-child {
  animation: slideInFromRight 0.6s ease-out 0.2s both;
}

.additional-details .col:first-child {
  animation: slideInFromLeft 0.6s ease-out 0.4s both;
}

.additional-details .col:last-child {
  animation: slideInFromRight 0.6s ease-out 0.4s both;
}

/* Mobile First Responsive Design */
@media screen and (max-width: 768px) {
  .card {
    padding: 1.5rem;
    margin: 0;
    max-width: 100%;
  }
  
  .search input {
    font-size: 16px;
    padding: 14px 20px;
    height: 52px;
  }
  
  .search button, .search-btn {
    width: 52px;
    height: 52px;
  }
  
  .unit-btn {
    font-size: 13px;
    padding: 10px 20px;
  }
  
  .weather h1 {
    font-size: 3rem;
  }
  
  .weather h2 {
    font-size: 1.25rem;
  }
  
  .weather-icon {
    width: 100px;
    height: 100px;
  }
}

@media screen and (max-width: 490px) {
  .card {
    padding: 1.25rem;
    margin: 0;
    width: 100%;
  }

  .search {
    gap: 8px;
  }

  .search input {
    padding: 12px 16px;
    height: 48px;
    font-size: 15px;
  }

  .search button, .search-btn {
    width: 48px;
    height: 48px;
  }

  .search img {
    width: 18px;
    height: 18px;
  }

  .weather-icon {
    width: 90px;
    height: 90px;
    margin: 1rem 0;
  }

  .weather h1 {
    font-size: 2.5rem;
    margin: 0.5rem 0;
  }
  
  .weather h2 {
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
  }

  .details,
  .additional-details {
    gap: 1rem;
    margin: 1.5rem 0;
  }

  .details .col,
  .additional-details .col {
    padding: 1rem 0.75rem;
  }

  .humidity,
  .wind {
    font-size: 1.5rem;
  }
  
  .feels-like,
  .pressure {
    font-size: 1.125rem;
  }
  
  .details .col p:last-child,
  .additional-details .col p:last-child {
    font-size: 0.75rem;
  }
  
  .unit-btn {
    font-size: 12px;
    padding: 8px 16px;
  }
  
  .loading-spinner {
    width: 36px;
    height: 36px;
    border-width: 2px;
  }
  
  .loading-spinner::after {
    width: 16px;
    height: 16px;
    border-width: 1px;
  }
  
  .loading p {
    font-size: 0.875rem;
  }
}
/* Height-based responsive adjustments */
@media screen and (max-height: 576px) {
  .card {
    padding: 1rem;
  }
  
  .weather-icon {
    width: 80px;
    height: 80px;
  }
  
  .weather h1 {
    font-size: 2rem;
  }
  
  .weather h2 {
    font-size: 1rem;
  }
  
  .details,
  .additional-details {
    margin: 1rem 0;
    gap: 0.75rem;
  }
  
  .details .col,
  .additional-details .col {
    padding: 0.75rem 0.5rem;
  }
}

@media screen and (max-height: 480px) {
  .weather {
    max-height: 300px;
    overflow-y: auto;
  }
  
  .weather-icon {
    width: 60px;
    height: 60px;
  }
  
  .weather h1 {
    font-size: 1.75rem;
  }
  
  .weather h2 {
    font-size: 0.875rem;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  :root {
    --glass-bg: rgba(0, 0, 0, 0.2);
    --glass-border: rgba(255, 255, 255, 0.1);
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}