/* Shared by the React entrance and the eight crawlable, no-JavaScript pages. */
.landing-card-panel {
  min-width: 0;
  text-align: center;
}
.landing-card-panel > p {
  margin: 16px auto 0;
}
.landing-card-stage {
  perspective: 1200px;
  container-type: inline-size;
  padding: 16px 0;
}
.landing-card-spin {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: auto;
  aspect-ratio: 85.6 / 54;
  transform-style: preserve-3d;
  animation: landing-card-turn 18s linear infinite;
  animation-play-state: running;
}
.landing-card-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  box-sizing: border-box;
  padding: clamp(12px, 4cqw, 24px);
  border: 1px solid var(--sand-dim);
  border-radius: clamp(10px, 3cqw, 14px);
  background: linear-gradient(
    135deg,
    #244b39,
    var(--green-container) 60%,
    #123023
  );
  color: var(--card);
  text-align: left;
  box-shadow:
    0 16px 32px #1b3b2b24,
    inset 0 0 0 1px #e0c29818;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform: rotateY(0deg) translateZ(3px);
  animation: landing-card-front 18s steps(1, end) infinite;
  animation-play-state: inherit;
}
.landing-card-face::before {
  content: '';
  position: absolute;
  z-index: 0;
  pointer-events: none;
  inset: -15% -8% -15% 58%;
  border: 1px solid #ffffff0d;
  background:
    linear-gradient(90deg, transparent 49.8%, #ffffff0d 50%, transparent 50.2%),
    linear-gradient(transparent 49.8%, #ffffff0d 50%, transparent 50.2%);
  transform: rotate(-12deg);
}
.landing-card-face > * {
  position: relative;
}
.landing-card-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--sand-dim);
  font-size: clamp(8px, 2.6cqw, 12px);
  letter-spacing: 0.14em;
  font-weight: 700;
}
.landing-card-brand img {
  width: clamp(24px, 8cqw, 36px);
  height: auto;
}
.landing-card-panel .landing-card-membership {
  margin: 4px 0 0;
  color: var(--surface);
  font-size: clamp(7px, 2cqw, 10px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.landing-card-identity {
  display: flex;
  align-items: center;
  gap: clamp(8px, 3cqw, 16px);
  margin: clamp(8px, 3.5cqw, 18px) 0;
}
.landing-card-avatar {
  display: grid;
  place-items: center;
  flex: none;
  width: clamp(28px, 10cqw, 48px);
  height: clamp(28px, 10cqw, 48px);
  border: 1px solid var(--sand-dim);
  border-radius: 50%;
  background: #ffffff14;
  font: clamp(16px, 5cqw, 24px) var(--font-heading);
}
.landing-card-panel .landing-card-identity h2 {
  margin: 0 0 3px;
  color: var(--card);
  font: 600 clamp(17px, 5.8cqw, 28px)/1.15 var(--font-heading);
}
.landing-card-panel .landing-card-identity p {
  margin: 0;
  color: var(--surface);
  font-size: clamp(9px, 3cqw, 14px);
}
.landing-card-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding-top: clamp(6px, 2.5cqw, 12px);
  border-top: 1px solid #ffffff33;
}
.landing-card-stats > div {
  display: flex;
  flex-direction: column;
}
.landing-card-stats > div + div {
  padding-left: clamp(4px, 1.5cqw, 8px);
  border-left: 1px solid #ffffff33;
}
.landing-card-stats dt {
  font-size: clamp(6px, 1.9cqw, 9px);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.landing-card-stats dd {
  order: -1;
  margin: 0 0 4px;
  font-size: clamp(17px, 5.8cqw, 28px);
  line-height: 1.2;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.landing-card-stats > div:first-child dd {
  color: var(--sand-dim);
}
.landing-card-back {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: clamp(8px, 3cqw, 16px);
  transform: rotateY(180deg) translateZ(3px);
  animation-name: landing-card-back;
  text-align: center;
  color: var(--sand-dim);
}
.landing-card-back strong {
  font-size: clamp(14px, 4.5cqw, 20px);
  letter-spacing: 0.14em;
}
.landing-card-back img {
  width: clamp(48px, 18cqw, 80px);
  height: auto;
}
.landing-card-back span {
  font-size: clamp(8px, 2.6cqw, 12px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
/* Explicit face visibility also handles WebKit's backface compositing behavior. */
@keyframes landing-card-turn {
  0%,
  20% {
    transform: rotateY(0deg);
  }
  to {
    transform: rotateY(360deg);
  }
}
@keyframes landing-card-front {
  0%,
  80%,
  100% {
    visibility: visible;
  }
  40% {
    visibility: hidden;
  }
}
@keyframes landing-card-back {
  0%,
  80%,
  100% {
    visibility: hidden;
  }
  40% {
    visibility: visible;
  }
}
@media (prefers-reduced-motion: reduce) {
  .landing-card-spin,
  .landing-card-face {
    animation: none;
  }
  .landing-card-back {
    display: none;
  }
}

/* Preserve vertical page scrolling while horizontal dragging turns the card. */
.landing-card-stage {
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.landing-card-stage img {
  -webkit-user-drag: none;
  pointer-events: none;
}
.landing-card-stage[data-dragging] {
  cursor: grabbing;
}
.landing-card-stage:focus-visible {
  outline: 3px solid var(--sand);
  outline-offset: 4px;
  border-radius: 14px;
}
.landing-card-spin[data-manual] {
  transform: rotateY(var(--manual-angle)) !important;
}
.landing-card-spin[data-manual] .landing-card-face {
  visibility: hidden !important;
}
.landing-card-spin[data-manual][data-side='front'] section.landing-card-face,
.landing-card-spin[data-manual][data-side='back'] .landing-card-back {
  visibility: visible !important;
}
.landing-card-spin[data-manual] .landing-card-back {
  display: flex;
}

/* Closely spaced opaque slices follow the printed faces' rounded silhouette.
   This fills the thickness without detached rectangular strips or open corners. */
.landing-card-core {
  position: absolute;
  inset: 0;
  box-sizing: border-box;
  border: 1px solid #a68a60;
  border-radius: clamp(10px, 3cqw, 14px);
  background: #244b39;
  pointer-events: none;
  backface-visibility: visible;
  -webkit-backface-visibility: visible;
}

.landing-card-panel > .landing-card-example {
  margin-top: 0;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.landing-card-panel > .landing-card-hint {
  margin: 2px auto 0;
  min-height: 20px;
  color: var(--muted);
  font-size: 12px;
  animation: landing-hint-away 600ms ease 5s forwards;
}
.landing-card-panel:has(.landing-card-stage[data-interacted])
  .landing-card-hint {
  animation: none;
  opacity: 0;
}
section.landing-card-face::after {
  content: '';
  position: absolute;
  inset: -20% -50%;
  pointer-events: none;
  background: linear-gradient(
    110deg,
    transparent 40%,
    #fedeb2 50%,
    transparent 60%
  );
  opacity: 0;
  transform: translateX(-70%);
  animation: landing-card-sheen 18s linear infinite;
  animation-play-state: inherit;
}
@keyframes landing-card-sheen {
  0%,
  20% {
    transform: translateX(-70%);
    opacity: 0;
  }
  40% {
    opacity: 0.08;
  }
  60%,
  100% {
    transform: translateX(70%);
    opacity: 0;
  }
}
@keyframes landing-hint-away {
  to {
    opacity: 0;
  }
}
.landing-closing {
  margin: 56px 0 24px;
  padding: clamp(28px, 5vw, 56px);
  border-radius: 12px;
  background: var(--green);
  color: var(--surface);
  text-align: center;
}
.landing-closing h2 {
  font-size: clamp(28px, 3vw, 40px);
  margin: 0 auto 16px;
  color: var(--surface);
  max-width: 24ch;
}
.landing-closing p {
  margin: 0 auto 24px;
}
.landing-closing .button {
  background: var(--sand-container);
  border-color: var(--sand-container);
  color: var(--green);
}
.hero > div:first-child {
  animation: landing-intro 550ms ease-out both;
}
@keyframes landing-intro {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (prefers-reduced-motion: reduce) {
  section.landing-card-face::after,
  .hero > div:first-child,
  .landing-card-panel > .landing-card-hint {
    animation: none;
  }
  section.landing-card-face::after {
    opacity: 0;
  }
}
