/* TapasSEO — /checkout/ page styles
   Pairs with output/checkout/index.html + output/assets/checkout.js
   Dark theme tokens are defined inline in checkout/index.html's <style> block
   (mirrors thank-you.html / research-confirmation.html :root vars).
   Generated: 2026-07-06
*/

/* ---- Layout shell ---- */
.co-main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 108px 20px 64px;
}

.co-header {
  max-width: 720px;
  margin: 0 auto 32px;
  text-align: center;
}
.co-header h1 {
  font-family: 'Fraunces', serif;
  font-size: clamp(1.9rem, 4.2vw, 2.6rem);
  line-height: 1.15;
  margin: 0 0 12px;
  letter-spacing: -0.015em;
  color: var(--text);
}
.co-header-sub {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
}

/* Single centered column — the buyer flows summary → form → pay in one line of sight,
   so the Pay CTA is always exactly where the form ends. */
.co-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 640px;
  margin: 0 auto;
}

/* ---- Pay panel (the CTA block, right after the form) ---- */
.co-pay-panel {
  background: var(--dark-card);
  border: 1px solid rgba(0,212,170,0.32);
  border-radius: 18px;
  padding: 26px 26px 24px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.28);
}
.co-pay-headline {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(0,212,170,0.22);
}
.co-pay-lead {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}
.co-pay-amount {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.9rem;
  color: var(--teal);
  line-height: 1;
}

/* ---- Panels ---- */
.co-panel {
  background: var(--dark-card);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 26px 26px 28px;
}
.co-panel:empty,
#co-forms:empty,
#co-manual:empty { display: none; }
#co-forms-panel:has(#co-forms:empty) { display: none; }
#co-manual-panel:has(#co-manual:empty) { display: none; }

.co-panel-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 18px;
  line-height: 1.3;
}

/* ---- Intake form sections (one per auto-fulfillment item) ---- */
.co-form-section { margin-bottom: 28px; }
.co-form-section:last-child { margin-bottom: 0; }
.co-form-section h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--teal);
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.co-field { margin-bottom: 16px; }
.co-field:last-child { margin-bottom: 0; }
.co-field label {
  display: block;
  font-family: 'Outfit', sans-serif;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.co-field .req { color: var(--teal); }
.co-field input,
.co-field select {
  width: 100%;
  box-sizing: border-box;
  background: var(--dark-soft);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 0.96rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.co-field input::placeholder { color: #6b6478; }
.co-field input:focus,
.co-field select:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0,212,170,0.16);
}
.co-field input:invalid:not(:placeholder-shown) { border-color: rgba(239,68,68,0.6); }
.co-field select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='12'%20height='8'%20viewBox='0%200%2012%208'%3E%3Cpath%20fill='%23A09890'%20d='M1%201l5%205%205-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 12px 8px;
  padding-right: 36px;
}

/* ---- Manual/auto list (no-form items) ---- */
.co-manual-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  color: var(--text-muted);
  font-size: 0.94rem;
  line-height: 1.5;
}
.co-manual-item:last-child { border-bottom: none; }
.co-manual-item .check { color: var(--teal); font-weight: 800; }
.co-manual-item strong { color: var(--text); }

/* ---- Order summary card ---- */
.co-summary-card {
  background: var(--dark-card);
  border: 1px solid rgba(0,212,170,0.20);
  border-radius: 18px;
  padding: 26px 24px 24px;
}

.co-summary-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.co-summary-item:first-child { padding-top: 0; }
.co-summary-item-info { min-width: 0; }
.co-summary-item-name {
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.94rem;
  color: var(--text);
  line-height: 1.4;
  margin: 0 0 4px;
}
.co-summary-item-delivery {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0;
}
.co-summary-item-price {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--text);
  white-space: nowrap;
}

.co-summary-empty {
  color: var(--text-muted);
  font-size: 0.94rem;
  line-height: 1.6;
  padding: 12px 0;
}
.co-summary-empty a { color: var(--teal); font-weight: 600; text-decoration: none; }
.co-summary-empty a:hover { text-decoration: underline; }

.co-summary-total-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(0,212,170,0.25);
  font-family: 'Outfit', sans-serif;
}
.co-summary-total-row span:first-child {
  font-size: 0.92rem;
  color: var(--text-muted);
  font-weight: 600;
}
.co-summary-total-row span:last-child {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--teal);
}

.co-trust {
  list-style: none;
  margin: 18px 0 0;
  padding: 14px 0 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.co-trust li {
  font-size: 0.82rem;
  color: var(--text-muted);
  padding-left: 20px;
  position: relative;
  line-height: 1.4;
}
.co-trust li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 800;
}

/* ---- Pay area ---- */
.co-pay-area {
  margin-top: 20px;
  min-height: 48px;
}
.co-pay-area.is-disabled { opacity: 0.55; pointer-events: none; }

.co-fallback {
  margin: 16px 0 0;
  text-align: center;
  font-size: 0.84rem;
  color: var(--text-muted);
}
.co-fallback a { color: var(--teal); text-decoration: none; font-weight: 600; }
.co-fallback a:hover { text-decoration: underline; }

/* ---- Error banner ---- */
.co-error {
  display: none;
  padding: 14px 18px;
  background: rgba(233,69,96,0.1);
  border: 1px solid rgba(233,69,96,0.4);
  border-radius: 10px;
  color: #ffb3c0;
  font-size: 0.92rem;
  line-height: 1.55;
}
.co-error.is-visible { display: block; }
.co-error a { color: #ffb3c0; font-weight: 700; text-decoration: underline; }

/* ---- In-app-browser deflect banner ---- */
.co-inapp-slot:empty { display: none; }
.co-inapp {
  max-width: 1180px;
  margin: 0 auto 24px;
  background: rgba(249,115,22,0.12);
  border: 1px solid rgba(249,115,22,0.45);
  border-radius: 14px;
  padding: 18px 22px;
  color: var(--text);
}
.co-inapp-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1rem;
  color: #F97316;
  margin: 0 0 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.co-inapp-text {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 0 0 14px;
}
.co-inapp-copy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  background: #F97316;
  color: #1A1A2E;
  border: none;
  border-radius: 10px;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 0.92rem;
  cursor: pointer;
  transition: transform 0.18s, box-shadow 0.18s;
}
.co-inapp-copy:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(249,115,22,0.35); }
.co-inapp-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 10px 0 0;
  line-height: 1.5;
}
.co-inapp-anyway {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.84rem;
  color: var(--text-muted);
  text-decoration: underline;
}
.co-inapp-anyway:hover { color: var(--text); }

/* ---- Empty-cart state (full page) ---- */
.co-empty-state {
  max-width: 520px;
  margin: 40px auto;
  text-align: center;
  padding: 40px 30px;
  background: var(--dark-card);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
}
.co-empty-state h2 {
  font-family: 'Fraunces', serif;
  font-size: 1.5rem;
  margin: 0 0 12px;
  color: var(--text);
}
.co-empty-state p {
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
  margin: 0 0 20px;
}
.co-empty-state a.co-browse-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--gradient-teal);
  color: var(--dark);
  border-radius: 12px;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 0.98rem;
  text-decoration: none;
  box-shadow: 0 6px 24px rgba(0,212,170,0.36);
}

/* ---- Mobile sticky CTA bar ---- */
.co-sticky-mobile {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 40;
  background: var(--dark-card);
  border-top: 1px solid rgba(0,212,170,0.25);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  box-shadow: 0 -6px 24px rgba(0,0,0,0.35);
}
.co-sticky-mobile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.co-sticky-mobile-total {
  font-family: 'Outfit', sans-serif;
}
.co-sticky-mobile-total .lbl {
  display: block;
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.co-sticky-mobile-total .amt {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--teal);
}
.co-sticky-mobile-link {
  flex: 1;
  text-align: center;
  padding: 12px 18px;
  background: var(--gradient-teal);
  color: var(--dark);
  border-radius: 10px;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
}
@media (max-width: 900px) {
  .co-sticky-mobile { display: block; }
  .co-main { padding-bottom: 100px; }
}
