/* ==========================================================================
   משרד עורכי דין מאור גרצנשטיין — Core Design System
   v1.0 · Pure CSS3 · RTL-first · No frameworks
   --------------------------------------------------------------------------
   Contents
   01. Tokens
   02. Reset & base
   03. Layout primitives
   04. Typography
   05. Buttons & links
   06. Header / navigation
   07. Hero
   08. Trust strip
   09. Practice cards
   10. Contact & forms
   11. Footer
   12. Mobile action bar
   13. Article components (TLDR / TOC / FAQ / shortcodes)
   14. Motion & accessibility
   ========================================================================== */

/* ==========================================================================
   01. Tokens
   ========================================================================== */

:root {
  /* --- Color ------------------------------------------------------------
     navy    : trust, authority. Headings + hero canvas.
     ink     : sampled from the firm's own logo (#2e3d6c). Bridges the new
               palette to the existing mark. Used for strokes, rules, tiles.
     emerald : action. Reserved for things the visitor can do.
     paper   : the page.                                                   */
  --navy-900: #0f172a;
  --navy-800: #1e293b;
  --navy-700: #334155;

  --ink-600: #2e3d6c;
  --ink-500: #3d5089;
  --ink-050: rgba(46, 61, 108, 0.07);

  --emerald-600: #059669;
  --emerald-700: #047857;
  --emerald-050: rgba(5, 150, 105, 0.09);

  --paper: #f8fafc;
  --surface: #ffffff;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --muted: #64748b;
  --muted-invert: rgba(226, 232, 240, 0.78);

  /* --- Type -------------------------------------------------------------
     Heebo   : display. Tighter, more architectural at heavy weights.
     Assistant: body. Opens up for long Hebrew paragraphs.                 */
  --font-display: "Heebo", "Assistant", system-ui, sans-serif;
  --font-body: "Assistant", "Heebo", system-ui, sans-serif;

  --step--1: clamp(0.82rem, 0.79rem + 0.14vw, 0.9rem);
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.08rem);
  --step-1: clamp(1.15rem, 1.08rem + 0.35vw, 1.32rem);
  --step-2: clamp(1.38rem, 1.26rem + 0.6vw, 1.75rem);
  --step-3: clamp(1.7rem, 1.45rem + 1.2vw, 2.4rem);
  --step-4: clamp(2.1rem, 1.6rem + 2.4vw, 3.6rem);

  /* --- Space ------------------------------------------------------------ */
  --space-2xs: 0.375rem;
  --space-xs: 0.625rem;
  --space-s: 1rem;
  --space-m: 1.5rem;
  --space-l: 2.25rem;
  --space-xl: 3.5rem;
  --space-2xl: clamp(4rem, 8vw, 7rem);

  --wrap: 1180px;
  --wrap-narrow: 760px;

  /* --- Shape & elevation ------------------------------------------------ */
  --radius: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-s: 0 2px 8px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-m: 0 10px 30px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);
  --shadow-l: 0 24px 60px rgba(15, 23, 42, 0.12), 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-cta: 0 8px 20px rgba(5, 150, 105, 0.28);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --header-h: 98px;
}

/* ==========================================================================
   02. Reset & base
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.7;
  color: var(--navy-800);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img,
svg,
picture { display: block; max-width: 100%; }

img { height: auto; }

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--emerald-600);
  color: #fff;
}

/* Skip link — first stop for keyboard and screen-reader users */
.skip-link {
  position: absolute;
  inset-inline-start: var(--space-s);
  top: -100px;
  z-index: 200;
  padding: 0.7rem 1.2rem;
  border-radius: var(--radius);
  background: var(--navy-900);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  transition: top 0.2s var(--ease);
}

.skip-link:focus { top: var(--space-s); }

/* ==========================================================================
   03. Layout primitives
   ========================================================================== */

.wrap {
  width: min(100% - 2.5rem, var(--wrap));
  margin-inline: auto;
}

.section { padding-block: var(--space-2xl); }

.section-tight { padding-block: var(--space-xl); }

.section-head {
  max-width: 62ch;
  margin-bottom: var(--space-xl);
}

.section-head-center {
  margin-inline: auto;
  text-align: center;
}

.grid-3 {
  display: grid;
  gap: var(--space-m);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

/* ==========================================================================
   04. Typography
   ========================================================================== */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.015em;
  color: var(--navy-900);
  text-wrap: balance;
}

h1 { font-size: var(--step-4); font-weight: 900; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }

p { text-wrap: pretty; }

.lede {
  font-size: var(--step-1);
  line-height: 1.62;
  color: var(--navy-700);
}

.muted { color: var(--muted); }

.mt-s { margin-block-start: var(--space-s); }
.mt-m { margin-block-start: var(--space-m); }
.mb-s { margin-block-end: var(--space-s); }
.mb-m { margin-block-end: var(--space-m); }
.measure-narrow { max-width: 38ch; }

/* Eyebrow — Hebrew has no capitals, so the label reads as a label through
   weight, tracking and color instead of case. */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: var(--step--1);
  font-weight: 700;
  letter-spacing: 0.09em;
  color: var(--emerald-700);
  margin-bottom: var(--space-xs);
}

.eyebrow::before {
  content: "";
  inline-size: 22px;
  block-size: 2px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.55;
}

.eyebrow-invert { color: #6ee7b7; }

/* The ink stroke: the firm's mark is a signed line, so the signature is the
   page's structural motif. Draws right-to-left, the way Hebrew is written. */
.ink-stroke {
  display: block;
  inline-size: min(100%, 420px);
  block-size: auto;
  margin-block-start: 0.35rem;
  color: var(--emerald-600);
}

.ink-stroke path { fill: currentColor; }

/* ==========================================================================
   05. Buttons & links
   ========================================================================== */

.btn {
  --btn-bg: var(--emerald-600);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.85rem 1.6rem;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-display);
  font-size: var(--step-0);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.18s var(--ease), background-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease), border-color 0.18s var(--ease);
}

.btn svg { inline-size: 20px; block-size: 20px; flex: none; }

.btn-primary { box-shadow: var(--shadow-cta); }

.btn-primary:hover {
  --btn-bg: var(--emerald-700);
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(4, 120, 87, 0.34);
}

.btn-ghost {
  --btn-bg: transparent;
  --btn-fg: var(--navy-900);
  border-color: var(--line-strong);
}

.btn-ghost:hover {
  --btn-bg: var(--surface);
  border-color: var(--ink-600);
  transform: translateY(-2px);
  box-shadow: var(--shadow-s);
}

.btn-ghost-invert {
  --btn-bg: rgba(255, 255, 255, 0.06);
  --btn-fg: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-ghost-invert:hover {
  --btn-bg: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
}

.btn-sm { padding: 0.55rem 1.1rem; font-size: var(--step--1); }

.btn-block { inline-size: 100%; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Text link with the ink motif as an animated underline */
.link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--ink-600);
  font-weight: 700;
  text-decoration: none;
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0% 2px;
  background-position: 100% 100%;
  background-repeat: no-repeat;
  transition: background-size 0.28s var(--ease), color 0.2s var(--ease);
}

.link:hover,
.link:focus-visible {
  color: var(--emerald-700);
  background-size: 100% 2px;
}

.link svg {
  inline-size: 16px;
  block-size: 16px;
  transition: transform 0.22s var(--ease);
}

.link:hover svg { transform: translateX(-4px); }

/* ==========================================================================
   06. Header / navigation
   ========================================================================== */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 250, 252, 0.86);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.header-scrolled {
  border-bottom-color: var(--line);
  box-shadow: var(--shadow-xs);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: var(--space-m);
  block-size: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  flex: none;
  text-decoration: none;
}

.brand img {
  block-size: 70px;
  inline-size: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-inline-end: auto;
}

.nav a {
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-pill);
  color: var(--navy-800);
  font-size: var(--step--1);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.18s var(--ease), color 0.18s var(--ease);
}

.nav a:hover {
  background: var(--ink-050);
  color: var(--ink-600);
}

.nav a[aria-current="page"] {
  background: var(--ink-050);
  color: var(--ink-600);
  font-weight: 700;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: none;
}

.header-phone {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--navy-900);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--step--1);
  text-decoration: none;
  direction: ltr;
}

.header-phone svg { inline-size: 17px; block-size: 17px; color: var(--emerald-600); }

.header-phone:hover { color: var(--emerald-700); }

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  inline-size: 44px;
  block-size: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
}

.nav-toggle svg { inline-size: 22px; block-size: 22px; color: var(--navy-900); }

.nav-toggle .icon-close,
.nav-toggle[aria-expanded="true"] .icon-menu { display: none; }

.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

@media (max-width: 1023px) {
  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--space-s) 1.25rem var(--space-m);
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-m);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.22s var(--ease), transform 0.22s var(--ease),
      visibility 0.22s;
  }

  .nav-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav a {
    padding: 0.85rem 0.75rem;
    border-radius: 12px;
    font-size: var(--step-0);
    border-bottom: 1px solid var(--line);
  }

  .nav a:last-child { border-bottom: 0; }

  .nav-toggle { display: inline-flex; }

  .header-phone span { display: none; }
}

@media (max-width: 560px) {
  .header-actions .btn { display: none; }
}

/* ==========================================================================
   07. Hero
   ========================================================================== */

.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(3.5rem, 7vw, 6rem) var(--space-2xl);
  background: linear-gradient(200deg, var(--navy-900) 0%, #16223c 55%, var(--navy-800) 100%);
  color: #fff;
  isolation: isolate;
}

/* An oversized impression of the same signature stroke, pressed into the
   page like the sheet underneath a signed document. */
.hero-watermark {
  position: absolute;
  inset-block-start: 8%;
  inset-inline-start: -12%;
  inline-size: 130%;
  color: #fff;
  opacity: 0.045;
  transform: rotate(-7deg);
  pointer-events: none;
  z-index: -1;
}

.hero-watermark path { fill: currentColor; }

.hero h1 { color: #fff; }

.hero-lede {
  max-width: 56ch;
  margin-block-start: var(--space-m);
  font-size: var(--step-1);
  line-height: 1.62;
  color: var(--muted-invert);
}

.hero-inner { max-width: 62ch; }

.hero .btn-row { margin-block-start: var(--space-l); }

/* Three pillars, stated in the hero as the three moments a signature matters */
.pillars {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  margin-block-start: var(--space-xl);
}

.pillar {
  display: block;
  padding: 1.1rem 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  text-decoration: none;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease),
    transform 0.2s var(--ease);
}

.pillar:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(110, 231, 183, 0.55);
  transform: translateY(-3px);
}

.pillar-name {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: var(--step-0);
  font-weight: 700;
  line-height: 1.3;
}

.pillar-name svg {
  inline-size: 16px;
  block-size: 16px;
  flex: none;
  color: #6ee7b7;
  transition: transform 0.2s var(--ease);
}

.pillar:hover .pillar-name svg { transform: translateX(-4px); }

/* The document at the centre of each area — the concrete artifact, not a tagline */
.pillar-doc {
  display: block;
  margin-block-start: 0.3rem;
  font-size: var(--step--1);
  line-height: 1.5;
  color: var(--muted-invert);
}

/* ==========================================================================
   08. Trust strip
   ========================================================================== */

.trust {
  background: var(--surface);
  border-block-end: 1px solid var(--line);
}

.trust-grid {
  display: grid;
  gap: 0;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  padding-block: var(--space-l);
}

.trust-item {
  padding: var(--space-xs) var(--space-m);
  border-inline-end: 1px solid var(--line);
}

.trust-item:last-child { border-inline-end: 0; }

.trust-item h3 {
  font-size: var(--step-0);
  margin-block-end: 0.25rem;
}

.trust-item p {
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--muted);
}

@media (max-width: 720px) {
  .trust-item {
    border-inline-end: 0;
    border-block-end: 1px solid var(--line);
    padding-block: var(--space-s);
  }
  .trust-item:last-child { border-block-end: 0; }
}

/* ==========================================================================
   09. Practice cards
   ========================================================================== */

.card {
  display: flex;
  flex-direction: column;
  padding: var(--space-m);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-s);
  transition: transform 0.24s var(--ease), box-shadow 0.24s var(--ease),
    border-color 0.24s var(--ease);
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--ink-500);
  box-shadow: var(--shadow-m);
}

.card-icon {
  display: grid;
  place-items: center;
  inline-size: 52px;
  block-size: 52px;
  margin-block-end: var(--space-s);
  border-radius: 14px;
  background: var(--ink-050);
  color: var(--emerald-700);
}

.card-icon svg { inline-size: 26px; block-size: 26px; }

.card h3 { margin-block-end: 0.4rem; }

.card > p:not(.eyebrow) {
  color: var(--muted);
  font-size: var(--step-0);
}

.card-list {
  margin-block: var(--space-s) var(--space-m);
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.45rem;
}

.card-list li {
  position: relative;
  padding-inline-start: 1.55rem;
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--navy-700);
}

.card-list li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  inset-block-start: 0.55em;
  inline-size: 7px;
  block-size: 7px;
  border-radius: 50%;
  background: var(--emerald-600);
}

.card-foot {
  margin-block-start: auto;
  padding-block-start: var(--space-s);
  border-block-start: 1px solid var(--line);
}

/* ==========================================================================
   10. Contact & forms
   ========================================================================== */

.contact { background: var(--paper); }

.contact-grid {
  display: grid;
  gap: var(--space-l);
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: start;
}

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
}

.form-panel {
  padding: clamp(1.25rem, 3vw, 2.25rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-m);
}

.field-row {
  display: grid;
  gap: var(--space-s);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.field { margin-block-end: var(--space-s); }

.field label {
  display: block;
  margin-block-end: 0.35rem;
  font-family: var(--font-display);
  font-size: var(--step--1);
  font-weight: 700;
  color: var(--navy-900);
}

.field .req { color: var(--emerald-700); }

.field input,
.field select,
.field textarea {
  inline-size: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--surface);
  color: var(--navy-900);
  font-size: var(--step-0);
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.field textarea { resize: vertical; min-block-size: 120px; }

.field select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 0.9rem center;
  background-size: 18px;
  padding-inline-end: 2.6rem;
}

.field input::placeholder,
.field textarea::placeholder { color: #94a3b8; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--emerald-600);
  box-shadow: 0 0 0 4px var(--emerald-050);
}

.field input:user-invalid,
.field textarea:user-invalid {
  border-color: #dc2626;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.09);
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-block: var(--space-s);
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--muted);
}

.consent input {
  flex: none;
  inline-size: 20px;
  block-size: 20px;
  margin-block-start: 0.15rem;
  accent-color: var(--emerald-600);
}

.form-note {
  margin-block-start: var(--space-s);
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--muted);
  text-align: center;
}

.form-status {
  display: none;
  margin-block-end: var(--space-s);
  padding: 0.8rem 1rem;
  border-radius: 12px;
  font-size: var(--step--1);
  font-weight: 600;
}

.form-status-visible { display: block; }

.form-status-error {
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.3);
  color: #b91c1c;
}

/* Contact details column */
.contact-aside {
  display: grid;
  gap: var(--space-s);
}

.contact-card {
  padding: var(--space-m);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-s);
}

.contact-card-dark {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: #fff;
}

.contact-card-dark h3 { color: #fff; }

.contact-card-dark p { color: var(--muted-invert); font-size: var(--step--1); }

.contact-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.9rem;
}

.contact-list a,
.contact-list span {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--navy-900);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.18s var(--ease);
}

.contact-list a:hover { color: var(--emerald-700); }

.contact-list svg {
  inline-size: 20px;
  block-size: 20px;
  flex: none;
  color: var(--emerald-600);
}

.contact-list .ltr { direction: ltr; }

/* ==========================================================================
   11. Footer
   ========================================================================== */

.footer {
  padding-block: var(--space-xl) var(--space-m);
  background: var(--navy-900);
  color: var(--muted-invert);
  font-size: var(--step--1);
}

.footer-grid {
  display: grid;
  gap: var(--space-l);
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  padding-block-end: var(--space-l);
  border-block-end: 1px solid rgba(255, 255, 255, 0.12);
}

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer img {
  block-size: 52px;
  inline-size: auto;
  margin-block-end: var(--space-s);
  /* The mark is navy ink; lift it to near-white on the dark ground */
  filter: brightness(0) invert(1);
  opacity: 0.92;
}

.footer h4 {
  margin-block-end: var(--space-xs);
  font-size: var(--step-0);
  color: #fff;
}

.footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.5rem;
}

.footer a {
  color: var(--muted-invert);
  text-decoration: none;
  transition: color 0.18s var(--ease);
}

.footer a:hover { color: #6ee7b7; }

.socials {
  display: flex;
  gap: 0.6rem;
  margin-block-start: var(--space-s);
}

.socials a {
  display: grid;
  place-items: center;
  inline-size: 40px;
  block-size: 40px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  transition: background-color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.socials a:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(110, 231, 183, 0.6);
}

.socials svg { inline-size: 19px; block-size: 19px; }

.disclaimer {
  padding-block: var(--space-m);
  font-size: 0.8rem;
  line-height: 1.7;
  color: rgba(203, 213, 225, 0.62);
  border-block-end: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-s);
  padding-block-start: var(--space-m);
  font-size: 0.8rem;
}

.footer-bottom ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
}

/* ==========================================================================
   12. Mobile action bar
   ========================================================================== */

.action-bar { display: none; }

@media (max-width: 767px) {
  .action-bar {
    position: fixed;
    inset-inline: 0;
    inset-block-end: 0;
    z-index: 90;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    padding: 0.7rem 0.9rem calc(0.7rem + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-block-start: 1px solid var(--line);
  }

  body { padding-block-end: 84px; }
}

/* ==========================================================================
   13. Article components (CMS-rendered pages)
   ========================================================================== */

.prose { max-width: var(--wrap-narrow); }

.prose > * + * { margin-block-start: var(--space-s); }

.prose h2 { margin-block-start: var(--space-l); }

.prose h3 { margin-block-start: var(--space-m); }

.prose ul,
.prose ol { padding-inline-start: 1.3rem; }

.prose li + li { margin-block-start: 0.35rem; }

.prose a { color: var(--ink-600); font-weight: 600; }

.tldr {
  padding: var(--space-m);
  border: 1px solid var(--line);
  border-inline-start: 4px solid var(--emerald-600);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
}

.toc {
  padding: var(--space-m);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.toc ol { margin: 0; padding-inline-start: 1.2rem; }

.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  margin-block-end: 0.6rem;
  overflow: hidden;
}

.faq-item summary {
  padding: 1rem 1.15rem;
  font-family: var(--font-display);
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  font-size: 1.4rem;
  color: var(--emerald-600);
  line-height: 1;
}

.faq-item[open] summary::after { content: "\2013"; }

.faq-item .faq-body {
  padding: 0 1.15rem 1.15rem;
  color: var(--navy-700);
}

/* Shortcode component shells: [checklist] [calculator] [red_flag_quiz] */
.checklist,
.calculator,
.quiz {
  padding: var(--space-m);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-s);
}

.checklist ul { list-style: none; padding: 0; display: grid; gap: 0.6rem; }

.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.calculator-result {
  margin-block-start: var(--space-s);
  padding: var(--space-s);
  border-radius: var(--radius);
  background: var(--emerald-050);
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 900;
  color: var(--emerald-700);
  text-align: center;
}

/* ==========================================================================
   14. Motion & accessibility
   ========================================================================== */

:focus-visible {
  outline: 3px solid var(--emerald-600);
  outline-offset: 3px;
  border-radius: 6px;
}

.hero :focus-visible { outline-color: #6ee7b7; }

.visually-hidden {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* One orchestrated moment: the hero settles, then signs itself. */
@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes sign {
  from { clip-path: inset(0 0 0 100%); }
  to { clip-path: inset(0 0 0 0); }
}

.rise {
  opacity: 0;
  animation: rise 0.6s var(--ease) forwards;
}

.rise-1 { animation-delay: 0.05s; }
.rise-2 { animation-delay: 0.14s; }
.rise-3 { animation-delay: 0.23s; }
.rise-4 { animation-delay: 0.32s; }

.ink-stroke {
  clip-path: inset(0 0 0 100%);
  animation: sign 0.85s var(--ease) 0.45s forwards;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .rise { opacity: 1; transform: none; }
  .ink-stroke { clip-path: none; }
}

@media print {
  .header, .action-bar, .footer, .hero-watermark { display: none; }
  body { background: #fff; }
}
