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

        :root {
      --bg:          #FFFFFF;
      --bg-raised:   #F5F5F3;
      --text:        #1A1A1A;
            --text-secondary: #D1D1D1;
      --text-muted:  #999999;
      --text-link:   rgba(0,0,0,0.22);
      --accent:      #FF5C00;
      --sidebar-w:   300px;
      --border:      rgba(0,0,0,0.08);
      --card-bg:     #EBEBEB;
      --row-hover:   rgba(0,0,0,0.04);
      --max-w:       760px;
      --side-pad:    48px;
      --nav-h:       80px;
      --col:         600px;
      --pad:         24px;
      --font-main:   "Neue Haas Grotesk Display Pro", "Neue Haas Grotesk", "Inter", sans-serif;
    }

    html.dark {
      --bg:          #1F1F1F;
      --bg-raised:   #2A2A2A;
      --text:        #E6E6E6;
      --text-muted:  #666666;
      --text-link:   rgba(255,255,255,0.18);
      --border:      rgba(255,255,255,0.07);
      --card-bg:     #2C2C2C;
      --row-hover:   rgba(255,255,255,0.05);
    }

    html { font-size: 16px; scroll-behavior: smooth; }

        body {
            background: var(--bg);
            color: var(--text);
            font-family: var(--font-main);
            -webkit-font-smoothing: antialiased;
            overflow: hidden;
        }

        .layout-wrapper {
            display: flex;
            height: 100vh;
            width: 100vw;
        }

        /* ─── MAIN CONTENT ─── */
        .scroll-container {
            flex: 1;
            margin-left: var(--sidebar-w);
            height: 100vh;
            overflow-y: auto;
            scroll-behavior: smooth;
        }

        main {
            display: flex;
            justify-content: center;
            padding: 64px 40px 120px 40px;
        }

        .container {
            max-width: 540px;
            width: 100%;
            display: flex;
            flex-direction: column;
            gap: 48px;
        }

        .back-btn-circular {
            width: 16px;
            height: 16px;
            border-radius: 50%;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: all 0.15s ease;
            background: transparent;
            color: var(--text);
            text-decoration: none;
            border: none;
            cursor: pointer;
            align-self: flex-start;
        }

        .back-btn-circular:hover {
            background: transparent;
            color: var(--accent);
        }

        .back-btn-circular:active {
            transform: scale(0.97);
        }

        .back-btn-circular svg {
            width: 16px;
            height: 16px;
        }

        
    /* ── PAGE HEADER ── */
    .page-header {
      padding: 0 0 4px;
    }

    .page-header h1 {
      font-size: 14px;
      font-weight: 500;
      color: var(--text);
      margin-bottom: 4px;
      letter-spacing: -0.01em;
    }

    .page-header p {
      font-size: 14px;
      font-weight: 400;
      color: var(--text-muted);
    }

    /* ── WORK LIST ── */
    .work-list {
      padding-bottom: 80px;
    }

    /* ── COMPANY BLOCK ── */
    .company-block {
      border: none;
    }

    /* ── COMPANY ROW ── */
    .company-row {
      display: flex;
      align-items: center;
      gap: 0;
      padding: 4px 0;
      cursor: default;
      position: relative;
    }

    .company-block.has-projects .company-row {
      cursor: pointer;
    }

    /* The pill that gets the hover bg.
       Negative side margins so the visible content (logo / role)
       aligns flush with the page-header (container) left edge,
       while the hover pill keeps its 10px breathing room. */
    .company-row-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      flex: 1;
      gap: 16px;
      padding: 8px 10px;
      margin: 0 -10px;
      border-radius: 10px;
      transition: background 0.15s ease;
    }

    .company-block.has-projects .company-row:hover .company-row-inner {
      background: var(--row-hover);
    }

    /* Left chevron — sits in the gutter to the left of the row,
       so it never pushes the logo inward */
    .company-chevron {
      position: absolute;
      left: -28px;
      top: 50%;
      width: 20px;
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--text-muted);
      opacity: 0;
      transform: translateY(-50%);
      transition: opacity 0.15s ease, transform 0.3s cubic-bezier(0.76, 0, 0.24, 1);
    }

    .company-chevron svg { display: block; }

    .company-block.has-projects .company-row:hover .company-chevron {
      opacity: 1;
    }

    .company-block.has-projects.open .company-chevron {
      opacity: 1;
      transform: translateY(-50%) rotate(90deg);
    }

    .company-chevron-spacer {
      display: none;
    }

    .company-left {
      display: flex;
      align-items: center;
      gap: 12px;
      min-width: 0;
    }

    /* Logo — larger to match reference */
    .company-logo {
      width: 32px; height: 32px;
      border-radius: 8px;
      background: var(--card-bg);
      flex-shrink: 0;
      overflow: hidden;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: background 0.3s ease;
    }

    .company-logo img {
      width: 100%; height: 100%;
      object-fit: cover;
      display: block;
      border-radius: 8px;
    }

    /* Per-company placeholder tints */
    .company-block[data-company="catch"]    .company-logo { background: #D4EAD0; }
    .company-block[data-company="basis"]    .company-logo { background: #D0D9EA; }
    .company-block[data-company="dioscuri"] .company-logo { background: #EAD9D0; }
    .company-block[data-company="waihi"]    .company-logo { background: #D6EAD0; }
    .company-block[data-company="auckland"] .company-logo { background: #D0E6EA; }
    .company-block[data-company="saluberty"] .company-logo { background: #E8D0EA; }
    .company-block[data-company="hers"]     .company-logo { background: #EAD0D9; }

    html.dark .company-block[data-company="catch"]    .company-logo { background: #1a2e1a; }
    html.dark .company-block[data-company="basis"]    .company-logo { background: #1a1e2e; }
    html.dark .company-block[data-company="dioscuri"] .company-logo { background: #2e1e1a; }
    html.dark .company-block[data-company="waihi"]    .company-logo { background: #1a2a1a; }
    html.dark .company-block[data-company="auckland"] .company-logo { background: #1a262e; }
    html.dark .company-block[data-company="saluberty"] .company-logo { background: #2a1a2e; }
    html.dark .company-block[data-company="hers"]     .company-logo { background: #2e1a22; }

    .company-name {
      font-size: 14px;
      font-weight: 500;
      color: var(--text);
      white-space: nowrap;
      text-decoration: none;
      letter-spacing: -0.01em;
    }

    a.company-name {
      text-underline-offset: 3px;
      text-decoration-thickness: 1px;
    }

    a.company-name:hover { text-decoration: underline; }

    .company-right {
      display: flex;
      align-items: flex-end;
      flex-shrink: 0;
    }

    .company-role,
    .company-year {
      font-size: 14px;
      font-weight: 400;
      color: var(--text-muted);
      white-space: nowrap;
    }

    /* ── PROJECTS PANEL ── */
    .projects-panel {
      overflow: hidden;
      max-height: 0;
      transition: max-height 0.5s cubic-bezier(0.76, 0, 0.24, 1);
      /* flush with page-header left edge */
      padding-left: 0;
    }

    .company-block.open .projects-panel {
      max-height: 3000px;
    }

    .projects-inner {
      padding: 12px 0 24px;
      display: flex;
      flex-direction: column;
      gap: 14px;
    }

    .company-impact-card {
      border: 1px solid var(--border);
      border-radius: 12px;
      background: var(--bg);
      padding: 18px 20px;
      display: flex;
      flex-direction: column;
      gap: 18px;
    }

    .company-impact-card > p,
    .company-impact-card p {
      font-size: 13px;
      line-height: 1.5;
      color: var(--text-muted);
    }

    .company-impact-meta {
      display: flex;
      flex-direction: column;
      gap: 16px;
    }

    .company-impact-meta h3 {
      font-size: 12px;
      line-height: 1.35;
      font-weight: 500;
      color: var(--text);
      margin-bottom: 4px;
      letter-spacing: -0.01em;
    }

    .company-impact-meta .company-impact-role {
      color: var(--text);
      margin-bottom: 4px;
    }

    .company-impact-case-study {
      border: 1px solid var(--border);
      border-radius: 8px;
      overflow: hidden;
      margin-top: 2px;
    }

    .company-impact-thumb-link {
      display: block;
      text-decoration: none;
      color: inherit;
    }

    .company-impact-card .company-impact-case-study .project-thumb {
      margin: 0;
      border: none;
      border-radius: 0;
    }

    .company-impact-thumb-link:hover .project-thumb img {
      transform: scale(1.02);
    }

    .company-impact-media {
      border: 1px solid var(--border);
      border-radius: 8px;
      overflow: hidden;
    }

    .company-impact-card .company-impact-media .project-thumb {
      margin: 0;
      border: none;
      border-radius: 0;
      min-height: 160px;
    }

    .company-impact-case-study .project-footer {
      background: var(--bg);
    }

    /* ── PROJECT CARD ── */
    .project-card {
      border: 1px solid var(--border);
      border-radius: 12px;
      overflow: hidden;
      background: var(--bg);
      transition: border-color 0.2s ease;
    }

    .project-card:hover { border-color: rgba(0,0,0,0.14); }
    html.dark .project-card:hover { border-color: rgba(255,255,255,0.13); }

    /* Header: title + description FIRST */
    .project-card-header {
      padding: 18px 20px 16px;
    }

    .project-card-header h3 {
      font-size: 14px;
      font-weight: 500;
      color: var(--text);
      margin-bottom: 4px;
      letter-spacing: -0.01em;
    }

    .project-card-header p {
      font-size: 13px;
      font-weight: 400;
      color: var(--text-muted);
      line-height: 1.5;
    }

    /* Image BELOW header — floats inside the card with subtle inset */
    .project-thumb {
      aspect-ratio: 16 / 10;
      min-height: 280px;
      background: var(--card-bg);
      overflow: hidden;
      position: relative;
      transition: background 0.3s ease, border-color 0.2s ease;
      margin: 0 10px 10px;
      border: 1px solid var(--border);
      border-radius: 8px;
    }

    .project-thumb img {
      width: 100%; height: 100%;
      object-fit: cover;
      display: block;
      transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }

    .project-placeholder-grid {
      display: flex;
      flex-direction: column;
      gap: 10px;
      padding: 10px;
    }

    .project-placeholder-grid .project-thumb {
      min-height: 160px;
      margin: 0;
    }

    .project-card:hover .project-thumb img { transform: scale(1.02); }

    /* Shimmer on empty thumbs */
    .project-thumb::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(108deg, transparent 36%, rgba(255,255,255,0.14) 50%, transparent 64%);
      background-size: 240% 100%;
      animation: shimmer 2.4s ease-in-out infinite;
      border-radius: 8px;
    }

    .project-thumb.has-image::after { display: none; }

    @keyframes shimmer {
      0%   { background-position: 240% 0; }
      100% { background-position: -240% 0; }
    }

    html.dark .project-thumb::after {
      background: linear-gradient(108deg, transparent 36%, rgba(255,255,255,0.06) 50%, transparent 64%);
      background-size: 240% 100%;
    }

    /* View more footer */
    .project-footer {
      padding: 12px 20px 16px;
      display: flex;
      align-items: center;
      justify-content: center;
      border-top: 1px solid var(--border);
    }

    .project-view-more {
      font-size: 14px;
      font-weight: 500;
      color: var(--text);
      display: flex;
      align-items: center;
      gap: 6px;
      text-decoration: none;
      transition: opacity 0.15s ease;
      letter-spacing: -0.01em;
    }

    .project-view-more:hover { opacity: 0.5; }

    .project-view-more svg { transition: transform 0.2s ease; }
    .project-view-more:hover svg { transform: translate(2px, -2px); }

    /* ── ENTRANCE ANIMATIONS ── */
    .company-block {
      opacity: 0;
      transform: translateY(10px);
      animation: fadeUp 0.5s ease forwards;
    }

    .company-block:nth-child(1) { animation-delay: 0.05s; }
    .company-block:nth-child(2) { animation-delay: 0.10s; }
    .company-block:nth-child(3) { animation-delay: 0.15s; }
    .company-block:nth-child(4) { animation-delay: 0.20s; }
    .company-block:nth-child(5) { animation-delay: 0.25s; }
    .company-block:nth-child(6) { animation-delay: 0.30s; }
    .company-block:nth-child(7) { animation-delay: 0.35s; }

    @keyframes fadeUp {
      to { opacity: 1; transform: translateY(0); }
    }
