/* =========================================================================
   Anonymous Video Chat (Frost) — design system
   Direction C-1 Soft Glassmorphism · Palette A-3 Peach Cloud · Fonts B-11 Geologica+Rubik
   Edges E2-3 Pill & feather · Header E1-5 Centered · Accent strategy 2 (tinted surfaces)
   ========================================================================= */

:root {
	--frs-bg:      #FBF5F0;
	--frs-surface: #FFFDFB;
	--frs-text:    #33231B;
	--frs-muted:   #6E5A4D;
	--frs-accent:  #A04F34;   /* tonal shift from A-3 #B05C3E so accent passes AA as TEXT, not only as a button bg */
	--frs-accent2: #F2C4A8;
	--frs-link:    #A04F34;   /* split from --accent so dark mode can lighten it (dark-accent-as-link trap) */
	--frs-on-accent: #FFFFFF;
	--frs-gate-note: #574334; /* darker than --muted so it clears AA on the peach gate gradient (worst 6.28) */
	--frs-grad: linear-gradient(135deg, #FDF1E7, #F9E0CD 50%, #F3CDB2);

	--frs-glass:      rgba(255, 253, 251, 0.55);
	--frs-glass-brd:  rgba(255, 255, 255, 0.72);
	--frs-tint:       rgba(160, 79, 52, 0.06);   /* accent-2 style tinted surface */
	--frs-tint-strong:rgba(160, 79, 52, 0.10);
	--frs-hair:       rgba(51, 35, 27, 0.12);
	--frs-blob-a: rgba(242, 196, 168, 0.55);
	--frs-blob-b: rgba(160, 79, 52, 0.14);

	--frs-font-head: "Geologica", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
	--frs-font-body: "Rubik", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;

	--frs-s1: 4px; --frs-s2: 8px; --frs-s3: 12px; --frs-s4: 16px;
	--frs-s5: 24px; --frs-s6: 32px; --frs-s7: 48px; --frs-s8: 64px;

	--frs-col: 44rem;
	--frs-container: 1160px;
	--frs-pad: clamp(16px, 4vw, 32px);
	--frs-r-card: 20px;
	--frs-r-pill: 999px;
	--frs-shadow: 0 2px 12px rgba(51, 35, 27, 0.05);
	--frs-shadow-lift: 0 10px 30px rgba(51, 35, 27, 0.10);
	--frs-header-h: 66px;
}

[data-theme="dark"] {
	--frs-bg:      #1E1611;
	--frs-surface: #281D16;
	--frs-text:    #F2E7DF;
	--frs-muted:   #C4AB9B;
	--frs-accent:  #A8552F;
	--frs-accent2: #E0A983;
	--frs-link:    #E7A981;   /* lightened so links clear AA on the dark bg */
	--frs-on-accent: #FFFFFF; /* white clears AA on the dark accent #A8552F (5.24); a dark ink there fails */
	--frs-gate-note: #C4AB9B; /* dark gate gradient is dark -> the muted tone reads fine here */
	--frs-grad: linear-gradient(135deg, #2A1E16, #33241A 50%, #3C2A1E);

	--frs-glass:      rgba(40, 29, 22, 0.55);
	--frs-glass-brd:  rgba(255, 255, 255, 0.10);
	--frs-tint:       rgba(224, 169, 131, 0.08);
	--frs-tint-strong:rgba(224, 169, 131, 0.13);
	--frs-hair:       rgba(242, 231, 223, 0.14);
	--frs-blob-a: rgba(168, 85, 47, 0.30);
	--frs-blob-b: rgba(224, 169, 131, 0.12);

	--frs-shadow: 0 2px 14px rgba(0, 0, 0, 0.35);
	--frs-shadow-lift: 0 12px 34px rgba(0, 0, 0, 0.45);
}

/* ---- base ---- */
[hidden] { display: none !important; }   /* attribute must always beat a component display: rule (tap-trap guard) */

html { scroll-behavior: auto; }
body {
	margin: 0;
	background: var(--frs-bg);
	color: var(--frs-text);
	font-family: var(--frs-font-body);
	font-size: 1.0625rem;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

h1, h2, h3 { font-family: var(--frs-font-head); line-height: 1.2; color: var(--frs-text); font-weight: 700; }
strong { font-weight: 600; color: var(--frs-text); }

:focus-visible { outline: 2px solid var(--frs-accent); outline-offset: 2px; border-radius: 4px; }

.frs-skip {
	position: absolute; left: -9999px; top: 0; z-index: 100;
	background: var(--frs-surface); color: var(--frs-text);
	padding: var(--frs-s3) var(--frs-s4); border-radius: 0 0 12px 0;
}
.frs-skip:focus { left: 0; }

/* =========================================================================
   Layout + reading column
   ========================================================================= */
.frs-entry {
	max-width: var(--frs-container);
	margin: 0 auto;
	padding: 0 var(--frs-pad) var(--frs-s8);
}
/* Zero-specificity column rule: every block except the gate shares the same centered 44rem edges. */
.frs-entry > :where(*:not(.frs-gate)) {
	max-width: var(--frs-col);
	margin-inline: auto;
}
/* Headings: touch block margins only — never margin-inline (that would break centering). */
.frs-entry > h1, .frs-entry > h2 { margin-block: var(--frs-s7) var(--frs-s4); }
.frs-entry > p { margin-block: 0 var(--frs-s4); }
.frs-entry > h1 { margin-block-top: var(--frs-s6); }

.frs-entry h1 { font-size: clamp(1.9rem, 1.3rem + 3vw, 2.9rem); font-weight: 800; letter-spacing: -0.01em; }
.frs-entry h2 { font-size: clamp(1.4rem, 1.1rem + 1.6vw, 1.9rem); }
:where(h1, h2, h3)[id], .frs-entry h1, .frs-entry h2 { scroll-margin-top: calc(var(--frs-header-h) + 20px); }

/* Entry links get the accent + an underline — but NOT anything with a class (buttons/CTAs). */
.frs-entry a:not([class]) {
	color: var(--frs-link);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	background-image: none;
}
.frs-entry a:not([class]):hover { text-decoration-thickness: 2px; }

/* Gutenberg lists are .wp-block-list — style them explicitly (a ul:not([class]) reset would miss them). */
.frs-entry .wp-block-list {
	margin: 0 auto var(--frs-s5);
	padding-left: 1.2em;
	max-width: var(--frs-col);
}
.frs-entry .wp-block-list li { margin-block: 0 var(--frs-s2); }

.frs-inline-cta, .frs-page-title { }
.frs-inline-cta {
	display: inline-block; color: var(--frs-on-accent); background: var(--frs-accent);
	padding: 10px 18px; border-radius: var(--frs-r-pill); text-decoration: none; font-weight: 500;
}

/* =========================================================================
   Header (E1-5 Centered) — sticky glass, 3-column grid so the brand stays centered
   ========================================================================= */
.frs-header {
	position: sticky; top: 0; z-index: 30;
	background: var(--frs-glass);
	border-bottom: 1px solid var(--frs-hair);
	backdrop-filter: blur(14px) saturate(150%);
	-webkit-backdrop-filter: blur(14px) saturate(150%);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
	.frs-header { background: var(--frs-surface); }
}
.frs-header__bar {
	max-width: var(--frs-container); margin: 0 auto;
	min-height: var(--frs-header-h);
	padding: 0 var(--frs-pad);
	display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--frs-s3);
}
.frs-header__start { justify-self: start; min-width: 0; }
.frs-header__end { justify-self: end; display: flex; align-items: center; gap: var(--frs-s2); }

.frs-brand {
	justify-self: center; min-width: 0; max-width: 100%;
	display: inline-flex; align-items: center; gap: var(--frs-s2);
	text-decoration: none; color: var(--frs-text);
}
.frs-brand__icon { display: inline-grid; place-items: center; flex: 0 0 auto; color: var(--frs-text); }
.frs-brand__name {
	font-family: var(--frs-font-head); font-weight: 700; font-size: clamp(0.95rem, 0.8rem + 0.9vw, 1.2rem);
	letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}

/* Icon-only buttons: fixed size, grid-centered. NEVER let the svg reset carry max-width (iOS 0-width trap). */
.frs-toggle, .frs-burger, .frs-sheet__close {
	display: inline-grid; place-items: center; width: 44px; height: 44px;
	border: 0; background: transparent; color: var(--frs-text); cursor: pointer; border-radius: 12px;
}
.frs-toggle:hover, .frs-burger:hover, .frs-sheet__close:hover { background: var(--frs-tint); }
.frs-toggle svg { display: block; }
.frs-toggle__moon { display: none; }
[data-theme="dark"] .frs-toggle__sun { display: none; }
[data-theme="dark"] .frs-toggle__moon { display: block; }

.frs-burger { display: none; }
.frs-burger__box { position: relative; width: 22px; height: 16px; }
.frs-burger__line {
	position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px; background: currentColor;
	transition: transform .25s ease, opacity .2s ease, top .25s ease;
}
.frs-burger__line:nth-child(1) { top: 0; }
.frs-burger__line:nth-child(2) { top: 7px; }
.frs-burger__line:nth-child(3) { top: 14px; }
body.frs-sheet-open .frs-burger__line:nth-child(1) { top: 7px; transform: rotate(45deg); }
body.frs-sheet-open .frs-burger__line:nth-child(2) { opacity: 0; }
body.frs-sheet-open .frs-burger__line:nth-child(3) { top: 7px; transform: rotate(-45deg); }

/* Language dropdown (desktop) */
.frs-lang { position: relative; }
.frs-lang__toggle {
	display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--frs-hair);
	background: var(--frs-surface); color: var(--frs-text); padding: 8px 14px;
	border-radius: var(--frs-r-pill); cursor: pointer; font-size: 0.95rem;
}
.frs-lang__toggle:hover { border-color: var(--frs-accent2); }
.frs-lang__chev { transition: transform .2s ease; }
.frs-lang__toggle[aria-expanded="true"] .frs-lang__chev { transform: rotate(180deg); }
.frs-lang__menu {
	position: absolute; top: calc(100% + 8px); left: 0; z-index: 20;
	background: var(--frs-surface); border: 1px solid var(--frs-hair); border-radius: 14px;
	box-shadow: var(--frs-shadow-lift); padding: 8px; min-width: 190px;
}
.frs-lang__list { list-style: none; margin: 0; padding: 0; }
.frs-lang__list li a, .frs-lang__list li > * {
	display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 10px;
	border-radius: 10px; text-decoration: none; color: var(--frs-text);
}
.frs-lang__list li a:hover { background: var(--frs-tint); }
.frs-lang__list img { width: 20px; height: auto; border-radius: 2px; }

/* =========================================================================
   Mobile sheet
   ========================================================================= */
.frs-sheet { position: fixed; inset: 0; z-index: 40; }
.frs-sheet__scrim { position: absolute; inset: 0; background: rgba(20, 12, 8, 0.42); opacity: 0; transition: opacity .28s ease; }
.frs-sheet__panel {
	position: absolute; top: 0; right: 0; z-index: 41; height: 100%; width: min(86vw, 340px);
	background: var(--frs-surface); border-left: 1px solid var(--frs-hair);
	box-shadow: var(--frs-shadow-lift); padding: var(--frs-s5) var(--frs-s5) var(--frs-s6);
	transform: translateX(100%); transition: transform .3s cubic-bezier(.4,0,.2,1); overflow-y: auto;
}
body.frs-sheet-open .frs-sheet__scrim { opacity: 1; }
body.frs-sheet-open .frs-sheet__panel { transform: translateX(0); }
.frs-sheet__close { position: absolute; top: 12px; right: 12px; }
.frs-sheet__label {
	font-family: var(--frs-font-head); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase;
	color: var(--frs-muted); margin: var(--frs-s5) 0 var(--frs-s2);
}
.frs-sheet__label:first-of-type { margin-top: var(--frs-s6); }
.frs-sheet__links { list-style: none; margin: 0; padding: 0; }
.frs-sheet__links a, .frs-sheet .frs-lang__list li a, .frs-sheet .frs-lang__list li > * {
	display: flex; align-items: center; min-height: 44px; text-decoration: none; color: var(--frs-text);
}
.frs-sheet__links a:hover { color: var(--frs-link); }

/* =========================================================================
   Age gate (D-1 Aurora Veil) — full-width band that dissolves into the page
   ========================================================================= */
.frs-gate {
	position: relative; overflow: hidden;
	margin: 0 calc(var(--frs-pad) * -1) var(--frs-s7);
	padding: clamp(48px, 8vw, 96px) var(--frs-pad) clamp(64px, 10vw, 120px);
	background: var(--frs-grad);
	text-align: center;
}
.frs-gate::after { /* dissolve the band's bottom into the page bg */
	content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 46%;
	background: linear-gradient(to bottom, transparent, var(--frs-bg));
	pointer-events: none;
}
.frs-gate__blobs { position: absolute; inset: -10% -5%; z-index: 0; pointer-events: none; }
.frs-gate__blobs span {
	position: absolute; width: 42vmax; height: 42vmax; border-radius: 50%; filter: blur(60px); opacity: .7;
}
.frs-gate__blobs span:nth-child(1) { background: var(--frs-blob-a); top: -20%; left: -10%; animation: frs-drift1 22s ease-in-out infinite; }
.frs-gate__blobs span:nth-child(2) { background: var(--frs-blob-b); bottom: -25%; right: -8%; animation: frs-drift2 26s ease-in-out infinite; }
.frs-gate__blobs span:nth-child(3) { background: var(--frs-accent2); top: 20%; right: 25%; opacity: .35; animation: frs-drift1 30s ease-in-out infinite reverse; }
@keyframes frs-drift1 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(6%, 8%); } }
@keyframes frs-drift2 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(-7%, -5%); } }

.frs-gate__inner { position: relative; z-index: 1; max-width: 640px; margin: 0 auto; display: grid; justify-items: center; gap: var(--frs-s4); }
.frs-gate__badge {
	display: inline-grid; place-items: center; width: 62px; height: 62px; border-radius: var(--frs-r-pill);
	background: var(--frs-accent); color: var(--frs-on-accent); font-family: var(--frs-font-head); font-weight: 800;
	font-size: 1.25rem; box-shadow: var(--frs-shadow);
}
.frs-gate__trust { color: var(--frs-gate-note); font-size: 0.98rem; margin: 0; max-width: 42ch; }
.frs-gate__q { font-size: clamp(1.35rem, 1.05rem + 1.6vw, 2rem); margin: 0; color: var(--frs-text); }
.frs-gate__go {
	display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 30px;
	background: var(--frs-accent); color: var(--frs-on-accent); font-weight: 500; font-size: 1.05rem;
	border-radius: var(--frs-r-pill); text-decoration: none; background-image: none;
	box-shadow: var(--frs-shadow-lift); transition: transform .18s ease, filter .18s ease;
}
.frs-gate__go:hover { transform: translateY(-2px); filter: brightness(1.04); }
.frs-gate__foot { color: var(--frs-gate-note); font-size: 0.85rem; margin: 0; max-width: 46ch; }

/* =========================================================================
   Illustration (H-7 webcam lens, frosted glass, faceless, no recording dot)
   ========================================================================= */
.frs-illus { margin: var(--frs-s6) auto var(--frs-s7); }
.frs-illus__svg { width: 100%; height: auto; border-radius: var(--frs-r-card); }
.frs-illus__bg { fill: var(--frs-tint-strong); }
.frs-illus__g0 { stop-color: var(--frs-accent2); stop-opacity: 0.55; }
.frs-illus__g1 { stop-color: var(--frs-surface); stop-opacity: 0.20; }
.frs-illus__glassEdge { fill: none; stroke: var(--frs-glass-brd); stroke-width: 1.5; }
.frs-illus__ring { fill: none; stroke: var(--frs-accent); }
.frs-illus__ring--1 { stroke-width: 3; opacity: 0.85; }
.frs-illus__ring--2 { stroke-width: 2.5; opacity: 0.55; }
.frs-illus__ring--3 { stroke-width: 2; opacity: 0.9; stroke: var(--frs-muted); }
.frs-illus__open { fill: var(--frs-bg); }             /* hollow centre — an aperture that keeps nothing */
.frs-illus__glint { fill: none; stroke: var(--frs-surface); stroke-width: 4; stroke-linecap: round; opacity: 0.8; }

/* =========================================================================
   Chips marquee (F-5) — lives INSIDE the 44rem column and clips its own scroll
   ========================================================================= */
.frs-chips {
	max-width: var(--frs-col); margin: var(--frs-s2) auto var(--frs-s6);
	overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
	padding: 4px 0;
}
.frs-chips__track { display: flex; gap: var(--frs-s3); width: max-content; animation: frs-marquee 34s linear infinite; }
.frs-chips:hover .frs-chips__track { animation-play-state: paused; }
.frs-chips__item {
	flex: 0 0 auto; background: var(--frs-tint); color: var(--frs-text); border: 1px solid var(--frs-hair);
	padding: 8px 16px; border-radius: var(--frs-r-pill); font-size: 0.95rem; white-space: nowrap;
}
@keyframes frs-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* =========================================================================
   Quote callout (accent-2 tinted surface) + norms list
   ========================================================================= */
.frs-quote {
	position: relative; background: var(--frs-tint); border: 1px solid var(--frs-hair);
	border-left: 4px solid var(--frs-accent); border-radius: var(--frs-r-card);
	padding: var(--frs-s6) var(--frs-s6) var(--frs-s6) var(--frs-s7);
	margin: var(--frs-s6) auto; box-shadow: var(--frs-shadow);
}
.frs-quote::before {
	content: "\201C"; position: absolute; top: 2px; left: 16px; font-family: var(--frs-font-head);
	font-size: 3.4rem; line-height: 1; color: var(--frs-accent2);
}
.frs-quote p { margin: 0; font-size: clamp(1.15rem, 1rem + 0.7vw, 1.42rem); font-family: var(--frs-font-head); font-weight: 600; }

.frs-norms {
	background: var(--frs-surface); border: 1px solid var(--frs-hair); border-radius: var(--frs-r-card);
	padding: var(--frs-s5) var(--frs-s5) var(--frs-s5) calc(var(--frs-s5) + 1.2em) !important;
	box-shadow: var(--frs-shadow); list-style: disc;
}
.frs-norms li::marker { color: var(--frs-accent); }

/* =========================================================================
   Footer
   ========================================================================= */
.frs-footer { background: var(--frs-tint); border-top: 1px solid var(--frs-hair); }
.frs-footer__inner {
	max-width: var(--frs-container); margin: 0 auto; padding: var(--frs-s6) var(--frs-pad);
	display: flex; flex-wrap: wrap; gap: var(--frs-s4); align-items: center; justify-content: space-between;
}
.frs-footer__copy { margin: 0; color: var(--frs-muted); font-size: 0.95rem; }
.frs-footer__list { list-style: none; display: flex; flex-wrap: wrap; gap: var(--frs-s5); margin: 0; padding: 0; }
.frs-footer__list a { color: var(--frs-text); text-decoration: none; font-size: 0.95rem; }
.frs-footer__list a:hover { color: var(--frs-link); text-decoration: underline; text-underline-offset: 3px; }

/* =========================================================================
   Cookie banner (compact centered bottom pill) — sits above nothing important on mobile
   ========================================================================= */
.frs-cookie {
	position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%) translateY(20px);
	z-index: 25; width: min(680px, calc(100vw - 24px));
	display: flex; flex-wrap: wrap; align-items: center; gap: var(--frs-s3) var(--frs-s4);
	background: var(--frs-surface); border: 1px solid var(--frs-hair); border-radius: 16px;
	box-shadow: var(--frs-shadow-lift); padding: var(--frs-s4) var(--frs-s5);
	opacity: 0; transition: opacity .3s ease, transform .3s ease;
}
.frs-cookie.frs-cookie--in { opacity: 1; transform: translateX(-50%) translateY(0); }
.frs-cookie__text { margin: 0; flex: 1 1 260px; font-size: 0.92rem; color: var(--frs-muted); }
.frs-cookie__text a { color: var(--frs-link); text-decoration: underline; text-underline-offset: 2px; }
.frs-cookie__ok {
	flex: 0 0 auto; border: 0; cursor: pointer; background: var(--frs-accent); color: var(--frs-on-accent);
	font-weight: 500; padding: 10px 20px; border-radius: var(--frs-r-pill); font-size: 0.95rem;
}
.frs-cookie__ok:hover { filter: brightness(1.05); }

/* =========================================================================
   404
   ========================================================================= */
.frs-404 { max-width: var(--frs-col); margin: 0 auto; padding: clamp(48px,10vw,120px) var(--frs-pad); text-align: center; }
.frs-404__num { font-family: var(--frs-font-head); font-weight: 800; font-size: clamp(5rem, 14vw, 9rem); line-height: 1; margin: 0; color: var(--frs-accent2); }
.frs-404__title { font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2rem); margin: var(--frs-s3) 0 var(--frs-s3); }
.frs-404__text { color: var(--frs-muted); margin: 0 auto var(--frs-s5); max-width: 40ch; }
.frs-404__home {
	display: inline-flex; min-height: 48px; align-items: center; padding: 0 26px; background: var(--frs-accent);
	color: var(--frs-on-accent); border-radius: var(--frs-r-pill); text-decoration: none; font-weight: 500;
}

/* Inner page (Privacy/Terms) */
.frs-entry--page { padding-top: var(--frs-s7); }
.frs-page-title { font-size: clamp(1.8rem, 1.3rem + 2vw, 2.6rem); margin: 0 auto var(--frs-s5); }

/* =========================================================================
   Responsive
   ========================================================================= */
@media (max-width: 768px) {
	/* Only the desktop dropdown hides — the in-sheet list stays visible (scoped, not global). */
	.frs-header__start .frs-lang--desk { display: none; }
	.frs-burger { display: inline-grid; }
	.frs-header__start { justify-self: start; }
}
@media (min-width: 769px) {
	.frs-sheet { display: none !important; }
}
@media (max-width: 400px) {
	.frs-brand__name { font-size: 0.92rem; }
	.frs-header__bar { gap: var(--frs-s2); }
}

/* =========================================================================
   Reduced motion — kill every decorative animation, no smooth scroll
   ========================================================================= */
@media (prefers-reduced-motion: no-preference) {
	html { scroll-behavior: smooth; }
}
@media (prefers-reduced-motion: reduce) {
	.frs-gate__blobs span, .frs-chips__track { animation: none !important; }
	.frs-sheet__panel, .frs-sheet__scrim, .frs-cookie, .frs-gate__go, .frs-burger__line { transition: none !important; }
}
