/* ---------- Theme tokens ---------- */
.site {
  --bg: #ffffff;
  --surface: #ffffff;
  --soft: #f3f2ef;
  --ink: #141414;
  --muted: #5f5e5a;
  --faint: #8c8a85;
  --line: #e6e4df;
  --dot: #d9d6cf;
  --accent: #c8502a;
  --accent-ink: #ffffff;
  background-color: var(--bg);
  color: var(--ink);
  font-family: "Instrument Sans", Inter, system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition:
    background-color 0.5s ease,
    color 0.5s ease;
  min-height: 100%;
}
.site.bg-warm {
  --bg: #fff7f1;
  --surface: #fffcf9;
  --soft: #fbede3;
  --line: #f0e1d6;
  --dot: #ebd3c2;
}
.site {
  --pattern: #f1efeb;
}
.site.dark {
  --pattern: #1b1a18;
}
.site.bg-dots {
  background-image: radial-gradient(var(--pattern) 1px, transparent 1.1px);
  background-size: 22px 22px;
}
.site.bg-grid {
  background-image:
    linear-gradient(var(--pattern) 1px, transparent 1px),
    linear-gradient(90deg, var(--pattern) 1px, transparent 1px);
  background-size: 64px 64px;
}
.site.dark {
  --bg: #0f0f0e;
  --surface: #181816;
  --soft: #1e1d1b;
  --ink: #f3f1ec;
  --muted: #b3b0a9;
  --faint: #8f8c86;
  --line: #2c2b28;
  --dot: #33312d;
  --accent: #f07a4f;
  --accent-ink: #16110e;
}
.site.dark.bg-warm {
  --bg: #14100d;
  --surface: #1c1612;
  --soft: #241c17;
  --line: #33281f;
  --dot: #3c2f25;
}
.site a {
  color: inherit;
}
.site .serif {
  font-family: "Instrument Serif", Georgia, serif;
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}
.site .mono {
  font-family: "Instrument Sans", Inter, sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}
.site .wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 40px;
  padding-right: 40px;
}

/* ---------- Controls ---------- */
.site .pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font:
    500 15px/1 "Instrument Sans",
    sans-serif;
  text-decoration: none;
  transition:
    transform 0.3s ease,
    background-color 0.3s ease,
    border-color 0.3s ease;
}
.site .pill:hover {
  transform: translateY(-2px);
}
.site .pill.solid {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.site .pill.accent {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}
.site .icon-btn {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
}
.site .seg {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
  background: var(--surface);
}
.site .seg button {
  min-width: 44px;
  min-height: 38px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font:
    600 13px/1 "Instrument Sans",
    sans-serif;
  cursor: pointer;
  transition:
    background-color 0.3s,
    color 0.3s;
}
.site .seg button.on {
  background: var(--ink);
  color: var(--bg);
}
.site .link-u {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100%/0 1px no-repeat;
  transition: background-size 0.4s ease;
}
.site .link-u:hover {
  background-size: 100% 1px;
}

/* ---------- Motion ---------- */
@keyframes rise {
  from {
    opacity: 0;
    filter: blur(14px);
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    filter: blur(0);
    transform: none;
  }
}
@keyframes lit {
  from {
    opacity: 0.16;
    filter: blur(3px);
  }
  to {
    opacity: 1;
    filter: blur(0);
  }
}
@keyframes float {
  0%,
  100% {
    transform: translateY(0) rotate(0);
  }
  50% {
    transform: translateY(-12px) rotate(-1.5deg);
  }
}
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 168, 83, 0.45);
  }
  100% {
    box-shadow: 0 0 0 10px rgba(52, 168, 83, 0);
  }
}
@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
@keyframes grow {
  from {
    transform: scaleY(0);
  }
  to {
    transform: scaleY(1);
  }
}
@keyframes dotOn {
  from {
    background: var(--line);
    transform: scale(0.7);
  }
  to {
    background: var(--accent);
    transform: scale(1);
  }
}
.site .rise {
  animation: rise 1s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.site .d1 {
  animation-delay: 0.08s;
}
.site .d2 {
  animation-delay: 0.2s;
}
.site .d3 {
  animation-delay: 0.34s;
}
.site .d4 {
  animation-delay: 0.5s;
}
.site .d5 {
  animation-delay: 0.68s;
}
@keyframes revealSoft {
  from {
    opacity: 0;
    filter: blur(5px);
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    filter: blur(0);
    transform: none;
  }
}
.site .reveal {
  animation: revealSoft linear both;
  animation-timeline: view();
  animation-range: entry 0px entry 220px;
}
.site .words span {
  display: inline-block;
  animation: lit linear both;
  animation-timeline: view();
  animation-range: entry 0% entry 100%;
}
.site .float {
  animation: float 7s ease-in-out infinite;
}
.site .float.f2 {
  animation-duration: 9s;
  animation-delay: -2s;
}
.site .float.f3 {
  animation-duration: 8s;
  animation-delay: -4s;
}
.site .live {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34a853;
  animation: pulse 1.8s ease-out infinite;
  flex: none;
}
.site .marquee {
  animation: marquee 36s linear infinite;
}
.site .tl-line {
  transform-origin: top;
  animation: grow linear both;
  animation-timeline: view();
  animation-range: entry 0% cover 60%;
}
.site .tl-dot {
  animation: dotOn linear both;
  animation-timeline: view();
  animation-range: entry 0% entry 100%;
}
@supports not (animation-timeline: view()) {
  .site .reveal {
    animation: revealSoft 0.8s both;
  }
  .site .words span {
    animation: none;
    opacity: 1;
  }
  .site .tl-line,
  .site .tl-dot {
    animation: none;
  }
  .site .tl-dot {
    background: var(--accent);
  }
}
.site .lift {
  transition: transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.site a:hover .lift {
  transform: scale(1.03);
}
.site .arrow {
  display: inline-block;
  transition: transform 0.35s ease;
}
.site a:hover .arrow {
  transform: translate(4px, -4px);
}
.site .row-link {
  transition:
    padding-left 0.4s ease,
    background-color 0.4s ease;
}
.site .row-link:hover {
  padding-left: 16px;
  background: var(--soft);
}
@media (prefers-reduced-motion: reduce) {
  .site * {
    animation: none !important;
    transition: none !important;
  }
}

/* ---------- Placeholders ---------- */
.site .ph {
  background: var(--soft);
  border: 1px dashed var(--dot);
  color: var(--faint);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 14px;
  padding: 16px;
  box-sizing: border-box;
}

/* ---------- Proposal A layout ---------- */
.site .a-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 56px;
  min-height: 65vh;
  align-items: center;
}
.site .a-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.site .a-stats > div {
  border-left: 1px solid var(--line);
  padding: 8px 24px;
}
.site .a-stats > div:first-child {
  border-left: 0;
  padding-left: 0;
}
.site .a-work-row {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) 280px;
  gap: 32px;
  align-items: center;
}
.site .a-tl {
  display: grid;
  grid-template-columns: 160px 32px minmax(0, 1fr);
  gap: 24px;
}
.site .a-visual {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}
.site .a-foot {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 48px;
}
.site .nav-links {
  display: flex;
  gap: 28px;
}

/* ---------- Proposal B (minimal) ---------- */
.site.m {
  font-size: 16px;
}
.site .m-shell {
  max-width: 1240px;
  margin: 0 auto;
  padding: 28px 40px 40px;
  min-height: 100vh;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}
.site .m-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.site .m-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  align-items: center;
}
.site .m-nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 15px;
  padding: 12px 0;
}
.site .m-nav a.on,
.site .m-nav a:hover {
  color: var(--ink);
}
.site .m-home {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 64px;
  align-items: center;
  flex: 1;
  padding: 48px 0;
}
.site .m-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 200px 40px;
  gap: 24px;
  align-items: baseline;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  text-decoration: none;
}
.site .m-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.site .m-two {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 64px;
}

/* ---------- Mobile ---------- */
@media (max-width: 760px) {
  .site {
    font-size: 16px;
  }
  .site .wrap {
    padding-left: 20px;
    padding-right: 20px;
  }
  .site .nav-links {
    display: none;
  }
  .site .a-hero {
    height: auto;
  }
  .site .a-hero,
  .site .a-foot,
  .site .m-home,
  .site .m-two {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
  .site .a-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    row-gap: 28px;
  }
  .site .a-stats > div {
    border-left: 0;
    padding: 0;
  }
  .site .a-work-row {
    grid-template-columns: 40px minmax(0, 1fr);
  }
  .site .a-work-row .a-thumb {
    grid-column: 1 / -1;
  }

  .p-meta.rise.d3 div p:nth-child(2){
    font-size: 14px !important;
  }

  p.rise.d3 {
    font-size: 16px !important;
  }

  div.rise.d4.a-ctas {
    padding: 0 !important;
  }

  .site .d4 {
    gap: 24px !important;
    padding: 20px !important;
  }

  .site .d4 > div:first-child p:nth-child(2) {
    font-size: 20px !important;
    line-height: 1.5 !important;
  }

  .site .d4 .serif  {
    font-size: 48px !important;
  }

  .site .d4 > div:nth-child(2) {
    flex-direction: column !important;
    gap: 24px !important;
  }

  figcaption {
    font-size: 12px !important;
  }

  .site .a-tl {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 4px 16px;
  }
  .site .a-tl .a-tl-year {
    grid-column: 2;
    grid-row: 1;
  }
  .site .a-tl .a-tl-rail {
    grid-row: 1 / span 2;
    grid-column: 1;
  }
  .site .a-tl .a-tl-main {
    grid-column: 2;
    grid-row: 2;
  }
  .site .a-cases {
    grid-template-columns: minmax(0, 1fr);
  }
  .site .notch-links,
  .site .notch-cta {
    display: none !important;
  }
  .site .menu-btn {
    display: inline-flex !important;
  }
  .site .notch-bar {
    gap: 10px;
    padding: 8px 8px 8px 12px;
  }
  .site .p-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .site .a-visual,
  .site .m-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .site .m-shell {
    padding: 20px 20px 32px;
  }
  .site .m-row {
    grid-template-columns: minmax(0, 1fr) 32px;
    gap: 4px 12px;
  }
  .site .m-row .m-year {
    grid-column: 1 / -1;
  }
  .site .m-row .m-type {
    display: none;
  }
  .site .hide-sm {
    display: none !important;
  }
}

/* ---------- Accordion ---------- */
@keyframes accIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.site .acc-btn {
  display: flex;
  width: 100%;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  min-height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.site .acc-icon {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  line-height: 1;
  transition:
    transform 0.4s ease,
    background-color 0.3s,
    color 0.3s;
}
.site .acc-icon.open {
  transform: rotate(45deg);
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.site .acc-btn:hover .acc-icon {
  border-color: var(--ink);
}
.site .acc-body {
  animation: accIn 0.45s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.site .a-cases {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

/* ---------- Notch menu ---------- */
.site .notch {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.site .notch-bar {
  pointer-events: auto;
  position: relative;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 10px 10px 10px 14px;
  background: #ffffff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 22px 22px;
  box-shadow: 0 12px 32px rgba(20, 20, 20, 0.07);
}
.site.dark .notch-bar {
  background: var(--surface);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}
.site .notch-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
}
.site .notch-mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--accent);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Instrument Serif", serif;
  font-style: italic;
  font-size: 18px;
}
.site .notch-links {
  display: flex;
  gap: 18px;
}
.site .notch-links a,
.site .notch-panel a {
  color: var(--ink);
  opacity: 0.6;
  text-decoration: none;
  font-size: 15px;
  padding: 12px 0;
  transition: opacity 0.3s;
}
.site .notch-links a:hover,
.site .notch-links a.on,
.site .notch-panel a.on {
  opacity: 1;
}
.site .notch-links a.on {
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1px;
}
.site .notch-cta {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
  font-weight: 600;
  gap: 8px;
}
.site .menu-btn {
  display: none;
}
.site .notch-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 8px 18px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 12px 32px rgba(20, 20, 20, 0.08);
  animation: accIn 0.35s ease both;
}
.site .seg.sm {
  padding: 2px;
}
.site .seg.sm button {
  min-width: 32px;
  min-height: 32px;
  font-size: 11px;
}
.site .icon-btn.sm {
  width: 36px;
  height: 36px;
  min-height: 36px;
}
.site .corner {
  position: fixed;
  top: 14px;
  right: 20px;
  z-index: 31;
  display: flex;
  gap: 6px;
  align-items: center;
  padding: 4px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 6px 20px rgba(20, 20, 20, 0.06);
}
.site .corner .seg {
  border: 0;
  padding: 0;
  background: transparent;
}
.site .corner .icon-btn {
  border: 0;
}
.site .p-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}
@media (max-width: 760px) {
  .site .a-cases,
  .site .p-meta {
    grid-template-columns: minmax(0, 1fr);
  }
  .site .p-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .site .notch-bar {
    gap: 8px;
    padding: 8px 8px 8px 12px;
    border-radius: 0 0 18px 18px;
  }
  .site .notch-name {
    display: none;
  }
  .site .corner {
    top: auto;
    bottom: 16px;
    right: 16px;
  }
}

/* ---------- Scroll-drawn experience line ---------- */
@keyframes drawLine {
  from {
    transform: scaleY(0);
  }
  to {
    transform: scaleY(1);
  }
}
.site .tl-wrap {
  position: relative;
  view-timeline-name: --tl;
}
.site .tl-rail {
  position: absolute;
  left: 200px;
  top: 18px;
  bottom: 60px;
  width: 2px;
  margin-left: -1px;
  background: var(--line);
  border-radius: 2px;
}
.site .tl-fill {
  background: var(--accent);
  transform-origin: top;
  animation: drawLine linear both;
  animation-timeline: --tl;
  animation-range: entry 30% exit 70%;
}
@supports not (animation-timeline: view()) {
  .site .tl-fill {
    animation: none;
  }
}
@media (max-width: 760px) {
  .site .tl-rail {
    left: 12px;
  }
}

/* ---------- Client logos ---------- */
.site .logo {
  display: block;
  flex: none;
  height: 30px;
  width: auto;
  max-width: 170px;
  object-fit: contain;
  filter: grayscale(1) brightness(0);
  opacity: 0.5;
  transition:
    opacity 0.3s,
    filter 0.3s;
}
.site .logo:hover {
  filter: none;
  opacity: 1;
}
.site.dark .logo {
  filter: grayscale(1) brightness(0) invert(1);
  opacity: 0.55;
}
.site.dark .logo:hover {
  filter: grayscale(1) brightness(0) invert(1);
  opacity: 1;
}
