/* ============================================================
   BF Video Calling — design system
   Palette A-3 Peach Cloud · Direction C-2 Pastel Neo-Brutalism
   Edges E2-2 hard offset · Header E1-2 floating pill
   Gate D-10 Paper Stack · Accent strategy 1 (CTA + links only)
   ============================================================ */

/* ---- 1. Tokens ------------------------------------------- */

:root {
  --bg:      #FBF5F0;
  --surface: #FFFDFB;
  --text:    #33231B;
  --muted:   #6E5A4D;
  /* Bank A-3 ships accent #B05C3E, which the bank only checks as a BUTTON
     BACKGROUND (white-on-accent 4.65). As TEXT it fails AA: 4.37 on --bg and
     3.93 on --tint, so a footer link hover and any link on the Privacy/Terms
     pages would fail. Tonally adapted -1 shade (Bank A permits this, ratios
     kept): as text 5.30/5.65/4.78, and white-on-accent improves to 5.65. */
  --accent:  #A04F34;
  --accent2: #F2C4A8;
  --grad: linear-gradient(135deg, #FDF1E7, #F9E0CD 50%, #F3CDB2);

  /* neo-brutalist outline + the hard offset that replaces every shadow */
  --ink: #1f2430;
  --hard: var(--accent2);
  --tint: #F6E8DC;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;

  /* type scale, ratio 1.25 */
  --t--1: .8rem;
  --t-0:  1rem;
  --t-1:  1.25rem;
  --t-2:  1.563rem;
  --t-3:  1.953rem;

  --r-card: 14px;      /* E2-2: one radius for cards and panels */
  --r-pill: 999px;     /* E1-2's identity — header bar, buttons, chips */
  --line: 2px;
  --off: 4px;

  --col: 44rem;        /* reading column — rem, never ch */
  --head: 'Exo 2', 'Segoe UI', system-ui, sans-serif;
  --body: 'Noto Sans', system-ui, -apple-system, sans-serif;
}

[data-theme="dark"] {
  --bg:      #1E1611;
  --surface: #281D16;
  --text:    #F2E7DF;
  --muted:   #C4AB9B;
  --accent:  #E0A983;   /* light accent + dark text on buttons in dark mode */
  --accent2: #A8552F;
  --grad: linear-gradient(135deg, #2A1E16, #33251B 50%, #3D2C20);

  --ink: #F2E7DF;       /* the outline flips light so the language survives */
  --hard: #A8552F;
  --tint: #2E211A;
}

/* ---- 2. Base --------------------------------------------- */

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: var(--t-0);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--head);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -.01em;
}

/* margin-block only — margin shorthand would zero margin-inline and break
   the centred reading column. */
h1 { font-size: clamp(1.9rem, 1.2rem + 3vw, 2.9rem); margin-block: 0 var(--space-5); }
h2 { font-size: clamp(1.4rem, 1.05rem + 1.6vw, 1.95rem); margin-block: var(--space-7) var(--space-4); }
h3 { font-size: var(--t-1); font-weight: 600; margin-block: 0 var(--space-2); }
p  { margin-block: 0 var(--space-4); }

/* F-8: custom ::selection, follows the theme */
::selection { background: var(--accent2); color: var(--ink); }
[data-theme="dark"] ::selection { background: var(--accent); color: #1E1611; }

/* F-12: custom scrollbar */
html { scrollbar-color: var(--accent) var(--tint); scrollbar-width: thin; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--tint); }
::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: var(--r-pill);
  border: 3px solid var(--tint);
}

:where(a, button, summary):focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.vrn-skip {
  position: absolute;
  left: -9999px;
  top: var(--space-2);
  z-index: 60;
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  padding: var(--space-2) var(--space-4);
  text-decoration: none;
}
.vrn-skip:focus { left: var(--space-4); }

/* ---- 3. Header — E1-2 floating pill, neo-brutalist -------- */

.vrn-header {
  position: sticky;
  top: 0;
  z-index: 30;
  padding: var(--space-3) clamp(12px, 4vw, 32px);
  background: transparent;
}

.vrn-header__pill {
  max-width: 1140px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 56px;
  padding: var(--space-2) var(--space-3);
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  box-shadow: var(--off) var(--off) 0 var(--hard);
}

/* Mobile top bar: ONE row, always. The brand may shrink; the buttons never do. */
.vrn-brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-width: 0;          /* lets the wordmark ellipsis instead of shoving buttons out */
  flex: 1 1 auto;
  text-decoration: none;
  color: inherit;
}

.vrn-brand__ico { flex: 0 0 auto; display: grid; place-items: center; width: 30px; height: 30px; }
.vrn-brand__ico svg { width: 30px; height: 30px; }
.vrn-brand__box { fill: var(--accent2); stroke: var(--ink); stroke-width: 2; }
.vrn-brand__lens { fill: var(--accent); stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.vrn-brand__dot { fill: var(--surface); stroke: var(--ink); stroke-width: 2; }

.vrn-brand__name {
  font-family: var(--head);
  font-weight: 800;
  font-size: clamp(.95rem, .8rem + .7vw, 1.15rem);
  letter-spacing: -.02em;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vrn-header__actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* Icon-only buttons: fixed box + grid-centred. A shrink-to-fit flex button
   whose only child is an <svg> collapses to 0 width on iOS Safari — which is
   also why the reset keeps max-width on img only. */
.vrn-icobtn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  padding: 0;
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  cursor: pointer;
  color: var(--text);
  transition: transform .12s, box-shadow .12s;
}
.vrn-icobtn svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.vrn-toggle__moon { fill: currentColor; stroke: none; }
.vrn-icobtn:hover { box-shadow: 2px 2px 0 var(--hard); transform: translate(-1px, -1px); }

[data-theme="light"] .vrn-toggle__moon,
[data-theme="dark"]  .vrn-toggle__sun { display: none; }

.vrn-burger[aria-expanded="true"] .vrn-burger__t { transform: translateY(5px) rotate(45deg); }
.vrn-burger[aria-expanded="true"] .vrn-burger__m { opacity: 0; }
.vrn-burger[aria-expanded="true"] .vrn-burger__b { transform: translateY(-5px) rotate(-45deg); }
.vrn-burger__t, .vrn-burger__m, .vrn-burger__b {
  transform-origin: center;
  transition: transform .2s, opacity .2s;
}

/* ---- 4. Language dropdown (desktop) ---------------------- */

.vrn-lang { position: relative; }

.vrn-lang__btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 40px;
  padding: 0 var(--space-4);
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  cursor: pointer;
  font-size: var(--t--1);
  font-weight: 600;
  white-space: nowrap;
}
.vrn-lang__btn:hover { box-shadow: 2px 2px 0 var(--hard); transform: translate(-1px, -1px); }
.vrn-lang__chev {
  width: 15px; height: 15px;
  fill: none; stroke: currentColor; stroke-width: 2.4;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform .18s;
}
.vrn-lang__btn[aria-expanded="true"] .vrn-lang__chev { transform: rotate(180deg); }

.vrn-lang__pop {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  min-width: 190px;
  padding: var(--space-2);
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  box-shadow: var(--off) var(--off) 0 var(--hard);
  z-index: 5;
}

.vrn-lang__list { list-style: none; margin: 0; padding: 0; }
.vrn-lang__list li a,
.vrn-lang__list li > span {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0 var(--space-3);
  border-radius: 10px;
  text-decoration: none;
  font-size: var(--t--1);
  color: var(--text);
}
.vrn-lang__list li a:hover { background: var(--tint); }
/* TranslatePress injects flags into its menu items */
.vrn-lang__list img,
.trp-language-switcher-container img { width: 18px; height: auto; border-radius: 2px; }
.trp-language-switcher-container { font-size: var(--t--1); }

/* ---- 5. Sheet (mobile) + scrim --------------------------- */

.vrn-scrim {
  position: fixed;
  inset: 0;
  z-index: 40;               /* scrim under the panel, and before it in the DOM */
  background: rgba(31, 36, 48, .5);
  border: 0;
}

.vrn-sheet {
  position: fixed;
  z-index: 41;               /* above scrim, header and cookie banner */
  left: var(--space-3);
  right: var(--space-3);
  bottom: var(--space-3);
  max-height: 78vh;
  overflow-y: auto;
  padding: var(--space-4);
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  box-shadow: var(--off) var(--off) 0 var(--hard);
}

.vrn-sheet__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-block-end: var(--space-3);
}
.vrn-sheet__title { font-family: var(--head); font-weight: 800; }
.vrn-sheet__links { margin-block-start: var(--space-4); border-top: var(--line) dashed var(--ink); padding-block-start: var(--space-3); }
.vrn-sheet__links .vrn-footer__links { flex-direction: column; align-items: flex-start; gap: 0; }
.vrn-sheet__links .vrn-footer__links a { min-height: 44px; display: flex; align-items: center; }

/* ---- 6. Main + the reading column ------------------------ */

.vrn-main { padding: var(--space-5) clamp(16px, 4vw, 32px) var(--space-8); }

.vrn-entry { max-width: 1140px; margin-inline: auto; }

/* Every direct child shares one centred column. Zero specificity, so any
   component rule below still wins. Only the gate opts out — it is a full
   card with its own wider, still-centred max-width. */
.vrn-entry > :where(*:not(.vrn-gate)) {
  max-width: var(--col);
  margin-inline: auto;
}

.vrn-kicker {
  font-family: var(--head);
  font-weight: 600;
  font-size: var(--t--1);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  margin-block-end: var(--space-4);
}

.vrn-entry h1,
.vrn-entry h2 { scroll-margin-top: 96px; }

.vrn-entry h2 { position: relative; padding-block-start: var(--space-4); }
/* number and rule at separate coordinates — together they read as a
   struck-through number. */
.vrn-entry h2::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 56px;
  height: var(--line);
  background: var(--accent);
}

/* Accent strategy 1: colour on links and the CTA, nothing else.
   a:not([class]) keeps this rule off the buttons — a general entry-link rule
   beats a button class on specificity and paints button text accent-on-accent. */
.vrn-entry a:not([class]) {
  color: var(--accent);
  text-decoration: none;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-size: 100% 2px;
  background-repeat: no-repeat;
  background-position: 0 100%;
}
.vrn-entry a:not([class]):hover { background-size: 100% 3px; }

/* Gutenberg lists are .wp-block-list — a ul:not([class]) selector misses them
   entirely and a ul[class]{list-style:none} reset strips their markers. */
.vrn-entry .wp-block-list {
  margin-block: 0 var(--space-4);
  padding-inline-start: var(--space-5);
  list-style: disc;
}
.vrn-entry .wp-block-list li { margin-block-end: var(--space-2); }

.vrn-btn,
.vrn-entry .vrn-btn {
  display: inline-block;
  padding: var(--space-3) var(--space-5);
  background: var(--accent);
  color: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  box-shadow: var(--off) var(--off) 0 var(--hard);
  font-family: var(--head);
  font-weight: 600;
  text-decoration: none;
  background-image: none;
  transition: transform .12s, box-shadow .12s;
}
[data-theme="dark"] .vrn-btn { color: #1E1611; }
.vrn-btn:hover { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--hard); }

/* ---- 7. Age gate — D-10 Paper Stack ---------------------- */

.vrn-gate {
  max-width: 60rem;
  margin-inline: auto;
  margin-block-end: var(--space-7);
  padding-block: var(--space-4) var(--space-5);
}

.vrn-gate__stack { position: relative; padding-block-start: 14px; }

/* the back sheet */
.vrn-gate__stack::before {
  content: "";
  position: absolute;
  inset: 14px 0 0 0;
  background: var(--grad);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  transform: rotate(-2.5deg);
  transform-origin: 50% 60%;
  animation: vrn-settle 10s ease-in-out infinite alternate;
}

.vrn-gate__sheet {
  position: relative;
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  padding: var(--space-7) var(--space-5) var(--space-6);
  text-align: center;
  box-shadow: var(--off) var(--off) 0 var(--hard);
}

/* the 18+ tab, sticking out of the top like a folder tab */
.vrn-gate__tab {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  padding: var(--space-2) var(--space-5);
  background: var(--accent);
  color: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: 10px 10px 0 0;
  font-family: var(--head);
  font-weight: 800;
  letter-spacing: .06em;
  animation: vrn-tab .5s cubic-bezier(.2, .9, .3, 1) both;
}
[data-theme="dark"] .vrn-gate__tab { color: #1E1611; }

.vrn-gate__q {
  font-family: var(--head);
  font-weight: 600;
  font-size: clamp(1.15rem, .95rem + 1vw, 1.6rem);
  margin-block: 0 var(--space-5);
}

.vrn-gate__go {
  display: inline-block;
  min-height: 48px;
  padding: var(--space-3) var(--space-6);
  background: var(--accent);
  color: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  box-shadow: var(--off) var(--off) 0 var(--hard);
  font-family: var(--head);
  font-weight: 800;
  font-size: var(--t-1);
  text-decoration: none;
  background-image: none;
  transition: transform .12s, box-shadow .12s;
}
[data-theme="dark"] .vrn-gate__go { color: #1E1611; }
.vrn-gate__go:hover { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--hard); }

@keyframes vrn-settle {
  from { transform: rotate(-2.5deg); }
  to   { transform: rotate(-1.5deg); }
}
@keyframes vrn-tab {
  from { transform: translate(-50%, 40%); opacity: 0; }
  to   { transform: translate(-50%, -50%); opacity: 1; }
}

/* ---- 8. Illustration ------------------------------------- */

.vrn-illus { margin-block: var(--space-6); }
.vrn-illus__svg { width: 100%; height: auto; }

.vrn-illus__bg     { fill: var(--tint); stroke: var(--ink); stroke-width: 2; }
.vrn-illus__panel  { fill: var(--surface); }
.vrn-illus__shadow { fill: var(--hard); }
.vrn-illus__accent { fill: var(--accent2); }
.vrn-illus__skin   { fill: var(--accent2); }
.vrn-illus__hair   { fill: var(--ink); }
.vrn-illus__fig    { fill: var(--accent); }
.vrn-illus__ink    { fill: var(--ink); }
.vrn-illus__line   { stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.vrn-illus__stroke { fill: none; stroke-linecap: round; }
.vrn-illus__band   { stroke-width: 3; }

/* ---- 9. Feature cards ------------------------------------ */

.vrn-cards {
  display: grid;
  gap: var(--space-4);
  margin-block: var(--space-5) var(--space-6);
}

.vrn-card {
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  box-shadow: var(--off) var(--off) 0 var(--hard);
  padding: var(--space-5);
  transition: transform .12s, box-shadow .12s;
}
.vrn-card:hover { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--hard); }

.vrn-card__ico {
  width: 26px;
  height: 26px;
  margin-block-end: var(--space-3);
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.vrn-card__h { font-family: var(--head); }
.vrn-card__p { font-size: var(--t--1); color: var(--muted); margin-block-end: 0; }

/* ---- 10. Pull quote -------------------------------------- */

.vrn-entry .vrn-pull {
  position: relative;
  margin-block: var(--space-6);
  padding: var(--space-6) var(--space-5) var(--space-5);
  background: var(--grad);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-card);
  box-shadow: var(--off) var(--off) 0 var(--hard);
}
.vrn-entry .vrn-pull::before {
  content: "\201C";
  position: absolute;
  top: -6px;
  left: var(--space-4);
  font-family: var(--head);
  font-size: 4.5rem;
  line-height: 1;
  color: var(--accent);
}
.vrn-entry .vrn-pull p {
  font-family: var(--head);
  font-weight: 600;
  font-size: clamp(1.15rem, .95rem + 1vw, 1.5rem);
  line-height: 1.35;
  margin: 0;
  color: var(--ink);
}
[data-theme="dark"] .vrn-entry .vrn-pull p { color: var(--text); }
.vrn-entry .vrn-pull cite { display: none; }

/* ---- 11. Footer — tinted, never inverted ----------------- */

.vrn-footer {
  background: var(--tint);
  border-top: var(--line) solid var(--ink);
  padding: var(--space-6) clamp(16px, 4vw, 32px);
}
.vrn-footer__in {
  max-width: 1140px;
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}
.vrn-footer__c { margin: 0; font-size: var(--t--1); color: var(--muted); }
.vrn-footer__links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
}
.vrn-footer__links a {
  font-size: var(--t--1);
  color: var(--text);
  text-decoration: none;
  border-bottom: var(--line) solid var(--accent);
}
.vrn-footer__links a:hover { color: var(--accent); }

/* ---- 12. Cookie banner ----------------------------------- */

.vrn-cookie {
  position: fixed;
  left: 50%;
  bottom: var(--space-4);
  transform: translate(-50%, 140%);
  z-index: 35;
  width: min(680px, calc(100vw - var(--space-6)));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  box-shadow: var(--off) var(--off) 0 var(--hard);
  transition: transform .45s cubic-bezier(.2, .9, .3, 1);
}
.vrn-cookie.is-up { transform: translate(-50%, 0); }
.vrn-cookie__t { flex: 1 1 260px; margin: 0; font-size: var(--t--1); line-height: 1.5; }
.vrn-cookie__t a { color: var(--accent); }
.vrn-cookie__ok {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 var(--space-5);
  background: var(--accent);
  color: var(--surface);
  border: var(--line) solid var(--ink);
  border-radius: var(--r-pill);
  font-family: var(--head);
  font-weight: 700;
  cursor: pointer;
}
[data-theme="dark"] .vrn-cookie__ok { color: #1E1611; }

/* ---- 13. 404 --------------------------------------------- */

.vrn-404 { text-align: center; padding-block: var(--space-7); }
.vrn-404__n {
  font-family: var(--head);
  font-weight: 800;
  font-size: clamp(5rem, 3rem + 14vw, 10rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 3px var(--ink);
  margin-block-end: var(--space-4);
}

/* ---- 14. Reveals — F-18 ---------------------------------- */

@keyframes vrn-rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  @supports (animation-timeline: view()) {
    .vrn-entry > h2,
    .vrn-entry > p,
    .vrn-illus,
    .vrn-cards,
    .vrn-entry > .vrn-pull {
      animation: vrn-rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 40%;
    }
  }

  /* JS fallback only where view() is unsupported; .vrn-io is set by main.js */
  @supports not (animation-timeline: view()) {
    .vrn-io .vrn-entry > h2,
    .vrn-io .vrn-illus,
    .vrn-io .vrn-cards,
    .vrn-io .vrn-entry > .vrn-pull {
      opacity: 0;
      transform: translateY(14px);
      transition: opacity .5s ease-out, transform .5s ease-out;
    }
    .vrn-io .is-in {
      opacity: 1;
      transform: none;
    }
  }
}

/* ---- 15. Breakpoints ------------------------------------- */

@media (max-width: 768px) {
  /* Scoped to the header, or the in-sheet list would be hidden by the same
     rule — it reuses the .vrn-lang class. */
  .vrn-header__actions .vrn-lang { display: none; }
}

@media (min-width: 769px) {
  .vrn-burger,
  .vrn-sheet,
  .vrn-scrim { display: none !important; }
}

@media (min-width: 640px) {
  .vrn-cards { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 400px) {
  .vrn-header__pill { gap: var(--space-2); padding-inline: var(--space-2); }
  .vrn-brand__name { font-size: .9rem; }
}

/* ---- 16. Reduced motion ---------------------------------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  /* the stack settles to a finished, deliberate composition */
  .vrn-gate__stack::before { transform: rotate(-2deg); }
  .vrn-gate__tab { opacity: 1; transform: translate(-50%, -50%); }
}
