* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  background-color: #d2e3e2;
  color: #000;
  overflow: hidden;
}

@media (min-width: 900px) {
  body {
    background-color: #d6e6d9;
  }
}

.bg-pattern {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.bg-pattern svg {
  width: 100%;
  height: 100%;
  display: block;
}

.bg-pattern--1 {
  display: block;
}

.bg-pattern--2 {
  display: none;
}

@media (min-width: 900px) {
  .bg-pattern--1 {
    display: none;
  }

  .bg-pattern--2 {
    display: block;
  }
}

.main {
  position: relative;
  z-index: 1;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8vmin 6vmin clamp(4.5rem, 12vmin, 6rem);
  text-align: center;
}

.headline {
  font-family: "Cinzel", Georgia, "Times New Roman", serif;
  font-size: clamp(1.9rem, 8.5vw, 3.6rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.32;
  text-transform: uppercase;
  margin-bottom: clamp(1.75rem, 6vmin, 3rem);
}

.headline span {
  display: block;
}

.icon-wrap {
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #000;
  border-radius: 15px;
  width: clamp(104px, 32vmin, 168px);
  height: clamp(104px, 32vmin, 168px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
}

.icon-wrap svg {
  display: block;
  flex: 0 0 auto;
  width: 75%;
  height: 75%;
  min-width: 56px;
  min-height: 56px;
}

.connection-status {
  position: fixed;
  top: max(16px, env(safe-area-inset-top, 0px));
  left: max(16px, env(safe-area-inset-left, 0px));
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.connection-status__oval {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #000;
  border-radius: 999px;
  padding: 7px 14px 7px 10px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.connection-google-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #000;
  border-radius: 50%;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  text-decoration: none;
  color: inherit;
  transition: background 0.15s ease, transform 0.15s ease;
}

.connection-google-circle:hover {
  background: #f3f4f6;
}

.connection-google-circle:active {
  transform: scale(0.96);
}

.connection-google-circle svg {
  display: block;
  width: 24px;
  height: 24px;
}

.connection-google-circle--fixed-tr {
  position: fixed;
  top: max(16px, env(safe-area-inset-top, 0px));
  right: max(16px, env(safe-area-inset-right, 0px));
  left: auto;
  z-index: 2;
}

.connection-datetime-oval {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: #fff;
  border: 1px solid #000;
  border-radius: 999px;
  padding: 10px 18px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.connection-status__dot {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  background: #22c55e;
  border: 2px solid #000;
  border-radius: 50%;
  box-sizing: content-box;
}

.connection-status__label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.15;
  color: #000;
  white-space: nowrap;
}

.connection-status__datetime {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  margin: 0;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: #1a1a1a;
  text-align: center;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}

.connection-status__date {
  opacity: 0.85;
}

.connection-status__time {
  font-weight: 600;
}

.wifi-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.25rem, 4vmin, 2rem);
}

.google-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: #fff;
  border: 1px solid #000;
  border-radius: 999px;
  color: #000;
  text-decoration: none;
  font-size: clamp(1.1rem, 4vw, 1.35rem);
  font-weight: 600;
  transition: background 0.15s ease, transform 0.15s ease;
}

.google-link:hover {
  background: #f3f4f6;
}

.google-link:active {
  transform: scale(0.98);
}

.google-link__logo {
  display: block;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.greeting-footer {
  position: fixed;
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
  left: max(16px, env(safe-area-inset-left, 0px));
  z-index: 2;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.greeting-footer__burger {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  padding: 0;
  margin: 0;
  border: 1px solid #000;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.greeting-footer__burger:hover {
  background: #f3f4f6;
}

.greeting-footer__burger:active {
  transform: scale(0.96);
}

.greeting-footer__burger-line {
  display: block;
  width: 18px;
  height: 2px;
  background: #000;
  border-radius: 1px;
}

.weather-popup--hidden {
  display: none !important;
}

.weather-popup {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right))
    max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.2s ease, visibility 0.2s;
}

.weather-popup.is-open {
  pointer-events: auto;
  visibility: visible;
  opacity: 1;
}

.weather-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  cursor: pointer;
}

.weather-popup__card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 380px;
  max-height: min(88vh, 560px);
  overflow-y: auto;
  background: #fff;
  border: 1px solid #000;
  border-radius: 16px;
  padding: 20px 20px 18px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.weather-popup__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #fff;
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
  color: #1a1a1a;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: background 0.2s ease, transform 0.25s cubic-bezier(0.34, 1.2, 0.64, 1), box-shadow 0.2s ease;
}

.weather-popup__close:hover {
  background: #f5f5f5;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
  transform: rotate(90deg);
}

.weather-popup__close:active {
  transform: rotate(90deg) scale(0.95);
}

.weather-popup__greeting-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  margin: 0 44px 8px 0;
}

.weather-popup__greeting-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(160deg, rgba(255, 95, 21, 0.16) 0%, rgba(34, 197, 94, 0.12) 100%);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.05);
}

.weather-popup__greeting-material {
  font-size: clamp(22px, 6vw, 28px);
  line-height: 1;
  color: #000;
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 40;
}

.weather-popup__greeting {
  margin: 0;
  font-family: "Cinzel", Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 4.5vw, 1.75rem);
  font-weight: 600;
  letter-spacing: 0.06em;
  color: #000;
  line-height: 1.2;
}

.weather-popup__subtitle {
  margin: 0 36px 14px 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #444;
}

.speed-fab {
  position: fixed;
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
  right: max(16px, env(safe-area-inset-right, 0px));
  z-index: 3;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 2px solid #c4001a;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 14px rgba(196, 0, 26, 0.2);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.speed-fab:hover {
  background: #fff5f5;
  box-shadow: 0 4px 18px rgba(196, 0, 26, 0.28);
}

.speed-fab:active {
  transform: scale(0.96);
}

.speed-fab__icon {
  font-size: 1.65rem !important;
  color: #c4001a;
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}

.speed-popup {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right))
    max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.2s ease, visibility 0.2s;
}

.speed-popup.is-open {
  pointer-events: auto;
  visibility: visible;
  opacity: 1;
}

.speed-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  cursor: pointer;
}

.speed-popup__card {
  position: relative;
  z-index: 1;
  width: min(560px, 100%);
  max-height: min(92vh, 720px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.speed-popup__close {
  color: #c4001a;
}

.speed-popup__close:hover {
  color: #8f0012;
}

.speed-popup__title {
  margin: 0 44px 8px 0;
  padding-bottom: 8px;
  border-bottom: 3px solid #c4001a;
  font-size: clamp(1.2rem, 4.5vw, 1.45rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: #111;
}

.speed-popup__lead {
  margin: 0 36px 8px 0;
  font-size: 0.8rem;
  line-height: 1.5;
  color: #333;
}

.speed-popup__lead strong {
  color: #000;
}

.speed-popup__hint {
  margin: 0 36px 12px 0;
  font-size: 0.74rem;
  line-height: 1.45;
  color: #555;
}

.speed-popup__frame-wrap {
  flex: 1;
  min-height: min(420px, 55vh);
  margin: 0 0 14px;
  border: 2px solid #e8e8e8;
  border-radius: 14px;
  overflow: hidden;
  background: #1a1a1a;
  box-shadow: inset 0 0 0 1px rgba(196, 0, 26, 0.12);
}

.speed-popup__iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: min(420px, 55vh);
  border: 0;
  background: #fff;
}

.speed-popup__shortcuts-title {
  margin: 0 36px 8px 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #666;
}

.speed-popup__shortcuts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 0 36px 0 0;
}

.speed-popup__shortcut {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 88px;
  padding: 10px 6px;
  border: 1px solid #e0e0e0;
  border-radius: 14px;
  background: linear-gradient(180deg, #fff 0%, #fafafa 100%);
  text-decoration: none;
  color: #111;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.12s ease, box-shadow 0.15s ease;
}

.speed-popup__shortcut:hover {
  border-color: #c4001a;
  background: #fff;
  box-shadow: 0 4px 14px rgba(196, 0, 26, 0.12);
  transform: translateY(-1px);
}

.speed-popup__shortcut:focus-visible {
  outline: 2px solid #c4001a;
  outline-offset: 2px;
}

.speed-popup__shortcut-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #eee;
}

.speed-popup__shortcut-icon {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.speed-popup__shortcut-icon--fast {
  border-radius: 4px;
}

.speed-popup__shortcut-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.2;
  max-width: 100%;
}

.weather-popup__state {
  font-size: 0.9rem;
  line-height: 1.45;
  color: #333;
}

.weather-popup__place {
  margin: 0 0 12px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  color: #000;
}

.weather-popup__current {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
  padding: 12px 14px;
  background: #f4f7f6;
  border: 1px solid #ddd;
  border-radius: 12px;
}

.weather-popup__cloud-icon {
  flex-shrink: 0;
  width: 56px;
  height: 42px;
}

.weather-popup__current-text {
  min-width: 0;
}

.weather-popup__current-desc {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 600;
  color: #000;
}

.weather-popup__current-temp {
  margin: 0;
  font-size: 0.85rem;
  color: #333;
}

.weather-popup__forecast-title {
  margin: 0 0 8px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #555;
}

.weather-popup__forecast {
  list-style: none;
  margin: 0;
  padding: 0;
}

.weather-popup__forecast-item {
  display: grid;
  grid-template-columns: 1fr 1.2fr auto;
  gap: 8px;
  align-items: baseline;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  font-size: 0.82rem;
}

.weather-popup__forecast-item:last-child {
  border-bottom: none;
}

.weather-popup__forecast-day {
  font-weight: 600;
  color: #000;
}

.weather-popup__forecast-desc {
  color: #444;
}

.weather-popup__forecast-temps {
  font-variant-numeric: tabular-nums;
  color: #000;
  text-align: right;
}
