:root { --ink: #1f1b16; --muted: #6b6257; --paper: #fbfaf7; --line: #e6e0d4; --accent: #9a3b28; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.6 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
a { color: var(--accent); }
.lp-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 860px; margin: 0 auto; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.lp-brand { font: 600 22px/1 Georgia, 'Times New Roman', serif; color: var(--ink); text-decoration: none; }
.lp-brand span { color: var(--accent); }
.lp-crumbs { font-size: 14px; color: var(--muted); }
.lp-crumbs a { color: var(--muted); }
.lp { max-width: 860px; margin: 0 auto; padding: 8px 20px 40px; }
.lp h1 { font: 600 clamp(30px, 5vw, 42px)/1.15 Georgia, 'Times New Roman', serif; margin: 32px 0 12px; }
.lp h2 { font: 600 24px/1.3 Georgia, 'Times New Roman', serif; margin: 36px 0 10px; }
.lp-lede { font-size: 19px; color: #3a332b; }
.lp-cta { display: inline-block; background: var(--accent); color: #fff; text-decoration: none; font-weight: 600; padding: 12px 22px; border-radius: 8px; }
.lp-cta:hover { filter: brightness(1.08); }
.lp-note { color: var(--muted); font-size: 14px; }
.lp-list li, .lp-steps li { margin: 6px 0; }
.lp-code { background: #f3efe6; border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; overflow-x: auto; font: 13.5px/1.5 ui-monospace, 'JetBrains Mono', Menlo, monospace; }
details { border-top: 1px solid var(--line); padding: 10px 0; }
summary { cursor: pointer; font-weight: 600; }

.lp-foot { max-width: 860px; margin: 0 auto; padding: 18px 20px 40px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }
code, kbd { font-family: ui-monospace, Menlo, monospace; font-size: 0.92em; }
.lp-nav { display: flex; gap: 16px; align-items: center; font-size: 15px; flex-wrap: wrap; }
.lp-nav a { color: var(--muted); text-decoration: none; }
.lp-nav a:hover { color: var(--ink); }
.lp-nav .lp-nav-cta { color: var(--accent); font-weight: 600; }
.lp-crumbs { max-width: 1040px; margin: 0 auto; padding: 12px 20px 0; }
.lp-top, .lp-foot { max-width: 1040px; }
.lp { max-width: 1040px; }
.lp-kicker { text-transform: uppercase; letter-spacing: .08em; font-size: 13px; color: var(--muted); margin: 28px 0 0; }
.lp-split { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: start; }
.lp-split h1 { margin-top: 8px; }
@media (max-width: 820px) { .lp-split { grid-template-columns: 1fr; } }
.lp-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.lp-secondary { display: inline-block; border: 1px solid var(--line); background: #fff; color: var(--ink); text-decoration: none; padding: 11px 18px; border-radius: 8px; font-weight: 500; cursor: pointer; }
.lp-secondary:hover { border-color: #cfc6b5; }
.lp-preview { margin: 24px 0 0; }
.lp-preview img { width: 100%; height: auto; display: block; background: #fff; border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 8px 30px rgba(60, 45, 20, .12); }
.lp-preview figcaption { font-size: 13px; color: var(--muted); margin-top: 8px; text-align: center; }
.lp-cards { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 18px; columns: auto; }
.lp-cards-lg { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.lp-cards a { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--ink); }
.lp-cards img { width: 100%; height: auto; background: #fff; border: 1px solid var(--line); border-radius: 4px; }
.lp-cards a:hover img { border-color: var(--accent); }
.lp-cards span { font-weight: 600; }
.lp-cards small { color: var(--muted); }
.tool { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 8px; }
@media (max-width: 820px) { .tool { grid-template-columns: 1fr; } }
.tool-in { border: 1px solid var(--line); border-radius: 10px; background: #fff; display: flex; flex-direction: column; }
.tool-in.over { outline: 2px dashed var(--accent); }
.tool-bar { display: flex; gap: 10px; align-items: center; padding: 10px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.tool-bar .lp-cta { margin-left: auto; border: 0; font-size: 16px; cursor: pointer; }
.tool-bar .lp-cta:disabled { opacity: .6; cursor: progress; }
.tool-hint { color: var(--muted); font-size: 14px; }
.tool-file { padding: 8px 14px; font-size: 15px; }
.tool textarea { flex: 1; min-height: 380px; border: 0; padding: 12px; font: 13px/1.5 ui-monospace, Menlo, monospace; resize: vertical; background: transparent; color: var(--ink); }
.tool textarea:focus { outline: none; }
.tool-out { display: flex; flex-direction: column; gap: 8px; }
.tool-out iframe { width: 100%; min-height: 460px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.tool-status { margin: 0; color: var(--muted); }
.tool-status.ok { color: #2b7a4b; }
.tool-status.err { color: var(--accent); }
[hidden] { display: none !important; }
.tool-err { border: 1px solid #e8c9bf; border-left: 4px solid #9a3b28; border-radius: 8px; background: #fff; padding: 12px 14px; margin: 0 0 12px; }
.tool-err-title { font-weight: 700; margin: 0; }
.tool-err-text { margin: 4px 0 8px; font-size: 15px; }
.tool-err-line { display: flex; gap: 10px; width: 100%; text-align: left; background: #faf6ee; border: 1px solid #ece4d3; border-radius: 6px; padding: 6px 9px; cursor: pointer; font-size: 13px; margin-bottom: 10px; }
.tool-err-line b { color: #9a3b28; white-space: nowrap; }
.tool-err-line code { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tool-fix { border: 0; cursor: pointer; font-size: 15px; }
.import-drop { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 36px 20px; border: 2px dashed #d8cfbd; border-radius: 12px; background: #fffdf8; text-align: center; }
.import-drop.over { border-color: #9a3b28; background: #fff6ef; }
.import-big { font-size: 20px; font-weight: 700; margin: 0; }
.tool-status.ok { color: #2f6b3a; }
.tool-status.err { color: #9a3b28; }
/* phones: keep the header to one line; every page's footer carries the same links */
@media (max-width: 600px) { .lp-nav a:not(.lp-nav-cta):not(:first-child) { display: none; } }
.lp-links { padding-left: 20px; }
.lp-links li { margin: 4px 0; }
.lp-toc { font-size: 15px; line-height: 1.9; }
.sym { border-collapse: collapse; width: 100%; max-width: 640px; font-size: 15px; }
.sym th, .sym td { text-align: left; padding: 5px 10px; border-bottom: 1px solid #ece5d6; }
.sym th { font-weight: 600; color: var(--muted); }
.sym-g { font-size: 20px; width: 80px; font-family: 'STIX Two Math', 'Cambria Math', 'Latin Modern Math', serif; }
.sym code[data-copy] { cursor: copy; }
.sym code.copied { background: #e2f1e4; }
.tool-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.tool-err-more { display: inline-block; margin-top: 8px; font-size: 14px; }
.err-msg { font: 14px ui-monospace, monospace; background: #f3efe6; border-left: 3px solid #9a3b28; padding: 10px 12px; border-radius: 4px; overflow-x: auto; }
.err-list { list-style: none; padding: 0; }
.err-list li { padding: 10px 0; border-bottom: 1px solid #ece5d6; display: flex; flex-direction: column; gap: 4px; }
.err-list code { font-size: 13px; color: #6b6355; }
.cmp-wrap { overflow-x: auto; }
.cmp { border-collapse: collapse; width: 100%; font-size: 15px; }
.cmp th, .cmp td { text-align: left; vertical-align: top; padding: 8px 10px; border-bottom: 1px solid #ece5d6; }
.cmp thead th { color: var(--muted); font-weight: 600; }
.cmp tbody th { font-weight: 600; width: 22%; }
