/* Homepage editorial (01b-refined); vars scoped to .home-editorial-root */

  .home-editorial-root {
    /* Ink — your existing portfolio dark navy */
    --ink: #1c2839;
    --ink-soft: #4f5563;
    --ink-muted: #6b6f76;

    /* Surfaces */
    --bg: #ffffff;             /* white */
    --paper: #ffffff;
    --paper-alt: #f4f4f1;      /* near-white neutral */

    /* Light tone for text-on-dark */
    --cream: #f5f2ea;

    /* Hero / dark surfaces */
    --navy: #1c2839;
    --navy-deep: #0f1a2a;
    --hero-card-bg: #ffffff; /* light hero trial — was #25342a forest */

    /* Accents — deep mauve primary, warm ochre secondary, plus quiet supporters */
    --accent: #f4431e;          /* coral — primary (from your existing portfolio) */
    --accent-deep: #d23811;     /* coral hover */
    --accent-2: #d68c3e;        /* warm ochre — secondary */
    --accent-2-deep: #b0701f;
    --accent-3: #aa9bc4;        /* dusty lavender — tertiary */
    --accent-4: #6b7d4c;        /* dusty olive — quietest */

    /* Hairlines / borders — slightly heavier for that neubrut character */
    --rule: rgba(28, 40, 57, 0.18);
    --rule-soft: rgba(28, 40, 57, 0.10);

    /* Shadows — ink-tinted offset, with the chunkier neubrut feel back */
    --shadow-card: 5px 5px 0 0 rgba(28, 40, 57, 0.12), 0 10px 24px rgba(28, 40, 57, 0.06);
    --shadow-hover: 8px 8px 0 0 rgba(28, 40, 57, 0.18), 0 16px 36px rgba(28, 40, 57, 0.10);

    /* Type — your existing portfolio stack */
    --serif: "Cormorant Garamond", Georgia, serif;
    --sans: "DM Sans", system-ui, sans-serif;
    --mono: "DM Mono", monospace;

    /* Layout — hero, works, colophon share one max; gutters scale down on small viewports */
    --home-max: 1480px;
    --home-gutter-x: clamp(16px, 3.5vw, 44px);

    width: 100%;
    max-width: 100%;
    overflow-x: clip;
    box-sizing: border-box;
  }

  .kicker {
    font-family: var(--mono); font-size: 11px;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--ink-muted); font-weight: 500;
    display: inline-flex; align-items: center; gap: 10px;
  }
  .kicker::before {
    content: ""; width: 18px; height: 1px; background: currentColor;
  }
  .kicker.no-rule::before { display: none; }
  
  
  .kicker.cream { color: rgba(245, 242, 234, 0.85); }

  /* Page padding — wide rail; max aligns hero / works / about */
  .home-editorial-root.page {
    width: 100%;
    max-width: var(--home-max);
    margin: 0 auto;
    padding: 56px var(--home-gutter-x) 100px;
    box-sizing: border-box;
  }

  /* --- HERO GRID ------------------------------------ */
  .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.68fr) minmax(0, 1fr);
    gap: clamp(16px, 2vw, 24px);
    width: 100%;
    /* Equal row height; each card fills the row — hero uses flex so space isn’t trapped under CTAs */
    align-items: stretch;
  }
  .block {
    border: 1px solid var(--rule);
    border-radius: 14px;
    box-shadow: var(--shadow-card);
    padding: 40px 42px;
    position: relative;
  }
  /* Hero row: no “card” chrome — flat against the page */
  .hero-grid > .block {
    border: none;
    box-shadow: none;
    border-radius: 0;
  }
  .block-hero {
    background: var(--hero-card-bg);
    color: var(--ink);
    padding: clamp(36px, 4.5vw, 52px) 0 clamp(24px, 3vw, 36px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-height: 0;
  }
  .block-meta {
    background: var(--paper);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0;
    height: 100%;
    padding: clamp(22px, 3vw, 30px) 0 clamp(18px, 2.2vw, 26px);
    min-height: 0;
    box-sizing: border-box;
  }

  /* Hero copy */
  .hi {
    font-family: var(--serif);
    font-size: clamp(60px, 7.4vw, 108px);
    line-height: 0.95;
    letter-spacing: -0.025em;
    font-weight: 500;
    margin: 0 0 32px;
    color: var(--ink);
    position: relative; z-index: 1;
    width: 100%;
    max-width: 100%;
  }
  .hi .it {
    font-style: italic; font-weight: 600;
    color: var(--accent);
  }

  .hero-body {
    font-family: var(--sans);
    font-size: clamp(19px, 1.35vw, 23px);
    line-height: 1.6;
    color: var(--ink-soft);
    max-width: 44ch;
    width: min(100%, 44ch);
    margin: 0 0 16px;
    position: relative; z-index: 1;
  }
  .hero-body em {
    font-family: var(--sans);
    font-style: italic;
    font-weight: inherit;
    font-size: inherit;
    color: var(--accent);
  }
  .hero-body strong {
    color: var(--ink); font-weight: 600;
  }

  .hero-ctas {
    display: flex;
    gap: 12px;
    margin-top: auto;
    padding-top: clamp(18px, 2.5vw, 26px);
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
    width: 100%;
  }
  .cta {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 13px 22px; border-radius: 10px;
    font-family: var(--sans);
    font-size: 15px;
    letter-spacing: -0.01em;
    text-transform: none;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid currentColor;
    transition:
      background-color 0.15s ease,
      color 0.15s ease,
      border-color 0.15s ease;
  }
  .cta-primary {
    background: var(--ink);
    color: var(--cream);
    border-color: var(--ink);
  }
  .cta-primary:hover {
    background: var(--cream);
    border-color: var(--ink);
    color: var(--ink);
  }
  .cta-ghost {
    background: transparent; color: var(--ink);
    border-color: rgba(28, 40, 57, 0.28);
  }
  .cta-ghost:hover {
    background: var(--cream);
    border-color: var(--ink);
    color: var(--ink);
  }

  /* Meta block — skills + now combined */
  .meta-section { padding: 0; }
  .meta-section + .meta-section {
    padding-top: 16px;
    border-top: 1px dashed var(--rule);
  }
  .meta-title {
    font-family: var(--sans); font-weight: 600; font-style: normal;
    font-size: 20px; letter-spacing: -0.01em;
    margin: 6px 0 12px; color: var(--ink);
  }
  .pills { display: flex; flex-wrap: wrap; gap: 6px; }
  /* Practice chips — same mono treatment as case card .tags */
  .pill {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-style: normal;
    line-height: 1.25;
    white-space: normal;
    max-width: 100%;
    text-align: center;
    background: var(--paper-alt); color: var(--ink-soft);
    padding: 4px 10px; border-radius: 999px;
    border: 1px solid var(--rule-soft);
    cursor: default;
    transition:
      background-color 0.18s ease,
      color 0.18s ease,
      border-color 0.18s ease,
      transform 0.18s ease,
      box-shadow 0.18s ease;
  }
  .pill.featured {
    background: var(--ink); color: var(--cream); border-color: var(--ink);
  }
  .pill:not(.featured):hover,
  .pill:not(.featured):focus-visible {
    background: var(--ink);
    color: var(--cream);
    border-color: var(--ink);
    transform: translate(-1px, -1px);
    box-shadow: 2px 2px 0 0 rgba(28, 40, 57, 0.14);
  }
  .pill.featured:hover,
  .pill.featured:focus-visible {
    background: var(--accent);
    color: var(--cream);
    border-color: var(--accent);
    transform: translate(-1px, -1px);
    box-shadow: 2px 2px 0 0 rgba(28, 40, 57, 0.12);
  }

  .now-list {
    list-style: none; margin: 0; padding: 0;
    display: grid; gap: 10px;
  }
  .now-row {
    display: grid; grid-template-columns: 78px 1fr;
    gap: 14px; align-items: baseline;
    padding: 8px 0; border-bottom: 1px dashed var(--rule-soft);
  }
  .now-row:last-child { border-bottom: none; }
  .now-key {
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--accent); font-weight: 600;
  }
  .now-val {
    font-family: var(--sans); font-style: normal; font-weight: 500;
    font-size: 16px; line-height: 1.3; color: var(--ink);
  }
  .now-val small {
    display: block; font-family: var(--sans); font-style: normal;
    font-size: 12px; letter-spacing: 0.04em;
    color: var(--ink-muted); margin-top: 2px;
  }
  /* --- RECENT WORK ---------------------------------- */
  .works {
    margin-top: calc(96px + 24px);
    width: 100%;
  }
  .works-head {
    border-top: 1px solid var(--ink);
    padding-top: 22px;
    margin-bottom: 36px;
  }
  .works-title {
    font-family: var(--sans); font-weight: 500;
    font-size: clamp(32px, 4vw, 48px);
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin: 0; color: var(--ink);
    max-width: min(36ch, 100%);
  }
  .works-title em { font-style: normal; color: var(--accent); font-weight: 700; }

  /* Featured card */
  .feature-card {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 18px;
    box-shadow: var(--shadow-card);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform .18s, box-shadow .18s;
    margin-bottom: 28px;
  }
  .feature-card:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow-hover); }
  .feat-img {
    background: var(--paper-alt);
    aspect-ratio: 5/4;
    position: relative; overflow: hidden;
    display: flex; align-items: stretch; justify-content: center;
    border-right: 1px solid var(--rule);
  }
  .feat-img img {
    width: 100%; height: 100%; object-fit: cover;
    object-position: top center;
    background: #fff;
  }
  .feat-img .feat-tag {
    position: absolute; top: 18px; left: 18px;
    background: var(--accent); color: var(--navy-deep);
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500;
    padding: 5px 12px; border-radius: 999px;
    border: 1px solid var(--ink);
    box-shadow: 2px 2px 0 0 rgba(28,40,57,0.18);
  }
  .feat-body {
    padding: 44px 40px 36px;
    display: flex; flex-direction: column; gap: 16px;
    justify-content: space-between;
  }
  .feat-meta-row {
    display: flex; gap: 16px; flex-wrap: wrap;
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--ink-muted); font-weight: 500;
    border-bottom: 1px dashed var(--rule); padding-bottom: 14px;
  }
  .feat-meta-row .key { color: var(--accent-deep); margin-right: 6px; }
  .feat-title {
    font-family: var(--sans); font-weight: 500;
    font-size: clamp(28px, 3.4vw, 44px);
    line-height: 1.04; letter-spacing: -0.02em;
    margin: 0; color: var(--ink);
  }
  .feat-title em { font-style: normal; color: var(--accent); font-weight: 600; }
  .feat-body p {
    font-family: var(--sans); font-size: 16px; line-height: 1.55;
    color: var(--ink-soft); margin: 0;
  }
  .feat-body p em { font-family: var(--sans); font-style: italic; color: var(--ink); font-size: 1.04em; }
  .feat-tags { display: flex; flex-wrap: wrap; gap: 6px; }
  .tag {
    /* Match global portfolio mono (styles.css --font-mono); long tags must not drift to body sans. */
    font-family: var(--font-mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase; font-weight: 500;
    font-style: normal;
    line-height: 1.25;
    white-space: normal;
    max-width: 100%;
    text-align: center;
    padding: 4px 10px; border-radius: 999px;
    background: var(--paper-alt); color: var(--ink-soft);
    border: 1px solid var(--rule-soft);
  }
  .tag.coral { background: rgba(244,67,30,0.10); color: var(--accent-deep); border-color: rgba(244,67,30,0.32); }
  .tag.ochre { background: rgba(214,140,62,0.10); color: var(--accent-2-deep); border-color: rgba(214,140,62,0.35); }
  .tag.lavender { background: rgba(170,155,196,0.14); color: #6a5a8a; border-color: rgba(170,155,196,0.36); }
  .tag.moss { background: rgba(107,125,76,0.10); color: #4f5d36; border-color: rgba(107,125,76,0.32); }
  .tag.navy { background: var(--navy); color: var(--cream); border-color: var(--navy); }

  .feat-cta {
    font-family: var(--mono); font-size: 11px;
    letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500;
    color: var(--ink); display: inline-flex; align-items: center; gap: 10px;
    margin-top: 8px;
  }
  .feat-cta .arr { color: var(--accent-deep); transition: transform .15s; }
  .feature-card:hover .feat-cta .arr { transform: translateX(4px); }

  /* Card grid — desktop: 3 equal + 2 equal (same width, left-aligned); tablet: 2 cols; mobile: 1 */
  .cards {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    column-gap: clamp(16px, 2vw, 22px);
    row-gap: clamp(28px, 3.5vw, 44px);
    width: 100%;
  }

  .home-editorial-root .cards > .card:nth-child(-n + 3) {
    grid-column: span 2;
  }

  /* Bottom row: same width as top (span 2); left-aligned — empty tracks on the right */
  .home-editorial-root .cards > .card:nth-child(4) {
    grid-column: 1 / span 2;
  }

  .home-editorial-root .cards > .card:nth-child(5) {
    grid-column: 3 / span 2;
  }

  @media (max-width: 1100px) and (min-width: 681px) {
    .cards {
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-editorial-root .cards > .card:nth-child(-n + 3),
    .home-editorial-root .cards > .card:nth-child(4),
    .home-editorial-root .cards > .card:nth-child(5) {
      grid-column: auto;
    }

    .home-editorial-root .cards > .card:last-child:nth-child(odd) {
      grid-column: 1 / -1;
      max-width: 560px;
      width: 100%;
      margin-inline: auto;
    }
  }

  @media (max-width: 680px) {
    .cards {
      grid-template-columns: minmax(0, 1fr);
    }

    .home-editorial-root .cards > .card:nth-child(-n + 3),
    .home-editorial-root .cards > .card:nth-child(4),
    .home-editorial-root .cards > .card:nth-child(5) {
      grid-column: auto;
    }

    .home-editorial-root .cards > .card:last-child:nth-child(odd) {
      grid-column: auto;
      max-width: none;
      margin-inline: 0;
    }
  }

  .card {
    background: var(--paper);
    border: 1.5px solid var(--ink);
    border-radius: 14px;
    box-shadow: var(--shadow-card);
    padding: 22px;
    display: flex; flex-direction: column; gap: 12px;
    text-decoration: none; color: inherit;
    transition:
      transform 0.18s ease,
      box-shadow 0.18s ease,
      background-color 0.2s ease,
      border-color 0.2s ease;
    position: relative;
  }
  .card:hover {
    transform: translate(-3px, -3px);
    box-shadow: var(--shadow-hover);
    background-color: var(--paper-alt);
    border-color: color-mix(in srgb, var(--ink) 88%, var(--accent) 12%);
  }
  .card-num {
    position: absolute; top: 18px; right: 22px;
    font-family: var(--mono); font-style: normal; font-weight: 500;
    font-size: 11px; color: var(--ink-muted); letter-spacing: 0.14em; text-transform: uppercase;
  }
  .card-thumb {
    width: 100%; aspect-ratio: 4/3;
    border: 1px solid var(--rule-soft);
    border-radius: 8px; overflow: hidden;
    background: var(--paper-alt);
    margin-bottom: 4px;
    position: relative;
  }
  .card-thumb img {
    width: 100%; height: 100%; object-fit: cover;
    object-position: top center; display: block;
    background: #fff;
  }
  /* Real UI thumbs — zoom in slightly; per-card origin so the focal UI stays in frame */
  .home-editorial-root .cards > .card[href="./ad-studio.html"] .card-thumb img {
    transform: scale(1.14);
    transform-origin: 50% 10%;
    object-position: 50% 6%;
  }
  .home-editorial-root .cards > .card[href="./ad-creation.html"] .card-thumb img {
    transform: scale(1.22);
    transform-origin: 46% 18%;
    object-position: 44% 10%;
  }
  .home-editorial-root .cards > .card[href="./personalized-offers.html"] .card-thumb img {
    transform: scale(1.2);
    transform-origin: 50% 40%;
    object-position: 48% 34%;
  }
  .card-thumb.ph { background: var(--paper-alt); }
  .card-thumb svg { width: 100%; height: 100%; display: block; }
  .card-meta {
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--ink-muted); font-weight: 500;
    display: flex; gap: 14px; flex-wrap: wrap;
    margin-bottom: 2px;
  }
  .card-meta .org { color: var(--accent-deep); }
  .card-title {
    font-family: var(--sans); font-weight: 500;
    font-size: 22px; line-height: 1.15; letter-spacing: -0.015em;
    margin: 0; color: var(--ink);
  }
  .card-title em { font-style: italic; color: var(--accent-deep); }
  .card-body {
    font-family: var(--sans); font-size: 14px; line-height: 1.55;
    color: var(--ink-soft); margin: 0; flex: 1;
  }
  .card-foot {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 12px; border-top: 1px dashed var(--rule);
    margin-top: 4px;
  }
  .card-tags { display: flex; flex-wrap: wrap; gap: 6px; }
  .card-arrow {
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase; font-weight: 500;
    color: var(--ink); display: inline-flex; align-items: center; gap: 6px;
  }
  .card-arrow .arr { color: var(--accent-deep); transition: transform .15s; }
  .card:hover .card-arrow .arr { transform: translateX(4px); }

  /* Closing card — dark scrapbook */
  .scrapbook-card {
    background: var(--navy);
    color: var(--cream);
    text-align: left;
    padding: 36px 32px;
    display: flex; flex-direction: column; justify-content: space-between; gap: 24px;
    border-color: var(--navy);
  }
  .scrapbook-card .card-title { color: var(--cream); font-size: 26px; }
  .scrapbook-card .card-title em { color: var(--accent); }
  .scrapbook-card .card-body { color: rgba(245,242,234,0.75); }
  .scrapbook-card .card-meta { color: rgba(245,242,234,0.5); }
  .scrapbook-card .card-meta .org { color: var(--accent); }
  .scrapbook-card .card-foot { border-top-color: rgba(245,242,234,0.18); }
  .scrapbook-card .card-arrow { color: var(--cream); }
  .scrapbook-card .card-arrow .arr { color: var(--accent); }
  .scrapbook-card:hover {
    background-color: color-mix(in srgb, var(--navy) 78%, var(--cream) 22%);
    border-color: color-mix(in srgb, var(--navy) 70%, var(--accent) 30%);
  }

  /* --- ABOUT / SIDE STRIP -------------------------- */
  .colophon {
    margin-top: 120px;
    display: grid;
    grid-template-columns: minmax(0, 1.72fr) minmax(220px, 0.82fr);
    gap: clamp(28px, 4vw, 56px);
    padding-top: 36px;
    border-top: 1px solid var(--ink);
    width: 100%;
  }
  .colophon-l h3 {
    font-family: var(--sans); font-weight: 500;
    font-size: clamp(32px, 4vw, 48px);
    line-height: 1.05; letter-spacing: -0.02em;
    margin: 12px 0 16px;
    max-width: min(36ch, 100%);
  }
  .colophon-l h3 em { font-style: normal; color: var(--accent); font-weight: 700; }
  .colophon-l p {
    font-family: var(--sans); font-style: normal; font-size: 17px;
    line-height: 1.45; color: var(--ink-soft);
    max-width: min(68ch, 100%); margin: 0 0 18px;
  }
  .colophon-cta {
    font-family: var(--mono); font-size: 11px;
    letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500;
    color: var(--ink); text-decoration: none; padding-bottom: 4px;
    border-bottom: 1.5px solid var(--accent);
    display: inline-flex; align-items: center; gap: 10px;
    margin-top: 8px;
  }
  .colophon-cta:hover { color: var(--accent-deep); }

  .colophon-r {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em;
    align-content: start;
    padding-top: 0.25rem;
  }
  .colophon-r a {
    color: var(--ink); text-decoration: none;
    display: flex; justify-content: space-between;
    padding: 10px 0; border-bottom: 1px solid var(--rule);
    transition: color .12s;
  }
  .colophon-r a:hover { color: var(--accent-deep); }
  .colophon-r a .arr { color: var(--ink-muted); }

  /* Foot */
  .foot {
    margin-top: 80px;
    padding: 24px 0;
    border-top: 1px solid var(--rule);
    display: flex; justify-content: space-between; align-items: center;
    font-family: var(--mono); font-size: 10px;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--ink-muted); flex-wrap: wrap; gap: 12px;
  }
  .foot .foot-sig {
    font-family: var(--sans); font-style: normal; font-size: 14px;
    color: var(--ink); letter-spacing: 0; text-transform: none;
    font-weight: 600;
  }

  /* --- RESPONSIVE ----------------------------------- */
  @media (max-width: 900px) {
    .home-editorial-root.page {
      padding: 32px var(--home-gutter-x) 80px;
    }
    .hero-grid { grid-template-columns: 1fr; }
    .block-hero { padding: 32px 0 26px; }
    .feature-card { grid-template-columns: 1fr; }
    .colophon {
      grid-template-columns: 1fr;
      gap: 32px;
    }
    .colophon-r {
      align-content: start;
      padding-top: 0;
    }
  }

.home-editorial-root .feat-img img,
.home-editorial-root .card-thumb img {
  border-radius: 0;
  box-shadow: none;
  transition: none;
}
