/* ============================================
   Simplified Logic — Support page (/support/)
   Builds on site.css: theme tokens, .btn, and the .iform-* field / card / state
   styles shared with the home-page wizard. Only what is specific to the support
   page lives here.
   ============================================ */

.support-hero { text-align: center; padding: 44px 20px 32px; background: linear-gradient(135deg, #1a1a2e, #16213e); color: #fff; }
.support-hero h1 { font-size: 2.2rem; margin-bottom: 10px; }
.support-hero p { max-width: 640px; margin: 0 auto; font-size: 1.05rem; opacity: .85; line-height: 1.6; }
/* The hero only introduces the three options; it is hidden once a form is open. */
.support-hero[hidden] { display: none; }

.support-main { padding: 32px 0 48px; }
.support { max-width: 860px; margin: 0 auto; }
/* site.css only hides specific classes for [hidden]; this page toggles many more. */
.support [hidden] { display: none !important; }

/* --- Step 1: the three options --- */
.sf-heading { font-size: 1.4rem; text-align: center; color: var(--heading); margin-bottom: 24px; }
.sf-heading:focus { outline: none; }
.sf-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 20px; }
.sf-card {
  display: flex; flex-direction: column; gap: 10px; padding: 26px 22px;
  color: var(--text); background: var(--surface);
  border: 2px solid var(--border); border-radius: 14px; box-shadow: var(--card-shadow-soft);
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.sf-card:hover, .sf-card:focus-visible { opacity: 1; border-color: var(--accent); box-shadow: var(--card-shadow); transform: translateY(-2px); }
.sf-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.sf-card__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--cta-soft); color: var(--accent); }
.sf-card__icon svg { width: 26px; height: 26px; }
.sf-card h3 { font-size: 1.15rem; color: var(--heading); }
.sf-card p { font-size: .9rem; color: var(--text-soft); }
.sf-card__go { margin-top: auto; padding-top: 6px; font-size: .9rem; font-weight: 600; color: var(--accent); }
.sf-alt { margin-top: 28px; text-align: center; font-size: .9rem; color: var(--text-muted); }

/* --- Step 2: a form --- */
.sf-bar { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 22px; margin-bottom: 12px; }
.sf-back { padding: 4px 0; font: inherit; font-size: .9rem; font-weight: 600; color: var(--accent); background: none; border: none; cursor: pointer; }
.sf-back:hover { opacity: .75; }
.sf-back:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.sf-title { font-size: 1.45rem; color: var(--heading); }
.sf-title:focus { outline: none; }

/* Compact the shared .iform card and fields (defined roomier in site.css for the wizard). */
.sf-form.iform { padding: 20px 24px; border-radius: 14px; }
.sf-form .iform-grid { gap: 12px 16px; }
.sf-form .iform-label { margin-bottom: 4px; font-size: .82rem; }
.sf-form .iform-field { padding: 8px 12px; font-size: .9rem; border-radius: 8px; }
/* display:block removes the inline baseline gap that otherwise pushes whatever follows a textarea ~8px down. */
.sf-form textarea.iform-field { display: block; min-height: 64px; }

.sf-group { min-width: 0; margin: 0 0 18px; border: 0; }
.sf-group > legend { padding: 0; margin-bottom: 8px; font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.sf-group > .sf-field,
.sf-group > .iform-grid + .sf-field,
.sf-group > .sf-field + .sf-field,
.sf-group > .iform-grid + .iform-grid { margin-top: 12px; }
.sf-req { margin-left: 3px; color: var(--accent); }
.sf-hint { margin-top: 6px; font-size: .85rem; color: var(--text-muted); }

.sf-count { margin-top: 2px; font-size: .75rem; text-align: right; color: var(--label-muted); }
.sf-count.is-near { color: var(--warn); }
.sf-msg { margin-top: 3px; font-size: .8rem; color: var(--warn); }
.sf-summary { margin-top: 4px; font-size: .9rem; text-align: center; color: var(--warn); }
.sf-summary:empty { display: none; }
.sf-actions { display: flex; justify-content: center; margin-top: 10px; }

select.iform-field { cursor: pointer; }

/* --- Product picker: a listbox, because <select> cannot show a logo beside each name --- */
.sf-product__btn { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; cursor: pointer; user-select: none; }
.sf-product__value { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sf-product__value.is-placeholder { color: var(--label-muted); }
.sf-product__chev { width: 16px; height: 16px; flex-shrink: 0; color: var(--text-muted); transition: transform .15s; }
.sf-product__btn[aria-expanded="true"] .sf-product__chev { transform: rotate(180deg); }
.sf-product__list { max-height: 400px; }
.sf-opt { display: flex; align-items: center; gap: 12px; padding: 6px 14px; }
.sf-opt[aria-selected="true"] { font-weight: 700; color: var(--heading); }
.sf-logo { width: 28px; height: 28px; flex-shrink: 0; object-fit: contain; }
.sf-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .95rem; }
.sf-product__btn.is-error, .sf-product__btn.is-error:focus { border-color: var(--warn); box-shadow: 0 0 0 3px var(--warn-ring); }
.sf-product__btn:focus { outline: none; border-color: var(--ok); box-shadow: 0 0 0 3px var(--ok-ring); }

/* --- Sending / sent / failed --- */
.sf-status h3 { margin-bottom: 10px; font-size: 1.3rem; color: var(--heading); }

@media (max-width: 520px) {
  .support-hero { padding: 32px 20px 24px; }
  .support-hero h1 { font-size: 1.8rem; }
  .sf-title { font-size: 1.3rem; }
  .sf-form.iform { padding: 16px 14px; }
}
