/* Base + the shared sections under each hero. Every colour, font and corner comes from the page's own variables. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
button, input { font: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.sec { scroll-margin-top: 72px; padding: clamp(64px, 9vw, 120px) clamp(16px, 3vw, 36px); border-top: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 28px clamp(24px, 4vw, 64px); }
.sec-head { align-self: start; position: sticky; top: 92px; }
.sec-num { font: 500 12px var(--font); letter-spacing: .14em; color: var(--accent); }
.sec h2 { font: var(--h2-weight, 800) clamp(28px, 3.4vw, 44px)/1.05 var(--h2-font, var(--display)); letter-spacing: var(--h2-track, -0.03em); text-transform: var(--h2-case, none); margin: 12px 0 14px; color: var(--ink); }
.sec-head p { color: var(--mute); font-size: 14px; line-height: 1.65; margin: 0; max-width: 360px; }

/* steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.step { border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; box-shadow: var(--card-shadow, none); }
.illus { width: 100%; height: auto; margin-bottom: 14px; background: var(--bg2); border-radius: var(--radius); border: 1px solid var(--line); }
.s-fill { fill: var(--panel); stroke: var(--line2); }
.s-ink { fill: var(--ink); }
.s-mute { fill: var(--dim); }
.s-accent { fill: var(--accent); }
.s-coin-t { fill: var(--accent-ink); font: 700 16px var(--font); }
.s-line { fill: none; stroke: var(--line2); stroke-width: 6; }
.s-arc { fill: none; stroke: var(--accent); stroke-width: 6; stroke-dasharray: 100; stroke-dashoffset: 100; transform: rotate(-90deg); transform-origin: 80px 55px; animation: arc 4s ease-in-out infinite; }
.s-hand { stroke: var(--ink); stroke-width: 3; transform-origin: 80px 55px; animation: hand 4s ease-in-out infinite; }
.s-check { fill: none; stroke: var(--accent); stroke-width: 4; stroke-dasharray: 100; stroke-dashoffset: 100; animation: check 3s ease-out infinite; }
.coin-drop { animation: drop 3s cubic-bezier(.5,0,.3,1) infinite; }
@keyframes drop { 0%, 15% { transform: translateY(0); opacity: 1; } 55% { transform: translateY(34px); opacity: 1; } 60%, 100% { transform: translateY(40px); opacity: 0; } }
@keyframes arc { 0% { stroke-dashoffset: 100; } 60%, 100% { stroke-dashoffset: 18; } }
@keyframes hand { 0% { transform: rotate(0); } 60%, 100% { transform: rotate(295deg); } }
@keyframes check { 0%, 30% { stroke-dashoffset: 100; } 60%, 100% { stroke-dashoffset: 0; } }
.step-n { font: 500 11px var(--font); letter-spacing: .14em; color: var(--accent); }
.step h3 { font: 700 17px/1.25 var(--display); margin: 8px 0 8px; color: var(--ink); text-transform: var(--h3-case, none); letter-spacing: var(--h3-track, -0.01em); }
.step p { color: var(--mute); font-size: 13.5px; line-height: 1.6; margin: 0; }
.rules { grid-column: 2; list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border-top: 1px solid var(--line); }
.rules li { padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); color: var(--mute); font-size: 13.5px; line-height: 1.6; }
.rules li:nth-child(odd) { border-right: 1px solid var(--line); }
.rules li:nth-child(even) { padding-left: 16px; }
.rules b { color: var(--ink); font-weight: 600; display: block; margin-bottom: 2px; }

/* forms */
.panel { border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); padding: clamp(16px, 2.4vw, 26px); display: grid; gap: 14px; max-width: 640px; box-shadow: var(--card-shadow, none); }
.field { display: grid; gap: 8px; }
.field > span { font: 500 12px var(--font); letter-spacing: .1em; color: var(--mute); text-transform: uppercase; }
.field > span b { color: var(--ink); font-weight: 600; }
.panel input:not([type=range]) { width: 100%; background: var(--bg2); color: var(--ink); border: 1px solid var(--line2); border-radius: var(--radius); padding: 14px; font: 500 15px var(--font); outline: none; min-width: 0; }
.panel input:not([type=range]):focus { border-color: var(--accent); }
.amount { display: flex; gap: 8px; }
.amount button, .panel .durs button { font: 600 13px var(--font); color: var(--mute); background: var(--bg2); border: 1px solid var(--line2); border-radius: var(--radius); padding: 0 14px; cursor: pointer; }
.amount button:hover { color: var(--ink); }
.panel .durs { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.panel .durs button { padding: 11px 0; }
.panel .durs button.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.info, .result, .summary, .note { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--mute); }
.info[data-state=ok], .result[data-state=ok] { color: var(--ink); }
.info[data-state=bad], .result[data-state=bad] { color: var(--bad); }
.info[data-state=busy], .result[data-state=busy] { color: var(--accent); }
.summary { color: var(--ink); background: var(--bg2); border: 1px dashed var(--line2); border-radius: var(--radius); padding: 12px 14px; }
.summary b { color: var(--accent); font-weight: 600; }
.note:empty { display: none; }
.note { color: var(--accent); }
.wide { justify-content: center; width: 100%; padding: 16px; font-size: 14px; }
.hood summary { cursor: pointer; font: 500 12px var(--font); letter-spacing: .1em; color: var(--mute); text-transform: uppercase; }
.hood dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; font-size: 13px; margin: 12px 0 0; }
.hood dt { color: var(--dim); }
.hood dd { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.check-row { display: flex; gap: 8px; }
.check-row .btn { flex: none; }

/* faq */
.faq { border-top: 1px solid var(--line); max-width: 760px; }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item button { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px; text-align: left; background: none; border: 0; color: var(--ink); font: 600 16px/1.4 var(--display); padding: 20px 0; cursor: pointer; text-transform: var(--h3-case, none); }
.faq-item i { flex: none; width: 14px; height: 14px; position: relative; }
.faq-item i::before, .faq-item i::after { content: ''; position: absolute; left: 0; top: 6px; width: 14px; height: 2px; background: var(--accent); transition: transform .25s; }
.faq-item i::after { transform: rotate(90deg); }
.faq-item.open i::after { transform: rotate(0); }
.faq-item p { display: none; margin: 0 0 20px; color: var(--mute); font-size: 14px; line-height: 1.7; max-width: 620px; }
.faq-item.open p { display: block; }

.foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; padding: 22px clamp(16px, 3vw, 36px); border-top: 1px solid var(--line); font-size: 12.5px; color: var(--mute); }
.foot-brand { font-weight: 800; color: var(--ink); letter-spacing: .08em; margin-right: auto; }
.foot a { color: var(--mute); text-decoration: none; }
.foot a:hover { color: var(--ink); }

/* transaction steps and success */
.tx-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.tx-steps li { display: flex; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; font-size: 13.5px; color: var(--mute); background: var(--bg2); }
.tx-steps .n { width: 24px; height: 24px; flex: none; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line2); font-weight: 700; font-size: 12px; }
.tx-steps small { display: block; color: var(--dim); font-size: 12px; margin-top: 2px; }
.tx-steps li[data-state=active] { color: var(--ink); border-color: var(--accent); }
.tx-steps li[data-state=active] .n { border-color: var(--accent); border-right-color: transparent; animation: spin 1s linear infinite; color: transparent; }
.tx-steps li[data-state=active] small { color: var(--accent); }
.tx-steps li[data-state=done] { color: var(--ink); }
.tx-steps li[data-state=done] .n { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-size: 0; }
.tx-steps li[data-state=done] .n::after { content: '✓'; font-size: 13px; }
.tx-steps li[data-state=error] { border-color: var(--bad); }
.tx-steps li[data-state=error] small { color: var(--bad); }
.done { border: 1px solid var(--accent); background: var(--accent-soft); border-radius: var(--radius); padding: 16px; }
.done b { font-size: 16px; color: var(--ink); }
.done p { margin: 6px 0 14px; color: var(--mute); font-size: 13.5px; }
.done-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn.small { padding: 9px 12px; font-size: 12px; }

/* lock lists */
.check-head { display: flex; align-items: center; gap: 12px; }
.check-head > span:nth-child(2) { flex: 1; min-width: 0; color: var(--mute); }
.check-head b { color: var(--ink); }
.check-head small { display: block; color: var(--dim); font-size: 12px; }
.check-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); margin-top: 14px; overflow: hidden; }
.check-stats > span { background: var(--bg2); padding: 12px; }
.check-stats small { display: block; color: var(--dim); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 4px; }
.check-stats b { color: var(--ink); font-size: 15px; font-variant-numeric: tabular-nums; }
.lock-list { display: grid; gap: 6px; }
.lock-list:empty { display: none; }
.lock-row .pill { justify-self: end; }
.lock-row { display: grid; grid-template-columns: 56px 1fr 1fr 118px; gap: 12px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg2); text-decoration: none; color: var(--ink); transition: border-color .15s, transform .15s; }
.lock-row:hover { border-color: var(--accent); transform: translateX(2px); }
.lock-row small { display: block; color: var(--dim); font-size: 11.5px; margin-top: 2px; }
.lock-row b { font-weight: 600; font-variant-numeric: tabular-nums; }
.lr-id { color: var(--dim); font-size: 13px; }
.empty { color: var(--mute); font-size: 13.5px; line-height: 1.6; margin: 0; padding: 14px; border: 1px dashed var(--line2); border-radius: var(--radius); }

#toast { position: fixed; left: 50%; bottom: 22px; z-index: 100; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: .25s; max-width: min(92vw, 460px); background: var(--ink); color: var(--bg); font: 500 13px/1.5 var(--font); padding: 12px 16px; border-radius: var(--radius); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 900px) {
  .sec { grid-template-columns: 1fr; }
  .sec-head { position: static; }
  .rules { grid-column: auto; }
  .steps { grid-template-columns: 1fr; }
  .step { display: grid; grid-template-columns: 132px 1fr; column-gap: 16px; align-items: start; }
  .step .illus { grid-row: span 3; margin: 0; }
}
@media (max-width: 560px) {
  .check-stats { grid-template-columns: repeat(2, 1fr); }
  .lock-row { grid-template-columns: 1fr auto; }
  .lr-id { display: none; }
  .lr-when { grid-column: 1; }
  .lock-row .pill { grid-row: 1; grid-column: 2; }
  .rules { grid-template-columns: 1fr; }
  .rules li:nth-child(odd) { border-right: 0; }
  .rules li:nth-child(even) { padding-left: 0; }
  .step { grid-template-columns: 96px 1fr; }
  .check-row { flex-direction: column; }
  .panel .durs button { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .s-arc { stroke-dashoffset: 18; }
  .s-check { stroke-dashoffset: 0; }
}
