/* Website account pages: signin.html and account.html (DECISIONS D31). Class prefix .ac-.
   Load after fonts.css, tokens.css, base.css, chrome.css. Colours come only from tokens.css; the one exception is
   google-g.svg, Google's own logo file, which must keep Google's colours (Google sign-in branding guidelines). */

.ac-page { padding: clamp(40px, 6vw, 96px) 0 clamp(48px, 6vw, 96px); position: relative; overflow: hidden; }
.ac-page::before { content: ""; position: absolute; inset: -30% -10% auto auto; width: 64vw; height: 64vw; max-width: 820px; max-height: 820px; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in oklab, var(--tt-brand) 14%, transparent), transparent); z-index: -1; pointer-events: none; }
.ac-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); grid-template-rows: auto 1fr; grid-template-areas: "head card" "facts card"; column-gap: clamp(32px, 6vw, 88px); align-items: start; }
.ac-grid__head { grid-area: head; }
.ac-grid__facts { grid-area: facts; }
.ac-grid__card { grid-area: card; }
.ac-narrow { max-width: calc(720px + 2 * var(--gutter)); }
.ac-title { font-size: clamp(2.4rem, 1.2rem + 3.8vw, 4.5rem); max-width: 14ch; text-wrap: balance; margin-top: 16px; }
.ac-lede { margin-top: 20px; max-width: 52ch; }
.ac-facts { margin-top: 28px; display: grid; gap: 12px; list-style: none; padding: 0; max-width: 54ch; }
.ac-facts li { display: flex; gap: 12px; align-items: baseline; color: var(--tt-ink-2); line-height: 1.55; }
.ac-facts li::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--tt-accent); box-shadow: 0 0 0 1px var(--tt-accent-edge); transform: translateY(-1px); }
.ac-facts b { color: var(--tt-ink); font-weight: var(--w-semi); }

/* The card that holds the sign-in steps or one account setting */
.ac-card { padding: clamp(22px, 3vw, 32px); display: grid; gap: 16px; }
.ac-card + .ac-card { margin-top: 16px; }
.ac-card h2 { font-family: var(--f-display); font-size: 1.375rem; font-weight: 700; letter-spacing: -.02em; color: var(--tt-ink); }
.ac-card p { color: var(--tt-ink-2); line-height: 1.55; }
.ac-age { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: .875rem; color: var(--tt-ink-2); }
.ac-age b { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: var(--r-pill); background: var(--tt-accent); color: var(--tt-accent-ink); font-weight: var(--w-bold); font-size: .8125rem; }

/* The 18+ and terms tick: a large, unticked box */
.ac-check { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--tt-line-2); background: var(--tt-bg); cursor: pointer; font-size: .9375rem; line-height: 1.45; color: var(--tt-ink); transition: border-color var(--d-fast), background-color var(--d-fast); }
.ac-check:hover { border-color: var(--tt-brand); }
.ac-check:has(input:checked) { border-color: var(--tt-brand); background: var(--tt-brand-soft); }
.ac-check input { margin: 0; width: 24px; height: 24px; flex: none; accent-color: var(--tt-brand); cursor: pointer; }
.ac-check a { color: var(--tt-brand); }
.ac-check[data-invalid] { border-color: var(--tt-fake-ink); }

/* "Continue with Google": neutral button with Google's logo, per Google's sign-in branding guidelines */
.ac-google { width: 100%; background: var(--tt-surface); color: var(--tt-ink); border-color: var(--tt-line-2); gap: 12px; }
.ac-google:hover { border-color: var(--tt-brand); }
.ac-google img { width: 20px; height: 20px; flex: none; }
.ac-google[aria-disabled="true"] img { opacity: .45; }
.ac-hint { font-size: .875rem; color: var(--tt-ink-3); margin-top: -6px; }
.ac-note { font-size: .875rem; }
.ac-msg { font-size: .9375rem; font-weight: var(--w-semi); line-height: 1.45; }
.ac-msg:empty { display: none; }
.ac-msg.is-err { color: var(--tt-fake-ink); }
.ac-msg.is-ok { color: var(--tt-real-ink); }
.ac-off { padding: 16px 18px; border-radius: 12px; background: var(--tt-surface-2); color: var(--tt-ink); line-height: 1.5; }
.ac-off b { display: block; margin-bottom: 4px; }
.ac-or { display: flex; align-items: center; gap: 12px; color: var(--tt-ink-3); font-size: .8125rem; font-family: var(--f-mono); letter-spacing: .12em; text-transform: uppercase; }
.ac-or::before, .ac-or::after { content: ""; flex: 1; height: 1px; background: var(--tt-line-2); }
.ac-link { font-weight: var(--w-semi); color: var(--tt-brand); text-underline-offset: 3px; }
.ac-plain { padding-top: 14px; border-top: 1px solid var(--tt-line); font-size: .9375rem; }
.ac-plain b { color: var(--tt-ink); }

/* Account page */
.ac-rows { display: grid; gap: 0; margin: 0; }
.ac-rows > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 14px 0; border-bottom: 1px solid var(--tt-line); }
.ac-rows > div:first-child { padding-top: 0; }
.ac-rows > div:last-child { border-bottom: 0; padding-bottom: 0; }
.ac-rows dt { color: var(--tt-ink-3); font-size: .9375rem; }
.ac-rows dd { margin: 0; color: var(--tt-ink); font-weight: var(--w-semi); overflow-wrap: anywhere; }
.ac-offer { font-size: .875rem; padding: 12px 14px; border-radius: 12px; border: 1px dashed var(--tt-brand-line); background: var(--tt-brand-soft); }
.ac-offer b { color: var(--tt-ink); }

/* On/off switch: a real checkbox with role="switch", drawn with CSS */
.ac-switch { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; cursor: pointer; }
.ac-switch span { color: var(--tt-ink-2); line-height: 1.5; }
.ac-switch span b { display: block; color: var(--tt-ink); font-weight: var(--w-semi); margin-bottom: 2px; }
.ac-switch input { appearance: none; -webkit-appearance: none; margin: 2px 0 0; flex: none; width: 52px; height: 32px; border-radius: var(--r-pill); background: var(--tt-surface-2); border: 1px solid var(--tt-line-2); position: relative; cursor: pointer; transition: background-color var(--d-fast), border-color var(--d-fast); }
.ac-switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--tt-ink-3); transition: transform 200ms var(--ease-ui, ease), background-color var(--d-fast); }
.ac-switch input:checked { background: var(--tt-brand); border-color: var(--tt-brand); }
.ac-switch input:checked::after { transform: translateX(20px); background: var(--tt-brand-ink); }
.ac-switch input:disabled { opacity: .6; cursor: progress; }
.ac-state { font-size: .875rem; font-weight: var(--w-semi); color: var(--tt-ink-3); }

.ac-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.ac-danger { border: 1px solid color-mix(in oklab, var(--tt-fake-ink) 35%, transparent); }
.tt-btn.ac-btn-danger { background: var(--tt-fake-ink); color: var(--tt-surface); border-color: transparent; }
.tt-btn.ac-btn-danger:hover { background: color-mix(in oklab, var(--tt-fake-ink) 86%, var(--tt-ink)); }
.ac-btn-danger::before { display: none; }
.ac-confirm { display: grid; gap: 14px; padding: 16px 18px; border-radius: 12px; background: var(--tt-fake-soft); }
.ac-confirm[hidden] { display: none; }
.ac-confirm p { color: var(--tt-ink); }
.ac-skel { height: 220px; border-radius: var(--r-2); background: var(--tt-surface-2); }

@media (max-width: 900px) {
  .ac-grid { grid-template-columns: 1fr; grid-template-areas: "head" "card" "facts"; row-gap: 28px; }
  .ac-grid .ac-facts { margin-top: 0; }
  .ac-title { max-width: 18ch; }
}
@media (max-width: 480px) { .ac-actions .tt-btn { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .ac-switch input::after { transition: none; } }
html.calm .ac-switch input::after { transition: none; }
.ac-block { margin-top: 32px; }
.ac-form { display: grid; gap: 16px; }
.ac-form[hidden], .ac-card[hidden] { display: none; }

/* Peep (D32) peeks over the top edge of the card: his cut-off line sits on the card's edge, so he never covers it. */
.ac-grid__card, .ac-stack { position: relative; }
.ac-grid__card { margin-top: 56px; }
.ac-stack { padding-top: 40px; }
.ac-peep { position: absolute; right: clamp(20px, 4vw, 36px); bottom: 100%; width: 92px; height: auto; pointer-events: none; }
.ac-stack > .ac-peep { bottom: auto; top: calc(40px + 32px); translate: 0 -100%; } /* the stack's padding plus .ac-block's margin */

.ac-peepbox { display: block; aspect-ratio: 140 / 98; }
.ac-peepbox > svg { display: block; width: 100%; height: 100%; }
