/* ═══════════════════════════════════════════════════════════
   SAKHA LIVE · widgets: ambient + weather carousel + metrics
   ═══════════════════════════════════════════════════════════ */

/* ─── Ambient строка (полярная ночь и т.д.) ─── */
.sakha-live {
  margin: 18px 0 12px;
  opacity: 0;
  animation: sakha-fade-in 0.8s ease 1.5s forwards;
}
.sakha-live-ambient {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: linear-gradient(
    135deg,
    rgba(93, 211, 255, 0.08),
    rgba(240, 195, 60, 0.06)
  );
  border: 1px solid rgba(93, 211, 255, 0.15);
  border-radius: 100px;
  font-size: 13px;
  color: rgba(245, 250, 255, 0.85);
  backdrop-filter: blur(8px);
  letter-spacing: 0.3px;
}
.sakha-live-icon {
  font-size: 15px;
  filter: drop-shadow(0 0 6px rgba(93, 211, 255, 0.5));
}
.sakha-live-text {
  transition: opacity 0.5s ease;
}
.sakha-live-text.is-fading { opacity: 0; }

/* ─── Погодная карусель ─── */
.sakha-weather {
  margin: 16px 0;
  padding: 14px 16px;
  background: rgba(10, 22, 40, 0.45);
  border: 1px solid rgba(240, 195, 60, 0.12);
  border-radius: 14px;
  backdrop-filter: blur(10px);
  max-width: 520px;
  opacity: 0;
  animation: sakha-fade-in 0.8s ease 1.8s forwards;
}
.sakha-weather-label {
  font-size: 10.5px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: rgba(240, 195, 60, 0.7);
  font-weight: 600;
  margin-bottom: 10px;
}
.sakha-weather-carousel {
  position: relative;
  height: 54px;
  overflow: hidden;
}
.sakha-weather-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  opacity: 0;
  transform: translateX(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  pointer-events: none;
}
.sakha-weather-slide.is-active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}
.sakha-weather-slide.is-leaving {
  opacity: 0;
  transform: translateX(-20px);
}
.sakha-weather-flag {
  font-size: 28px;
  filter: drop-shadow(0 0 8px rgba(93, 211, 255, 0.4));
}
.sakha-weather-info {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.sakha-weather-info strong {
  font-size: 16px;
  color: #fafcff;
  font-weight: 600;
  letter-spacing: 0.2px;
}
.sakha-weather-fact {
  font-size: 11.5px;
  color: rgba(93, 211, 255, 0.75);
  margin-top: 2px;
  letter-spacing: 0.3px;
}
.sakha-weather-temp {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 26px;
  font-weight: 700;
  color: #5dd3ff;
  text-shadow: 0 0 20px rgba(93, 211, 255, 0.4);
  white-space: nowrap;
}
.sakha-weather-slide[data-temp-warm] .sakha-weather-temp {
  color: #f0c33c;
  text-shadow: 0 0 20px rgba(240, 195, 60, 0.4);
}
.sakha-weather-dots {
  display: flex;
  gap: 5px;
  margin-top: 10px;
  justify-content: flex-start;
}
.sakha-weather-dot {
  width: 18px;
  height: 3px;
  background: rgba(93, 211, 255, 0.15);
  border-radius: 2px;
  transition: background 0.4s ease, width 0.4s ease;
  cursor: pointer;
  border: none;
  padding: 0;
}
.sakha-weather-dot.is-active {
  background: linear-gradient(90deg, #5dd3ff, #f0c33c);
  width: 28px;
}

/* ─── Live Metrics ─── */
.sakha-metrics {
  display: flex;
  gap: 10px;
  margin: 16px 0;
  max-width: 520px;
  opacity: 0;
  animation: sakha-fade-in 0.8s ease 2.1s forwards;
}
.sakha-metric {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 10px 12px;
  background: rgba(10, 22, 40, 0.5);
  border: 1px solid rgba(93, 211, 255, 0.12);
  border-radius: 10px;
  backdrop-filter: blur(8px);
  transition: border-color 0.3s ease, transform 0.3s ease;
}
.sakha-metric:hover {
  border-color: rgba(93, 211, 255, 0.3);
  transform: translateY(-2px);
}
.sakha-metric-icon {
  font-size: 16px;
  margin-bottom: 2px;
}
.sakha-metric-icon--live {
  animation: sakha-pulse-dot 2s ease-in-out infinite;
}
.sakha-metric-value {
  font-family: 'Inter', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: #fafcff;
  letter-spacing: -0.3px;
  line-height: 1;
}
.sakha-metric-unit {
  font-size: 12px;
  color: rgba(93, 211, 255, 0.7);
  margin-left: 2px;
  font-weight: 500;
}
.sakha-metric-label {
  font-size: 10.5px;
  color: rgba(240, 245, 255, 0.5);
  letter-spacing: 0.4px;
  text-transform: uppercase;
  margin-top: 3px;
}

/* ─── Keyframes ─── */
@keyframes sakha-fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes sakha-pulse-dot {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(46, 213, 115, 0.6)); }
  50%      { filter: drop-shadow(0 0 12px rgba(46, 213, 115, 0.9)); }
}

/* ─── Mobile ─── */
@media (max-width: 768px) {
  .sakha-weather {
    padding: 12px 14px;
  }
  .sakha-weather-temp {
    font-size: 22px;
  }
  .sakha-weather-flag {
    font-size: 24px;
  }
  .sakha-metrics {
    gap: 6px;
  }
  .sakha-metric {
    padding: 8px 10px;
  }
  .sakha-metric-value {
    font-size: 16px;
  }
  .sakha-metric-label {
    font-size: 9.5px;
  }
}

/* ─── Reduced motion ─── */
@media (prefers-reduced-motion: reduce) {
  .sakha-live, .sakha-weather, .sakha-metrics {
    opacity: 1 !important;
    animation: none !important;
  }
  .sakha-weather-slide {
    transition: opacity 0.2s !important;
    transform: none !important;
  }
  .sakha-metric-icon--live {
    animation: none !important;
  }
}

/* ═══ PR-2.5.2 additions · live weather ═══ */
.sakha-weather-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.sakha-weather-header .sakha-weather-label {
  margin-bottom: 0;
}
.sakha-weather-updated {
  font-size: 10px;
  letter-spacing: 0.6px;
  color: rgba(180, 220, 255, 0.45);
  font-weight: 500;
  white-space: nowrap;
}

/* Увеличенная высота под 3 строки текста (name / fact / meta) */
.sakha-weather-carousel {
  height: 72px;
}
.sakha-weather-meta {
  display: block;
  font-size: 11px;
  color: rgba(200, 220, 240, 0.55);
  margin-top: 3px;
  letter-spacing: 0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Тона температуры по диапазонам (dataset.tone из JS) */
.sakha-weather-slide[data-tone="cold"] .sakha-weather-temp {
  color: #5dd3ff;
  text-shadow: 0 0 20px rgba(93, 211, 255, 0.45);
}
.sakha-weather-slide[data-tone="cool"] .sakha-weather-temp {
  color: #a0d8ff;
  text-shadow: 0 0 18px rgba(160, 216, 255, 0.35);
}
.sakha-weather-slide[data-tone="mild"] .sakha-weather-temp {
  color: #f5d687;
  text-shadow: 0 0 18px rgba(245, 214, 135, 0.35);
}
.sakha-weather-slide[data-tone="warm"] .sakha-weather-temp {
  color: #f0c33c;
  text-shadow: 0 0 22px rgba(240, 195, 60, 0.5);
}

@media (max-width: 768px) {
  .sakha-weather-carousel { height: 84px; }
  .sakha-weather-meta     { font-size: 10.5px; }
  .sakha-weather-updated  { font-size: 9.5px; }
}
