:root {
    --navy: #0c3270;
    --gold: #c5b37b;
    --gold-ink: #8d7344;
    --muted: #5e6d84;
    --line: #e3ddd2;
    --paper: #ffffff;
  }

  * { box-sizing: border-box; }

  html { min-height: 100%; background: var(--paper); }

  body {
    margin: 0;
    min-height: 100svh;
    color: var(--navy);
    font-family: Montserrat, "Avenir Next", "Segoe UI", sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    isolation: isolate;
  }

  body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--navy) 0 72px, var(--gold) 72px 148px, var(--navy) 148px);
    z-index: 5;
  }

  .drafting {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    color: #b7ad9b;
    opacity: .85;
    -webkit-mask-image: radial-gradient(ellipse 72% 64% at 50% 46%, transparent 55%, #000 100%);
    mask-image: radial-gradient(ellipse 72% 64% at 50% 46%, transparent 55%, #000 100%);
  }

  .drafting path { stroke-width: 1.05; }

  .drafting-bl {
    position: fixed;
    left: 0;
    bottom: 0;
    width: clamp(190px, 22vw, 320px);
    height: auto;
    z-index: 0;
    pointer-events: none;
    color: #b7ad9b;
    opacity: .6;
    -webkit-mask-image: radial-gradient(ellipse 100% 100% at 0% 100%, #000 40%, transparent 100%);
    mask-image: radial-gradient(ellipse 100% 100% at 0% 100%, #000 40%, transparent 100%);
  }

  .corner {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
  }

  .corner::before,
  .corner::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    width: min(18vw, 280px);
    height: min(11vw, 168px);
    clip-path: polygon(100% 0, 100% 100%, 0 100%);
    background: var(--gold);
  }

  .corner::after {
    width: calc(min(18vw, 280px) - 8px);
    height: calc(min(11vw, 168px) - 8px);
    background: var(--navy);
  }

  .sheet {
    position: relative;
    z-index: 1;
    width: min(1120px, calc(100% - 64px));
    padding: clamp(28px, 5vh, 56px) 0 clamp(56px, 9vh, 96px);
  }

  .logo {
    display: block;
    width: min(420px, 70%);
    height: auto;
    margin: 0 auto clamp(22px, 3.5vh, 36px);
  }

  .kicker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin: 0 0 clamp(14px, 2vh, 20px);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .42em;
    text-transform: uppercase;
  }

  .kicker::before,
  .kicker::after {
    content: "";
    width: clamp(28px, 6vw, 72px);
    height: 1px;
    background: var(--gold);
  }

  h1 {
    margin: 0 auto;
    text-align: center;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 500;
    font-size: clamp(36px, 4.4vw, 60px);
    line-height: 1.02;
    letter-spacing: -0.02em;
  }

  h1 .line { display: block; }

  h1 em {
    font-style: italic;
    font-weight: 500;
    color: var(--gold-ink);
  }

  .lede {
    margin: clamp(14px, 2vh, 18px) auto 0;
    max-width: 38em;
    text-align: center;
    color: var(--muted);
    font-size: clamp(13px, 1.2vw, 15px);
    font-weight: 500;
    letter-spacing: .04em;
    line-height: 1.6;
  }

  .works {
    margin-top: clamp(28px, 4.5vh, 48px);
  }

  .works-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 0 2px 10px;
  }

  .works-head p {
    margin: 0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .28em;
    text-transform: uppercase;
  }

  a:focus-visible {
    outline: 2px solid var(--navy);
    outline-offset: 4px;
    border-radius: 2px;
  }

  .works-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
  }

  .work {
    margin: 0;
    min-width: 0;
    padding: 16px 14px 14px;
  }

  .work + .work { border-left: 1px solid var(--line); }

  .work svg {
    display: block;
    width: 100%;
    height: clamp(108px, 16vh, 150px);
    color: var(--navy);
    overflow: hidden;
  }

  figcaption {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    margin-top: 8px;
    min-height: 3.2em;
    text-align: center;
  }

  .num {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .22em;
    color: var(--gold-ink);
  }

  .name {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    line-height: 1.45;
    text-wrap: balance;
  }

  .ground { fill: #cbbc8d; opacity: .12; }
  .stratum { fill: none; stroke: #cbbc8d; stroke-width: 1; opacity: .5; }
  .technical { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
  .light { opacity: .38; }
  .gold { stroke: #b7a268; }
  .mast { fill: #fff; stroke: currentColor; stroke-width: 1.7; }

  .build-lower, .build-upper, .bridge-piers, .build-roof, .beam-lower, .beam-upper, .bridge-deck {
    transform-box: fill-box;
  }
  .build-lower, .build-upper, .bridge-piers { transform-origin: bottom; }
  .build-lower { animation: lower-rise 14s ease-in-out -10.2s infinite; }
  .beam-lower { animation: lower-beam 14s ease-in-out -10.2s infinite; }
  .build-upper { animation: upper-rise 14s ease-in-out -10.2s infinite; }
  .beam-upper { animation: upper-beam 14s ease-in-out -10.2s infinite; }
  .build-roof { animation: roof-place 14s ease-in-out -10.2s infinite; }
  .bridge-piers { animation: pier-rise 14s ease-in-out -10.2s infinite; }
  .bridge-deck { animation: deck-place 14s ease-in-out -10.2s infinite; }
  .bridge-arch { stroke-dasharray: 700; animation: arch-draw 14s ease-in-out -10.2s infinite; }
  .river { stroke-dasharray: 8 5; animation: river-flow 6s linear infinite; }
  .drill { animation: drill-down 10s ease-in-out infinite; }
  .drill-bit { transform-box: fill-box; transform-origin: center; animation: bit-turn 1.8s linear infinite; }
  .pile-fill { transform-box: fill-box; transform-origin: bottom; animation: pile-grow 10s ease-in-out infinite; }
  .dsm-shaft { animation: dsm-depth 11s ease-in-out infinite; }
  .mix-blade { transform-box: fill-box; transform-origin: center; animation: bit-turn 1.6s linear infinite; }
  .mix-blade.reverse { animation-direction: reverse; }
  .mix-zone { animation: mix-bloom 11s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
  .flow { stroke-dasharray: 4 7; animation: flow-down 1.8s linear infinite; }
  .plume { transform-box: fill-box; transform-origin: center; animation: plume-grow 8s ease-in-out infinite; }
  .plume.second { animation-delay: -2.6s; }
  .plume.third { animation-delay: -5.2s; }

  .contacts {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 28px;
    margin: clamp(22px, 3.5vh, 36px) auto 0;
    max-width: 760px;
  }

  .contact {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
  }

  .contact + .contact {
    padding-left: 28px;
    border-left: 1px solid var(--gold);
  }

  .icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    fill: none;
    stroke: var(--gold-ink);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  a { color: var(--navy); text-decoration: none; }

  a:hover { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--gold); }

  .email {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: .01em;
    overflow-wrap: anywhere;
  }

  address {
    font-style: normal;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
  }


  @keyframes lower-rise { 0%, 8%, 100% { transform: scaleY(.02); opacity: 0 } 23%, 90% { transform: scaleY(1); opacity: 1 } }
  @keyframes lower-beam { 0%, 23%, 100% { transform: translateY(-13px); opacity: 0 } 33%, 90% { transform: none; opacity: 1 } }
  @keyframes upper-rise { 0%, 33%, 100% { transform: scaleY(.02); opacity: 0 } 48%, 90% { transform: scaleY(1); opacity: 1 } }
  @keyframes upper-beam { 0%, 48%, 100% { transform: translateY(-13px); opacity: 0 } 58%, 90% { transform: none; opacity: 1 } }
  @keyframes roof-place { 0%, 58%, 100% { transform: translateY(-13px); opacity: 0 } 70%, 90% { transform: none; opacity: 1 } }
  @keyframes pier-rise { 0%, 8%, 100% { transform: scaleY(.02); opacity: 0 } 28%, 90% { transform: scaleY(1); opacity: 1 } }
  @keyframes deck-place { 0%, 28%, 100% { transform: translateY(-20px); opacity: 0 } 44%, 90% { transform: none; opacity: 1 } }
  @keyframes arch-draw { 0%, 44%, 100% { stroke-dashoffset: 700; opacity: 0 } 45% { opacity: 1; stroke-dashoffset: 700 } 72%, 90% { stroke-dashoffset: 0; opacity: 1 } }
  @keyframes river-flow { to { stroke-dashoffset: -52 } }
  @keyframes drill-down { 0%, 100% { transform: translateY(0) } 45%, 65% { transform: translateY(47px) } }
  @keyframes bit-turn { 0%, 100% { transform: scaleX(1) } 50% { transform: scaleX(.25) } }
  @keyframes pile-grow { 0%, 35%, 100% { transform: scaleY(.03); opacity: 0 } 65%, 88% { transform: scaleY(1); opacity: .3 } }
  @keyframes dsm-depth { 0%, 100% { transform: translateY(-18px) } 45%, 70% { transform: translateY(22px) } }
  @keyframes mix-bloom { 0%, 100% { transform: scaleX(.7); opacity: .07 } 45%, 75% { transform: scaleX(1); opacity: .23 } }
  @keyframes flow-down { to { stroke-dashoffset: -22 } }
  @keyframes plume-grow { 0% { transform: scale(.2); opacity: 0 } 35% { opacity: .3 } 80%, 100% { transform: scale(1.15); opacity: 0 } }

  @media (max-width: 860px) {
    .sheet { width: min(680px, calc(100% - 40px)); }
    .drafting-bl { display: none; }
    .corner::before,
    .corner::after { width: min(22vw, 160px); height: min(14vw, 100px); }
    .corner::after { width: calc(min(22vw, 160px) - 6px); height: calc(min(14vw, 100px) - 6px); }
    .works-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .work:nth-child(odd) { border-left: 0; }
    .work:nth-child(1),
    .work:nth-child(2) { border-bottom: 1px solid var(--line); }
    .work svg { height: 140px; }
  }

  @media (max-width: 640px) {
    .sheet { width: calc(100% - 36px); padding-top: 36px; padding-bottom: 72px; }
    .logo { width: min(320px, 88%); }
    .kicker { letter-spacing: .28em; font-size: 10px; gap: 12px; }
    h1 { font-size: 34px; }
    .contacts { flex-direction: column; align-items: flex-start; gap: 16px; max-width: 320px; }
    .contact + .contact { padding: 16px 0 0; border-left: 0; border-top: 1px solid var(--gold); width: 100%; }
    .works-head p { letter-spacing: .16em; }
  }

  @media (max-height: 740px) and (min-width: 861px) {
    .logo { width: min(340px, 46vw); margin-bottom: 16px; }
    h1 { font-size: 44px; }
    .work svg { height: 112px; }
    .sheet { padding-top: 24px; padding-bottom: 48px; }
    .works { margin-top: 22px; }
  }

  @media (prefers-reduced-motion: reduce) {
    .works * { animation: none !important; }
    .bridge-arch { stroke-dashoffset: 0; opacity: 1; }
  }
