/*
  Learnerful group — one-screen light desk
*/
:root {
  color-scheme: dark;
  --ink: #14201c;
  --paper: #ffffff;
  --jade: #14946a;
  --jade-deep: #0d7352;
  --muted: #5c6b64;
  --line: rgba(20, 32, 28, 0.1);
  --font:
    -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display",
    "Helvetica Neue", "Segoe UI", "Noto Sans TC", "PingFang HK",
    "Hiragino Sans CNS", "Manrope", "Plus Jakarta Sans", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 3.5rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--ink);
  font-family: var(--font);
  font-weight: 500;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
}

.card-defs {
  position: absolute;
  width: 0;
  height: 0;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 50;
  padding: 0.6rem 0.9rem;
  border-radius: 10px;
  background: var(--ink);
  color: white;
  transform: translateY(-160%);
  text-decoration: none;
}

.skip-link:focus {
  transform: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.deck-card:focus-visible,
.deck-dots button:focus-visible,
.skip-link:focus {
  outline: 2px solid var(--jade);
  outline-offset: 3px;
}

.shell {
  width: 100%;
  background: var(--ink);
}

.hero {
  position: relative;
  width: 100%;
}

.hero-frame {
  position: relative;
  width: 100%;
  height: 100dvh;
  min-height: 40rem;
}

.hero-photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}

.hero-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: rgba(20, 32, 28, 0.5);
}

.hero-stage {
  position: absolute;
  z-index: 3;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 1.4rem;
  padding: 0 1.25rem max(1.5rem, env(safe-area-inset-bottom));
  pointer-events: none;
}

.brand {
  position: absolute;
  z-index: 2;
  top: 16%;
  right: 0;
  left: 0;
  margin: 0;
  font-family: var(--font);
  font-size: clamp(3.2rem, 16.4vw, 15.5rem);
  font-weight: 800;
  color: white;
  letter-spacing: -0.055em;
  line-height: 0.86;
  text-align: center;
  pointer-events: none;
}

.brand-mark {
  color: var(--jade);
}

.deck-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  height: 100%;
  padding: 0.7rem;
}

.pack {
  position: relative;
  width: 3.6rem;
  height: 3.6rem;
  pointer-events: none;
}

.pack span {
  position: absolute;
  top: 0.2rem;
  left: 0.2rem;
  width: 3rem;
  height: 3rem;
  border: 1px solid rgba(20, 32, 28, 0.08);
  border-radius: 0.35rem;
  background: white;
  box-shadow: 0 8px 14px rgba(20, 32, 28, 0.28);
}

.pack span:nth-child(1) {
  top: 0;
  left: 0.38rem;
  background: #d7f3e8;
  transform: rotate(-8deg);
}

.pack span:nth-child(2) {
  top: 0.28rem;
  left: 0.06rem;
  background: #f3fbf7;
  transform: rotate(6deg);
}

.pack span:nth-child(3) {
  top: 0.48rem;
  left: 0.3rem;
  background:
    linear-gradient(#c9cfcb, #c9cfcb) 0.7rem 0.7rem / 55% 2px no-repeat,
    linear-gradient(#c9cfcb, #c9cfcb) 0.7rem 1.15rem / 38% 2px no-repeat,
    white;
}

.deck[hidden] {
  display: none;
}

.deck {
  position: relative;
  z-index: 2;
  display: flex;
  flex: 0 0 auto;
  width: min(7.25rem, 28vw);
  height: auto;
  aspect-ratio: 1 / 1.18;
  margin: 0;
  padding: 0;
  pointer-events: auto;
}

.deck-scroller {
  display: flex;
  width: 100%;
  height: 100%;
  overflow: hidden;
  padding-inline: 0;
  scrollbar-width: none;
}

.deck-scroller::-webkit-scrollbar {
  display: none;
}

.deck-slide {
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
}

.deck-card {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 0;
  clip-path: url("#card-shape");
  font-size: 0.95rem;
  color: var(--ink);
  text-decoration: none;
  background: #f4f1ea;
  filter: drop-shadow(0 14px 22px rgba(16, 24, 18, 0.38));
  transition: transform 280ms var(--ease);
}

.deck-slide.is-on .deck-card {
  transform: none;
}

.deck-title {
  margin-top: 0.45rem;
  font-size: 1.2rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.deck-dots {
  display: none;
  justify-content: center;
  gap: 0.4rem;
}

.deck-dots button {
  width: 0.45rem;
  height: 0.45rem;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #c5c7bf;
  cursor: pointer;
}

.deck-dots button.is-on {
  width: 1.1rem;
  background: var(--jade-deep);
}

html[lang="zh-HK"] .brand,
html[lang="zh-HK"] .pack-promise {
  letter-spacing: 0;
}

@media (min-width: 800px) {
  .hero-stage {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
    padding: 0 clamp(2rem, 5vw, 4.5rem) clamp(2.4rem, 6vh, 4rem);
  }

  .brand {
    top: 22%;
    font-size: clamp(6rem, 13.6vw, 13.5rem);
  }

  .deck {
    width: min(9.5rem, 14vw);
  }

  .deck-card {
    font-size: clamp(0.75rem, 1.05vw, 0.95rem);
  }
}

.intro {
  max-width: 36rem;
  margin: 0;
  padding: 0;
  text-align: left;
  pointer-events: none;
}

.intro p {
  margin: 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.35;
  text-wrap: balance;
}

.intro p + p {
  margin-top: 0.7rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.98rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.5;
}

.pack-page {
  color-scheme: light;
  background: #dce8e1;
  color: var(--ink);
}

.pack-page .shell {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding:
    max(1.25rem, env(safe-area-inset-top))
    clamp(1.25rem, 6vw, 4.5rem)
    max(1.5rem, env(safe-area-inset-bottom));
  background: transparent;
}

.back {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
}

.back:focus-visible {
  outline: 2px solid var(--jade);
  outline-offset: 3px;
}

.pack-sheet {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: min(40rem, 100%);
  flex: 1;
  margin: 0;
  padding-top: clamp(2.5rem, 8vh, 4.5rem);
}

.pack-name {
  margin: 0;
  font-size: clamp(2.8rem, 6vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.pack-promise {
  margin: 0.6rem 0 0;
  font-size: clamp(1.35rem, 2.6vw, 1.9rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.pack-promise span {
  display: block;
}

.pack-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem 2.75rem;
  margin: auto 0;
}

.pack-items {
  flex: 1 1 14rem;
  max-width: 22rem;
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.05rem;
}

.pack-items li {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.item-name {
  font-weight: 750;
  letter-spacing: -0.02em;
}

.item-body {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.4;
}

.pack-figure {
  position: relative;
  width: min(18rem, 100%);
  height: 11rem;
  flex: 0 0 auto;
  margin: 0;
}

.plane {
  position: absolute;
  display: block;
  border-radius: 1.15rem;
}

.plane-back {
  width: 62%;
  height: 70%;
  left: 0;
  top: 16%;
  background: rgba(255, 255, 255, 0.55);
  transform: rotate(-8deg);
}

.plane-mid {
  width: 58%;
  height: 64%;
  left: 16%;
  top: 6%;
  background: white;
  transform: rotate(4deg);
}

.plane-front {
  width: 42%;
  height: 48%;
  left: 36%;
  top: 32%;
  background: var(--ink);
  transform: rotate(-2deg);
}

.plane-mark {
  width: 4.25rem;
  height: 4.25rem;
  right: 0;
  bottom: 0.4rem;
  border-radius: 999px;
  background: var(--jade);
}

.pack-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 0;
}

.pack-soon {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0 1.25rem;
  border: 1px solid rgba(20, 32, 28, 0.16);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  cursor: default;
}

@media (prefers-reduced-motion: reduce) {
  .deck-card {
    transition: none;
  }
}
