/* =====================================================================
   Free Video Chat Call — design system  (prefix bcn)
   Concept: cool Swiss studio — Ink & Citron (A-12), Swiss Minimal (C-7),
   Wix Madefor (B-7), Swiss-flat edges (E2-5), hairline header (E1-3).
   ===================================================================== */

:root {
	--bg: #FAFAF2;
	--surface: #FFFFFE;
	--tint: #F3F4E4;            /* section bg swap (accent strategy 2) */
	--text: #20240F;
	--muted: #5C6147;
	--accent: #6E711C;         /* CTA background (white text ~4.8:1 AA) */
	--accent-text: #FFFFFE;
	--accent2: #D9DB8A;        /* light citron tint — borders/fills, not text */
	--link: #5B5E18;           /* link + small accent text (~6:1 AA in light) */
	--line: rgba(32, 36, 15, .14);
	--line-strong: rgba(32, 36, 15, .24);

	--shell: 1180px;
	--col: 44rem;              /* reading column — rem, never ch */
	--gate-col: 60rem;

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

	--step--1: .84rem;
	--step-0: 1rem;
	--step-1: 1.2rem;
	--step-2: clamp(1.3rem, 1.05rem + 1.1vw, 1.6rem);
	--step-3: clamp(1.65rem, 1.25rem + 1.8vw, 2.15rem);
	--step-4: clamp(2.1rem, 1.5rem + 2.8vw, 3.1rem);

	--radius: 8px;             /* Swiss flat */
	--radius-sm: 6px;
	--pad: clamp(16px, 4vw, 32px);
}

:root[data-theme="dark"] {
	--bg: #16170F;
	--surface: #1F2115;
	--tint: #23241A;
	--text: #ECEDE0;
	--muted: #B5B79A;
	--accent: #9A9E2E;         /* citron button — dark text in dark mode */
	--accent-text: #16170F;
	--accent2: #4A4C22;
	--link: #BCC05A;           /* ~8:1 on dark bg */
	--line: rgba(236, 237, 224, .14);
	--line-strong: rgba(236, 237, 224, .26);
}

/* ---------- base ---------- */

body {
	background: var(--bg);
	color: var(--text);
	font-family: "Wix Madefor Text", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	font-size: var(--step-0);
	line-height: 1.65;
	transition: background-color .25s ease, color .25s ease;
}

h1, h2, h3, .bcn-brand__name {
	font-family: "Wix Madefor Display", "Wix Madefor Text", system-ui, sans-serif;
	line-height: 1.15;
	letter-spacing: -.01em;
}

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 3px; }

.bcn-shell { max-width: var(--shell); margin-inline: auto; padding-inline: var(--pad); }
.bcn-narrow { max-width: var(--col); }

.bcn-eyebrow,
.bcn-gate__eyebrow,
.bcn-sheet__label {
	font-size: var(--step--1);
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--link);
	font-weight: 500;
	margin: 0;
}

.bcn-skip {
	position: absolute; left: -9999px; top: 0;
	background: var(--surface); color: var(--text);
	padding: var(--s3) var(--s4); border: 1px solid var(--line-strong); border-radius: var(--radius);
	z-index: 20;
}
.bcn-skip:focus { left: var(--s4); top: var(--s4); }

/* ---------- buttons ---------- */

.bcn-btn {
	display: inline-flex; align-items: center; gap: var(--s2);
	background: var(--accent); color: var(--accent-text);
	font-family: "Wix Madefor Display", sans-serif;
	font-weight: 600; font-size: var(--step-0);
	line-height: 1.1;
	padding: 14px 22px; min-height: 48px;
	border: 0; border-radius: var(--radius);
	text-decoration: none; cursor: pointer;
	transition: background-color .2s ease, transform .15s ease;
}
.bcn-btn:hover { background: var(--text); color: var(--bg); }
.bcn-btn--sm { min-height: 40px; padding: 9px 16px; font-size: var(--step--1); }
.bcn-btn__arrow { width: 20px; height: 20px; stroke: currentColor; transition: transform .2s ease; }
.bcn-btn--go:hover .bcn-btn__arrow { transform: translateX(4px); }

/* icon-only buttons: FIXED size, grid-centered. No svg max-width anywhere
   (that collapses these to 0 on iOS). */
.bcn-icobtn {
	display: inline-grid; place-items: center;
	width: 44px; height: 44px;
	background: transparent; border: 1px solid transparent; border-radius: var(--radius);
	color: var(--text); cursor: pointer;
	transition: background-color .2s ease, border-color .2s ease;
}
.bcn-icobtn:hover { background: var(--tint); border-color: var(--line); }
.bcn-icobtn svg { width: 22px; height: 22px; stroke: currentColor; }

/* burger icon: one line + two pseudo-lines, morphs to a cross when open */
.bcn-burger__box { position: relative; display: block; width: 22px; height: 16px; }
.bcn-burger__line,
.bcn-burger__line::before,
.bcn-burger__line::after {
	position: absolute; left: 0; width: 22px; height: 2px;
	background: currentColor; border-radius: 2px;
	transition: transform .25s ease, opacity .2s ease, background-color .2s ease;
}
.bcn-burger__line { top: 50%; transform: translateY(-50%); }
.bcn-burger__line::before { content: ""; top: -7px; }
.bcn-burger__line::after { content: ""; top: 7px; }
.bcn-burger[aria-expanded="true"] .bcn-burger__line { background: transparent; }
.bcn-burger[aria-expanded="true"] .bcn-burger__line::before { top: 0; transform: rotate(45deg); }
.bcn-burger[aria-expanded="true"] .bcn-burger__line::after { top: 0; transform: rotate(-45deg); }

/* ---------- header (E1-3 hairline) ---------- */

.bcn-header {
	position: sticky; top: 0; z-index: 10;
	background: transparent;
	transition: background-color .25s ease, border-color .25s ease;
	border-bottom: 1px solid transparent;
}
.bcn-header--solid {
	background: var(--bg);
	background: color-mix(in srgb, var(--bg) 88%, transparent);
	backdrop-filter: saturate(140%) blur(8px);
	border-bottom-color: var(--line);
}
.bcn-header__inner {
	max-width: var(--shell); margin-inline: auto; padding: var(--s3) var(--pad);
	display: flex; align-items: center; justify-content: space-between; gap: var(--s4);
}
.bcn-brand { display: inline-flex; align-items: center; gap: var(--s3); text-decoration: none; color: var(--text); min-width: 0; }
.bcn-brand__mark { display: inline-grid; place-items: center; width: 32px; height: 32px; flex: 0 0 auto; }
.bcn-brand__mark svg { width: 32px; height: 32px; }
.bcn-ico-dot { fill: var(--accent); }
.bcn-ico-arc { stroke: var(--text); }
.bcn-ico-arc--soft { stroke: var(--muted); opacity: .6; }
.bcn-brand__name {
	font-weight: 700; font-size: 1.05rem; letter-spacing: -.01em;
	white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.bcn-header__actions { display: flex; align-items: center; gap: var(--s2); flex: 0 0 auto; }

/* desktop language dropdown */
.bcn-lang--desk { position: relative; }
.bcn-lang__toggle {
	display: inline-flex; align-items: center; gap: 6px;
	background: transparent; border: 0; color: var(--text); cursor: pointer;
	font-family: "Wix Madefor Text", sans-serif; font-size: var(--step-0);
	padding: 10px 8px; min-height: 44px;
}
.bcn-chev { width: 16px; height: 16px; stroke: currentColor; transition: transform .2s ease; }
.bcn-lang--desk[data-open="true"] .bcn-chev { transform: rotate(180deg); }
.bcn-lang__menu {
	position: absolute; top: calc(100% + 6px); right: 0;
	min-width: 200px; background: var(--surface);
	border: 1px solid var(--line-strong); border-radius: var(--radius);
	padding: var(--s2); display: none;
}
.bcn-lang--desk[data-open="true"] .bcn-lang__menu { display: block; }

.bcn-lang__list { list-style: none; margin: 0; padding: 0; }
.bcn-lang__list li { margin: 0; }
.bcn-lang__list a {
	display: flex; align-items: center; gap: var(--s2);
	padding: 10px 12px; min-height: 44px; border-radius: var(--radius-sm);
	color: var(--text); text-decoration: none; font-size: var(--step-0);
}
.bcn-lang__list a:hover { background: var(--tint); }
.bcn-lang__list img { width: 20px; height: auto; border-radius: 2px; }

/* ---------- mobile sheet + scrim ---------- */

.bcn-scrim {
	position: fixed; inset: 0; z-index: 40;
	background: rgba(20, 22, 10, .42);
	opacity: 0; transition: opacity .25s ease;
}
.bcn-scrim.is-open { opacity: 1; }

.bcn-sheet {
	position: fixed; top: 0; right: 0; z-index: 41;
	width: min(84vw, 340px); height: 100dvh;
	background: var(--surface); border-left: 1px solid var(--line-strong);
	padding: var(--s5) var(--pad) var(--s7);
	transform: translateX(100%); transition: transform .28s ease;
	display: flex; flex-direction: column; gap: var(--s4);
	overflow-y: auto;
}
.bcn-sheet.is-open { transform: translateX(0); }
.bcn-sheet__head { display: flex; align-items: center; justify-content: space-between; }
.bcn-sheet__title { font-family: "Wix Madefor Display", sans-serif; font-weight: 600; font-size: var(--step-1); }
.bcn-sheet__label { margin-top: var(--s2); }

/* ---------- gate (D-3 Editorial Caret, Swiss) ---------- */

.bcn-gate {
	max-width: var(--gate-col); margin-inline: auto;
	margin-block: var(--s7) var(--s6);
	padding-inline: var(--pad);
}
.bcn-gate__card {
	position: relative; overflow: hidden;
	background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius);
	padding: clamp(28px, 5vw, 56px);
}
.bcn-gate__eyebrow { margin-bottom: var(--s4); }
.bcn-gate__q {
	font-family: "Wix Madefor Display", sans-serif;
	font-weight: 600; font-size: var(--step-3); line-height: 1.2;
	max-width: 20ch; margin: 0 0 var(--s5);
}
.bcn-gate__caret {
	display: inline-block; width: 3px; height: .95em;
	background: var(--accent); margin-left: 4px; vertical-align: -.08em;
	animation: bcn-blink 1.05s steps(2, jump-none) infinite;
}
.bcn-gate__row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s4); }
.bcn-gate__note { margin: 0; color: var(--muted); font-size: var(--step--1); }
.bcn-gate__fig {
	position: absolute; right: clamp(16px, 4vw, 40px); top: 50%; transform: translateY(-50%);
	font-family: "Wix Madefor Display", sans-serif; font-weight: 700;
	font-size: clamp(72px, 16vw, 168px); line-height: 1;
	color: transparent; -webkit-text-stroke: 2px var(--line-strong); text-stroke: 2px var(--line-strong);
	pointer-events: none; user-select: none;
}
@keyframes bcn-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* ---------- main slabs ---------- */

.bcn-main { display: block; }
.bcn-slab { padding-block: var(--s7); }
.bcn-slab--plain { padding-block: var(--s8); }

/* the homepage article is rendered inside .bcn-entry */
.bcn-entry {
	padding-block: var(--s6) var(--s8);
	padding-inline: var(--pad);
}

/* READING COLUMN — zero-specificity so components override it; only the gate
   is exempt. Never blanket margin:0 a direct child (that strips this). */
.bcn-entry > :where(*:not(.bcn-gate)) {
	max-width: var(--col);
	margin-inline: auto;
}
/* explicit re-centre at higher specificity so no later reset can left-align
   these classed blocks (the recurring "chips/list run past the text" bug) */
.bcn-entry > .bcn-figure,
.bcn-entry > .wp-block-list,
.bcn-entry > .wp-block-quote {
	max-width: var(--col);
	margin-inline: auto;
}

.bcn-entry > * + * { margin-block-start: var(--s5); }
.bcn-entry h1 { font-size: var(--step-4); margin-block: var(--s2) var(--s3); scroll-margin-top: 90px; }
.bcn-entry h2 {
	font-size: var(--step-2); margin-block: var(--s7) 0; scroll-margin-top: 90px;
	padding-top: var(--s5); border-top: 1px solid var(--line);
}
.bcn-entry h2 + * { margin-block-start: var(--s3); }
.bcn-entry p { color: var(--text); }
.bcn-entry p + p { margin-block-start: var(--s4); }

/* links inside prose keep the underline; buttons are excluded by class specificity */
.bcn-entry a:not([class]) {
	color: var(--link);
	background-image: linear-gradient(currentColor, currentColor);
	background-size: 0% 1.5px; background-position: 0 100%; background-repeat: no-repeat;
	text-decoration: none;
	transition: background-size .25s ease;
}
.bcn-entry a:not([class]):hover { background-size: 100% 1.5px; }

/* Gutenberg list — style markers WITHOUT a blanket margin:0 */
.bcn-entry .wp-block-list {
	padding-inline-start: 1.4em;
	list-style: disc;
}
.bcn-entry .wp-block-list li { margin-block: var(--s2); }
.bcn-entry .wp-block-list li::marker { color: var(--accent); }

/* pull-quote */
.bcn-pull {
	border: 0; border-left: 3px solid var(--accent);
	background: var(--tint);
	padding: var(--s5) var(--s6);
	border-radius: 0 var(--radius) var(--radius) 0;
}
.bcn-pull p {
	font-family: "Wix Madefor Display", sans-serif;
	font-weight: 600; font-size: var(--step-2); line-height: 1.35; margin: 0;
}

/* ---------- illustration (H-10 signal waves) ---------- */

.bcn-figure { margin-block: var(--s6); }
.bcn-illus { width: 100%; height: auto; display: block; }
.bcn-illus__wave { stroke: var(--accent); stroke-width: 2.4; opacity: .9; }
.bcn-illus__wave--soft { stroke: var(--muted); opacity: .45; }
.bcn-illus__rule { stroke: var(--line-strong); stroke-width: 1.5; }
.bcn-illus__origin { fill: var(--accent); }
.bcn-illus__node { fill: none; stroke: var(--text); stroke-width: 2.4; }
.bcn-illus__pip { fill: var(--accent); }
.bcn-illus__reach { stroke: var(--muted); }
.bcn-illus__tile { fill: var(--tint); stroke: var(--line-strong); stroke-width: 1.5; }

/* ---------- footer ---------- */

.bcn-footer { border-top: 1px solid var(--line); margin-top: var(--s8); }
.bcn-footer__inner {
	max-width: var(--shell); margin-inline: auto; padding: var(--s6) var(--pad);
	display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4);
}
.bcn-foot__copy { margin: 0; color: var(--muted); font-size: var(--step--1); }
.bcn-foot__links { list-style: none; display: flex; flex-wrap: wrap; gap: var(--s5); margin: 0; padding: 0; }
.bcn-foot__links li { margin: 0; }
.bcn-foot__links a { color: var(--text); text-decoration: none; font-size: var(--step--1); }
.bcn-foot__links a:hover { color: var(--link); }

/* ---------- cookie ---------- */

.bcn-cookie {
	position: fixed; left: 50%; bottom: var(--s4); transform: translateX(-50%) translateY(12px);
	z-index: 30; width: min(680px, calc(100vw - 2 * var(--s4)));
	background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius);
	padding: var(--s4) var(--s5);
	display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4);
	opacity: 0; transition: opacity .3s ease, transform .3s ease;
}
.bcn-cookie.is-open { opacity: 1; transform: translateX(-50%) translateY(0); }
.bcn-cookie__text { margin: 0; font-size: var(--step--1); color: var(--muted); max-width: 46ch; }
.bcn-cookie__text a { color: var(--link); }
.bcn-cookie__ok { flex: 0 0 auto; }

/* ---------- 404 ---------- */

.bcn-404 { text-align: center; }
.bcn-404__fig { font-family: "Wix Madefor Display", sans-serif; font-weight: 700; font-size: clamp(72px, 20vw, 200px); line-height: 1; color: transparent; -webkit-text-stroke: 2px var(--line-strong); margin: var(--s4) 0; }
.bcn-404 .bcn-btn { margin-top: var(--s4); }
.bcn-page-title { font-size: var(--step-4); margin-bottom: var(--s5); }

/* ---------- theme toggle icons ---------- */

.bcn-theme .bcn-sun, .bcn-theme .bcn-moon { stroke: currentColor; fill: none; transition: opacity .2s ease, transform .3s ease; grid-area: 1 / 1; }
.bcn-theme { display: inline-grid; }
.bcn-theme svg { grid-area: 1 / 1; }
:root[data-theme="dark"] .bcn-theme .bcn-sun { opacity: 1; transform: rotate(0); }
:root[data-theme="dark"] .bcn-theme .bcn-moon { opacity: 0; transform: rotate(-40deg) scale(.6); }
:root:not([data-theme="dark"]) .bcn-theme .bcn-sun { opacity: 0; transform: rotate(40deg) scale(.6); }
:root:not([data-theme="dark"]) .bcn-theme .bcn-moon { opacity: 1; transform: rotate(0); }

/* ---------- custom scrollbar (F-12) ---------- */

* { scrollbar-color: var(--accent2) transparent; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: var(--accent2); border-radius: 99px; border: 3px solid var(--bg); }
::-webkit-scrollbar-track { background: transparent; }
::selection { background: var(--accent2); color: var(--text); }

/* ---------- responsive ---------- */

.bcn-burger { display: none; }

@media (max-width: 768px) {
	/* hide ONLY the desktop dropdown — scope keeps the in-sheet list visible */
	.bcn-header__actions .bcn-lang--desk { display: none; }
	.bcn-burger { display: inline-grid; }
	.bcn-gate__fig { opacity: .5; font-size: clamp(64px, 22vw, 120px); }
	.bcn-footer__inner { flex-direction: column; align-items: flex-start; }
}

@media (min-width: 769px) {
	.bcn-sheet, .bcn-scrim { display: none; }
}

/* ---------- motion / a11y ---------- */

@media (prefers-reduced-motion: no-preference) {
	html { scroll-behavior: smooth; }   /* F-16 smooth anchors */
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
	.bcn-gate__caret { animation: none; opacity: 1; }
}
