/* ==========================================================================
   /aeo-guide — chapter hub + chapter reader
   (scaffolding — .pv-rise, .pv-section — from prompt-volumes.css)
   ========================================================================== */
.gd { --expo: cubic-bezier(.19, 1, .22, 1); --cell-line: rgba(255,255,255,.1); --ok: #08ffb6; --vio: #a78bfa; }

/* ---------- Hub hero ---------- */
.gd-hero { padding: 96px 0 56px; background: radial-gradient(70% 80% at 15% 0%, #161618 0%, #0a0a0b 60%, #000 100%); }
.gd-hero .eyebrow { display: block; font-size: 13px; color: var(--fg-3); margin-bottom: 18px; }
.gd-hero h1 { font-size: clamp(38px, 5vw, 54px); font-weight: 500; line-height: 1.06; letter-spacing: -0.045em; }
.gd-hero p { max-width: 560px; margin-top: 20px; font-size: 16px; color: var(--fg-2); }
.gd-authors { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 22px; font-size: 14px; color: var(--fg-3); }
.gd-authors span { display: flex; align-items: center; gap: 8px; }
.gd-authors i { width: 20px; height: 20px; border-radius: 50%; background: linear-gradient(135deg, var(--a, #c9a27e), #5a4636); }
.gd-authors b { color: var(--fg); font-weight: 500; }

/* progress strip */
.gd-progress { display: flex; align-items: center; gap: 16px; margin-top: 40px; padding: 14px 18px; border: 1px solid var(--cell-line); border-radius: 12px; background: #0d0d0e; font-size: 13.5px; color: var(--fg-2); }
.gd-progress .dots { display: flex; gap: 6px; }
.gd-progress .dots i { width: 22px; height: 5px; border-radius: 3px; background: #232325; transition: background .5s, transform .5s var(--expo); }
.gd-progress .dots i.read { background: var(--ok); }
.gd-progress .dots i.hot { background: #fff; transform: scaleY(1.6); }
.gd-progress .sp { flex: 1; }
.gd-progress a { padding: 7px 13px; border-radius: 8px; background: var(--fg); color: #000; font-weight: 500; font-size: 13px; white-space: nowrap; transition: transform .4s var(--expo); }
.gd-progress a:hover { transform: translateX(3px); }

/* ---------- Chapter grid ---------- */
.gd-grid { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--cell-line); border-left: 1px solid var(--cell-line); }
.gd-ch { position: relative; display: flex; flex-direction: column; min-height: 250px; padding: 30px 32px; border-right: 1px solid var(--cell-line); border-bottom: 1px solid var(--cell-line); background: #0b0b0c; overflow: hidden; transition: background .5s; }
.gd-ch::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s; background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.07), transparent 70%); }
.gd-ch:hover::after { opacity: 1; }
.gd-ch:hover, .gd-ch.pulse { background: #101012; }
.gd-ch .no { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--fg-3); }
.gd-ch .no em { font-style: normal; font-size: 11px; padding: 2px 8px; border-radius: 999px; background: rgba(8,255,182,.12); color: var(--ok); opacity: 0; transform: translateX(-6px); transition: opacity .4s, transform .5s var(--expo); }
.gd-ch.read .no em { opacity: 1; transform: none; }
.gd-ch h3 { margin-top: auto; font-size: 19px; font-weight: 500; letter-spacing: -0.02em; transition: transform .6s var(--expo); }
.gd-ch p { margin-top: 10px; color: var(--fg-2); font-size: 15px; max-width: 360px; transition: transform .6s var(--expo); }
.gd-ch .go { position: absolute; right: 30px; bottom: 30px; font-size: 13px; color: var(--fg); opacity: 0; transform: translateX(-10px); transition: opacity .4s, transform .6s var(--expo); }
.gd-ch:hover .go { opacity: 1; transform: none; }
.gd-ch:hover h3, .gd-ch:hover p { transform: translateY(-4px); }

/* chapter glyphs */
.gd-glyph { position: absolute; right: 26px; top: 24px; width: 96px; height: 76px; color: #4a4a4d; transition: color .5s; }
.gd-ch:hover .gd-glyph, .gd-ch.pulse .gd-glyph { color: var(--gc, var(--vio)); }
.gd-glyph svg { width: 100%; height: 100%; overflow: visible; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.gd-glyph .a, .gd-glyph .b, .gd-glyph .c, .gd-glyph .d { transform-box: fill-box; transform-origin: center; }
.gd-ch:hover .g1 .a, .gd-ch.pulse .g1 .a { animation: gdRing 1.8s ease-out infinite; }
.gd-ch:hover .g1 .b, .gd-ch.pulse .g1 .b { animation: gdRing 1.8s ease-out .5s infinite; }
@keyframes gdRing { from { transform: scale(.5); opacity: 1; } to { transform: scale(1.25); opacity: 0; } }
.gd-glyph.g2 .a, .gd-glyph.g2 .b, .gd-glyph.g2 .c { transition: transform .7s var(--expo); }
.gd-ch:hover .g2 .a, .gd-ch.pulse .g2 .a { transform: translateY(-9px); }
.gd-ch:hover .g2 .c, .gd-ch.pulse .g2 .c { transform: translateY(9px); }
.gd-glyph.g3 .a { stroke-dasharray: 60; stroke-dashoffset: 60; }
.gd-ch:hover .g3 .a, .gd-ch.pulse .g3 .a { animation: gdType 1.6s steps(8) infinite; }
.gd-ch:hover .g3 .b, .gd-ch.pulse .g3 .b { animation: gdBlink .7s steps(2) infinite; }
@keyframes gdType { to { stroke-dashoffset: 0; } }
@keyframes gdBlink { 50% { opacity: 0; } }
.gd-glyph.g4 .a, .gd-glyph.g4 .b, .gd-glyph.g4 .c { stroke-dasharray: 16; stroke-dashoffset: 16; }
.gd-ch:hover .g4 .a, .gd-ch.pulse .g4 .a { animation: gdTick .5s var(--expo) forwards; }
.gd-ch:hover .g4 .b, .gd-ch.pulse .g4 .b { animation: gdTick .5s var(--expo) .25s forwards; }
.gd-ch:hover .g4 .c, .gd-ch.pulse .g4 .c { animation: gdTick .5s var(--expo) .5s forwards; }
@keyframes gdTick { to { stroke-dashoffset: 0; } }
.gd-glyph.g5 .a { stroke-dasharray: 4 6; }
.gd-ch:hover .g5 .a, .gd-ch.pulse .g5 .a { animation: gdDash .6s linear infinite; }
@keyframes gdDash { to { stroke-dashoffset: -10; } }
.gd-glyph.g6 .a, .gd-glyph.g6 .b, .gd-glyph.g6 .c, .gd-glyph.g6 .d { transform-origin: bottom; transition: transform .8s var(--expo); }
.gd-glyph.g6 .a { transform: scaleY(.3); } .gd-glyph.g6 .b { transform: scaleY(.45); } .gd-glyph.g6 .c { transform: scaleY(.6); } .gd-glyph.g6 .d { transform: scaleY(.75); }
.gd-ch:hover .g6 .a, .gd-ch.pulse .g6 .a, .gd-ch:hover .g6 .b, .gd-ch.pulse .g6 .b, .gd-ch:hover .g6 .c, .gd-ch.pulse .g6 .c, .gd-ch:hover .g6 .d, .gd-ch.pulse .g6 .d { transform: scaleY(1); }
.gd-ch:hover .g6 .b, .gd-ch.pulse .g6 .b { transition-delay: .08s; } .gd-ch:hover .g6 .c, .gd-ch.pulse .g6 .c { transition-delay: .16s; } .gd-ch:hover .g6 .d, .gd-ch.pulse .g6 .d { transition-delay: .24s; }

/* ---------- Chapter reader ---------- */
.gd-bar { position: sticky; top: 60px; z-index: 40; height: 2px; background: transparent; }
.gd-bar i { display: block; height: 100%; width: calc(var(--p, 0) * 100%); background: linear-gradient(90deg, var(--vio), var(--ok)); transition: width .15s linear; }
.gd-read { display: grid; grid-template-columns: 250px minmax(0, 720px); gap: 64px; padding: 56px 0 96px; }
.gd-side { position: sticky; top: 130px; align-self: start; font-size: 14px; }
.gd-side > a { display: inline-block; margin-bottom: 18px; color: var(--fg-3); transition: color .3s; }
.gd-side > a:hover { color: var(--fg); }
.gd-side ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.gd-side li a { position: relative; display: block; padding: 9px 0 9px 16px; color: var(--fg-3); line-height: 1.35; transition: color .3s, padding .5s var(--expo); }
.gd-side li a small { display: block; font-size: 11.5px; color: var(--fg-4); }
.gd-side li a::before { content: ""; position: absolute; left: -1px; top: 20%; bottom: 20%; width: 2px; background: var(--fg); transform: scaleY(0); transition: transform .5s var(--expo); }
.gd-side li a:hover { color: var(--fg); padding-left: 20px; }
.gd-side li.cur a { color: var(--fg); } .gd-side li.cur a::before { transform: scaleY(1); }
.gd-side li.read a small::after { content: " · read"; color: var(--ok); }
.gd-article .eyebrow { font-size: 13px; color: var(--vio); }
.gd-article h1 { margin: 14px 0 0; font-size: clamp(32px, 4.2vw, 46px); font-weight: 500; line-height: 1.1; letter-spacing: -0.04em; }
.gd-article .lede { margin-top: 20px; font-size: 19px; line-height: 1.55; color: var(--fg); }
.gd-article h2 { margin: 52px 0 14px; font-size: 25px; font-weight: 500; letter-spacing: -0.025em; scroll-margin-top: 130px; }
.gd-article p { margin-top: 14px; font-size: 16.5px; line-height: 1.7; color: var(--fg-2); }
.gd-article ul { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.gd-article ul li { position: relative; padding-left: 24px; font-size: 16.5px; line-height: 1.6; color: var(--fg-2); }
.gd-article ul li::before { content: ""; position: absolute; left: 4px; top: .7em; width: 6px; height: 6px; border-radius: 50%; background: var(--vio); }
.gd-take { margin-top: 52px; padding: 24px 26px; border: 1px solid var(--cell-line); border-radius: 14px; background: #0d0d0e; }
.gd-take h3 { margin: 0 0 6px; font-size: 16px; font-weight: 500; }
.gd-take > small { color: var(--fg-3); }
.gd-take label { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; font-size: 15.5px; line-height: 1.5; color: var(--fg-2); cursor: pointer; transition: color .3s; }
.gd-take input { position: absolute; opacity: 0; }
.gd-take label i { flex: none; width: 18px; height: 18px; margin-top: 2px; border-radius: 6px; border: 1.5px solid #555; display: grid; place-items: center; font-style: normal; font-size: 11px; color: transparent; transition: background .3s, border-color .3s, color .3s, transform .4s var(--expo); }
.gd-take input:checked + i { background: var(--ok); border-color: var(--ok); color: #000; transform: scale(1.1); }
.gd-take input:focus-visible + i { outline: 2px solid #fff; outline-offset: 2px; }
.gd-take label:has(input:checked) { color: var(--fg); }
.gd-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 44px; }
.gd-nav a { display: block; padding: 20px 22px; border: 1px solid var(--cell-line); border-radius: 14px; transition: border-color .4s, background .4s, transform .6s var(--expo); }
.gd-nav a:hover { border-color: #555; background: #0f0f10; transform: translateY(-3px); }
.gd-nav small { display: block; color: var(--fg-3); font-size: 12.5px; margin-bottom: 6px; }
.gd-nav b { font-weight: 500; font-size: 16px; }
.gd-nav .next { text-align: right; }
.gd-nav .cta { background: var(--fg); color: #000; border-color: var(--fg); } .gd-nav .cta small { color: #444; } .gd-nav .cta:hover { background: #fff; }

@media (max-width: 980px) { .gd-read { grid-template-columns: 1fr; gap: 28px; } .gd-side { position: static; } .gd-side ol { display: flex; gap: 6px; overflow-x: auto; border-left: 0; scrollbar-width: none; } .gd-side li a { white-space: nowrap; padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; } .gd-side li a small { display: none; } .gd-side li a::before { display: none; } .gd-side li.cur a { border-color: #777; } .gd-side li a:hover { padding-left: 12px; } }
@media (max-width: 720px) { .gd-grid { grid-template-columns: 1fr; } .gd-ch { min-height: 210px; padding: 24px 22px; } .gd-glyph { right: 18px; top: 18px; width: 76px; height: 60px; } .gd-progress { flex-wrap: wrap; } .gd-nav { grid-template-columns: 1fr; } .gd-nav .next { text-align: left; } .gd-bar { top: 60px; } }
@media (prefers-reduced-motion: reduce) { .gd-glyph * { animation: none !important; } .gd-glyph.g3 .a, .gd-glyph.g4 .a, .gd-glyph.g4 .b, .gd-glyph.g4 .c { stroke-dashoffset: 0; } }
