/* REPO RABBIT HOLE · Free guides. Public, phone-first page (most visitors arrive from Instagram's in-app browser).
   Same design language as Studio HQ (dashboard/styles.css): dark glass, brand greens, star gold.
   System font stacks only, so the page needs nothing outside 'self' (CSP default-src 'self'). */

:root {
  color-scheme: dark;
  --font-sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", system-ui, sans-serif;
  --font-display: ui-sans-serif, -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Roboto, system-ui, sans-serif;
  --font-serif: "New York", ui-serif, "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, "Roboto Mono", Consolas, monospace;

  --brand: #1F9D55;
  --brand-2: #3DDC84;
  --star: #E3B341;
  --danger: #FF7A7A;
  --danger-solid: #D64545;

  --bg: #0B0F0D;
  --surface: rgba(19, 23, 26, .62);
  --surface-solid: #121619;
  --surface-2: rgba(255, 255, 255, .04);
  --surface-3: rgba(255, 255, 255, .07);
  --border: rgba(255, 255, 255, .08);
  --border-2: rgba(255, 255, 255, .14);
  --text: #ECF0EE;
  --text-2: #A9B2AE;
  --text-3: #7D8682;
  --accent: #3DDC84;
  --accent-soft: rgba(61, 220, 132, .12);
  --accent-glow: rgba(61, 220, 132, .34);
  --star-soft: rgba(227, 179, 65, .14);
  --danger-soft: rgba(214, 69, 69, .14);
  --shadow: 0 1px 0 rgba(255, 255, 255, .05) inset, 0 14px 38px -16px rgba(0, 0, 0, .7);
  --shadow-lift: 0 1px 0 rgba(255, 255, 255, .07) inset, 0 26px 54px -18px rgba(0, 0, 0, .8), 0 0 0 1px rgba(61, 220, 132, .2), 0 0 44px -10px rgba(61, 220, 132, .3);

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --gutter: 16px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --t-fast: 160ms;
  --t: 260ms;
  --t-slow: 460ms;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh; background: var(--bg); color: var(--text);
  font: 400 16px/1.55 var(--font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden; -webkit-tap-highlight-color: transparent;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}
::selection { background: var(--accent-glow); }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; font-family: var(--font-display); letter-spacing: -.02em; }
p { margin: 0; }
ol, ul { margin: 0; padding: 0; list-style: none; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 14px; border-radius: 10px; background: var(--accent); color: #04160b; font-weight: 700; text-decoration: none; }
.skip:focus { top: 12px; }

/* ------------------------------------------------------------------ background */
.aurora { position: fixed; inset: -20vmax; z-index: 0; pointer-events: none; filter: blur(64px); opacity: .6; }
.aurora span { position: absolute; border-radius: 50%; mix-blend-mode: screen; animation: drift 26s ease-in-out infinite alternate; will-change: transform; }
.aurora span:nth-child(1) { width: 52vmax; height: 52vmax; left: 30%; top: 0; background: radial-gradient(closest-side, rgba(31, 157, 85, .42), transparent); }
.aurora span:nth-child(2) { width: 40vmax; height: 40vmax; left: 0; top: 44%; background: radial-gradient(closest-side, rgba(61, 220, 132, .16), transparent); animation-duration: 34s; animation-delay: -8s; }
.aurora span:nth-child(3) { width: 34vmax; height: 34vmax; left: 66%; top: 52%; background: radial-gradient(closest-side, rgba(227, 179, 65, .14), transparent); animation-duration: 40s; animation-delay: -16s; }
@keyframes drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(-6vmax, 5vmax, 0) scale(1.14); } }
/* a faint contribution-graph grid, fading out downwards */
.grid-bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .5;
  background-image: linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px);
  background-size: 28px 28px; background-position: center -1px;
  -webkit-mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, #000 30%, transparent 80%); mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, #000 30%, transparent 80%); }
.grain { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .04;
  background-image: radial-gradient(rgba(255, 255, 255, .9) .5px, transparent .6px); background-size: 3px 3px; }

/* ------------------------------------------------------------------ top bar */
.topbar, .main, .footer { position: relative; z-index: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; padding-bottom: 6px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; border-radius: 12px; padding: 4px 6px 4px 4px; margin-left: -4px; }
.brand-logo { width: 32px; height: 32px; border-radius: 10px; object-fit: cover; box-shadow: 0 0 0 1px var(--border-2), 0 6px 16px -6px var(--accent-glow); }
.brand-name { font: 750 12.5px/1 var(--font-display); letter-spacing: .09em; white-space: nowrap; }
.tag { display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 11px; border-radius: 99px; font: 600 12px var(--font-sans);
  color: var(--accent); background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); white-space: nowrap; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); flex: none; }

/* ------------------------------------------------------------------ hero */
.hero { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 26px 0 22px; }
.avatar-wrap { position: relative; width: 104px; height: 104px; margin-bottom: 18px; animation: rise var(--t-slow) var(--ease) both; }
.avatar { width: 100%; height: 100%; border-radius: 30px; object-fit: cover; position: relative; z-index: 1;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 18px 40px -14px rgba(0, 0, 0, .9), 0 0 50px -6px var(--accent-glow); animation: bob 5.5s ease-in-out infinite; }
.avatar-ring { position: absolute; inset: -3px; border-radius: 33px; z-index: 0; --angle: 0deg;
  background: conic-gradient(from var(--angle), rgba(61, 220, 132, .06) 0%, rgba(61, 220, 132, .95) 18%, rgba(61, 220, 132, .06) 36%, rgba(227, 179, 65, .06) 52%, rgba(227, 179, 65, .9) 70%, rgba(227, 179, 65, .06) 88%);
  animation: ring 7s linear infinite; }
.avatar-ring::after { content: ""; position: absolute; inset: -6px; border-radius: 39px; background: inherit; filter: blur(14px); opacity: .55; }
@property --angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes ring { to { --angle: 360deg; } }
.avatar-badge { position: absolute; z-index: 2; right: -10px; bottom: -6px; padding: 4px 8px; border-radius: 9px; transform: rotate(-6deg);
  font: 800 11px/1 var(--font-mono); letter-spacing: .06em; color: #1c1404; background: linear-gradient(180deg, #F2C95C, #E3B341);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .5) inset, 0 8px 18px -6px rgba(227, 179, 65, .6); }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes rise { from { opacity: 0; transform: translateY(12px) scale(.96); } to { opacity: 1; transform: none; } }

.eyebrow { display: inline-flex; align-items: center; gap: 8px; font: 550 11.5px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--text-2);
  margin-bottom: 12px; animation: rise var(--t-slow) var(--ease) 60ms both; }
.hero h1 { font-size: clamp(31px, 8.6vw, 54px); line-height: 1.04; font-weight: 760; letter-spacing: -.035em; max-width: 15ch; text-wrap: balance;
  animation: rise var(--t-slow) var(--ease) 110ms both; }
.hero h1 em { display: inline-block; font-family: var(--font-serif); font-style: italic; font-weight: 500; letter-spacing: -.02em; padding-right: .06em;
  background: linear-gradient(100deg, #8CF5B9 0%, var(--accent) 45%, #F2C95C 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .sub { margin-top: 12px; font-size: clamp(16.5px, 4.4vw, 19px); color: var(--text-2); text-wrap: balance; animation: rise var(--t-slow) var(--ease) 160ms both; }

/* ------------------------------------------------------------------ cards */
.card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%); }
.card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, .05), transparent 38%); }

/* ------------------------------------------------------------------ unlock */
.unlock { max-width: 620px; margin: 0 auto; padding: 18px 16px 16px; animation: rise var(--t-slow) var(--ease) 210ms both; }
.unlock::after { content: ""; position: absolute; left: 12%; right: 12%; top: -1px; height: 1px; pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(61, 220, 132, .7), transparent); }
.field-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 24px; margin: 0 2px 10px; }
.field-head label { flex: none; white-space: nowrap; font: 650 12px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--text-2); }
.for-ep { display: inline-flex; align-items: center; gap: 6px; min-width: 0; max-width: 64%; height: 24px; padding: 0 4px 0 9px; border-radius: 99px;
  font-size: 12px; font-weight: 600; color: var(--star); background: var(--star-soft); border: 1px solid color-mix(in srgb, var(--star) 32%, transparent);
  animation: pop var(--t) var(--ease-spring); }
.for-ep .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.for-ep button { flex: none; width: 18px; height: 18px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 50%; background: rgba(227, 179, 65, .18); color: inherit; cursor: pointer; }
.for-ep button svg { width: 11px; height: 11px; }

.input-row { position: relative; display: flex; gap: 8px; align-items: stretch; padding: 6px; border-radius: 18px;
  background: rgba(0, 0, 0, .32); border: 1px solid var(--border-2);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .04), 0 0 0 0 var(--accent-soft) inset;
  transition: border-color var(--t-fast), box-shadow var(--t), background var(--t-fast); }
.input-row:focus-within { border-color: color-mix(in srgb, var(--accent) 70%, transparent); box-shadow: 0 0 0 4px var(--accent-soft), 0 12px 40px -14px var(--accent-glow); background: rgba(0, 0, 0, .4); }
.input-row.is-wrong { border-color: color-mix(in srgb, var(--danger-solid) 80%, transparent); box-shadow: 0 0 0 4px var(--danger-soft); }
.input-row.is-right { border-color: color-mix(in srgb, var(--accent) 85%, transparent); box-shadow: 0 0 0 4px var(--accent-soft), 0 0 50px -8px var(--accent-glow); }
.input-icon { flex: none; display: grid; place-items: center; width: 34px; margin-left: 4px; color: var(--text-3); transition: color var(--t-fast), transform var(--t) var(--ease-spring); }
.input-icon svg { width: 20px; height: 20px; }
.input-row:focus-within .input-icon { color: var(--accent); }
.input-row.is-right .input-icon { color: var(--accent); transform: scale(1.12); }
.input-row.is-wrong .input-icon { color: var(--danger); }
.word-input { flex: 1; min-width: 0; height: 54px; padding: 0 6px; border: 0; background: transparent; outline: none;
  font: 750 21px/1 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--text); caret-color: var(--accent); }
.word-input::placeholder { color: var(--text-3); font: 500 17px var(--font-sans); letter-spacing: 0; text-transform: none; opacity: .9; }
.word-input:focus-visible { outline: none; }

.btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 46px; padding: 0 18px; border-radius: 13px;
  border: 1px solid var(--border-2); background: var(--surface-2); color: var(--text); font-weight: 650; font-size: 15px; text-decoration: none;
  cursor: pointer; white-space: nowrap; user-select: none; -webkit-user-select: none; overflow: hidden; touch-action: manipulation;
  transition: transform var(--t-fast) var(--ease), background var(--t-fast), border-color var(--t-fast), box-shadow var(--t), filter var(--t-fast); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:hover { background: var(--surface-3); border-color: rgba(255, 255, 255, .22); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn-primary { color: #04160b; border-color: rgba(61, 220, 132, .6); background: linear-gradient(180deg, #4BE592 0%, #2DB868 55%, #1F9D55 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .45) inset, 0 -1px 0 rgba(0, 0, 0, .15) inset, 0 10px 26px -10px var(--accent-glow); }
.btn-primary:hover { background: linear-gradient(180deg, #4BE592 0%, #2DB868 55%, #1F9D55 100%); filter: brightness(1.07);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .45) inset, 0 14px 34px -8px var(--accent-glow); }
.btn .shine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%); transform: translateX(-110%); }
.btn-primary:hover .shine, .btn-primary.shimmer .shine { transform: translateX(110%); transition: transform 800ms var(--ease); }
.btn-unlock { height: auto; min-height: 54px; min-width: 104px; padding: 0 20px; border-radius: 13px; font-size: 16px; font-weight: 750; letter-spacing: .01em; }
.btn-unlock .spinner { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid rgba(4, 22, 11, .25); border-top-color: #04160b; animation: spin 700ms linear infinite; }
.btn-unlock.loading .spinner { display: block; }
.btn-unlock.loading .btn-label { display: none; }
.btn-unlock[disabled] { cursor: progress; }
.unlock-form.is-wrong .help { display: none; }
.help { margin: 10px 4px 0; font-size: 13.5px; color: var(--text-3); text-wrap: pretty; }

/* shake on a wrong word */
.shake { animation: shake 460ms cubic-bezier(.36, .07, .19, .97) both; }
@keyframes shake { 10%, 90% { transform: translateX(-1px); } 20%, 80% { transform: translateX(3px); } 30%, 50%, 70% { transform: translateX(-7px); } 40%, 60% { transform: translateX(7px); } }
@keyframes pop { from { transform: scale(.7); opacity: 0; } to { transform: none; opacity: 1; } }

/* ------------------------------------------------------------------ status messages */
.status:empty { display: none; }
.status { margin-top: 14px; }
.notice { display: flex; gap: 12px; padding: 13px 14px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface-2); animation: rise var(--t) var(--ease) both; }
.notice .ic { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; }
.notice .ic svg { width: 18px; height: 18px; }
.notice h3 { font-size: 15px; font-weight: 700; letter-spacing: -.01em; margin-bottom: 3px; }
.notice p { font-size: 14px; color: var(--text-2); text-wrap: pretty; }
.notice p + p { margin-top: 6px; }
.notice .tip { display: flex; gap: 7px; align-items: flex-start; color: var(--text-3); font-size: 13px; }
.notice .tip svg { width: 15px; height: 15px; flex: none; margin-top: 2px; color: var(--star); }
.notice.wrong { border-color: color-mix(in srgb, var(--danger-solid) 38%, transparent); background: linear-gradient(180deg, rgba(214, 69, 69, .1), rgba(214, 69, 69, .04)); }
.notice.wrong .ic { color: var(--danger); background: var(--danger-soft); }
.notice.warn .ic { color: var(--star); background: var(--star-soft); }

/* ------------------------------------------------------------------ unlocked result */
.result:empty { display: none; }
.result { margin-top: 14px; outline: none; }
.unlocked { position: relative; overflow: hidden; border-radius: 20px; border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  background: linear-gradient(180deg, rgba(61, 220, 132, .1), rgba(19, 23, 26, .5) 46%); box-shadow: var(--shadow-lift);
  animation: unfold 620ms var(--ease) both; transform-origin: 50% 0; }
@keyframes unfold { 0% { opacity: 0; transform: translateY(-6px) scale(.97); clip-path: inset(0 0 100% 0 round 20px); } 100% { opacity: 1; transform: none; clip-path: inset(0 0 0 0 round 20px); } }
.unlocked .thumb { position: relative; aspect-ratio: 16 / 9; background: #0e1311; overflow: hidden; }
.unlocked .thumb img { width: 100%; height: 100%; object-fit: cover; animation: reveal-img 900ms var(--ease) both; }
@keyframes reveal-img { from { transform: scale(1.08); filter: blur(10px) saturate(.6); } to { transform: none; filter: none; } }
.unlocked .thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(11, 15, 13, .75)); pointer-events: none; }
/* the badge sits in the card body, above the title: never over the thumbnail's own headline */
.unlocked .badge { display: inline-flex; align-items: center; gap: 6px; height: 26px; margin-bottom: 10px; padding: 0 11px; border-radius: 99px;
  font: 800 11.5px var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: #1c1404; background: linear-gradient(180deg, #F5D06A, #E3B341);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .5) inset, 0 8px 20px -6px rgba(227, 179, 65, .7); animation: pop 420ms var(--ease-spring) 300ms both; }
.unlocked .badge svg { width: 14px; height: 14px; }
.unlocked .sweep { position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .28) 50%, transparent 65%);
  transform: translateX(-120%); animation: sweep 1100ms var(--ease) 250ms forwards; }
@keyframes sweep { to { transform: translateX(120%); } }
.unlocked .body { padding: 16px 16px 18px; }
.unlocked h3 { font-size: 20px; line-height: 1.22; font-weight: 750; letter-spacing: -.02em; text-wrap: balance; }
.unlocked .meta { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 6px; font: 500 12.5px var(--font-mono); color: var(--text-3); }
.unlocked .actions { display: grid; gap: 10px; margin-top: 16px; }
.btn-guide { height: 60px; border-radius: 16px; font-size: 17px; font-weight: 780; justify-content: space-between; padding: 0 14px 0 18px; }
.btn-guide .l { display: inline-flex; align-items: center; gap: 11px; }
.btn-guide .l svg { width: 22px; height: 22px; }
.btn-guide .size { font: 650 12px var(--font-mono); padding: 4px 8px; border-radius: 8px; background: rgba(4, 22, 11, .14); flex-shrink: 0; white-space: nowrap; }
@media (max-width: 400px) { .btn-guide { font-size: 15.5px; padding: 0 12px 0 14px; gap: 8px; } }
.btn-watch { height: 50px; border-radius: 14px; font-size: 15.5px; }
.btn-watch .yt { width: 26px; height: 18px; border-radius: 5px; display: grid; place-items: center; background: #FF0033; color: #fff; }
.btn-watch .yt svg { width: 10px; height: 10px; }
.repos { margin-top: 16px; }
.repos h4 { font: 650 11.5px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); margin-bottom: 8px; }
.repos ul { display: flex; flex-wrap: wrap; gap: 8px; }
.repo { display: inline-flex; align-items: center; gap: 7px; max-width: 100%; height: 36px; padding: 0 12px; border-radius: 11px; text-decoration: none;
  font: 550 13.5px var(--font-mono); color: var(--text); background: var(--surface-2); border: 1px solid var(--border-2);
  transition: background var(--t-fast), border-color var(--t-fast), transform var(--t-fast); }
.repo span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.repo svg { width: 16px; height: 16px; flex: none; color: var(--text-2); }
.repo:hover { background: var(--surface-3); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.repo:active { transform: scale(.98); }
.fine { margin-top: 14px; display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--text-3); text-wrap: pretty; }
.fine svg { width: 15px; height: 15px; flex: none; margin-top: 2px; }
.again { display: flex; justify-content: center; margin-top: 12px; }
.guide-tools { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 8px; margin-top: 8px; }
.guide-tools .link-btn svg { width: 16px; height: 16px; }
.copy-buffer { position: fixed; top: 0; left: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.link-btn { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border: 0; border-radius: 10px; background: transparent; color: var(--text-2);
  font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; transition: color var(--t-fast), background var(--t-fast); }
.link-btn svg { width: 15px; height: 15px; }
.link-btn:hover { color: var(--text); background: var(--surface-2); }

/* ------------------------------------------------------------------ how it works */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--border-2); }
.steps li { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; font-size: 12.5px; line-height: 1.3; color: var(--text-2); }
.steps .n { width: 26px; height: 26px; border-radius: 9px; display: grid; place-items: center; font: 750 12.5px var(--font-mono); color: var(--accent);
  background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.unlock.has-result .steps { display: none; }

/* ------------------------------------------------------------------ library */
.library { margin: 44px auto 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.section-head h2 { font-size: 22px; font-weight: 750; letter-spacing: -.025em; }
.count { font: 600 12.5px var(--font-mono); color: var(--text-3); }
.section-sub { margin-top: 4px; font-size: 14.5px; color: var(--text-2); }
.guides { display: grid; gap: 12px; margin-top: 16px; grid-template-columns: minmax(0, 1fr); }
.guides > li { animation: rise var(--t-slow) var(--ease) both; animation-delay: calc(var(--i, 0) * 60ms + 260ms); }
.gcard { position: relative; display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 12px; align-items: center; width: 100%; padding: 8px; text-align: left; cursor: pointer;
  border-radius: 18px; color: inherit; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  backdrop-filter: blur(14px) saturate(135%); -webkit-backdrop-filter: blur(14px) saturate(135%);
  transition: transform var(--t) var(--ease), border-color var(--t-fast), box-shadow var(--t), background var(--t-fast); }
.gcard:hover { border-color: rgba(61, 220, 132, .3); box-shadow: var(--shadow-lift); transform: translateY(-2px); }
.gcard:active { transform: scale(.985); }
.gcard.is-target { border-color: color-mix(in srgb, var(--star) 55%, transparent); box-shadow: 0 0 0 3px var(--star-soft), var(--shadow); }
.gthumb { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #101513; isolation: isolate; }
.gthumb img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); filter: saturate(.85) brightness(.82); transition: transform var(--t-slow) var(--ease), filter var(--t-slow); }
.gcard:hover .gthumb img { transform: scale(1.09); }
/* frosted lock glass over the thumbnail */
.lockglass { position: absolute; inset: 0; z-index: 1; display: grid; place-items: center;
  background: linear-gradient(160deg, rgba(255, 255, 255, .1), rgba(11, 15, 13, .38)); backdrop-filter: blur(3px) saturate(120%); -webkit-backdrop-filter: blur(3px) saturate(120%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); transition: backdrop-filter var(--t-slow), background var(--t-slow); }
.lockglass .lk { width: 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; color: #fff;
  background: rgba(11, 15, 13, .55); border: 1px solid rgba(255, 255, 255, .22); box-shadow: 0 8px 22px -6px rgba(0, 0, 0, .7);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); transition: transform var(--t) var(--ease-spring), color var(--t), background var(--t); }
.lockglass .lk svg { width: 18px; height: 18px; }
.gcard:hover .lockglass .lk { transform: scale(1.08) rotate(-6deg); color: var(--star); }
.gcard.is-open .gthumb img { filter: none; }
.gcard.is-open .lockglass { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; place-items: end start; padding: 7px; }
.gcard.is-open .lockglass .lk { width: 28px; height: 28px; border-radius: 9px; color: #04160b; background: var(--accent); border-color: rgba(255, 255, 255, .4); }
.gcard.is-open .lockglass .lk svg { width: 15px; height: 15px; }
.ginfo { min-width: 0; display: flex; flex-direction: column; gap: 4px; padding-right: 4px; }
.ginfo h3 { font-size: 15px; line-height: 1.28; font-weight: 680; letter-spacing: -.012em; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.gmeta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; font: 500 12px var(--font-mono); color: var(--text-3); }
.gcta { display: inline-flex; align-items: center; gap: 5px; color: var(--star); font: 650 12px var(--font-sans); }
.gcta svg { width: 13px; height: 13px; }
.gcard.is-open .gcta { color: var(--accent); }

/* loading skeletons + empty state */
.skel { height: 90px; border-radius: 18px; border: 1px solid var(--border); background: linear-gradient(100deg, rgba(255, 255, 255, .03) 30%, rgba(255, 255, 255, .07) 50%, rgba(255, 255, 255, .03) 70%);
  background-size: 300% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
.empty { padding: 26px 18px; text-align: center; color: var(--text-2); border: 1px dashed var(--border-2); border-radius: 18px; font-size: 14.5px; }

/* ------------------------------------------------------------------ footer */
.footer { margin-top: 56px; padding-top: 26px; padding-bottom: 34px; display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.footer::before { content: ""; width: min(420px, 80%); height: 1px; margin-bottom: 8px; background: linear-gradient(90deg, transparent, var(--border-2), transparent); }
.socials { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.social { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border-radius: 12px; text-decoration: none; font-size: 14px; font-weight: 600;
  color: var(--text); background: var(--surface-2); border: 1px solid var(--border-2); transition: background var(--t-fast), border-color var(--t-fast), transform var(--t-fast); }
.social svg { width: 18px; height: 18px; flex: none; }
.social:hover { background: var(--surface-3); border-color: rgba(255, 255, 255, .24); }
.social:active { transform: scale(.98); }
.social .handle { color: var(--text-2); font-weight: 500; }
.disclosure { max-width: 46ch; font-size: 13px; color: var(--text-3); text-wrap: pretty; }
/* no separator characters: a wrapped line can never start with a lone "·" */
.legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; font-size: 12.5px; color: var(--text-3); }
.legal a { color: var(--text-2); text-underline-offset: 3px; }
.legal a:hover { color: var(--text); }

/* confetti canvas */
.confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 40; pointer-events: none; }

/* ------------------------------------------------------------------ wider screens */
@media (min-width: 560px) {
  :root { --gutter: 24px; }
  .unlock { padding: 22px 22px 18px; }
  .guides { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .gcard { grid-template-columns: minmax(0, 1fr); padding: 10px; align-items: stretch; }
  .ginfo { padding: 4px 6px 6px; gap: 6px; }
  .ginfo h3 { font-size: 16px; -webkit-line-clamp: 2; }
  .lockglass .lk { width: 50px; height: 50px; border-radius: 16px; }
  .lockglass .lk svg { width: 22px; height: 22px; }
  .unlocked { display: grid; grid-template-columns: minmax(0, 1fr); }
  .unlocked .actions { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
  .unlocked .actions .btn-watch { height: 60px; border-radius: 16px; }
}
@media (min-width: 900px) {
  .topbar { padding-top: 22px; }
  .hero { padding: 46px 0 30px; }
  .avatar-wrap { width: 120px; height: 120px; }
  .avatar { border-radius: 34px; }
  .avatar-ring { border-radius: 43px; }
  .hero h1 { max-width: 18ch; }
  .guides { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .library { margin-top: 64px; }
  /* unlocked on a wide screen: thumbnail left, actions right */
  .unlock { transition: max-width var(--t-slow) var(--ease); }
  .unlock.has-result { max-width: 880px; }
  .unlocked { grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); align-items: center; }
  .unlocked .thumb { margin: 14px 0 14px 14px; border-radius: 14px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 18px 36px -18px rgba(0, 0, 0, .8); }
  .unlocked .thumb::after { display: none; }
  .unlocked .body { padding: 20px 20px 16px; }
  .unlocked h3 { font-size: 22px; }
  .unlocked .actions { grid-template-columns: minmax(0, 1fr); }
  .unlocked .actions .btn-watch { height: 50px; border-radius: 14px; }
  .again { justify-content: flex-start; margin-left: -12px; }
  .guide-tools { justify-content: flex-start; margin-left: -12px; }
}
@media (max-width: 359px) {
  :root { --gutter: 12px; }
  .gcard { grid-template-columns: 108px minmax(0, 1fr); }
  .btn-unlock { min-width: 88px; padding: 0 14px; }
  .word-input { font-size: 18px; letter-spacing: .1em; }
  .brand-name { font-size: 11.5px; }
}
/* Very narrow phones: the input takes a full row, the button sits under it, so long words stay readable. */
@media (max-width: 359px) {
  .input-row { flex-wrap: wrap; }
  .input-row .word-input { flex: 1 1 calc(100% - 50px); }
  .btn-unlock { flex: 1 1 100%; min-height: 50px; }
}

@media (hover: none) {
  .gcard:hover { transform: none; box-shadow: var(--shadow); border-color: var(--border); }
  .gcard.is-target:hover { border-color: color-mix(in srgb, var(--star) 55%, transparent); }
  .gcard:hover .gthumb img { transform: scale(1.04); }
  .gcard:hover .lockglass .lk { transform: none; color: #fff; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
  .aurora span, .avatar, .avatar-ring, .unlocked .sweep { animation: none !important; }
  .unlocked .sweep { display: none; }
}
@media (forced-colors: active) {
  .btn, .input-row, .gcard, .repo, .social { border: 1px solid CanvasText; }
}
