
:root {
  --bg: #fbf8f1; --bg2: #f4efe3; --card: #ffffff; --ink: #1f2430; --muted: #5d6270; --line: #e6e0d3; --soft: #f3eee2;
  --brand: #f5b800; --brand-ink: #1f2430; --accent: #d63a6d; --go: #1f8a50; --link: #1d5fb8; --warn: #b4232c;
  --shadow: 0 1px 2px rgba(31,36,48,.06), 0 10px 28px rgba(31,36,48,.08); --r: 16px;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --round: ui-rounded, "SF Pro Rounded", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
}
:root[data-theme=dark] { --bg: #16181d; --bg2: #1c1f26; --card: #20242c; --ink: #eceef2; --muted: #a9afbb; --line: #333845; --soft: #262a33; --brand: #ffc928; --accent: #ff6f9c; --go: #43c784; --link: #8db8ff; --warn: #ff8a8f; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.35); color-scheme: dark; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { --bg: #16181d; --bg2: #1c1f26; --card: #20242c; --ink: #eceef2; --muted: #a9afbb; --line: #333845; --soft: #262a33; --brand: #ffc928; --accent: #ff6f9c; --go: #43c784; --link: #8db8ff; --warn: #ff8a8f; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.35); color-scheme: dark; } }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--sans); }
a { color: var(--link); }
img, svg { max-width: 100%; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 20px; }
.skip { position: absolute; left: -9999px; } .skip:focus { left: 12px; top: 12px; z-index: 99; background: var(--card); padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; border-radius: 6px; }
#printroot { display: none; }
.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }


header.top { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40; }
header.top .wrap { display: flex; align-items: center; gap: 14px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font: 800 21px/1 var(--round); letter-spacing: -.3px; margin-right: 8px; }
.brand svg { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 0 0 1px var(--line); } .brand b { color: var(--accent); font-weight: 800; }
.nav { display: flex; gap: 4px; margin-right: auto; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a { display: inline-flex; align-items: center; gap: 7px; padding: 9px 13px; border-radius: 12px; text-decoration: none; color: var(--muted); font: 700 15px var(--round); white-space: nowrap; min-height: 44px; }
.nav a:hover { color: var(--ink); background: var(--soft); }
.nav a[aria-current] { color: var(--ink); background: var(--soft); box-shadow: inset 0 -3px 0 var(--brand); }
.hbtn { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; cursor: pointer; }
.hbtn:hover { border-color: var(--ink); }
.themebtn .sun { display: none; }
:root[data-theme=dark] .themebtn .sun { display: inline; } :root[data-theme=dark] .themebtn .moon { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) .themebtn .sun { display: inline; } :root:not([data-theme=light]) .themebtn .moon { display: none; } }
@media (max-width: 899px) {
  header.top .wrap { flex-wrap: wrap; gap: 8px; padding-top: 8px; }
  .brand { margin-right: auto; }
  .nav { order: 3; width: 100%; margin: 0 -20px; padding: 0 20px 8px; -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .nav a { padding: 8px 11px; background: var(--soft); }
}


.crumbs { font-size: 13.5px; color: var(--muted); margin: 18px 0 6px; } .crumbs a { color: var(--muted); } .crumbs i { margin: 0 6px; font-style: normal; opacity: .6; }
.head h1 { font: 800 clamp(30px, 4.2vw, 46px)/1.08 var(--round); letter-spacing: -.8px; margin: 6px 0 10px; }
.head .lede { font-size: 18px; color: var(--muted); max-width: 820px; margin: 0 0 14px; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 6px; }
.badges li { display: inline-flex; align-items: center; gap: 7px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font: 700 13.5px var(--round); }
.badges .ic { width: 17px; height: 17px; color: var(--go); }


.stagecard { margin: 18px 0 26px; }
#app { min-height: 640px; }
.gen { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 980px) { .gen { grid-template-columns: 380px minmax(0, 1fr); align-items: start; } }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 18px; }
@media (min-width: 980px) { .panel { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow: auto; } }
.ctl { margin: 0 0 14px; }
.ctl label, .ctl .lbl { display: block; font: 700 14px var(--round); margin: 0 0 6px; }
.ctl label output { float: right; font-weight: 800; color: var(--accent); }
.ctl textarea, .ctl input[type=text], .ctl select { width: 100%; font: 16px var(--sans); color: var(--ink); background: var(--bg); border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.ctl textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.ctl textarea:focus, .ctl input:focus, .ctl select:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 45%, transparent); }
.ctl input.short { width: 72px; text-align: center; text-transform: uppercase; }
.ctl input[type=range] { width: 100%; accent-color: var(--accent); height: 28px; }
.ctl .hint { margin: 6px 0 0; }
.chk { display: flex !important; align-items: flex-start; gap: 10px; font-weight: 600 !important; cursor: pointer; }
.chk input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.seg { display: flex; flex-wrap: wrap; gap: 4px; background: var(--soft); padding: 4px; border-radius: 12px; }
.seg button { flex: 1 1 auto; border: 0; background: transparent; color: var(--muted); font: 700 14px var(--round); padding: 8px 10px; border-radius: 9px; cursor: pointer; min-height: 38px; }
.seg button[aria-checked=true] { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(31,36,48,.18); }
.more { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; }
.more summary { cursor: pointer; font: 800 14px var(--round); color: var(--muted); padding: 6px 0; list-style: none; }
.more summary::before { content: "+ "; color: var(--accent); } .more[open] summary::before { content: "− "; }
.more[open] summary { margin-bottom: 10px; }
.lists { display: flex; gap: 8px; flex-wrap: wrap; border-top: 1px solid var(--line); margin-top: 10px; padding-top: 12px; }
.lists select { flex: 1; min-width: 150px; font: 14px var(--sans); border: 1.5px solid var(--line); border-radius: 10px; padding: 7px 8px; background: var(--bg); color: var(--ink); }
.b { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: 800 15px var(--round); padding: 10px 16px; border-radius: 12px; cursor: pointer; min-height: 44px; text-decoration: none; }
.b:hover { border-color: var(--ink); }
.b.primary { background: var(--brand); border-color: var(--brand); color: #1f2430; }
.b.primary:hover { filter: brightness(.95); border-color: #1f2430; }
.b.sm { font-size: 14px; padding: 7px 12px; min-height: 38px; }
.b:disabled { opacity: .45; cursor: not-allowed; }
.preview { min-width: 0; }
.actions { position: sticky; top: 72px; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(6px); padding: 10px 0; }
.actions .meta { font: 700 13.5px var(--round); color: var(--muted); margin-left: auto; }
@media (max-width: 979px) { .actions { top: 108px; } .actions .meta { width: 100%; margin: 0; } }
.status { min-height: 1.3em; margin: 0 0 8px; font: 700 14px var(--round); color: var(--go); }
.status.warn { color: var(--warn); }
.sheets { display: grid; gap: 18px; background: var(--bg2); border-radius: var(--r); padding: 18px; }
.sheet { margin: 0; background: #fff; box-shadow: 0 2px 4px rgba(0,0,0,.08), 0 12px 30px rgba(31,36,48,.14); border-radius: 3px; overflow: hidden; }
.sheet svg { display: block; width: 100%; height: auto; }
@media (min-width: 1200px) { .sheets { grid-template-columns: minmax(0, 1fr); } .sheet { max-width: 760px; margin: 0 auto; width: 100%; } }
.more-pages { text-align: center; }
.printhint { margin: 10px 2px 0; }
.hint { font-size: 13.5px; color: var(--muted); }


.cards-sec { margin: 26px 0; }
.grouph { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; } .grouph h2 { font: 800 26px var(--round); margin: 0; } .grouph .more { font: 700 14px var(--round); }
.cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); margin-top: 10px; }
.card { display: grid; grid-template-columns: 56px 1fr; grid-template-rows: auto 1fr; column-gap: 12px; padding: 14px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); }
.card:hover { border-color: var(--ink); transform: translateY(-1px); }
.card .thumb { grid-row: span 2; width: 56px; height: 56px; }
.card b { font: 800 16px/1.25 var(--round); } .card span { font-size: 13.5px; color: var(--muted); line-height: 1.4; }


.below { display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); margin: 10px 0 40px; }
@media (min-width: 1000px) { .below { grid-template-columns: minmax(0, 1fr) 300px; align-items: start; } }
.guide { min-width: 0; overflow-wrap: break-word; }
.prose { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(18px, 3vw, 34px); box-shadow: var(--shadow); }
.prose h2 { font: 800 25px/1.25 var(--round); margin: 30px 0 10px; letter-spacing: -.3px; } .prose h2:first-child { margin-top: 0; }
.prose p { margin: 0 0 14px; max-width: 74ch; }
.howto { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); margin: 0 0 10px; }
.howto li { counter-increment: s; background: var(--soft); border-radius: 12px; padding: 12px 14px 12px 50px; position: relative; }
.howto li::before { content: counter(s); position: absolute; left: 12px; top: 12px; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--bg); font: 800 15px/28px var(--round); text-align: center; }
.howto b { display: block; font-family: var(--round); }
.scroll { overflow-x: auto; margin: 0 0 16px; }
.tbl { border-collapse: collapse; width: 100%; font-size: 15px; } .tbl th, .tbl td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; } .tbl th { font-family: var(--round); background: var(--soft); } .tbl caption { caption-side: bottom; text-align: left; font-size: 13px; color: var(--muted); padding-top: 6px; }
@media (max-width: 600px) { .tbl { font-size: 14px; } .tbl th, .tbl td { min-width: 110px; } }
.faq h2 { margin-top: 30px; }
.faq details { border-top: 1px solid var(--line); padding: 12px 0; } .faq summary { cursor: pointer; font: 800 16.5px var(--round); }
.faq details p { margin: 8px 0 0; }
.notice { margin-top: 18px; font-size: 12px; }
.side { display: grid; gap: 16px; }
.sidebox { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; box-shadow: var(--shadow); }
.sidebox h3 { font: 800 17px var(--round); margin: 0 0 12px; }
.facts { display: grid; gap: 12px; } .facts div { display: flex; gap: 10px; font-size: 14px; line-height: 1.45; } .facts .ic { color: var(--accent); margin-top: 2px; }
.sidebox ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.sidebox li a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; text-decoration: none; color: var(--ink); font: 700 15px var(--round); }
.sidebox li a:hover { background: var(--soft); } .sidebox li .ic { color: var(--muted); }
.hubguide { margin: 20px 0 40px; }


footer { background: var(--card); border-top: 1px solid var(--line); padding: 34px 0 22px; margin-top: 30px; }
.fgrid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.fgrid h3 { font: 800 14px var(--round); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 8px; }
.fgrid a { display: block; color: var(--ink); text-decoration: none; font-size: 14.5px; padding: 4px 0; } .fgrid a:hover { color: var(--link); text-decoration: underline; }
.fbase { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); margin-top: 24px; padding-top: 16px; font-size: 13px; color: var(--muted); }


.search { position: fixed; inset: 0; z-index: 80; background: rgba(22,24,29,.5); display: none; align-items: flex-start; justify-content: center; padding: 70px 16px; }
.search.open { display: flex; }
.search-box { width: min(640px, 100%); background: var(--card); border-radius: 18px; box-shadow: var(--shadow); padding: 12px; }
.search-box input[type=search] { width: 100%; height: 52px; padding: 0 16px; border: 2px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--ink); font: 600 18px var(--sans); outline: none; }
.search-box input[type=search]:focus { border-color: var(--ink); }
.search-res { max-height: 60vh; overflow: auto; margin-top: 8px; display: grid; gap: 4px; }
.search-res a { display: block; padding: 10px 12px; border-radius: 12px; text-decoration: none; color: var(--ink); font-weight: 700; } .search-res a:hover, .search-res a.on { background: var(--soft); }
.search-res small { color: var(--muted); display: block; font-size: 13px; font-weight: 400; }


.ad { margin: 18px 0; min-height: 120px; display: grid; place-items: center; background: var(--soft); border-radius: 12px; }
.ad-l { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
@media screen and (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }


@media (max-width: 979px) {
  .gen { display: flex; flex-direction: column; }
  .preview { order: -1; }
  .actions { position: fixed; left: 0; right: 0; bottom: 0; top: auto; z-index: 30; margin: 0; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--card); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(31,36,48,.12); flex-wrap: nowrap; overflow-x: auto; }
  .actions .b { flex: none; padding: 9px 12px; }
  .actions .meta { display: none; }
  body { padding-bottom: 76px; }
  .sheets { padding: 10px; }
  .sheet.later { display: none; }
  .sheets .more-pages { display: block; }
}


.ctl-first .ctl { margin-bottom: 14px; }
.nextstep { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 0 0 12px; font: 700 14px var(--round); }
@media (max-width: 979px) {
  .panel { display: contents; }
  .ctl-first { order: -2; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 14px 16px 2px; }
  .ctl-first textarea { min-height: 96px; }
  .preview { order: -1; }
  .panel-rest { order: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px; }
}


:root { --field: #b5ad9c; --go: #187a44; --accent: #c32c61; }
:root[data-theme=dark] { --field: #5b6272; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { --field: #5b6272; } }
.ctl textarea, .ctl input[type=text], .ctl select, .lists select { border-color: var(--field); }
.seg { border: 1px solid var(--field); }
.seg button[aria-checked=true] { background: var(--ink); color: var(--bg); box-shadow: none; }
.more-pages.mob, .morebtn { display: none; }
.grouph .more { border: 0; padding: 0; margin: 0; }
@media (max-width: 979px) {
  header.top { position: static; }
  .actions { flex-wrap: wrap; }
  .actions .link, .actions .share, .actions .keypdf { display: none; }
  .actions.expanded .link, .actions.expanded .share { display: inline-flex; }
  .actions.expanded .keypdf:not([hidden]) { display: inline-flex; }
  .morebtn { display: inline-flex; margin-left: auto; min-width: 44px; }
  .more-pages.desk { display: none; } .more-pages.mob { display: block; }
  .status:not(:empty) { position: fixed; left: 12px; right: 12px; bottom: calc(74px + env(safe-area-inset-bottom)); z-index: 31; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; box-shadow: var(--shadow); }
}


.sheet.ph { aspect-ratio: 8.5 / 11; background: #fff; }
.why { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin: -6px 0 26px; }
.why div { display: flex; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; font-size: 14px; line-height: 1.45; }
.why .ic { color: var(--accent); margin-top: 2px; }
.hero { display: grid; gap: 24px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow); padding: clamp(18px, 3vw, 34px); margin: 8px 0 26px; }
@media (min-width: 900px) { .hero { grid-template-columns: minmax(0, 1fr) 340px; } }
.kicker { font: 800 13px var(--round); text-transform: uppercase; letter-spacing: .07em; color: var(--go); margin: 0 0 10px; }
.quick label { display: block; font: 800 20px var(--round); margin: 0 0 8px; }
.qrow { display: flex; gap: 8px; flex-wrap: wrap; }
.qrow input { flex: 1 1 200px; font: 600 20px var(--sans); padding: 12px 14px; border: 2px solid var(--field); border-radius: 14px; background: var(--bg); color: var(--ink); min-height: 52px; }
.qrow input:focus { border-color: var(--ink); outline: none; }
.qrow .b { min-height: 52px; font-size: 16px; }
.styles { margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font: 700 14px var(--round); }
.styles span { color: var(--muted); margin-right: 4px; }
.styles a { text-decoration: none; color: var(--ink); background: var(--soft); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }
.styles a:hover { border-color: var(--ink); }
.hero-r { margin: 0; justify-self: center; }
.hero-r img { width: 100%; max-width: 340px; height: auto; background: #fff; border-radius: 4px; box-shadow: 0 2px 4px rgba(0,0,0,.08), 0 16px 36px rgba(31,36,48,.18); transform: rotate(1.5deg); }
.card img.thumb { grid-row: span 2; width: 56px; height: 72px; object-fit: cover; object-position: top; border: 1px solid var(--line); border-radius: 4px; background: #fff; }


.legend { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 8px; }
.legend li { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.legend b { font-family: var(--round); margin-right: 4px; }
.legend i { flex: none; width: 22px; height: 22px; display: inline-grid; place-items: center; font: 800 14px var(--round); font-style: normal; }
.lg-dot::before { content: ""; width: 12px; height: 12px; border-radius: 50%; background: #2c9a5b; }
.lg-arrow::before { content: "\2192"; color: #e0457b; font-size: 20px; font-weight: 800; }
.lg-num { color: #e0457b; }
@media (max-width: 979px) {
  .actions { flex-wrap: nowrap; gap: 6px; }
  .actions.expanded { flex-wrap: wrap; }
  .actions .b { padding: 8px 10px; font-size: 14px; }
}


:root { --field: #8c8474; }
:root[data-theme=dark] { --field: #737a8b; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { --field: #737a8b; } }
.lg-num { color: #b02556; }
@media (max-width: 979px) { .actions.expanded ~ .status:not(:empty) { bottom: calc(132px + env(safe-area-inset-bottom)); } }
