/* Escape Game Studio — start page + floating dock (aligned with reference site) */

:root {
  --red: #e63946;
  --red-dark: #c62f3a;
  --cyan-muted: #29b6f6;
  --cyan: #4ec8ff;
  --navy: #050a12;
  --navy-elevated: #0f1929;
  --text: #f1f5f9;
  --text-muted: #8b9cb3;
  --font-display: "Syne", system-ui, sans-serif;
  --font-body: "Plus Jakarta Sans", system-ui, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  --radius-lg: 20px;

  /* Game strip cards (match reference) */
  --game-card-shell: linear-gradient(165deg, #131f30 0%, #0c1524 48%, #080f18 100%);
  --game-card-shell-border: rgba(255, 255, 255, 0.1);
  --game-card-meta: linear-gradient(165deg, #2a3f58 0%, #1e2d42 55%, #172536 100%);
  --game-card-meta-border: rgba(110, 200, 255, 0.42);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* Snap only on the one-page home layout; otherwise mandatory snap fights content after the last section (e.g. footer). */
html:has(body.page--home) {
  scroll-snap-type: y mandatory;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: radial-gradient(900px 480px at 12% 10%, rgba(78, 200, 255, 0.08), transparent 55%),
    radial-gradient(760px 420px at 88% 88%, rgba(230, 57, 70, 0.06), transparent 58%),
    linear-gradient(180deg, #060d18 0%, var(--navy) 45%, #020508 100%);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* —— Full-viewport sections + scroll snap —— */
.snap-section {
  position: relative;
  height: 100vh;
  height: 100dvh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  box-sizing: border-box;
  overflow: hidden;
}

.snap-section__scroll {
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 1.75rem 1rem calc(5.75rem + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}

/* Contact + footer share one document scroll (no nested scroller) so the footer is reachable. */
.page--home .contact.snap-section {
  height: auto;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: visible;
}

.page--home .contact .snap-section__scroll {
  height: auto;
  overflow: visible;
  -webkit-overflow-scrolling: auto;
}

/* —— Floating bottom dock —— */
.dock {
  position: fixed;
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 10050;
  width: max-content;
  max-width: min(calc(100vw - 1rem), 720px);
  pointer-events: none;
}

.dock__list {
  pointer-events: auto;
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  margin: 0;
  padding: 0.5rem 0.65rem;
  list-style: none;
  background: linear-gradient(180deg, rgba(252, 253, 255, 0.97) 0%, rgba(226, 232, 241, 0.95) 100%);
  backdrop-filter: blur(12px) saturate(120%);
  -webkit-backdrop-filter: blur(12px) saturate(120%);
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(78, 200, 255, 0.45),
    0 8px 32px rgba(0, 0, 0, 0.35),
    0 20px 50px rgba(15, 23, 42, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  overflow: hidden;
  max-width: 100%;
}

/* Goo blob indicator: allow blur to extend slightly inside the bar */
.dock__list--blob {
  overflow: visible;
}

/* Sliding selector: JS positions this; links use transparent “pill” when active */
.dock__indicator {
  --x: 0px;
  --y: 0px;
  --w: 0px;
  --h: 0px;
  position: absolute;
  left: 0;
  top: 0;
  width: var(--w);
  height: var(--h);
  transform: translate3d(var(--x), var(--y), 0);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  box-shadow: 0 4px 16px rgba(230, 57, 70, 0.45);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    width 0.38s cubic-bezier(0.22, 1, 0.36, 1),
    height 0.38s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.15s ease,
    box-shadow 0.35s ease;
}

.dock__list--blob .dock__indicator {
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  width: auto;
  height: auto;
  transform: none;
  border-radius: 0;
  background: none;
  box-shadow: none;
  transition: opacity 0.15s ease;
}

.dock__list:not(.dock__list--blob) .dock__blob-svg {
  display: none;
}

.dock__blob-svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 3px 10px rgba(230, 57, 70, 0.42));
}

.dock__list--has-indicator .dock__indicator {
  opacity: 1;
}

.dock__indicator--line {
  box-shadow: 0 2px 10px rgba(230, 57, 70, 0.32);
}

.dock__indicator--instant {
  transition: none !important;
}

.dock__list li {
  flex: 0 0 auto;
}

.dock__list a {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #334155;
  text-decoration: none;
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
  white-space: nowrap;
  transform: scale(1);
  position: relative;
  z-index: 1;
  transition:
    color 0.32s var(--ease-out),
    background 0.32s var(--ease-out),
    box-shadow 0.32s var(--ease-out),
    transform 0.32s var(--ease-out);
}

.dock__list a:hover {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.08);
}

.dock__list a[aria-current="page"] {
  color: #fff;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  box-shadow: 0 4px 16px rgba(230, 57, 70, 0.45);
  transform: scale(1.06);
}

.dock__list--has-indicator a[aria-current="page"] {
  background: transparent;
  box-shadow: none;
}

.dock__list.dock--transitioning a {
  color: #334155 !important;
  background: transparent !important;
  box-shadow: none !important;
  transform: scale(1) !important;
}

.dock__list.dock--transitioning a:hover {
  color: #0f172a !important;
  background: rgba(15, 23, 42, 0.08) !important;
}

.dock__list a:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 2px;
}

/* —— Top-right account (slides off-screen to the right when scrolling) —— */
.auth-corner {
  position: fixed;
  top: calc(max(0.75rem, env(safe-area-inset-top, 0px)) + 0.5rem);
  right: calc(max(0.75rem, env(safe-area-inset-right, 0px)) + 1.25rem);
  z-index: 10051;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem;
  max-width: min(calc(100vw - 1.5rem), 320px);
  padding: 0.45rem 0.55rem;
  background: linear-gradient(180deg, rgba(252, 253, 255, 0.97) 0%, rgba(226, 232, 241, 0.95) 100%);
  backdrop-filter: blur(12px) saturate(120%);
  -webkit-backdrop-filter: blur(12px) saturate(120%);
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(78, 200, 255, 0.45),
    0 8px 28px rgba(0, 0, 0, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: transform 0.45s var(--ease-out), opacity 0.35s ease;
}

.auth-corner.auth-corner--away {
  transform: translateX(calc(100% + 1.25rem));
  opacity: 0;
  pointer-events: none;
}

.auth-corner__role {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  white-space: nowrap;
  user-select: none;
  line-height: 1;
}

.auth-corner__role[hidden] {
  display: none !important;
}

.auth-corner__link,
.auth-corner__trigger {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #334155;
  text-decoration: none;
  padding: 0.45rem 0.85rem;
  line-height: 1;
  border-radius: 999px;
  white-space: nowrap;
  transition: color 0.2s var(--ease-out), background 0.2s var(--ease-out);
}

button.auth-corner__link {
  -webkit-appearance: none;
  appearance: none;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: inherit;
}

.auth-corner__trigger {
  -webkit-appearance: none;
  appearance: none;
  border: none;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
}

.auth-corner__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
  border-radius: 999px;
  padding: 0.38rem 0.7rem;
  line-height: 1;
  flex: 0 0 auto;
}

.auth-corner__who {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 14.5rem;
  white-space: nowrap;
}

.auth-corner__chev {
  opacity: 0.65;
  flex: 0 0 auto;
}

.auth-corner__link:hover {
  color: #0f172a;
  background: rgba(15, 23, 42, 0.08);
}

.auth-corner__link:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 2px;
}

.auth-corner__link[hidden] {
  display: none !important;
}

.auth-corner__link--signout {
  color: #2563eb;
  font-weight: 600;
}

.auth-corner__link--signout:hover {
  color: #1d4ed8;
}

.auth-corner__menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  right: 0;
  min-width: 210px;
  padding: 0.4rem;
  border-radius: 18px;
  background: rgba(252, 253, 255, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(12px) saturate(120%);
  -webkit-backdrop-filter: blur(12px) saturate(120%);
}

.auth-corner__menuitem {
  display: block;
  padding: 0.65rem 0.75rem;
  border-radius: 14px;
  font-weight: 700;
  font-size: 0.8rem;
  color: #0f172a;
  letter-spacing: 0.02em;
}

.auth-corner__menuitem:hover {
  background: rgba(15, 23, 42, 0.08);
}

.auth-corner__menuitem:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 2px;
}

@media (max-width: 380px) {
  .dock__list a {
    font-size: 0.6875rem;
    padding: 0.5rem 0.65rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dock__indicator {
    transition: none;
  }
}

/* —— Home hero —— */
.home {
  --sticker-outline: #0a0a0a;
  --home-sticker-shadows:
    drop-shadow(2px 0 0 var(--sticker-outline)) drop-shadow(-2px 0 0 var(--sticker-outline))
    drop-shadow(0 2px 0 var(--sticker-outline)) drop-shadow(0 -2px 0 var(--sticker-outline))
    drop-shadow(1.5px 1.5px 0 var(--sticker-outline)) drop-shadow(-1.5px -1.5px 0 var(--sticker-outline))
    drop-shadow(1.5px -1.5px 0 var(--sticker-outline)) drop-shadow(-1.5px 1.5px 0 var(--sticker-outline))
    drop-shadow(3px 0 0 var(--sticker-outline)) drop-shadow(-3px 0 0 var(--sticker-outline))
    drop-shadow(0 3px 0 var(--sticker-outline)) drop-shadow(0 -3px 0 var(--sticker-outline));
  --logo-sticker-outline: rgba(10, 10, 10, 0.28);
  --home-logo-sticker-shadows:
    drop-shadow(2px 0 0 var(--logo-sticker-outline)) drop-shadow(-2px 0 0 var(--logo-sticker-outline))
    drop-shadow(0 2px 0 var(--logo-sticker-outline)) drop-shadow(0 -2px 0 var(--logo-sticker-outline))
    drop-shadow(1.5px 1.5px 0 var(--logo-sticker-outline)) drop-shadow(-1.5px -1.5px 0 var(--logo-sticker-outline))
    drop-shadow(1.5px -1.5px 0 var(--logo-sticker-outline)) drop-shadow(-1.5px 1.5px 0 var(--logo-sticker-outline))
    drop-shadow(3px 0 0 var(--logo-sticker-outline)) drop-shadow(-3px 0 0 var(--logo-sticker-outline))
    drop-shadow(0 3px 0 var(--logo-sticker-outline)) drop-shadow(0 -3px 0 var(--logo-sticker-outline));
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 1rem;
}

.home__center {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.5rem calc(5.5rem + env(safe-area-inset-bottom, 0px));
  max-width: 100%;
}

.home__logo {
  width: clamp(210px, 54vw, 330px);
  height: auto;
  margin: 0 0 1.5rem;
  transform-origin: center center;
  filter: var(--home-logo-sticker-shadows) drop-shadow(0 0 28px rgba(230, 57, 70, 0.45));
}

html.motion-ok .home__logo {
  animation: home-logo-in 0.95s cubic-bezier(0.22, 1.1, 0.32, 1) 0.08s both;
}

@keyframes home-logo-in {
  0% {
    opacity: 0;
    transform: scale(0.35) rotate(-16deg) translateY(28px);
  }
  58% {
    opacity: 1;
    transform: scale(1.1) rotate(5deg) translateY(0);
  }
  78% {
    transform: scale(0.96) rotate(-2deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

.home__title {
  font-family: "Anton", Impact, "Arial Narrow", sans-serif;
  font-weight: 400;
  font-size: clamp(2.25rem, 10vw, 4rem);
  line-height: 0.92;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  margin: 0;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.02em;
  background: linear-gradient(180deg, #ff6b6b 0%, #e63946 28%, #b91c1c 62%, #4a0d12 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  filter: var(--home-sticker-shadows);
}

.home__title-line {
  display: block;
  white-space: nowrap;
}

html.motion-ok .home__title-line {
  animation: home-title-line-in 0.72s cubic-bezier(0.2, 0.85, 0.18, 1) both;
}

html.motion-ok .home__title-line:nth-child(1) {
  animation-delay: 0.42s;
}

html.motion-ok .home__title-line:nth-child(2) {
  animation-delay: 0.62s;
}

.home__title-line--studio {
  font-size: 0.88em;
  letter-spacing: 0.02em;
}

/* —— Buttons (used by Games) —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.8125rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.9rem 1.35rem;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out);
}

.btn:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 3px;
}

.btn--primary {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff;
  box-shadow: 0 8px 32px rgba(230, 57, 70, 0.35);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(230, 57, 70, 0.45);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* —— Custom-styled Google sign-in (visual button + invisible real button overlay) —— */
.egs-google-wrap {
  position: relative;
  display: inline-block;
}

.egs-google-btn {
  pointer-events: none; /* clicks go to overlay */
}

.egs-google-overlay {
  position: absolute;
  inset: 0;
  opacity: 0.001;
  pointer-events: auto;
}

.egs-google-overlay > * {
  width: 100% !important;
  height: 100% !important;
}

/* —— Admin pages —— */
.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.9rem;
  margin-top: 1.2rem;
}

.admin-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 1rem;
  padding: calc(5.2rem + env(safe-area-inset-top, 0px)) 1rem 1.25rem;
  max-width: 1180px;
  margin: 0 auto;
  box-sizing: border-box;
}

.admin-sidebar {
  position: sticky;
  top: calc(5.2rem + env(safe-area-inset-top, 0px));
  align-self: start;
  border-radius: 22px;
  padding: 1rem;
  background: rgba(15, 25, 41, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.28);
}

.admin-sidebar__brand {
  font-family: "Anton", var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 1.05rem;
  margin-bottom: 0.85rem;
  color: rgba(241, 245, 249, 0.92);
}

.admin-nav {
  display: grid;
  gap: 0.35rem;
}

.admin-nav__item {
  display: block;
  padding: 0.65rem 0.75rem;
  border-radius: 16px;
  color: rgba(241, 245, 249, 0.9);
  font-weight: 700;
  background: rgba(3, 8, 18, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-nav__item:hover {
  background: rgba(78, 200, 255, 0.08);
  border-color: rgba(78, 200, 255, 0.22);
}

.admin-nav__item.is-active {
  background: rgba(230, 57, 70, 0.18);
  border-color: rgba(230, 57, 70, 0.35);
}

.admin-main {
  min-width: 0;
}

.admin-main__inner {
  position: relative;
  border-radius: 22px;
  padding: 1.2rem 1.2rem 1.3rem;
  background: rgba(15, 25, 41, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
}

.admin-heading-row {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 0.35rem;
}

.admin-heading-row__text {
  min-width: 0;
  flex: 1 1 auto;
}

.admin-heading-row__text .sub-page__title {
  margin-top: 0.15rem;
}

.admin-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(3, 8, 18, 0.55);
  color: rgba(241, 245, 249, 0.95);
  text-decoration: none;
  font-size: 1.25rem;
  line-height: 1;
  font-weight: 800;
  transition:
    background 0.2s var(--ease-out),
    border-color 0.2s var(--ease-out),
    transform 0.2s var(--ease-out);
}

.admin-back:hover {
  background: rgba(78, 200, 255, 0.1);
  border-color: rgba(78, 200, 255, 0.35);
  transform: translateX(-2px);
}

.admin-back:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 3px;
}

.admin-back__icon {
  display: block;
  margin-top: -2px;
}

@media (max-width: 900px) {
  .admin-shell {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    position: relative;
    top: auto;
  }
}

.admin-card {
  background: rgba(15, 25, 41, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  padding: 1rem 1rem 1.1rem;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.35);
}

.admin-card__title {
  margin: 0 0 0.5rem;
  font-family: "Anton", var(--font-display);
  letter-spacing: 0.02em;
  font-size: 1.2rem;
}

.admin-card__meta {
  margin: 0.25rem 0 0.6rem;
  color: rgba(241, 245, 249, 0.85);
}

.admin-card__muted {
  color: rgba(139, 156, 179, 0.95);
}

.admin-alert {
  margin: 0.9rem 0;
  padding: 0.85rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 25, 41, 0.65);
}

.admin-alert--ok {
  border-color: rgba(78, 200, 255, 0.35);
}

.admin-alert--err {
  border-color: rgba(230, 57, 70, 0.45);
}

.admin-form {
  margin-top: 1rem;
}

.admin-textarea {
  width: 100%;
  min-height: min(62vh, 720px);
  resize: vertical;
  padding: 0.9rem 1rem;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 8, 18, 0.65);
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.9rem;
  line-height: 1.45;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.admin-textarea--compact {
  min-height: 120px;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.9rem;
}

.admin-actions--sticky {
  position: sticky;
  bottom: 0.75rem;
  padding: 0.85rem 0.9rem;
  border-radius: 18px;
  background: rgba(3, 8, 18, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.25);
}

.admin-accordion {
  display: grid;
  gap: 0.65rem;
  margin-top: 1rem;
}

.admin-acc {
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(15, 25, 41, 0.55);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.admin-acc__sum {
  list-style: none;
  cursor: pointer;
  padding: 0.85rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.admin-acc__sum::-webkit-details-marker {
  display: none;
}

.admin-acc__title {
  font-weight: 900;
  letter-spacing: 0.02em;
}

.admin-acc__body {
  padding: 0 1rem 1rem;
}

.admin-game-head {
  display: grid;
  grid-template-columns: 1fr 140px;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.admin-thumb {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 8, 18, 0.55);
  overflow: hidden;
}

.admin-thumb__label {
  padding: 0.55rem 0.75rem;
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(241, 245, 249, 0.8);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-thumb__img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  display: block;
}

.admin-thumb--icon .admin-thumb__img {
  height: 140px;
  object-fit: cover;
}

.admin-thumb__empty {
  height: 140px;
  display: grid;
  place-items: center;
  color: rgba(139, 156, 179, 0.95);
  font-weight: 700;
}

.admin-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 0.9rem;
}

.admin-field {
  display: grid;
  gap: 0.35rem;
}

.admin-field--full {
  grid-column: 1 / -1;
}

.admin-field__label {
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(241, 245, 249, 0.8);
}

.admin-input {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 8, 18, 0.55);
  color: var(--text);
  padding: 0.75rem 0.85rem;
  font: inherit;
}

.admin-file {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 8, 18, 0.55);
  color: rgba(241, 245, 249, 0.92);
}

.admin-file::-webkit-file-upload-button {
  font: inherit;
}

.admin-platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.admin-platform {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.admin-platform input {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
}

.admin-platform__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(3, 8, 18, 0.45);
  color: rgba(241, 245, 249, 0.92);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  user-select: none;
  cursor: pointer;
}

.admin-platform input:checked + .admin-platform__btn {
  background: rgba(78, 200, 255, 0.12);
  border-color: rgba(78, 200, 255, 0.34);
}

.admin-platform__btn:focus-visible,
.admin-platform input:focus-visible + .admin-platform__btn {
  outline: 2px solid rgba(78, 200, 255, 0.55);
  outline-offset: 2px;
}

.admin-stars {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.2rem;
}

.admin-star {
  -webkit-appearance: none;
  appearance: none;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  color: rgba(255, 214, 10, 0.95);
  padding: 0.35rem 0.25rem;
}

.admin-star:focus-visible {
  outline: 2px solid rgba(78, 200, 255, 0.55);
  outline-offset: 2px;
  border-radius: 10px;
}

.admin-input:focus-visible,
.admin-textarea:focus-visible {
  outline: 2px solid rgba(78, 200, 255, 0.55);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .admin-game-head {
    grid-template-columns: 1fr;
  }

  .admin-fields {
    grid-template-columns: 1fr;
  }
}

.auth-corner__role--link {
  text-decoration: none;
}

.auth-corner__role--link:hover {
  text-decoration: underline;
}

/* —— Games (reference-style feature + strip) —— */
.main {
  position: relative;
  z-index: 1;
  padding: 0;
  background: transparent;
}

.games {
  display: flex;
  flex-direction: column;
}

.games__inner {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 0.65rem 0.85rem 0;
  padding-bottom: calc(5.35rem + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}

.games-feature {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: stretch;
  gap: 0.35rem;
  position: relative;
}

.games-feature__stage {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-inline: 0.25rem;
}

.games-feature__panel {
  width: 100%;
  max-width: min(1180px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr);
  gap: 1rem 1.75rem;
  align-items: center;
  min-height: 0;
  transform-origin: center center;
}

.games-feature__copy {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-right: 0.25rem;
  transition: opacity 0.32s ease;
}

.games-feature__copy--fade-out,
.games-feature__visual--fade-out {
  opacity: 0;
  pointer-events: none;
}

.games-feature__copy--fade-in,
.games-feature__visual--fade-in {
  opacity: 0;
  transition: none !important;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .games-feature__copy,
  .games-feature__visual {
    transition: none !important;
  }
}

.games-feature__eyebrow {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--cyan-muted);
  margin: 0;
}

.games-feature__title {
  font-weight: 800;
  font-size: clamp(1.35rem, 3.2vw, 2.1rem);
  letter-spacing: -0.02em;
  line-height: 1.12;
  margin: 0;
}

.games-feature__desc {
  margin: 0;
  color: var(--text-muted);
  font-size: clamp(0.8125rem, 1.65vw, 0.9375rem);
  line-height: 1.55;
}

.games-feature__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: 0.15rem;
}

.games-feature__links a {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--cyan);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.games-feature__links a:hover {
  color: #7dd8ff;
}

.games-feature__cta--disabled {
  opacity: 0.55;
  pointer-events: none;
  filter: grayscale(0.15);
}

.games-feature__cta-row {
  align-self: flex-start;
  margin-top: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: nowrap;
}

.games-feature__platforms {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: nowrap;
}

.games-feature__platform {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 0.24rem 0.46rem;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.34);
  background: rgba(15, 23, 42, 0.66);
  color: #bae6fd;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
}

.games-feature__platform-label {
  letter-spacing: 0.02em;
}

.games-feature__visual {
  width: 100%;
  min-width: 0;
  min-height: 0;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06), 0 24px 60px rgba(0, 0, 0, 0.45);
  /* Keep the hero media from becoming huge on tall viewports (closer to reference). */
  max-height: min(52vh, 460px);
  transition: opacity 0.32s ease;
}

.games-feature__media {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto;
  width: 100%;
  position: relative;
  isolation: isolate;
  background: var(--navy-elevated);
  border-radius: inherit;
  overflow: hidden;
}

.games-feature__media-sizer {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  aspect-ratio: 16 / 9;
  pointer-events: none;
  visibility: hidden;
}

.games-feature__media > img[data-field="heroImg"] {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  align-self: stretch;
  justify-self: stretch;
  object-fit: cover;
  z-index: 0;
  border-radius: inherit;
}

.games-feature__media--hero-suppressed > img[data-field="heroImg"] {
  display: none !important;
}

.games-feature__embed-wrap {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  align-self: stretch;
  justify-self: stretch;
  z-index: 3;
  background: #000;
  overflow: hidden;
  position: relative;
  border-radius: inherit;
}

.games-feature__embed-wrap--away {
  pointer-events: none;
}

.games-feature__embed {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.games-feature__video-wrap {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  align-self: stretch;
  justify-self: stretch;
  z-index: 2;
  position: relative;
  border-radius: inherit;
  cursor: pointer;
}

.games-feature__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #000;
}

.games-feature__video-wrap--away .games-feature__video {
  pointer-events: none;
}

.games-feature__arrow {
  flex: 0 0 auto;
  align-self: center;
  width: 42px;
  height: 42px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  background: rgba(252, 253, 255, 0.96);
  color: #0f172a;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s var(--ease-out), transform 0.2s var(--ease-out);
}

.games-feature__arrow:hover {
  background: #fff;
  transform: translateY(-1px);
}

.games-feature__arrow:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 2px;
}

.games-feature__arrow:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.games-strip {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding-top: 0.5rem;
  min-height: 0;
}

.games-strip__label {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text-muted);
  margin: 0;
  padding-inline: 0.15rem;
  text-align: center;
}

.games-strip__carousel {
  --carousel-card-max: 210px;
  /* px gap keeps the viewport width stable (no rem/vw subpixel drift). */
  --carousel-gap: 12px;
  --carousel-viewport-max: calc(var(--carousel-card-max) * 3 + var(--carousel-gap) * 2);
  display: grid;
  /* Cap width to the 3-card row; shrink with the container — avoid 1fr “breathing”. */
  grid-template-columns: 42px minmax(0, min(100%, var(--carousel-viewport-max))) 42px;
  align-items: center;
  gap: 0.65rem;
  width: min(100%, calc(var(--carousel-viewport-max) + 84px + 1.3rem));
  margin-inline: auto;
  justify-content: center;
  box-sizing: border-box;
}

.games-strip__viewport {
  min-width: 0;
  width: 100%;
  max-width: var(--carousel-viewport-max);
  margin-inline: auto;
  box-sizing: border-box;
}

.games-strip__scroller {
  overflow: hidden;
  min-width: 0;
  width: 100%;
  padding-top: 0.6rem;
  padding-bottom: 0.7rem;
  /* Stable compositor layer — avoids flex/clip repaints flashing during track transforms. */
  transform: translateZ(0);
  backface-visibility: hidden;
}

.games-strip__track {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: var(--carousel-gap);
  width: 100%;
  justify-content: center;
  padding: 0.35rem 0.1rem 0.55rem;
  box-sizing: border-box;
}

/* 4-card sequence: left-align row so [1][2][3] + incoming align predictably */
.games-strip__track--cart-seq {
  width: max-content;
  justify-content: flex-start;
}

/* Do not set opacity here — it fought exit/incoming fades (opacity !important caused flicker). */
.games-strip__track--cart-seq .games-card--cart-flat {
  transform: none !important;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.games-strip__track--cart-seq .games-card--cart-flat:hover {
  transform: none !important;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.games-card--cart-exit {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.games-card--cart-incoming {
  opacity: 0;
  pointer-events: none;
}

.games-card--cart-incoming.games-card--cart-enter {
  opacity: 1;
  transition: opacity 0.32s ease;
}

[data-games-track][aria-busy="true"] {
  pointer-events: none;
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .games-card--cart-exit,
  .games-card--cart-incoming.games-card--cart-enter {
    transition: none !important;
  }

  .games-card--cart-incoming {
    opacity: 1 !important;
  }
}

.games-card {
  flex: 0 0 var(--carousel-card-max);
  width: var(--carousel-card-max);
  max-width: var(--carousel-card-max);
  box-sizing: border-box;
  position: relative;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  border: 1px solid var(--game-card-shell-border);
  border-radius: 22px;
  cursor: pointer;
  text-align: left;
  overflow: hidden;
  background: var(--game-card-shell);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-out);
}

.games-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.5);
}

.games-card__art {
  position: relative;
  flex: 0 0 auto;
  width: 100%;
  height: 118px;
  overflow: hidden;
  border-radius: 20px 20px 0 0;
  isolation: isolate;
}

.games-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.games-card__meta {
  flex: 0 0 auto;
  margin: 0.45rem 0.5rem 0.5rem;
  padding: 0.55rem 0.65rem 0.6rem;
  border-radius: 14px;
  background: var(--game-card-meta);
  border: 1px solid var(--game-card-meta-border);
  color: var(--text);
}

.games-card__meta-head {
  display: grid;
  grid-template-columns: clamp(42px, 11vw, 50px) minmax(0, 1fr);
  align-items: stretch;
  gap: 0.55rem;
  width: 100%;
  min-width: 0;
}

.games-card__meta-head > .games-card__meta-text:only-child {
  grid-column: 1 / -1;
}

.games-card__icon-wrap {
  min-height: 0;
  min-width: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.38);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  background: rgba(8, 15, 24, 0.4);
  display: flex;
  align-self: stretch;
}

.games-card__icon {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  flex: 1 1 auto;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
}

.games-card__meta-text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0.15rem;
}

@media (max-width: 640px) {
  .games-strip__carousel {
    --carousel-card-max: 170px;
    --carousel-viewport-max: calc(var(--carousel-card-max) * 3 + var(--carousel-gap) * 2);
    width: min(100%, calc(var(--carousel-viewport-max) + 84px + 1.3rem));
    grid-template-columns: 42px minmax(0, min(100%, var(--carousel-viewport-max))) 42px;
  }

  .games-card {
    flex-basis: var(--carousel-card-max);
    width: var(--carousel-card-max);
    max-width: var(--carousel-card-max);
  }
}

.games-card__title {
  font-weight: 800;
  font-size: 0.8125rem;
  margin: 0;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.games-card__sub {
  margin: 0.15rem 0 0;
  font-size: 0.65rem;
  font-weight: 600;
  color: rgba(168, 188, 207, 0.92);
  line-height: 1.35;
}

@media (max-width: 900px) {
  .games-feature__panel {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  .games-feature__visual {
    max-height: min(38vh, 320px);
  }

  .games-feature__copy {
    max-height: min(28vh, 220px);
  }
}

.contact__inner {
  border-radius: 20px;
  padding: 2rem;
  background: linear-gradient(135deg, rgba(78, 200, 255, 0.08) 0%, rgba(15, 25, 41, 0.9) 45%, rgba(8, 15, 24, 0.95) 100%);
  border: 1px solid rgba(78, 200, 255, 0.24);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  max-width: 900px;
  margin: 0 auto;
}

/* —— Contact form (morph → loading bar → success → reset) —— */
.contact-form {
  margin-top: 1.25rem;
  display: grid;
  gap: 0.9rem;
}

.contact-form--page {
  text-align: left;
  margin-top: 1.5rem;
}

.contact-form__hp {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.contact-form__fields {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: 1fr 1fr;
  align-items: start;
  transition:
    opacity 0.28s var(--ease-out),
    transform 0.28s var(--ease-out),
    filter 0.28s var(--ease-out);
}

.contact-form__field {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}

.contact-form__field--full {
  grid-column: 1 / -1;
}

.contact-form__label {
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(241, 245, 249, 0.9);
}

.contact-form__input,
.contact-form__textarea {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(3, 8, 18, 0.55);
  color: var(--text);
  padding: 0.8rem 0.9rem;
  font: inherit;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 16px 40px rgba(0, 0, 0, 0.22);
  transition:
    border-color 0.2s var(--ease-out),
    background 0.2s var(--ease-out),
    transform 0.2s var(--ease-out);
}

.contact-form__textarea {
  resize: vertical;
  min-height: 140px;
}

.contact-form__input:focus-visible,
.contact-form__textarea:focus-visible {
  outline: 2px solid var(--cyan-muted);
  outline-offset: 3px;
  border-color: rgba(78, 200, 255, 0.35);
}

.contact-form__actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.contact-form__submit {
  min-width: 160px;
  position: relative;
  overflow: hidden;
}

.contact-form__hint {
  margin: 0;
  color: rgba(168, 188, 207, 0.92);
  font-weight: 600;
  font-size: 0.92rem;
}

.contact-form__status {
  display: none;
  gap: 0.6rem;
  align-items: center;
}

.contact-form__bar {
  height: 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.contact-form__bar-fill {
  height: 100%;
  width: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  background: linear-gradient(90deg, rgba(78, 200, 255, 0.25), rgba(78, 200, 255, 0.95));
}

@keyframes contact-bar-fill {
  0% {
    transform: scaleX(0);
  }
  65% {
    transform: scaleX(0.78);
  }
  100% {
    transform: scaleX(1);
  }
}

.contact-form__success {
  display: none;
  align-items: center;
  gap: 0.55rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: rgba(34, 197, 94, 0.98);
}

.contact-form__success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid rgba(34, 197, 94, 0.45);
  background: rgba(34, 197, 94, 0.14);
  font-weight: 900;
}

.contact-form__error {
  display: none;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(230, 57, 70, 0.12);
  border: 1px solid rgba(230, 57, 70, 0.35);
  border-radius: 16px;
  padding: 0.75rem 0.85rem;
  font-weight: 700;
}

/* State: loading */
.contact-form.is-loading .contact-form__fields {
  opacity: 0;
  transform: translateY(-6px) scale(0.985);
  filter: blur(1px);
  pointer-events: none;
}

.contact-form.is-loading .contact-form__status {
  display: grid;
}

.contact-form.is-loading .contact-form__bar-fill {
  animation: contact-bar-fill 2s linear forwards;
}

/* State: success */
.contact-form.is-success .contact-form__fields {
  opacity: 0;
  transform: translateY(-6px) scale(0.985);
  pointer-events: none;
}

.contact-form.is-success .contact-form__status {
  display: grid;
}

.contact-form.is-success .contact-form__bar {
  border-color: rgba(34, 197, 94, 0.45);
  background: rgba(34, 197, 94, 0.12);
}

.contact-form.is-success .contact-form__bar-fill {
  transform: scaleX(1);
  background: linear-gradient(90deg, rgba(34, 197, 94, 0.25), rgba(34, 197, 94, 0.95));
}

.contact-form.is-success .contact-form__success {
  display: inline-flex;
}

/* State: error */
.contact-form.is-error .contact-form__status {
  display: grid;
}

.contact-form.is-error .contact-form__error {
  display: block;
}

@media (max-width: 720px) {
  .contact-form__fields {
    grid-template-columns: 1fr;
  }

  .contact-form__submit {
    width: 100%;
  }
}

@keyframes home-title-line-in {
  0% {
    opacity: 0;
    transform: translateY(0.85em) scale(0.88);
    letter-spacing: 0.12em;
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    letter-spacing: inherit;
  }
}

@media (max-width: 380px) {
  .home__title {
    font-size: clamp(1.4rem, 8.5vw, 4rem);
    letter-spacing: -0.03em;
  }
}

@media (prefers-reduced-motion: reduce) {
  html:has(body.page--home) {
    scroll-snap-type: none;
  }

  .home__logo,
  .home__title-line {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  html.motion-ok .home__title-line:nth-child(1),
  html.motion-ok .home__title-line:nth-child(2) {
    animation-delay: 0s !important;
  }
}

/* —— Simple inner pages —— */
.sub-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
}

.sub-page__inner {
  max-width: 36rem;
  text-align: center;
}

.sub-page__title {
  font-family: "Anton", Impact, sans-serif;
  font-weight: 400;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 0.75rem;
  background: linear-gradient(180deg, #ff6b6b 0%, #b91c1c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.sub-page__lead {
  margin: 0 0 1.25rem;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.sub-page__meta a {
  color: var(--cyan-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.sub-page__meta a:hover {
  color: #7dd8ff;
}

/* —— Blob bubble footer (site palette) —— */
.site-footer {
  --site-footer-bg: var(--red);
  position: relative;
  z-index: 5;
  display: grid;
  min-height: 12rem;
  margin-top: 0;
  scroll-snap-align: start;
  scroll-snap-stop: normal;
}

.site-footer__bubbles {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1rem;
  background: var(--site-footer-bg);
  filter: url("#footerBlobFilter");
}

.site-footer__bubble {
  position: absolute;
  left: var(--position, 50%);
  background: var(--site-footer-bg);
  border-radius: 100%;
  animation:
    site-footer-bubble-size var(--time, 4s) ease-in infinite var(--delay, 0s),
    site-footer-bubble-move var(--time, 4s) ease-in infinite var(--delay, 0s);
  transform: translate(-50%, 100%);
}

.site-footer__content {
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.25rem;
  padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, var(--red) 0%, var(--red-dark) 100%);
}

.site-footer__copyright {
  margin: 0;
  font-size: 0.875rem;
  color: rgba(241, 245, 249, 0.92);
}

.site-footer__svg-defs {
  position: fixed;
  top: 100vh;
  width: 0;
  height: 0;
  pointer-events: none;
}

@keyframes site-footer-bubble-size {
  0%,
  75% {
    width: var(--size, 4rem);
    height: var(--size, 4rem);
  }

  100% {
    width: 0;
    height: 0;
  }
}

@keyframes site-footer-bubble-move {
  0% {
    bottom: -4rem;
  }

  100% {
    bottom: var(--distance, 10rem);
  }
}

@media (max-width: 720px) {
  .site-footer__copyright {
    font-size: 0.8rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-footer__bubble {
    animation: none;
    display: none;
  }

  .site-footer__bubbles {
    filter: none;
    height: 0.35rem;
  }
}
