/*
 * MAIN STYLES — Dogs Talk Philosophy
 * ─────────────────────────────────────────────────────────────
 * Architecture: @layer cascade control + native CSS nesting
 * Council MANIFESTO.md + SYSTEM.md before editing.
 * Last reviewed: 25 February 2026
 *
 * ─────────────────────────────────────────────────────────────
 * FOR SCSS DEVELOPERS — HOW TO READ THIS FILE
 * ─────────────────────────────────────────────────────────────
 *
 * 1. @layer replaces "file order = specificity order".
 *    In SCSS you controlled cascade by which partial was imported last.
 *    Here you declare the priority order explicitly at the top, then
 *    put styles in the right layer — they always resolve in the declared
 *    order, no matter where in the file they appear.
 *
 * 2. Native nesting (& .child {}) is identical to SCSS nesting.
 *    Pseudo-classes, pseudo-elements, modifiers, media queries — all
 *    can be nested inside the parent selector. No preprocessor needed.
 *
 * 3. @media can be nested inside a selector.
 *    Instead of a single responsive section at the bottom of the file,
 *    the breakpoint for a component lives INSIDE that component.
 *    This is the biggest flexibility gain over the flat version.
 *
 * 4. No @mixin / @include — custom properties handle reuse.
 *    Where you would have written a mixin, a token does the same job.
 *    For structural patterns, a utility layer works.
 * ─────────────────────────────────────────────────────────────
 */

@import url('tokens.css');
/* Cormorant Garamond — Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&display=swap');
/* Elza — loaded via Adobe Fonts <link> in index.html */


/* ═══════════════════════════════════════════════════════════
   LAYER ORDER DECLARATION
   ───────────────────────────────────────────────────────────
   This is the SCSS @import order — but explicit and unbreakable.
   Lower layers always lose to higher layers, regardless of
   where the actual rules appear in the file.
   ═══════════════════════════════════════════════════════════ */

@layer reset, base, components, sections, utilities;


/* ═══════════════════════════════════════════════════════════
   LAYER: reset
   ═══════════════════════════════════════════════════════════ */

@layer reset {

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

  html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;

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

  body {
    background-color: var(--color-paper);
    color: var(--color-ink);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    font-weight: 300;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
  }

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

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

  p, h1, h2, h3, h4, h5, h6 {
    overflow-wrap: break-word;
    hyphens: auto;
  }

  ul[role='list'],
  ol[role='list'] {
    list-style: none;
  }

  a {
    color: inherit;
    text-decoration: none;
  }

  hr {
    border: none;
    border-top: var(--border);
    margin: 0;
  }

  @keyframes hero-line {
    from { transform: translateY(115%); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
  }

  @keyframes fade-up {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  @keyframes fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  @media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
    }
  }
}


/* ═══════════════════════════════════════════════════════════
   LAYER: base
   ───────────────────────────────────────────────────────────
   HTML element defaults + typographic scale utilities.
   Low-specificity — any component style overrides these
   (components layer sits above base in the declared order).
   ═══════════════════════════════════════════════════════════ */

@layer base {

  h1, .t-h1 {
    font-family: var(--font-display);
    font-size: var(--text-h1);
    font-weight: 900;
    line-height: 1.05;   /* 160 × 1.05 = 168px = 7 × rhythm ✓ */
    letter-spacing: -0.01em;
    text-transform: uppercase;
    hyphens: none;
  }

  h2, .t-h2 {
    font-family: var(--font-display);
    font-size: var(--text-h2);
    font-weight: 300;
    line-height: 1.18;   /* 51 × 1.18 ≈ 60px = 2.5 × rhythm ✓ */
    letter-spacing: 0.01em;
    text-transform: uppercase;
    hyphens: none;
  }

  h3, .t-h3 {
    font-family: var(--font-display);
    font-size: var(--text-h3);
    font-weight: 300;
    line-height: 1.26;   /* 38 × 1.26 ≈ 48px = 2 × rhythm ✓ */
    letter-spacing: 0.02em;
    text-transform: uppercase;
    hyphens: none;
  }

  h4, .t-h4 {
    font-family: var(--font-display);
    font-size: var(--text-h4);
    font-weight: 300;
    line-height: 1.29;   /* 28 × 1.29 ≈ 36px = 1.5 × rhythm ✓ */
    letter-spacing: 0.06em;
    text-transform: uppercase;
  }

  p {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    font-weight: 400;
    line-height: 1.65;
    max-width: var(--content-text);
  }

  small,
  .t-small {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 400;
    line-height: 2;
  }

  .t-display {
    font-family: var(--font-display);
    font-size: var(--text-display);
    font-weight: 300;
    line-height: 1;
    letter-spacing: 0em;
    text-transform: uppercase;
    hyphens: none;
  }

  .t-lead {
    font-family: var(--font-serif);
    font-size: var(--text-lead);
    font-weight: 400;
    line-height: 1.6;
  }

  .t-micro {
    font-family: var(--font-sans);
    font-size: var(--text-micro);
    font-weight: 500;
    line-height: 2.67;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }

  .t-italic { font-style: italic; }
  .t-muted  { color: var(--color-ink-muted); }
}


/* ═══════════════════════════════════════════════════════════
   LAYER: components
   ───────────────────────────────────────────────────────────
   Each component is self-contained: base styles, variants,
   pseudo-classes, AND its own responsive breakpoints — all
   nested together. This is the SCSS partial pattern, but
   without a build step.
   ═══════════════════════════════════════════════════════════ */

@layer components {

  /* ── Eyebrow ── */
  .eyebrow {
    font-family: var(--font-sans);
    font-size: var(--text-micro);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-ink-muted);
    display: block;
    margin-bottom: var(--space-3);
  }

  /* ── Footnote ── */
  .footnote {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 400;
    font-style: italic;
    color: var(--color-ink-muted);
    line-height: 2;
    margin-top: var(--space-3);
  }

  /* ── Meta line ── */
  .meta {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 400;
    color: var(--color-ink-muted);
    letter-spacing: 0.04em;
  }

  /* ── Scroll reveal ──────────────────────────────────────
     JS adds .is-visible via IntersectionObserver.
     Optional --reveal-delay custom property for stagger
     (set via inline style="--reveal-delay: 120ms").
  ─────────────────────────────────────────────────────── */
  [data-reveal] {
    opacity: 0;
    transform: translateY(20px);
    transition:
      opacity 500ms var(--ease-out-expo) var(--reveal-delay, 0ms),
      transform 500ms var(--ease-out-expo) var(--reveal-delay, 0ms);

    &.is-visible {
      opacity: 1;
      transform: none;
    }
  }

  /* ── Button ──────────────────────────────────────────────
     SCSS equivalent:
       .btn { &:hover { ... } &--inverse { &:hover { ... } } }
     Identical syntax in native CSS.
  ─────────────────────────────────────────────────────────── */
  .btn {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: var(--text-micro);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 12px 32px;
    background-color: var(--color-ink);
    color: var(--color-paper);
    border: var(--border);
    cursor: pointer;
    transition:
      background-color var(--duration-base) var(--ease),
      color var(--duration-base) var(--ease);
    appearance: none;
    border-radius: 0;
    white-space: nowrap;

    &:hover,
    &:focus-visible {
      background-color: var(--color-paper);
      color: var(--color-ink);
      outline: none;
    }

    &:focus-visible {
      outline: 2px solid var(--color-ink);
      outline-offset: 2px;
    }

    &--inverse {
      background-color: var(--color-paper);
      color: var(--color-ink);
      border-color: var(--color-paper);

      &:hover,
      &:focus-visible {
        background-color: transparent;
        color: var(--color-paper);
      }
    }
  }

  /* ── Form ── */
  .form {
    width: 100%;
  }

  .form-group {
    margin-bottom: var(--space-4);

    &:last-of-type {
      margin-bottom: var(--space-5);
    }
  }

  .form-label {
    font-family: var(--font-sans);
    font-size: var(--text-micro);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    display: block;
    margin-bottom: var(--space-1);
  }

  .form-field {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    font-weight: 300;
    line-height: 1.5;
    width: 100%;
    padding: 11px 0;
    background-color: transparent;
    border: none;
    border-bottom: 1px solid var(--color-ink);
    border-radius: 0;
    outline: none;
    color: var(--color-ink);
    transition: border-color var(--duration-fast) var(--ease);
    appearance: none;

    &::placeholder {
      color: var(--color-ink-muted);
      font-weight: 300;
    }

    &:focus {
      border-bottom-width: 2px;
      padding-bottom: 10px;
    }

    &:is(textarea) {
      resize: vertical;
      min-height: 96px;
    }
  }

  .form-status {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 400;
    margin-top: var(--space-3);
    display: none;

    &--success {
      color: var(--color-ink);
      display: block;
    }

    &--error {
      color: var(--color-ink);
      font-style: italic;
      display: block;
    }
  }

  /* ── Expertise list ── */
  .expertise-list {
    list-style: none;
    padding: 0;
    margin: 0;

    /* The stagger system animates LI children — suppress the container
       fade-up that [data-reveal] would otherwise also apply to the UL */
    &[data-reveal] {
      opacity: 1;
      transform: none;
    }

    & li {
      font-family: var(--font-display);
      font-size: var(--text-lead);
      font-weight: 300;
      letter-spacing: -0.01em;
      line-height: 1.71;
      padding: var(--space-3) 0;
      border-bottom: 1px solid var(--color-ink);
      opacity: 0;
      transform: translateX(-16px);
      transition:
        opacity 500ms var(--ease-out-expo),
        transform 500ms var(--ease-out-expo);

      &:first-child {
        border-top: 1px solid var(--color-ink);
      }

      @media (max-width: 767px) {
        font-size: var(--text-base);
      }
    }

    /* Stagger triggered when .is-visible added to the list itself */
    &.is-visible li {
      opacity: 1;
      transform: none;

      &:nth-child(1) { transition-delay: 0ms; }
      &:nth-child(2) { transition-delay: 80ms; }
      &:nth-child(3) { transition-delay: 160ms; }
      &:nth-child(4) { transition-delay: 240ms; }
      &:nth-child(5) { transition-delay: 320ms; }
    }
  }

  /* ── Exclusion list ── */
  .exclusion-list {
    list-style: none;
    padding: 0;
    margin: var(--space-3) 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-1) var(--space-4);

    & li {
      font-family: var(--font-sans);
      font-size: var(--text-small);
      font-weight: 400;
      color: var(--color-ink-muted);
      letter-spacing: 0.06em;
      text-transform: uppercase;
    }
  }

  /* ── Two-col layout ── */
  .two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-6);
    align-items: start;

    @media (max-width: 1023px) {
      grid-template-columns: 1fr;
      gap: var(--space-4);
    }
  }
}


/* ═══════════════════════════════════════════════════════════
   LAYER: sections
   ───────────────────────────────────────────────────────────
   Page section styles. BEM children nested inside their block.
   Each block owns its responsive behaviour — no separate
   media query section at the bottom of the file.
   ═══════════════════════════════════════════════════════════ */

@layer sections {

  /* ── Container ── */
  .container {
    width: 100%;
    max-width: var(--content-max);
    margin-inline: auto;
    padding-inline: var(--outer-margin);
  }

  /* ── Section base ── */
  .section {
    padding-top: var(--space-7);
    padding-bottom: var(--space-7);

    @media (max-width: 767px) {
      padding-top: var(--space-5);
      padding-bottom: var(--space-5);
    }
  }

  /* ── Hero ── */
  .hero {
    min-height: 100svh;
    display: flex;
    flex-direction: row;
  }

  @media (max-width: 767px) {
    .hero { flex-direction: column; }
  }

  /* Panels: shared */
  .hero__panel {
    flex: 0 0 50%;
    width: 50%;
    min-height: 100svh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: var(--space-5) var(--space-4);
  }

  @media (max-width: 1023px) {
    .hero__panel { padding: var(--space-4) var(--space-3); }
  }

  @media (max-width: 767px) {
    .hero__panel {
      flex: 0 0 100%;
      width: 100%;
      min-height: 50svh;
      padding: var(--space-4) var(--space-3);
    }
  }

  /* Left panel */
  .hero__panel--left {
    background-color: var(--color-paper);
    color: var(--color-ink);
    justify-content: flex-end;
    border-right: var(--border);
    position: relative;
  }

  .hero__panel--left::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 7px;
    height: 96px;
    background-color: var(--color-ink);
  }

  @media (max-width: 767px) {
    .hero__panel--left {
      border-right: none;
      border-bottom: var(--border);
    }
    .hero__panel--left::before { display: none; }
  }

  /* Right panel */
  .hero__panel--right {
    background-color: var(--color-ink);
    color: var(--color-paper);
    justify-content: space-between;
  }

  /* Left panel elements */
  .hero__headline {
    font-family: var(--font-display);
    font-size: clamp(4rem, 7vw, 120px);
    font-weight: 900;
    line-height: 0.90;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    hyphens: none;
    max-width: none;
    margin-bottom: 0;
    overflow: hidden;
  }

  .hero__line {
    display: block;
    animation: hero-line 1000ms var(--ease-out-expo) both;
  }

  .hero__line:nth-child(2) { animation-delay: 140ms; }

  @media (max-width: 767px) {
    .hero__headline { font-size: clamp(3rem, 10vw, 72px); }
  }

  .hero__footnote {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 400;
    font-style: italic;
    color: var(--color-ink-muted);
    margin-top: var(--space-3);
    animation: fade-in 400ms ease 1100ms both;
  }

  /* Right panel elements */
  .hero__brand {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  .hero__brand-name {
    font-family: var(--font-display);
    font-size: clamp(3rem, 5vw, 90px);
    font-weight: 900;
    line-height: 0.92;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    color: var(--color-paper);
    max-width: none;
    animation: fade-up 900ms var(--ease-out-expo) 300ms both;
  }

  @media (max-width: 767px) {
    .hero__brand-name { font-size: clamp(2.5rem, 9vw, 60px); }
  }

  .hero__brand-sub {
    font-family: var(--font-display);
    font-size: var(--text-lead);
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--color-paper);
    margin-top: var(--space-3);
    max-width: none;
    animation: fade-in 500ms ease 700ms both;
  }

  .hero__event {
    text-align: center;
    animation: fade-in 400ms ease 1000ms both;
  }

  .hero__event p {
    font-family: var(--font-sans);
    font-size: var(--text-small);
    font-weight: 300;
    line-height: 2;
    color: rgba(255, 255, 255, 0.6);
    max-width: none;
  }

  .hero__event strong {
    font-weight: 700;
    color: var(--color-paper);
    display: block;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-size: var(--text-micro);
    margin-bottom: var(--space-1);
  }

  /* ── Intro ── */
  .intro {

    &__meta {
      display: flex;
      gap: var(--space-4);
      margin-bottom: var(--space-5);
      flex-wrap: wrap;

      @media (max-width: 767px) {
        gap: var(--space-3);
        flex-direction: column;
      }
    }

    &__lead {
      font-family: var(--font-display);
      font-size: clamp(1.5rem, 2.8vw, 48px);
      font-weight: 700;
      line-height: 1.2;
      letter-spacing: -0.02em;
      max-width: var(--content-text);
      margin-bottom: var(--space-4);
    }

    &__body {
      max-width: var(--content-text);

      & p + p {
        margin-top: var(--space-3);
      }
    }
  }

  /* ── Method ── */
  .method {

    &__claim {
      font-family: var(--font-display);
      font-size: clamp(2.5rem, 6vw, 96px);
      font-weight: 700;
      line-height: 1.0;
      letter-spacing: -0.03em;
      text-transform: uppercase;
      max-width: 800px;
      margin-bottom: var(--space-5);

      @media (max-width: 767px) { font-size: clamp(2rem, 8vw, 56px); }
    }

    &__body {
      max-width: var(--content-narrow);
    }
  }

  /* ── Expertise ── */
  .expertise {

    &__header {
      margin-bottom: var(--space-5);
    }

    &__note {
      font-family: var(--font-serif);
      font-size: var(--text-lead);
      font-weight: 400;
      font-style: italic;
      max-width: 480px;
      line-height: 1.71;
      margin-top: var(--space-5);
      padding-top: var(--space-5);
      border-top: var(--border);
    }

    &__exclusions {
      margin-top: var(--space-4);
    }

    &__exclusions-label {
      font-family: var(--font-sans);
      font-size: var(--text-micro);
      font-weight: 500;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--color-ink-muted);
      margin-bottom: var(--space-2);
      display: block;
    }
  }

  /* ── Focus ── */
  .focus {

    &__cities {
      display: flex;
      gap: 0;
      margin-top: var(--space-5);
      border-top: var(--border);

      @media (max-width: 767px) {
        flex-direction: column;
      }
    }

    &__city {
      flex: 1;
      padding: var(--space-5) var(--space-4) var(--space-5) 0;
      border-right: var(--border);

      &:last-child {
        border-right: none;
        padding-left: var(--space-4);
        padding-right: 0;
      }

      @media (max-width: 767px) {
        border-right: none;
        border-bottom: var(--border);
        padding: var(--space-4) 0;

        &:last-child {
          border-bottom: none;
          padding-left: 0;
        }
      }
    }

    &__city-name {
      font-family: var(--font-display);
      font-size: clamp(2rem, 4vw, 64px);
      font-weight: 700;
      line-height: 1.0;
      letter-spacing: -0.03em;
      text-transform: uppercase;
      margin-bottom: var(--space-2);
    }

    &__city-desc {
      font-family: var(--font-sans);
      font-size: var(--text-small);
      font-weight: 300;
      color: var(--color-ink-muted);
      line-height: 2;
      max-width: 280px;
    }
  }

  /* ── Contact ── */
  .contact {

    &__claim {
      font-family: var(--font-display);
      font-size: clamp(3rem, 9vw, 140px);
      font-weight: 900;
      line-height: 0.95;
      letter-spacing: -0.04em;
      text-transform: uppercase;
      margin-bottom: var(--space-5);
      hyphens: none;

      @media (max-width: 1023px) { font-size: clamp(2.5rem, 7vw, 96px); }
      @media (max-width: 767px)  { font-size: clamp(2rem, 9vw, 60px); }
    }

    &__sub {
      font-family: var(--font-sans);
      font-size: var(--text-base);
      font-weight: 300;
      line-height: 1.5;
      color: var(--color-ink-muted);
      margin-bottom: var(--space-6);
      max-width: 440px;
    }

    &__form-wrap {
      max-width: var(--content-narrow);
    }
  }

  /* ── Footer ── */
  .footer {
    padding-top: var(--space-4);
    padding-bottom: var(--space-4);
    border-top: var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    flex-wrap: wrap;

    @media (max-width: 767px) {
      flex-direction: column;
      align-items: flex-start;
      gap: var(--space-2);
    }

    &__brand {
      font-family: var(--font-sans);
      font-size: var(--text-micro);
      font-weight: 500;
      letter-spacing: 0.12em;
      text-transform: uppercase;
    }

    &__meta {
      font-family: var(--font-sans);
      font-size: var(--text-micro);
      font-weight: 400;
      letter-spacing: 0.06em;
      color: var(--color-ink-muted);
      text-transform: uppercase;
    }
  }
}


/* ═══════════════════════════════════════════════════════════
   LAYER: utilities
   ───────────────────────────────────────────────────────────
   Single-purpose helpers. Top layer — always win without
   needing !important. Outer margin token overrides live here
   since they affect all sections globally.
   ═══════════════════════════════════════════════════════════ */

@layer utilities {

  .col-wide   { max-width: var(--content-wide); }
  .col-text   { max-width: var(--content-text); }
  .col-narrow { max-width: var(--content-narrow); }

  @media (max-width: 1023px) {
    :root { --outer-margin: var(--space-4); }
  }

  @media (max-width: 767px) {
    :root { --outer-margin: var(--space-3); }
  }
}



