:root { --bg: #faf8f5; --card: #fff; --ink: #18161a; --muted: #625d66; --line: #e2ddd6; --accent: #5a2a96; --accent-ink: #fff; --warn: #a2321f; --w: 72rem; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 1.0625rem/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--accent); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; } .skip:focus { left: .5rem; top: .5rem; background: #000; color: #fff; padding: .4rem .7rem; }
.top, main, .foot { max-width: var(--w); margin: 0 auto; padding: 0 1.25rem; }
.top { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding-top: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.brand { font-weight: 800; letter-spacing: -.01em; color: var(--ink); text-decoration: none; font-size: 1.15rem; }
.top nav { display: flex; gap: 1.2rem; } .top nav a { color: var(--muted); text-decoration: none; } .top nav a:hover { color: var(--ink); }
.hero { padding: 2.2rem 0 1rem; max-width: 46rem; }
h1 { font-size: clamp(2rem, 6vw, 3.2rem); line-height: 1.05; margin: 0 0 .7rem; letter-spacing: -.02em; }
.lede { font-size: 1.15rem; color: var(--muted); margin: 0; }
.drop { border: 2px dashed #c9c0d6; background: var(--card); border-radius: 14px; padding: 2rem 1rem; text-align: center; margin-top: 1rem; transition: border-color .15s, background .15s; }
.drop.over { border-color: var(--accent); background: #f3eefa; }
.drop.small { padding: 1rem; }
.row { display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; margin: .6rem 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .6rem 1.1rem; border-radius: 10px; border: 1.5px solid #bdb4c8; background: #fff; color: var(--ink); font: 600 1rem system-ui, sans-serif; cursor: pointer; }
.btn:hover { border-color: var(--ink); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: #47207a; }
.btn.big { font-size: 1.1rem; padding: .8rem 1.4rem; }
.btn:disabled { opacity: .6; cursor: wait; }
.small { font-size: .88rem; color: var(--muted); margin: .4rem 0; }
.warn { color: var(--warn); }
.msg { min-height: 1.4em; font-weight: 600; margin: .8rem 0 0; } .msg.err { color: var(--warn); }
.balance { display: inline-block; background: #efe7fa; color: var(--accent); font-weight: 700; padding: .3rem .7rem; border-radius: 999px; margin: .3rem 0 0; }
.workspace { margin-top: 1rem; }
.panes { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
figure { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: .6rem; }
figcaption { font-size: .85rem; color: var(--muted); margin-bottom: .4rem; }
canvas { display: block; width: 100%; height: auto; border-radius: 6px; background: #fff; }
.controls { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 1rem; }
fieldset { border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: .8rem 1rem 1rem; margin: 0; }
legend { font-weight: 700; padding: 0 .3rem; }
fieldset label { display: block; margin: .6rem 0; font-weight: 600; font-size: .95rem; }
fieldset input[type=range], fieldset select, fieldset input[type=number] { display: block; width: 100%; margin-top: .3rem; min-height: 36px; font: inherit; }
.check { display: flex !important; gap: .5rem; align-items: center; } .check input { width: 20px; height: 20px; }
.inline { display: flex; gap: .4rem; } .inline input { flex: 1; } .inline select { width: 5rem !important; }
.hint { font-weight: 400; color: var(--muted); font-size: .82rem; margin-left: .3rem; }
.actions { margin: 1.2rem 0 .5rem; display: flex; flex-wrap: wrap; gap: .7rem; align-items: center; }
.actions .small { flex-basis: 100%; }
.prose { max-width: 46rem; margin-top: 2.5rem; }
.prose h2 { font-size: 1.45rem; margin: 2rem 0 .5rem; }
.prose li { margin: .35rem 0; }
details { border-top: 1px solid var(--line); padding: .6rem 0; } details:last-of-type { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; font-weight: 600; }
dialog { border: 0; border-radius: 16px; padding: 1.5rem; max-width: 30rem; width: calc(100% - 2rem); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
dialog::backdrop { background: rgba(20,10,30,.45); }
dialog h2 { margin-top: 0; }
.packs { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; margin: 1rem 0; }
.pack { display: flex; flex-direction: column; gap: .2rem; align-items: flex-start; padding: 1rem; border: 2px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; font: inherit; text-align: left; min-height: 44px; }
.pack:hover, .pack.best { border-color: var(--accent); }
.pack span { font-size: 1.6rem; font-weight: 800; }
.pack small { color: var(--muted); }
.foot { margin-top: 3rem; padding-top: 1rem; padding-bottom: 2.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.price-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1rem; margin: 1rem 0; }
.price-cards div { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 1rem; }
table { border-collapse: collapse; width: 100%; background: var(--card); font-size: .95rem; }
th, td { text-align: left; padding: .5rem .6rem; border-top: 1px solid var(--line); vertical-align: top; }
@media (max-width: 760px) { .panes { grid-template-columns: 1fr; } .controls { grid-template-columns: 1fr; } .packs { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
