:root {
  --ink: #073a3a;
  --ink-soft: #345d5a;
  --teal-900: #063f3b;
  --teal-800: #086258;
  --teal-700: #087c71;
  --blue-800: #1d4f82;
  --blue-100: #eaf5fb;
  --mint-100: #e6f6ef;
  --gold-700: #9f7018;
  --gold-500: #c99428;
  --gold-100: #fff3ce;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-strong: #ffffff;
  --line: rgba(8, 98, 88, 0.18);
  --shadow: 0 18px 48px rgba(6, 63, 59, 0.14);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--ink);
  background: #edf7f5;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  line-height: 1.62;
}

body {
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(201, 148, 40, 0.8);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  left: 14px;
  top: calc(12px + var(--safe-top));
  z-index: 30;
  padding: 9px 12px;
  border-radius: 8px;
  color: #fff;
  background: var(--teal-900);
  font-size: 0.88rem;
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 180ms ease;
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.share-probe {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0.01;
  pointer-events: none;
}

.deck {
  height: 100dvh;
  overflow-y: auto;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
  overscroll-behavior-y: contain;
  background:
    linear-gradient(180deg, rgba(244, 251, 250, 0.84), rgba(229, 243, 239, 0.92)),
    #edf7f5;
}

.panel {
  position: relative;
  min-height: 100dvh;
  width: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  overflow: hidden;
  isolation: isolate;
}

.cover-panel {
  display: grid;
  place-items: center;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(244, 251, 250, 0.84)),
    url("assets/content-bg.webp") center / cover no-repeat,
    #f7fcfb;
}

.cover-art {
  width: 100%;
  height: 100dvh;
  object-fit: contain;
  object-position: center;
}

.has-js .cover-art {
  opacity: 0;
  transform: scale(1.025);
}

.has-js .panel.is-active .cover-art {
  animation: cover-reveal 720ms cubic-bezier(0.2, 0.75, 0.2, 1) both;
}

.text-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(26px + var(--safe-top)) 18px calc(82px + var(--safe-bottom));
  background:
    linear-gradient(180deg, rgba(247, 253, 252, 0.92), rgba(237, 247, 245, 0.94)),
    url("assets/content-bg.webp") center / cover no-repeat,
    #f4fbfa;
}

.text-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(120deg, rgba(29, 79, 130, 0.08), transparent 34%),
    linear-gradient(300deg, rgba(201, 148, 40, 0.12), transparent 30%);
}

.panel-inner {
  width: min(100%, 520px);
  max-height: calc(100dvh - 108px - var(--safe-top) - var(--safe-bottom));
  padding: 2px 2px 4px;
}

.panel-inner.scrollable {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(8, 98, 88, 0.34) transparent;
}

.panel-inner.scrollable::-webkit-scrollbar {
  width: 6px;
}

.panel-inner.scrollable::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(8, 98, 88, 0.28);
}

.section-head {
  margin: 0 0 16px;
  padding: 0 4px;
}

.has-js .text-panel .section-head > *,
.has-js .text-panel .letter-card,
.has-js .text-panel .info-card,
.has-js .text-panel .host-card,
.has-js .text-panel .timeline li,
.has-js .text-panel .session-card,
.has-js .text-panel .guest-card,
.has-js .text-panel .guide-list article,
.has-js .text-panel .qr-card,
.has-js .text-panel .contact-card,
.has-js .text-panel .note-card,
.has-js .text-panel .primary-link,
.has-js .text-panel .closing {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
}

.has-js .panel.is-active .section-head .eyebrow {
  animation: panel-reveal 480ms cubic-bezier(0.2, 0.75, 0.2, 1) 60ms both;
}

.has-js .panel.is-active .section-head h1,
.has-js .panel.is-active .section-head h2 {
  animation: panel-reveal 560ms cubic-bezier(0.2, 0.75, 0.2, 1) 140ms both;
}

.has-js .panel.is-active .section-head p:last-child {
  animation: panel-reveal 560ms cubic-bezier(0.2, 0.75, 0.2, 1) 220ms both;
}

.has-js .panel.is-active .letter-card,
.has-js .panel.is-active .info-card,
.has-js .panel.is-active .host-card,
.has-js .panel.is-active .timeline li,
.has-js .panel.is-active .session-card,
.has-js .panel.is-active .guest-card,
.has-js .panel.is-active .guide-list article,
.has-js .panel.is-active .qr-card,
.has-js .panel.is-active .contact-card,
.has-js .panel.is-active .note-card,
.has-js .panel.is-active .primary-link,
.has-js .panel.is-active .closing {
  animation: card-reveal 560ms cubic-bezier(0.2, 0.75, 0.2, 1) both;
}

.has-js .panel.is-active .letter-card,
.has-js .panel.is-active .host-card,
.has-js .panel.is-active .contact-card,
.has-js .panel.is-active .note-card {
  animation-delay: 280ms;
}

.has-js .panel.is-active .primary-link {
  animation-delay: 500ms;
}

.has-js .panel.is-active .closing {
  animation-delay: 580ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(1) {
  animation-delay: 260ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(2) {
  animation-delay: 330ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(3) {
  animation-delay: 400ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(4) {
  animation-delay: 470ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(5) {
  animation-delay: 540ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(6) {
  animation-delay: 610ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(7) {
  animation-delay: 680ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(8) {
  animation-delay: 750ms;
}

.has-js .panel.is-active :is(.info-grid, .timeline, .session-list, .guest-grid, .guide-list, .qr-grid) > :nth-child(n+9) {
  animation-delay: 820ms;
}

.eyebrow {
  margin: 0 0 7px;
  color: var(--gold-700);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1,
h2 {
  margin-bottom: 9px;
  color: var(--teal-900);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-weight: 900;
  line-height: 1.16;
}

h1 {
  font-size: 2.42rem;
}

h2 {
  font-size: 2.12rem;
}

h3 {
  margin-bottom: 7px;
  color: var(--teal-900);
  font-size: 1.02rem;
  line-height: 1.36;
}

p {
  margin-bottom: 12px;
  font-size: 1rem;
}

.section-head p:last-child {
  max-width: 26rem;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 0.96rem;
  font-weight: 700;
  line-height: 1.5;
}

.lead {
  color: var(--teal-800);
  font-weight: 900;
}

.letter-card,
.info-card,
.host-card,
.session-card,
.guest-card,
.guide-list article,
.contact-card,
.note-card,
.qr-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 10px 30px rgba(6, 63, 59, 0.08);
  backdrop-filter: blur(10px);
}

.letter-card {
  padding: 22px 20px;
}

.letter-card p {
  color: #163f3d;
  text-align: justify;
}

.sign-block {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  text-align: right;
}

.sign-block p,
.sign-block time {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
  text-align: right;
}

.info-grid,
.guide-list,
.session-list,
.guest-grid,
.qr-grid {
  display: grid;
  gap: 12px;
}

.info-card {
  position: relative;
  min-height: 92px;
  padding: 16px 17px;
  overflow: hidden;
}

.info-card::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(180deg, var(--teal-700), var(--gold-500));
}

.primary-info {
  color: #fff;
  background: linear-gradient(135deg, var(--teal-900), var(--blue-800));
}

.info-card span,
.contact-card span {
  display: block;
  margin-bottom: 5px;
  color: var(--gold-700);
  font-size: 0.78rem;
  font-weight: 900;
}

.primary-info span,
.primary-info strong {
  color: #fff;
}

.info-card strong {
  display: block;
  color: var(--teal-900);
  font-size: 1.08rem;
  line-height: 1.45;
}

.primary-info strong {
  color: #fff;
}

.host-card,
.guide-list article,
.note-card {
  margin-top: 12px;
  padding: 16px 17px;
}

.host-card p,
.guide-list p,
.note-card {
  margin-bottom: 8px;
  color: var(--ink-soft);
  font-size: 0.94rem;
}

.host-card p:last-child,
.guide-list p:last-child {
  margin-bottom: 0;
}

.timeline {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.timeline li {
  display: grid;
  grid-template-columns: 102px 1fr;
  gap: 12px;
  align-items: start;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 8px 22px rgba(6, 63, 59, 0.06);
}

.timeline time,
.session-card time {
  color: var(--gold-700);
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1.42;
}

.timeline span {
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.45;
}

.session-card {
  padding: 15px 16px;
}

.session-card.with-photo {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 13px;
  align-items: center;
}

.session-card.with-photo img {
  width: 76px;
  height: 92px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  object-fit: cover;
  object-position: top center;
  background: var(--blue-100);
  box-shadow: 0 10px 22px rgba(6, 63, 59, 0.13);
}

.session-card h3 {
  margin-top: 5px;
}

.session-card p,
.session-card span {
  display: block;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.5;
}

.session-list.compact {
  gap: 10px;
}

.session-list.compact .session-card {
  padding: 12px 14px;
}

.session-list.compact h3 {
  margin-bottom: 4px;
  font-size: 0.98rem;
}

.guest-card {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 13px;
  align-items: center;
  min-height: 108px;
  padding: 12px 13px;
}

.guest-card img {
  width: 74px;
  height: 90px;
  border: 2px solid #fff;
  border-radius: 8px;
  object-fit: cover;
  object-position: top center;
  background: var(--blue-100);
  box-shadow: 0 10px 22px rgba(6, 63, 59, 0.12);
}

.guest-card strong {
  display: block;
  color: var(--teal-900);
  font-size: 1.08rem;
  line-height: 1.25;
}

.guest-card span {
  display: block;
  margin-top: 4px;
  color: var(--blue-800);
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.38;
}

.guest-card p {
  margin: 3px 0 0;
  color: var(--ink-soft);
  font-size: 0.82rem;
  line-height: 1.42;
}

.host-grid .guest-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(235, 247, 244, 0.92));
}

.qr-grid {
  margin: 16px 0;
}

.qr-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 13px;
  align-items: center;
  min-height: 118px;
  padding: 12px;
}

.qr-card img {
  width: 96px;
  height: 96px;
  border: 1px solid rgba(7, 58, 58, 0.12);
  border-radius: 8px;
  object-fit: contain;
  background: #fff;
}

.qr-card strong {
  display: block;
  color: var(--teal-900);
  font-size: 1rem;
  line-height: 1.3;
}

.qr-card span {
  display: block;
  margin-top: 5px;
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.4;
}

.primary-link {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 18px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--teal-700), var(--blue-800));
  box-shadow: 0 14px 30px rgba(8, 124, 113, 0.24);
  font-weight: 900;
  text-align: center;
  text-decoration: none;
  transition: background-color 180ms ease, box-shadow 180ms ease, color 180ms ease;
}

.primary-link:hover {
  box-shadow: 0 16px 36px rgba(8, 124, 113, 0.3);
}

.contact-card {
  padding: 18px;
  margin-bottom: 16px;
}

.contact-card p {
  margin-bottom: 14px;
}

.contact-card p:last-child {
  margin-bottom: 0;
}

.contact-card strong {
  display: block;
  color: var(--teal-900);
  font-size: 1.04rem;
  line-height: 1.48;
}

.closing {
  margin: 18px 0 0;
  color: var(--gold-700);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 1.12rem;
  font-weight: 900;
  text-align: center;
}

.page-dots {
  position: fixed;
  z-index: 10;
  top: 50%;
  right: max(9px, env(safe-area-inset-right, 0px));
  display: grid;
  gap: 8px;
  transform: translateY(-50%);
}

.page-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  background: rgba(8, 98, 88, 0.28);
  box-shadow: 0 3px 10px rgba(6, 63, 59, 0.1);
  cursor: pointer;
  transition: background-color 180ms ease, height 180ms ease;
}

.page-dots button[aria-current="true"] {
  height: 24px;
  background: var(--gold-500);
}

.deck-controls {
  position: fixed;
  right: max(12px, env(safe-area-inset-right, 0px));
  bottom: calc(14px + var(--safe-bottom));
  z-index: 11;
  display: grid;
  gap: 10px;
}

.control-btn {
  position: relative;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 28px rgba(6, 63, 59, 0.18);
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: background-color 180ms ease, opacity 180ms ease, box-shadow 180ms ease;
}

.control-btn:hover {
  background: #fff;
  box-shadow: 0 14px 34px rgba(6, 63, 59, 0.22);
}

.control-btn:disabled {
  cursor: default;
  opacity: 0.38;
}

.control-btn::before {
  content: "";
  position: absolute;
  inset: 17px 15px 12px;
  border-top: 3px solid var(--teal-800);
  border-left: 3px solid var(--teal-800);
  transform: rotate(45deg);
}

.control-btn.next::before {
  inset: 12px 15px 17px;
  transform: rotate(225deg);
}

.control-btn.next:not(:disabled) {
  animation: next-hint 1800ms ease-in-out infinite;
}

@keyframes cover-reveal {
  from {
    opacity: 0;
    transform: scale(1.025);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes panel-reveal {
  from {
    opacity: 0;
    transform: translate3d(0, 16px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes card-reveal {
  from {
    opacity: 0;
    transform: translate3d(0, 18px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes next-hint {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  50% {
    transform: translate3d(0, 4px, 0);
  }
}

@media (min-width: 560px) {
  body {
    background:
      linear-gradient(90deg, rgba(29, 79, 130, 0.08), transparent 26%, transparent 74%, rgba(8, 124, 113, 0.09)),
      #ddeeea;
  }

  .deck {
    width: min(100vw, 480px);
    margin: 0 auto;
    box-shadow: 0 0 80px rgba(6, 63, 59, 0.2);
  }

  .page-dots {
    right: calc(50% - min(50vw, 240px) + 12px);
  }

  .deck-controls {
    right: calc(50% - min(50vw, 240px) + 14px);
  }
}

@media (max-width: 374px) {
  .text-panel {
    padding-left: 14px;
    padding-right: 14px;
  }

  .panel-inner {
    max-height: calc(100dvh - 104px - var(--safe-top) - var(--safe-bottom));
  }

  h1 {
    font-size: 2.1rem;
  }

  h2 {
    font-size: 1.86rem;
  }

  p {
    font-size: 0.94rem;
  }

  .letter-card,
  .host-card,
  .contact-card {
    padding: 17px;
  }

  .timeline li {
    grid-template-columns: 88px 1fr;
    padding: 10px 11px;
  }

  .guest-card {
    grid-template-columns: 68px 1fr;
    gap: 11px;
  }

  .guest-card img {
    width: 68px;
    height: 84px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .has-js .cover-art,
  .has-js .text-panel .section-head > *,
  .has-js .text-panel .letter-card,
  .has-js .text-panel .info-card,
  .has-js .text-panel .host-card,
  .has-js .text-panel .timeline li,
  .has-js .text-panel .session-card,
  .has-js .text-panel .guest-card,
  .has-js .text-panel .guide-list article,
  .has-js .text-panel .qr-card,
  .has-js .text-panel .contact-card,
  .has-js .text-panel .note-card,
  .has-js .text-panel .primary-link,
  .has-js .text-panel .closing {
    opacity: 1 !important;
    transform: none !important;
  }

  .control-btn.next {
    animation: none !important;
  }
}
