/* /gift: plan + term picker, personalisation, live card preview.
   Design-system tokens only (vilkax-tokens.css); builds on growth.css. */

.gf-main { max-width: 1040px; }
.gf-center { text-align: center; }
.gf-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.gf-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; margin: 0 0 18px; }
.gf-steps { min-width: 0; }
.gf-layout .gw-card h2 { display: flex; align-items: center; gap: 10px; }
.gf-num {
  display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--vx-accent-sf); border: 1px solid var(--vx-accent-ln); color: var(--vx-accent-br);
  font: 700 13px/1 var(--vx-f-body);
}
.gf-label { color: var(--vx-text); font-weight: 600; font-size: 14px; margin: 0 0 8px; padding: 0; }
.gf-tight { margin: -4px 0 14px; }
fieldset.gf-plans, fieldset.gf-terms, fieldset.gf-when { border: 0; margin: 0; padding: 0; min-width: 0; }
.gf-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0 0 18px !important; }
.gf-plan {
  position: relative; display: flex; flex-direction: column; gap: 6px; cursor: pointer;
  padding: 16px 16px 16px 44px; border-radius: var(--vx-radius-sm);
  border: 1px solid var(--vx-line-2); background: var(--vx-surface-2);
  transition: border-color .15s ease, background .15s ease;
}
.gf-plan input { position: absolute; inset-inline-start: 16px; top: 18px; accent-color: var(--vx-accent); width: 18px; height: 18px; margin: 0; }
.gf-plan:has(input:checked) { border-color: var(--vx-accent-ln); background: var(--vx-accent-sf); }
.gf-plan-name { font-family: var(--vx-f-disp); font-weight: 700; color: var(--vx-text); font-size: 18px; }
.gf-plan-desc { color: var(--vx-text-muted); font-size: 13.5px; line-height: 1.45; }
[dir="rtl"] .gf-plan { padding: 16px 44px 16px 16px; }

.gf-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gf-seg label { cursor: pointer; }
.gf-seg input { position: absolute; opacity: 0; pointer-events: none; }
.gf-seg span {
  display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center;
  padding: 12px 8px; border-radius: var(--vx-radius-sm); border: 1px solid var(--vx-line-2); background: var(--vx-surface-2);
}
.gf-seg b { color: var(--vx-text); font-size: 15px; }
.gf-seg i { font-style: normal; color: var(--vx-text-muted); font-size: 13px; min-height: 1em; }
.gf-seg input:checked + span { border-color: var(--vx-accent-ln); background: var(--vx-accent-sf); }
.gf-seg input:focus-visible + span { outline: 2px solid var(--vx-accent-br); outline-offset: 2px; }

.gf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.gf-main .gw-field input[type="text"], .gf-main .gw-field input[type="date"], .gf-main .gw-field textarea {
  width: 100%; box-sizing: border-box; padding: 11px 12px; border-radius: var(--vx-radius-sm);
  border: 1px solid var(--vx-line-2); background: var(--vx-surface-3); color: var(--vx-text); font: inherit; font-size: 15px;
}
.gf-main .gw-field input[type="email"] { width: 100%; box-sizing: border-box; }
.gf-main .gw-field textarea { resize: vertical; min-height: 84px; line-height: 1.5; }
.gf-main .gw-field input[type="date"] { color-scheme: dark; max-width: 240px; }
.gf-count { align-self: flex-end; color: var(--vx-text-dim); font-size: 12px; }
.gf-when .gw-check { margin: 0 0 8px; }
.gf-when .gw-field { margin: 6px 0 0 28px; }

.gf-total {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 12px 0 14px; margin: 0 0 12px; border-bottom: 1px solid var(--vx-line);
  color: var(--vx-text-muted); font-size: 15px;
}
.gf-total strong { color: var(--vx-text); font-family: var(--vx-f-disp); font-size: 26px; }
.gf-buy { min-width: 220px; }

/* Live preview: an echo of the printable card the buyer receives. */
.gf-aside { position: sticky; top: 24px; }
.gf-card {
  position: relative; overflow: hidden; border-radius: 18px; padding: 26px 22px 22px;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(177,76,255,.28), transparent 60%),
    radial-gradient(100% 80% at 0% 100%, rgba(201,169,97,.20), transparent 60%),
    var(--vx-surface-2);
  border: 1px solid var(--vx-line-2);
  box-shadow: 0 24px 60px rgba(0,0,0,.35);
  min-height: 300px; display: flex; flex-direction: column;
}
.gf-card::before { content: ""; position: absolute; inset: 9px; border: 1px solid rgba(201,169,97,.35); border-radius: 12px; pointer-events: none; }
.gf-card-brand { display: flex; align-items: center; gap: 8px; color: var(--vx-text); font: 700 12px/1 var(--vx-f-body); letter-spacing: .2em; text-transform: uppercase; }
.gf-card-plan { font-family: var(--vx-f-disp); font-size: 28px; font-weight: 700; color: var(--vx-text); margin: 26px 0 2px; }
.gf-card-term { color: var(--vx-accent-br); font-weight: 600; margin: 0 0 14px; }
.gf-card-line { color: var(--vx-text); margin: 0 0 2px; font-size: 14px; overflow-wrap: anywhere; }
.gf-card-msg { color: var(--vx-text-muted); font-style: italic; margin: 12px 0 0; padding-inline-start: 10px; border-inline-start: 2px solid rgba(201,169,97,.6); white-space: pre-line; overflow-wrap: anywhere; font-size: 14px; }
.gf-card-code { margin: auto 0 0; padding-top: 18px; font: 700 15px/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .1em; color: var(--vx-text-dim); }

@media (max-width: 860px) {
  .gf-layout { grid-template-columns: 1fr; }
  .gf-aside { position: static; order: -1; }
  .gf-card { min-height: 0; }
}
@media (max-width: 520px) {
  .gf-plans, .gf-grid { grid-template-columns: 1fr; }
  .gf-buy { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .gf-plan { transition: none; } }
