:root {
  color-scheme: light;
  --bg: #f7f9fb;
  --surface: #ffffff;
  --ink: #17202a;
  --muted: #66727f;
  --line: #d8e1ea;
  --accent: #006d77;
  --accent-dark: #004f56;
  --shadow: 0 18px 50px rgba(48, 70, 88, 0.16);
  --radius: 8px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100dvh;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 249, 251, 0.98) 36%),
    var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

button {
  border: 0;
  font: inherit;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: 56px 1fr auto;
  align-items: center;
  gap: 14px;
  min-height: 82px;
  padding: calc(env(safe-area-inset-top) + 12px) clamp(18px, 4vw, 40px) 12px;
  border-bottom: 1px solid rgba(216, 225, 234, 0.72);
  background: rgba(247, 249, 251, 0.88);
  backdrop-filter: blur(18px);
}

.gallery-open .topbar {
  display: none;
}

.eyebrow {
  margin: 0 0 3px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1;
}

h2 {
  margin-bottom: 12px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.05;
  letter-spacing: 0;
}

.intro {
  max-width: 780px;
  padding: 48px clamp(18px, 5vw, 56px) 24px;
}

.intro p {
  max-width: 60ch;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.55;
}

.icon-button,
.round-button,
.install-button {
  min-height: 48px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}

.icon-button,
.round-button {
  display: grid;
  place-items: center;
  width: 48px;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
  font-size: 34px;
  line-height: 1;
}

.install-button {
  padding: 0 18px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  white-space: nowrap;
}

.icon-button:active,
.round-button:active,
.install-button:active,
.cover-card:active {
  transform: scale(0.97);
}

.cover-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 3vw, 28px);
  padding: 8px clamp(18px, 5vw, 56px) 48px;
}

.cover-card {
  position: relative;
  display: grid;
  min-height: clamp(330px, 42vw, 520px);
  overflow: hidden;
  border-radius: var(--radius);
  background: #dde7ef;
  box-shadow: var(--shadow);
  cursor: pointer;
  isolation: isolate;
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.cover-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 60px rgba(48, 70, 88, 0.2);
}

.cover-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover-card::after {
  position: absolute;
  inset: 0;
  z-index: 1;
  content: "";
  background: linear-gradient(180deg, rgba(9, 26, 34, 0.04), rgba(9, 26, 34, 0.72));
}

.cover-info {
  position: relative;
  z-index: 2;
  align-self: end;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  padding: 24px;
  color: #fff;
}

.cover-info h3 {
  margin: 0 0 7px;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1;
}

.cover-info p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 16px;
}

.cover-action {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 50%;
  font-size: 31px;
}

.gallery-view {
  position: fixed;
  inset: 0;
  z-index: 30;
  padding: 0;
  background: #000;
}

.gallery-shell {
  display: grid;
  gap: 0;
  width: 100vw;
  height: 100dvh;
  margin: 0;
}

.slide-stage {
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #000;
  box-shadow: none;
  touch-action: pan-y;
}

.slides {
  display: flex;
  transform: translate3d(0, 0, 0);
  transition: transform 260ms ease;
}

.slide {
  flex: 0 0 100%;
  display: grid;
  place-items: center;
  width: 100vw;
  height: 100dvh;
  min-height: 100dvh;
  padding: 0;
}

.slide-image-wrap {
  position: relative;
  display: grid;
  place-items: center;
  width: min(100vw, calc(100dvh * 1.333));
  height: min(100dvh, calc(100vw / 1.333));
  aspect-ratio: 2134 / 1601;
}

.slide img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  border-radius: 0;
  background: #000;
}

.image-home-button {
  position: absolute;
  top: 4.4%;
  right: 3.2%;
  z-index: 3;
  width: 6.8%;
  aspect-ratio: 1;
  border-radius: 22%;
  background: rgba(0, 109, 119, 0);
  cursor: pointer;
}

.aid-av2 .image-home-button {
  top: 2.4%;
  right: 18.1%;
  width: 6.6%;
}

.image-home-button:focus-visible {
  outline: 4px solid rgba(0, 109, 119, 0.8);
  outline-offset: 4px;
}

.controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

.gallery-open .controls {
  display: none;
}

.counter {
  min-width: 94px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
  text-align: center;
  font-weight: 800;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(env(safe-area-inset-bottom) + 22px);
  z-index: 20;
  max-width: min(420px, calc(100vw - 32px));
  padding: 13px 16px;
  border-radius: var(--radius);
  background: #17202a;
  color: #fff;
  box-shadow: 0 16px 42px rgba(23, 32, 42, 0.25);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.is-hidden {
  display: none !important;
}

@media (max-width: 760px) {
  .topbar {
    grid-template-columns: 48px 1fr;
  }

  .install-button {
    grid-column: 1 / -1;
    width: 100%;
  }

  .cover-grid {
    grid-template-columns: 1fr;
  }

  .cover-card {
    min-height: 360px;
  }

  .slide {
    min-height: 100dvh;
  }

  .slide img {
    max-height: none;
  }
}
