:root {
  --ink: #11182d;
  --muted: #606980;
  --line: #dfe4ef;
  --soft: #f5f7fb;
  --paper: #ffffff;
  --navy: #0b1020;
  --accent: #6c4dff;
  --accent-2: #1cc8a0;
  --accent-soft: #ede9ff;
  --shadow: 0 18px 60px rgba(26, 35, 66, .10);
  --radius: 22px;
  --shell: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.shell { width: min(var(--shell), calc(100% - 36px)); margin-inline: auto; }
.skip-link { position: fixed; left: 12px; top: 12px; z-index: 999; background: #fff; padding: 10px 14px; border-radius: 10px; transform: translateY(-180%); transition: transform .15s ease; }
.skip-link:focus { transform: translateY(0); }

.site-header { position: absolute; inset: 0 0 auto; z-index: 20; color: white; }
.header-inner { min-height: 78px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.08); border-radius: 11px; font-weight: 800; letter-spacing: -2px; }
.brand-mark span { color: #a9f3df; font-size: .67em; letter-spacing: -1px; }
.brand-name { font-size: 1.12rem; font-weight: 800; letter-spacing: -.02em; }
.brand-name small { font-size: .58rem; text-transform: uppercase; letter-spacing: .12em; opacity: .55; margin-left: 3px; }
.header-link { text-decoration: none; opacity: .72; font-size: .9rem; }
.header-link:hover { opacity: 1; }

.hero { color: white; background: radial-gradient(circle at 74% 20%, rgba(108,77,255,.4), transparent 34%), radial-gradient(circle at 26% 94%, rgba(28,200,160,.19), transparent 30%), var(--navy); overflow: hidden; }
.hero-inner { min-height: 650px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 118px 0 72px; position: relative; }
.hero-inner::before, .hero-inner::after { content:""; position:absolute; width:320px; height:320px; border:1px solid rgba(255,255,255,.055); border-radius:50%; pointer-events:none; }
.hero-inner::before { left:-210px; bottom:-100px; box-shadow: 0 0 0 70px rgba(255,255,255,.025), 0 0 0 140px rgba(255,255,255,.015); }
.hero-inner::after { right:-240px; top:80px; box-shadow: 0 0 0 74px rgba(255,255,255,.025); }
.eyebrow, .section-kicker { text-transform: uppercase; letter-spacing: .16em; font-size: .72rem; font-weight: 800; color: var(--accent); }
.eyebrow { color: #a9f3df; margin-bottom: 22px; }
.hero h1 { margin: 0; max-width: 850px; font-size: clamp(2.55rem, 7vw, 5.25rem); line-height: .98; letter-spacing: -.065em; font-weight: 780; }
.hero h1 em { font-style: normal; color: #b7a9ff; }
.hero-copy { max-width: 700px; margin: 26px auto 0; color: #b8bfd1; line-height: 1.65; font-size: clamp(1rem, 2.1vw, 1.15rem); }

.search-box { width: min(810px, 100%); margin-top: 34px; text-align: left; }
.search-box > label { display: block; font-weight: 760; font-size: 1.05rem; margin-bottom: 10px; color: white; }
.search-control { position: relative; display: flex; align-items: center; }
.search-control svg { position:absolute; left: 18px; width: 23px; height: 23px; fill:none; stroke:#7c8497; stroke-width:2; z-index:2; }
.search-control input { width:100%; height:64px; border:1px solid rgba(255,255,255,.12); border-radius:17px; background:white; color:var(--ink); padding:0 58px 0 54px; outline:none; font-size:1rem; box-shadow:0 16px 45px rgba(0,0,0,.23); transition:.2s ease; }
.search-control input:focus { box-shadow:0 0 0 4px rgba(183,169,255,.2), 0 16px 45px rgba(0,0,0,.23); }
.search-control input::placeholder { color:#9097a8; }
.clear-search { position:absolute; right:13px; width:38px; height:38px; border:0; border-radius:50%; background:#eef1f7; color:#687186; font-size:1.5rem; line-height:1; }
.search-hint { margin:9px 2px 0; font-size:.78rem; color:#7f899f; }
.example-row { margin-top:20px; display:flex; justify-content:center; align-items:center; gap:8px; flex-wrap:wrap; color:#858da1; font-size:.78rem; }
.example-row button { border:1px solid rgba(255,255,255,.12); color:#c5cada; background:rgba(255,255,255,.04); padding:7px 11px; border-radius:999px; }
.example-row button:hover { border-color:rgba(255,255,255,.3); color:white; }

.catalog { padding: 82px 0 96px; }
.section-heading { display:flex; align-items:end; justify-content:space-between; gap:30px; margin-bottom:26px; }
.section-heading h2, .principle h2, .concept-note h2 { margin:7px 0 0; font-size:clamp(1.75rem,4vw,2.55rem); letter-spacing:-.045em; line-height:1.08; }
.section-heading p { margin:0 0 4px; color:var(--muted); font-size:.9rem; }
.category-strip { display:flex; gap:9px; overflow-x:auto; padding:3px 2px 18px; scrollbar-width:none; }
.category-strip::-webkit-scrollbar { display:none; }
.category-chip { flex:0 0 auto; border:1px solid var(--line); background:white; color:#5a647a; border-radius:999px; padding:9px 13px; font-size:.84rem; transition:.18s ease; }
.category-chip:hover { border-color:#b7bfd0; }
.category-chip[aria-pressed="true"] { background:var(--navy); color:white; border-color:var(--navy); }
.result-context { margin:2px 0 20px; padding:13px 16px; background:#f4f1ff; color:#514576; border-radius:13px; font-size:.88rem; }
.cards-grid { display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:16px; }
.prompt-card { min-height:245px; border:1px solid var(--line); border-radius:var(--radius); padding:22px; background:white; text-align:left; display:flex; flex-direction:column; transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.prompt-card:hover { transform:translateY(-3px); border-color:#c8c0ff; box-shadow:var(--shadow); }
.card-top { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:18px; }
.card-category { font-size:.69rem; text-transform:uppercase; letter-spacing:.08em; font-weight:800; color:#7b6ad2; }
.card-kind { font-size:.66rem; background:#f0edff; color:#624fc1; padding:5px 7px; border-radius:8px; }
.prompt-card h3 { margin:0; font-size:1.25rem; letter-spacing:-.025em; }
.card-question { margin:8px 0 0; color:#4d5870; line-height:1.5; font-size:.92rem; }
.card-bottom { margin-top:auto; padding-top:20px; display:flex; align-items:center; justify-content:space-between; gap:8px; }
.card-tags { display:flex; gap:5px; min-width:0; overflow:hidden; }
.card-tags span { flex:0 0 auto; background:var(--soft); color:#7a8293; padding:5px 7px; border-radius:7px; font-size:.66rem; }
.card-open { color:var(--accent); font-size:.78rem; font-weight:800; white-space:nowrap; }
.load-more-wrap { display:flex; justify-content:center; margin-top:30px; }
.secondary-button { border:1px solid var(--line); background:white; color:var(--ink); padding:11px 16px; border-radius:12px; font-weight:700; }
.secondary-button:hover { background:var(--soft); }
.empty-state { max-width:600px; margin:45px auto 0; text-align:center; padding:40px 20px; }
.empty-state > span { width:56px; height:56px; display:grid; place-items:center; margin:auto; border-radius:18px; background:var(--soft); font-size:1.6rem; color:#778096; }
.empty-state h3 { margin:18px 0 8px; font-size:1.35rem; }
.empty-state p { color:var(--muted); line-height:1.6; }

.principle { background:var(--navy); color:white; padding:82px 0; }
.principle-grid { display:grid; grid-template-columns:1fr 1.1fr; gap:70px; align-items:center; }
.section-kicker.light { color:#a9f3df; }
.principle-copy { color:#b9c0d2; line-height:1.7; }
.principle-copy strong { color:white; }
.flow { margin-top:26px; display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.flow span { border:1px solid rgba(255,255,255,.13); padding:8px 11px; border-radius:10px; color:#d7dbea; font-size:.78rem; }
.flow i { font-style:normal; color:#6d768e; }
.concept-note { display:grid; grid-template-columns:auto 1fr; gap:20px; align-items:start; margin-top:68px; margin-bottom:68px; padding:28px; background:#f7f5ff; border:1px solid #e8e3ff; border-radius:var(--radius); }
.note-icon { width:40px; height:40px; border-radius:12px; display:grid; place-items:center; background:#e6dfff; color:#5b45c5; font-weight:900; }
.concept-note h2 { font-size:1.3rem; margin:1px 0 7px; }
.concept-note p { margin:0; color:#5d667b; line-height:1.6; }

.site-footer { border-top:1px solid var(--line); padding:30px 0; }
.footer-inner { display:flex; justify-content:space-between; gap:24px; align-items:center; color:#747d90; font-size:.78rem; }
.footer-inner > div { display:flex; flex-direction:column; gap:4px; }
.footer-inner strong { color:var(--ink); font-size:.9rem; }
.build-info { font-family:ui-monospace, SFMono-Regular, Menlo, monospace; }

.prompt-dialog { width:min(820px, calc(100% - 24px)); max-height:min(90dvh, 900px); padding:0; border:0; border-radius:24px; box-shadow:0 34px 100px rgba(8,13,30,.35); color:var(--ink); }
.prompt-dialog::backdrop { background:rgba(6,10,24,.72); backdrop-filter:blur(4px); }
.dialog-shell { padding:34px; position:relative; }
.dialog-close { position:sticky; z-index:4; float:right; top:0; width:40px; height:40px; border:0; border-radius:50%; background:#f0f2f6; color:#677087; font-size:1.45rem; }
.dialog-badges { display:flex; gap:7px; flex-wrap:wrap; margin-bottom:12px; }
.dialog-badges span { padding:5px 8px; background:#f2f0ff; color:#6554bd; border-radius:7px; text-transform:uppercase; letter-spacing:.08em; font-size:.64rem; font-weight:800; }
.dialog-header h2 { margin:0; padding-right:46px; font-size:2rem; letter-spacing:-.04em; }
.dialog-question { margin:8px 0 0; color:#4f5a72; font-size:1.02rem; font-weight:650; }
.dialog-description { color:var(--muted); line-height:1.6; margin:16px 0 0; }
.when-use { margin-top:22px; padding:16px 18px; border-radius:14px; background:var(--soft); }
.when-use strong { font-size:.76rem; text-transform:uppercase; letter-spacing:.08em; }
.when-use p { margin:5px 0 0; color:#5e687c; line-height:1.5; font-size:.9rem; }
.concept-warning { margin-top:14px; padding:14px 16px; border-left:3px solid var(--accent); background:#f7f5ff; color:#564c7f; font-size:.86rem; line-height:1.55; border-radius:0 11px 11px 0; }
.prompt-section { margin-top:34px; }
.prompt-section-head { display:flex; justify-content:space-between; align-items:end; gap:18px; }
.prompt-section h3, .related-section h3 { margin:5px 0 0; font-size:1.2rem; }
.version-tabs { display:flex; padding:4px; border-radius:12px; background:var(--soft); }
.version-tabs button { border:0; background:transparent; color:#6e778b; padding:7px 9px; border-radius:8px; font-size:.72rem; font-weight:750; }
.version-tabs button[aria-selected="true"] { background:white; color:var(--ink); box-shadow:0 2px 8px rgba(0,0,0,.06); }
.prompt-copy-box { margin-top:14px; border:1px solid var(--line); border-radius:16px; overflow:hidden; }
.prompt-copy-box pre { margin:0; padding:20px; background:#fbfcfe; color:#2d364a; font-family:inherit; white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.65; font-size:.88rem; max-height:390px; overflow:auto; }
.copy-button { width:100%; height:50px; border:0; border-top:1px solid var(--line); background:var(--navy); color:white; display:flex; align-items:center; justify-content:center; gap:8px; font-weight:800; }
.copy-button:hover { background:#171e33; }
.copy-button svg { width:18px; fill:none; stroke:currentColor; stroke-width:1.8; }
.related-section { margin-top:34px; padding-top:25px; border-top:1px solid var(--line); }
.related-list { display:flex; flex-wrap:wrap; gap:8px; margin-top:13px; }
.related-list button { border:1px solid var(--line); background:white; color:#525c72; padding:8px 10px; border-radius:10px; font-size:.78rem; }
.related-list button:hover { border-color:#b8aefe; color:#5741c2; }
.toast { position:fixed; z-index:100; left:50%; bottom:25px; transform:translate(-50%, 30px); opacity:0; pointer-events:none; background:#101729; color:white; padding:11px 15px; border-radius:11px; font-size:.84rem; box-shadow:0 12px 35px rgba(0,0,0,.2); transition:.22s ease; }
.toast.show { transform:translate(-50%, 0); opacity:1; }

:focus-visible { outline:3px solid #8b78ff; outline-offset:3px; }
@media (max-width: 900px) {
  .cards-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .principle-grid { grid-template-columns:1fr; gap:28px; }
}
@media (max-width: 620px) {
  .shell { width:min(100% - 24px, var(--shell)); }
  .header-inner { min-height:68px; }
  .header-link { display:none; }
  .hero-inner { min-height:auto; padding:110px 0 58px; }
  .hero h1 { font-size:clamp(2.35rem,13vw,3.6rem); }
  .hero-copy { font-size:.98rem; margin-top:22px; }
  .search-box { margin-top:27px; }
  .search-control input { height:60px; font-size:16px; }
  .search-hint { line-height:1.4; }
  .example-row { justify-content:flex-start; }
  .catalog { padding:58px 0 72px; }
  .section-heading { align-items:start; flex-direction:column; gap:8px; }
  .cards-grid { grid-template-columns:1fr; }
  .prompt-card { min-height:220px; }
  .principle { padding:60px 0; }
  .flow i { display:none; }
  .flow { align-items:stretch; flex-direction:column; }
  .flow span { text-align:center; }
  .concept-note { margin-top:48px; margin-bottom:48px; grid-template-columns:1fr; padding:22px; }
  .footer-inner { align-items:flex-start; flex-direction:column; }
  .prompt-dialog { width:100%; max-height:94dvh; margin:auto 0 0; border-radius:22px 22px 0 0; }
  .dialog-shell { padding:24px 18px 28px; }
  .dialog-header h2 { font-size:1.65rem; }
  .prompt-section-head { align-items:stretch; flex-direction:column; }
  .version-tabs { width:100%; }
  .version-tabs button { flex:1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior:auto !important; transition:none !important; }
}
