/* ugc-skill — single page, paper & ink */

@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Geist";
  src: url("/fonts/geist.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f2ede3;
  --paper-2: #e9e3d5;
  --ink: #141210;
  --ink-soft: #524d46;
  --black: #16130f;
  --cream: #f6f0e4;
  --red: #c9320f;
  --red-bright: #e03a15;
  --line: rgba(20, 18, 16, 0.16);
  --line-strong: rgba(20, 18, 16, 0.32);
  --sans: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --pad: clamp(20px, 4vw, 44px);
  --max: 1240px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  border-top: 4px solid var(--red);
  min-height: 100svh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.035;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: var(--red); color: var(--cream); }

html { caret-color: var(--red); }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 2px;
}

@supports (scrollbar-width: thin) {
  html { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
}
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--line-strong); border: 3px solid var(--paper); border-radius: 8px; }
::-webkit-scrollbar-track { background: transparent; }

p { margin: 0; }
a { color: inherit; }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  background: rgba(20, 18, 16, 0.07);
  padding: 1px 5px;
  border-radius: 3px;
}

h1, h2, h3 { margin: 0; font-weight: 400; }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--cream);
  padding: 10px 16px;
  z-index: 20;
  font-size: 14px;
}
.skip:focus { left: 12px; top: 12px; }

.i { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.i--up { width: 12px; height: 12px; }

/* ---------- header ---------- */

.top {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad);
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mark {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.005em;
}
.mark__seal {
  width: 9px;
  height: 9px;
  background: var(--red);
  transform: rotate(45deg);
  border-radius: 1px;
  margin: 0 3px 0 1px;
}
.mark__text { padding-top: 1px; }

.top__nav { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 30px); }
.top__nav a {
  font-size: 13px;
  color: var(--ink-soft);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 0;
  position: relative;
}
.top__nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
}
.top__nav a:hover { color: var(--ink); }
.top__nav a:hover::after { transform: scaleX(1); }

/* ---------- hero ---------- */

main { position: relative; z-index: 1; }

.hero {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(44px, 7vw, 96px) var(--pad) clamp(32px, 4vw, 56px);
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(360px, 5fr);
  gap: clamp(36px, 5vw, 76px);
  align-items: start;
}

.hero__text { padding-top: 6px; }

.hero__title {
  font-family: var(--serif);
  font-size: clamp(2.9rem, 6.4vw, 6rem);
  line-height: 0.94;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.hero__title em {
  font-style: italic;
  color: var(--red);
}

.lede {
  margin-top: clamp(22px, 2.6vw, 32px);
  max-width: 46ch;
  font-size: clamp(16px, 1.3vw, 18px);
  line-height: 1.55;
  color: var(--ink-soft);
}

.hero__foot {
  margin-top: clamp(26px, 3vw, 40px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  color: var(--ink-soft);
}
.hero__sep { color: var(--line-strong); }
.hero__pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--red);
  margin-right: 2px;
  box-shadow: 0 0 0 3px rgba(201, 50, 15, 0.14);
}

/* ---------- gate ticket ---------- */

.gate {
  position: relative;
  background: var(--black);
  color: var(--cream);
  border-radius: 8px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 26px 50px -28px rgba(20, 18, 16, 0.55),
    0 8px 18px -12px rgba(20, 18, 16, 0.4);
  isolation: isolate;
}

.gate::before,
.gate::after {
  content: "";
  position: absolute;
  top: 35px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--paper);
  z-index: 2;
}
.gate::before { left: -10px; }
.gate::after { right: -10px; }

.gate__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 17px 24px 15px;
}
.gate__serial,
.gate__status {
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.gate__serial { color: rgba(246, 240, 228, 0.72); }
.gate__status {
  color: rgba(246, 240, 228, 0.72);
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.gate__status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.gate.is-open .gate__status { color: #f0a083; }

.gate__cut {
  height: 1px;
  margin: 0 24px;
  background-image: linear-gradient(to right, rgba(246, 240, 228, 0.28) 50%, transparent 0);
  background-size: 7px 1px;
  background-repeat: repeat-x;
}

.gate__body { padding: 26px 24px 22px; }

.gate__view--success { position: relative; }

.gate__done { padding-right: 96px; }

.gate__title,
.gate__done {
  font-family: var(--serif);
  font-size: 32px;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.gate__hint {
  margin-top: 6px;
  font-size: 13px;
  color: rgba(246, 240, 228, 0.74);
}

.gate__form { margin-top: 24px; }

.field { display: block; }
.field__label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(246, 240, 228, 0.7);
  margin-bottom: 2px;
}
.field__input {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(246, 240, 228, 0.32);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 15.5px;
  padding: 10px 0 11px;
  border-radius: 0;
  outline: none;
  transition: border-color 180ms ease;
}
.field__input::placeholder { color: rgba(246, 240, 228, 0.58); }
.field__input:hover { border-bottom-color: rgba(246, 240, 228, 0.5); }
.field__input:focus {
  border-bottom-color: var(--cream);
  box-shadow: 0 1px 0 0 var(--cream);
}
.field__input:focus-visible { outline: none; }
.field__input[aria-invalid="true"] { border-bottom-color: var(--red-bright); }

.gate__error {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.45;
  color: #f09b7f;
}
.gate__error a { color: inherit; }

.btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 52px;
  padding: 0 18px;
  border: 0;
  border-radius: 4px;
  font-family: var(--sans);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms cubic-bezier(0.22, 1, 0.36, 1), background-color 160ms ease, color 160ms ease;
}
.btn .i { width: 18px; height: 18px; }
.btn--paper {
  margin-top: 18px;
  background: var(--cream);
  color: var(--ink);
}
.btn--paper:hover { background: #fffaf0; transform: translateY(-1px); }
.btn--paper:active { transform: translateY(0); }
.btn--paper[disabled] { opacity: 0.65; cursor: progress; transform: none; }
.btn--red[disabled] { opacity: 0.7; cursor: progress; transform: none; }

.btn--red {
  margin-top: 18px;
  background: var(--red);
  color: #fff7ec;
}
.btn--red:hover { background: #b62a0a; transform: translateY(-1px); }
.btn--red:active { transform: translateY(0); }

.gate__legal {
  margin-top: 14px;
  font-size: 12px;
  line-height: 1.5;
  color: rgba(246, 240, 228, 0.7);
}
.gate__legal a { color: rgba(246, 240, 228, 0.9); text-underline-offset: 2px; }

.gate__stub {
  margin: 0 24px;
  padding: 11px 0 15px;
  border-top: 1px dashed rgba(246, 240, 228, 0.2);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(246, 240, 228, 0.55);
}

.stamp {
  position: absolute;
  top: -2px;
  right: 0;
  transform: rotate(-7deg) scale(0.7);
  transform-origin: center;
  opacity: 0;
  background: var(--paper);
  color: var(--red);
  border: 1.5px solid var(--red);
  border-radius: 2px;
  padding: 5px 9px 4px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transition: none;
}
.gate.is-open .stamp {
  animation: stamp-in 620ms cubic-bezier(0.16, 1.2, 0.3, 1) 120ms forwards;
}
@keyframes stamp-in {
  from { opacity: 0; transform: rotate(-16deg) scale(1.45); }
  60% { opacity: 1; }
  to { opacity: 1; transform: rotate(-7deg) scale(1); }
}

.file {
  margin-top: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(246, 240, 228, 0.18);
  border-radius: 5px;
}
.file__glyph {
  width: 38px;
  height: 38px;
  flex: none;
  display: grid;
  place-items: center;
  background: rgba(246, 240, 228, 0.07);
  border-radius: 4px;
}
.file__glyph .i { width: 20px; height: 20px; }
.file__info { min-width: 0; display: grid; gap: 2px; }
.file__name {
  font-size: 13.5px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.file__meta { font-size: 12px; color: rgba(246, 240, 228, 0.72); }
.file__tag {
  margin-left: auto;
  flex: none;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #f0b9a4;
  border: 1px solid rgba(240, 185, 164, 0.5);
  border-radius: 2px;
  padding: 3px 6px 2px;
}

/* ---------- proof stories ---------- */

.proof {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(32px, 4.5vw, 56px) var(--pad) clamp(44px, 5.5vw, 72px);
}

.proof__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px 40px;
  flex-wrap: wrap;
  margin-bottom: clamp(24px, 3vw, 38px);
}

.proof__title {
  font-family: var(--serif);
  font-size: clamp(2.1rem, 3.6vw, 3.2rem);
  line-height: 1;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.proof__note {
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 36ch;
}

.stories {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 26px);
}

.story__frame {
  position: relative;
  aspect-ratio: 9 / 16;
  display: grid;
  place-items: center;
  background: var(--paper-2);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 200ms ease;
}
.story__frame--video { background: #0d0b09; }
.story__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.story__frame--video .story__n,
.story__frame--video .story__ratio {
  background: rgba(242, 237, 227, 0.88);
  border-radius: 2px;
  padding: 4px 7px 3px;
  z-index: 1;
}
.story__frame--video .story__n { top: 14px; left: 14px; }
.story__frame--video .story__ratio { bottom: 14px; left: 14px; }
.story__frame--video::before { z-index: 1; }


.story__sound {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  border: 0;
  border-radius: 20px;
  background: rgba(242, 237, 227, 0.92);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 180ms ease, transform 180ms cubic-bezier(0.22, 1, 0.36, 1), background-color 160ms ease;
}
.story__sound:hover { background: var(--cream); }

@media (hover: hover) {
  .story__sound {
    opacity: 0;
    transform: translateY(-4px);
    pointer-events: none;
  }
  .story__frame:hover .story__sound,
  .story__frame:focus-within .story__sound,
  .story__sound:focus-visible,
  .story__sound[aria-pressed="true"] {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
}
.story__sound .i { width: 14px; height: 14px; }
.story__sound[aria-pressed="true"] { background: var(--red); color: var(--cream); }

.story__frame::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px dashed rgba(20, 18, 16, 0.2);
  border-radius: 4px;
  pointer-events: none;
}

.story__n {
  position: absolute;
  top: 18px;
  left: 20px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  line-height: 1;
  color: var(--red);
}

.story__play {
  width: 58px;
  height: 58px;
  border: 1px dashed rgba(20, 18, 16, 0.45);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--ink-soft);
}
.story__play svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.3;
  stroke-linejoin: round;
  margin-left: 2px;
}

.story__ratio,
.story__status {
  position: absolute;
  bottom: 18px;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.story__ratio { left: 20px; }
.story__status {
  right: 20px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  padding: 3px 6px 2px;
  font-size: 10px;
  background: rgba(242, 237, 227, 0.6);
}

/* ---------- closing ---------- */

.cta {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(40px, 5vw, 68px) var(--pad) clamp(64px, 8vw, 110px);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}
.cta__text {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 4vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.015em;
}
.cta__text em { font-style: italic; color: var(--red); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--ink);
  transition: gap 200ms cubic-bezier(0.22, 1, 0.36, 1), color 160ms ease;
}
.link-arrow .i { width: 17px; height: 17px; }
.link-arrow:hover { gap: 13px; color: var(--red); border-bottom-color: var(--red); }

.foot {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad) 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--ink-soft);
}
.foot a {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  text-decoration: none;
  color: var(--ink-soft);
}
.foot a:hover { color: var(--ink); }

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; max-width: 720px; }
  .hero__text { max-width: 640px; }
  .gate { width: 100%; max-width: 560px; }
}

@media (max-width: 760px) {
  .top { height: 64px; }
  .top__nav a[href="#como"] { display: none; }
  .top__nav a { font-size: 12.5px; }
  .mark { font-size: 13.5px; }

  .hero { padding-top: 34px; gap: 32px; }
  .hero__title { font-size: clamp(2.55rem, 10.6vw, 3.5rem); }
  .lede { font-size: 16px; margin-top: 20px; }
  .hero__foot { font-size: 12.5px; gap: 8px; }

  .gate__top { padding: 15px 20px 13px; }
  .gate__cut { margin: 0 20px; }
  .gate__body { padding: 22px 20px 18px; }
  .gate__stub { margin: 0 20px; }
  .gate__title, .gate__done { font-size: 28px; }

  .stories {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    margin-inline: calc(var(--pad) * -1);
    padding: 2px calc(var(--pad) * 2) 8px;
    scrollbar-width: none;
  }
  .stories::-webkit-scrollbar { display: none; }
  .story { flex: 0 0 62%; scroll-snap-align: start; }

  .cta { align-items: flex-start; flex-direction: column; }
}

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