/* ─────────────────────────────────────────────
   Trivia CO · Legal Document styles (light theme)
   Used by: terms-and-conditions, privacy-policy,
            delete-account, child-safety-standards
   Tokens taken from desing/trivia-co-design-system.html — [data-theme="light"]
   ───────────────────────────────────────────── */

.tco-legal-page {
  /* Light palette (design system) */
  --tco-bg:            #F5F6FA;
  --tco-bg-elevated:   #ECEEF6;
  --tco-surface:       #FFFFFF;
  --tco-border:        #E1E3ED;
  --tco-text:          #1B1035;
  --tco-text-secondary:#5B5770;
  --tco-text-disabled: #A8A5B8;

  /* Brand */
  --tco-brand:         #E63888; /* Buganvilia */
  --tco-brand-dark:    #C22A6F;

  /* Semantic (alerts) */
  --tco-success-bg: #E3F8F3; --tco-success-fg: #04594E; --tco-success-icon: #00A896;
  --tco-warning-bg: #FEF3DC; --tco-warning-fg: #7A4B04; --tco-warning-icon: #F4A81D;
  --tco-error-bg:   #FCE8E7; --tco-error-fg:   #8C2620; --tco-error-icon:   #E8483F;
  --tco-info-bg:    #EAF1FE; --tco-info-fg:    #1E3E85; --tco-info-icon:    #3E7BFA;

  --tco-radius-s: 10px;
  --tco-radius-m: 16px;
  --tco-shadow: 0 1px 2px rgba(27, 16, 53, .06), 0 2px 8px rgba(27, 16, 53, .05);

  --font-display: 'Sora', sans-serif;
  --font-body: 'Manrope', sans-serif;

  min-height: 100vh;
  background: var(--tco-bg);
  padding: 48px 16px 80px;
  font-family: var(--font-body);
}

.tco-legal-container {
  max-width: 800px;
  margin: 0 auto;
}

/* ── Header ─────────────────────────────────── */

.tco-legal-header {
  margin-bottom: 36px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--tco-border);
}

.tco-legal-logo-badge {
  width: 72px;
  height: 72px;
  border-radius: var(--tco-radius-m);
  background: var(--tco-bg-elevated);
  box-shadow: var(--tco-shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
}

.tco-legal-logo {
  width: 100%;
  height: auto;
  display: block;
}

/* ── Typography ─────────────────────────────── */

.tco-legal-h1 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.3px;
  color: var(--tco-brand);
  margin: 20px 0 10px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--tco-brand);
}

.tco-legal-last-updated {
  color: var(--tco-text-disabled);
  font-style: italic;
  font-size: 14px;
  margin: 0 0 32px;
  display: block;
}

.tco-legal-h2 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--tco-brand);
  margin: 40px 0 12px;
}

.tco-legal-h3 {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--tco-text-secondary);
  margin: 24px 0 8px;
}

.tco-legal-p {
  color: var(--tco-text-secondary);
  font-size: 15px;
  line-height: 1.7;
  margin: 0 0 12px;
}

.tco-legal-p strong {
  color: var(--tco-text);
}

/* ── Lists ──────────────────────────────────── */

.tco-legal-ul {
  color: var(--tco-text-secondary);
  font-size: 15px;
  line-height: 1.7;
  margin: 0 0 12px;
  padding-left: 24px;
}

.tco-legal-ul li {
  margin-bottom: 6px;
}

.tco-legal-ul li strong {
  color: var(--tco-text);
}

/* ── Callouts ───────────────────────────────── */

.tco-legal-callout {
  padding: 14px 18px;
  border-radius: var(--tco-radius-s);
  margin: 20px 0;
  border-left: 4px solid;
}

.tco-legal-callout.important {
  background: var(--tco-warning-bg);
  border-color: var(--tco-warning-icon);
}

.tco-legal-callout.important .tco-legal-p,
.tco-legal-callout.important .tco-legal-h3,
.tco-legal-callout.important .tco-legal-ul {
  color: var(--tco-warning-fg);
}

.tco-legal-callout.critical {
  background: var(--tco-error-bg);
  border-color: var(--tco-error-icon);
}

.tco-legal-callout.critical .tco-legal-p {
  color: var(--tco-error-fg);
}

.tco-legal-callout.info {
  background: var(--tco-info-bg);
  border-color: var(--tco-info-icon);
}

.tco-legal-callout.info .tco-legal-p,
.tco-legal-callout.info .tco-legal-ul {
  color: var(--tco-info-fg);
}

.tco-legal-callout.contact {
  background: var(--tco-bg-elevated);
  border-color: var(--tco-brand);
}

.tco-legal-callout.contact .tco-legal-h2 {
  margin-top: 0;
}

/* ── Steps ──────────────────────────────────── */

.tco-legal-steps {
  background: var(--tco-surface);
  border: 1px solid var(--tco-border);
  box-shadow: var(--tco-shadow);
  border-radius: var(--tco-radius-m);
  padding: 20px 24px;
  margin: 20px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tco-legal-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.tco-legal-step-number {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  background: var(--tco-brand);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  margin-top: 2px;
}

.tco-legal-step-content {
  flex: 1;
}

.tco-legal-step-content strong {
  display: block;
  color: var(--tco-text);
  font-size: 15px;
  font-weight: 600;
}

.tco-legal-step-desc {
  display: block;
  color: var(--tco-text-disabled);
  font-size: 13px;
  line-height: 1.5;
  margin-top: 2px;
}

/* ── Third-party provider cards ─────────────── */

.tco-legal-providers {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 16px 0 20px;
}

.tco-legal-provider {
  background: var(--tco-surface);
  border: 1px solid var(--tco-border);
  border-radius: var(--tco-radius-s);
  padding: 12px 16px;
  border-left: 3px solid var(--tco-brand);
}

.tco-legal-provider-name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--tco-brand);
  margin-bottom: 8px;
}

.tco-legal-provider-row {
  display: flex;
  gap: 8px;
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 2px;
}

.tco-legal-provider-label {
  font-weight: 600;
  color: var(--tco-text-disabled);
  flex-shrink: 0;
  min-width: 60px;
}

.tco-legal-provider-value {
  color: var(--tco-text-secondary);
}

.tco-legal-provider-link {
  color: var(--tco-brand);
  text-decoration: none;
  font-size: 13px;
  word-break: break-all;
}

.tco-legal-provider-link:hover {
  text-decoration: underline;
}

/* ── Links ──────────────────────────────────── */

.tco-legal-link {
  color: var(--tco-brand);
  text-decoration: none;
}

.tco-legal-link:hover {
  text-decoration: underline;
}

/* ── Footer ─────────────────────────────────── */

.tco-legal-divider {
  height: 1px;
  background: var(--tco-border);
  margin: 48px 0 24px;
}

.tco-legal-footer-text {
  text-align: center;
  color: var(--tco-text-disabled);
  font-size: 13px;
  line-height: 1.8;
  margin: 0;
}

/* ── Responsive ─────────────────────────────── */

@media (max-width: 480px) {
  .tco-legal-page { padding: 24px 16px 60px; }
  .tco-legal-h1   { font-size: 22px; }
  .tco-legal-h2   { font-size: 16px; margin-top: 32px; }

  .tco-legal-provider-row   { flex-direction: column; gap: 1px; }
  .tco-legal-provider-label { min-width: unset; }
}
