/* Gift card site. Brand colours come from the dashboard and are set on :root by app.js. */
:root {
  --brand: #0F4C3A;
  --accent: #E8B04A;
  --ink: #15171a;
  --muted: #5d636b;
  --line: #e6e7e9;
  --paper: #ffffff;
  --tint: color-mix(in oklab, var(--brand) 5%, white);
  --tint-2: color-mix(in oklab, var(--brand) 10%, white);
  --brand-ink: color-mix(in oklab, var(--brand) 82%, black);
  --radius: 14px;
  --display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --body: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--body); font-size: 16px; line-height: 1.55; color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid color-mix(in oklab, var(--accent) 80%, black); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 8px; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.narrow { width: min(620px, 100% - 40px); margin-inline: auto; }
h1, h2, h3 { font-family: var(--display); line-height: 1.05; letter-spacing: -0.02em; margin: 0; }
h1 { font-size: clamp(40px, 6.4vw, 72px); font-weight: 800; }
h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0; }
.lead { font-size: 18px; color: var(--muted); max-width: 46ch; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.mono { font-variant-numeric: tabular-nums; letter-spacing: 0.08em; font-family: ui-monospace, "SF Mono", Menlo, monospace; }

/* Header */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in oklab, white 88%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.top-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { text-decoration: none; display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 22px; letter-spacing: -0.02em; color: var(--brand-ink); }
.brand img { height: 36px; width: auto; }
#brand-mark { display: flex; align-items: center; gap: 10px; }
.brand small { font-family: var(--body); font-weight: 600; font-size: 13px; color: var(--muted); letter-spacing: 0; }
.top-nav { display: flex; align-items: center; gap: 22px; font-weight: 500; font-size: 15px; }
.top-nav a { text-decoration: none; }
.top-nav a:not(.btn):hover { color: var(--brand); }
@media (max-width: 640px) { .top-nav a:not(.btn) { display: none; } }

/* Buttons and inputs */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 12px; background: var(--brand); color: #fff; font-weight: 700; padding: 14px 22px; text-decoration: none; cursor: pointer; transition: transform .12s ease, background .2s; }
.btn:hover { background: var(--brand-ink); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-sm { padding: 9px 15px; font-size: 14px; border-radius: 10px; }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { background: var(--tint); }
.btn-wa { background: #128C4A; }
.btn-wa:hover { background: #0e6f3b; }
.btn-block { width: 100%; }
label.field { display: block; font-weight: 600; font-size: 14px; }
label.field > span.hint { display: block; font-weight: 400; color: var(--muted); font-size: 13px; margin-top: 4px; }
.input { display: block; width: 100%; margin-top: 6px; border: 1.5px solid var(--line); border-radius: 12px; padding: 13px 14px; background: #fff; font-size: 16px; transition: border-color .15s; }
.input:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 4px color-mix(in oklab, var(--brand) 14%, transparent); }
textarea.input { resize: vertical; min-height: 84px; }
.row { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
@media (max-width: 560px) { .row { grid-template-columns: 1fr; } }
.stack > * + * { margin-top: 16px; }
.error { background: #fdecec; color: #a11b1b; border-radius: 10px; padding: 10px 12px; font-size: 14px; }
.note { background: var(--tint); border-radius: 12px; padding: 14px 16px; font-size: 14px; }

/* Amount chips */
.amounts { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1.5px solid var(--line); background: #fff; border-radius: 999px; padding: 9px 16px; font-weight: 700; cursor: pointer; font-variant-numeric: tabular-nums; }
.chip[aria-pressed="true"] { border-color: var(--brand); background: var(--brand); color: #fff; }
.chip:hover:not([aria-pressed="true"]) { border-color: color-mix(in oklab, var(--brand) 40%, var(--line)); }

/* The card: brand colour with a ribbon, the one bold element on every page */
.gcard { position: relative; aspect-ratio: 1.586; width: 100%; max-width: 440px; border-radius: 22px; color: #fff; overflow: hidden; isolation: isolate;
  background:
    radial-gradient(120% 90% at 0% 0%, color-mix(in oklab, var(--brand) 70%, white) 0%, transparent 55%),
    linear-gradient(145deg, var(--brand), var(--brand-ink));
  box-shadow: 0 30px 60px -28px color-mix(in oklab, var(--brand) 70%, black), 0 2px 0 rgba(255,255,255,.12) inset; }
.gcard::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: .08;
  background: repeating-linear-gradient(115deg, #fff 0 1px, transparent 1px 9px); }
.gcard .ribbon-v { position: absolute; top: 0; bottom: 0; right: 24%; width: 16px; background: var(--accent); box-shadow: 0 0 0 1px rgba(0,0,0,.06); }
.gcard .ribbon-h { position: absolute; left: 0; right: 0; top: 36%; height: 16px; background: var(--accent); box-shadow: 0 0 0 1px rgba(0,0,0,.06); }
.gcard .bow { position: absolute; right: calc(24% - 22px); top: calc(36% - 22px); width: 60px; height: 60px; }
.gcard .face { position: absolute; inset: 0; padding: 22px 24px; display: flex; flex-direction: column; justify-content: space-between; }
.gcard .brandline { font-family: var(--display); font-weight: 800; font-size: 22px; letter-spacing: -0.02em; display: flex; align-items: center; gap: 8px; max-width: 64%; }
.gcard .brandline img { height: 30px; width: auto; max-width: 100%; filter: brightness(0) invert(1); }
.gcard .amount { font-family: var(--display); font-weight: 800; font-size: clamp(34px, 5vw, 46px); letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.gcard .label { font-size: 12px; font-weight: 600; opacity: .8; letter-spacing: .02em; }
.gcard .number { font-size: 15px; opacity: .92; }
.gcard-tilt { transform: rotate(-4deg); transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.gcard-tilt:hover { transform: rotate(-1deg) translateY(-4px); }
@media (prefers-reduced-motion: reduce) { .gcard-tilt, .gcard-tilt:hover { transform: none; transition: none; } }

/* Home */
.hero { padding: 64px 0 72px; background: linear-gradient(180deg, var(--tint) 0%, #fff 100%); }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero-card { display: flex; justify-content: center; padding: 20px; }
@media (max-width: 880px) { .hero-grid { grid-template-columns: 1fr; gap: 36px; } .hero-card { order: -1; padding: 0 8px; } }
.hero h1 .brandword { color: var(--brand); }
.hero .lead { margin-top: 18px; }
.picker { margin-top: 30px; }
.picker .custom { margin-top: 12px; display: flex; gap: 10px; align-items: stretch; }
.picker .custom .input { margin-top: 0; max-width: 240px; }
.picker .go { margin-top: 18px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
section.block { padding: 84px 0; }
section.block.alt { background: var(--tint); }
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: start; }
@media (max-width: 880px) { .split { grid-template-columns: 1fr; gap: 28px; } }
.ways { border-top: 1.5px solid var(--ink); }
.ways > div { display: grid; grid-template-columns: 200px 1fr; gap: 20px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.ways h3 { font-size: 19px; }
@media (max-width: 560px) { .ways > div { grid-template-columns: 1fr; gap: 6px; } }
.perks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 40px; margin-top: 40px; }
.perks h3 { font-size: 18px; margin-bottom: 6px; }
.perks .mark { width: 34px; height: 4px; background: var(--accent); border-radius: 2px; margin-bottom: 14px; }
@media (max-width: 640px) { .perks { grid-template-columns: 1fr; } }
.steps { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; counter-reset: s; }
.steps li { counter-increment: s; border-top: 1.5px solid var(--ink); padding-top: 16px; }
.steps li::before { content: counter(s); font-family: var(--display); font-weight: 800; font-size: 40px; color: var(--brand); line-height: 1; display: block; margin-bottom: 12px; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 26px; box-shadow: 0 1px 0 rgba(0,0,0,.02); }
.stores { columns: 2; column-gap: 40px; margin-top: 28px; padding: 0; list-style: none; }
.stores li { break-inside: avoid; padding: 12px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 560px) { .stores { columns: 1; } }
.terms { margin: 0; padding-left: 20px; color: var(--muted); }
.terms li + li { margin-top: 6px; }

/* Buy, order, card, balance pages */
.page { padding: 48px 0 84px; }
.page h1 { font-size: clamp(34px, 5vw, 48px); }
.page-grid { display: grid; grid-template-columns: 1fr 380px; gap: 48px; align-items: start; margin-top: 32px; }
.sticky-card { position: sticky; top: 92px; }
@media (max-width: 880px) { .page-grid { grid-template-columns: 1fr; } .sticky-card { position: static; order: -1; } }
.legend { font-family: var(--display); font-weight: 700; font-size: 18px; margin-bottom: 12px; }
.acct { border: 1.5px solid var(--line); border-radius: 16px; padding: 18px; }
.acct .num { font-size: 30px; font-weight: 700; letter-spacing: .06em; font-variant-numeric: tabular-nums; }
.acct .big { font-family: var(--display); font-size: 40px; font-weight: 800; letter-spacing: -0.02em; }
.ref { display: inline-block; background: var(--ink); color: #fff; border-radius: 8px; padding: 4px 10px; font-weight: 700; letter-spacing: .08em; }
.status { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; padding: 6px 12px; border-radius: 999px; font-size: 14px; }
.status.wait { background: #fff5dd; color: #7a5300; }
.status.ok { background: #e3f6ea; color: #0b6b37; }
.status.bad { background: #fdecec; color: #a11b1b; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .dot { animation: none; } }
.barcode { background: #fff; border-radius: 14px; padding: 16px 16px 10px; border: 1px solid var(--line); text-align: center; }
.barcode svg { width: 100%; height: 86px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; font-size: 15px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 600; }
.message { font-family: var(--display); font-size: 22px; font-weight: 500; line-height: 1.3; border-left: 4px solid var(--accent); padding-left: 16px; }
.center { text-align: center; }
.spinner { width: 28px; height: 28px; border: 3px solid var(--tint-2); border-top-color: var(--brand); border-radius: 50%; animation: spin .8s linear infinite; margin: 60px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Footer */
.foot { border-top: 1px solid var(--line); padding: 36px 0 48px; font-size: 14px; color: var(--muted); }
.foot-inner { display: flex; flex-wrap: wrap; gap: 20px 40px; justify-content: space-between; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); }
