/* ========================================
   Studio 1299 — v2 · Warm editorial
   ======================================== */

:root {
  --bg:          #F5F0EA;
  --bg-alt:      #EDE7DF;
  --surface:     #FFFDF9;
  --ink:         #1C1917;
  --ink-soft:    #78716C;
  --ink-faint:   #A8A29E;
  --accent:      #D94F1E;
  --accent-hover:#C4431A;
  --accent-dim:  rgba(217, 79, 30, 0.10);
  --green:       #2D5A42;
  --border:      #D6D0C8;

  --serif:       "DM Serif Display", Georgia, serif;
  --sans:        "DM Sans", system-ui, -apple-system, sans-serif;

  --container:   min(90vw, 1140px);
  --ease:        cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Screen-reader only text (SEO + a11y) */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--accent);
  color: #fff;
}

/* ─── HEADER ─── */
.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 5vw;
  transition: background 0.35s, backdrop-filter 0.35s;
}

.header.scrolled {
  background: rgba(245, 240, 234, 0.8);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-family: var(--serif);
  font-size: 1.35rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.logo span {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-soft);
  margin-left: 0.2em;
  letter-spacing: 0.04em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}

.nav a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.2s;
}

.nav a:hover { color: var(--ink); }

.nav-cta {
  color: var(--accent) !important;
  font-weight: 600 !important;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--ink);
  cursor: pointer;
  padding: 4px;
}

/* ─── LAYOUT ─── */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 5vw;
}

.section {
  padding: 7rem 0;
}

.section-intro {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 3rem;
}

.section-num {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--accent);
}

.section-heading {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 400;
  margin: 0;
  color: var(--ink);
}

/* ─── HERO ─── */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 7rem 5vw 3rem;
  position: relative;
}

.hero-inner {
  max-width: var(--container);
  margin: 0 auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4rem;
}

.hero-left { flex: 1; }

.hero-eyebrow {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.5rem;
  opacity: 0;
  animation: rise 0.7s var(--ease) 0.15s forwards;
}

.hero-heading {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(4rem, 13vw, 9rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  margin: 0 0 1.25rem;
  color: var(--ink);
}

.hero-line {
  display: flex;
  align-items: center;
  gap: 0.15em;
}

.hero-zero {
  opacity: 0;
  animation: rise 0.8s var(--ease) 0.3s forwards;
  color: var(--ink-faint);
}

.hero-arrow {
  display: inline-flex;
  width: 0.75em;
  opacity: 0;
  animation: rise 0.6s var(--ease) 0.45s forwards;
  color: var(--accent);
}

.hero-arrow svg {
  width: 100%;
  height: auto;
}

.hero-hundred {
  opacity: 0;
  animation: rise 0.8s var(--ease) 0.55s forwards;
}

.hero-sub {
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  color: var(--ink-soft);
  line-height: 1.7;
  max-width: 34ch;
  margin: 0 0 2rem;
  opacity: 0;
  animation: rise 0.7s var(--ease) 0.7s forwards;
}

.hero-sub strong {
  color: var(--ink);
  font-weight: 600;
}

.hero-detail {
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.75;
  max-width: 44ch;
  margin: 0 0 2rem;
  opacity: 0;
  animation: rise 0.7s var(--ease) 0.78s forwards;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  opacity: 0;
  animation: rise 0.7s var(--ease) 0.85s forwards;
}

/* Hero badge */
.hero-right {
  flex-shrink: 0;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.6s forwards;
}

.hero-badge {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  animation: spin 30s linear infinite;
  position: relative;
}

.badge-num {
  font-family: var(--serif);
  font-size: 2.25rem;
  color: var(--accent);
  animation: counter-spin 30s linear infinite;
}

.badge-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  animation: counter-spin 30s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes counter-spin { to { transform: rotate(-360deg); } }

/* Scroll hint */
.hero-scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 5vw;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  opacity: 0;
  animation: rise 0.6s var(--ease) 1.2s forwards;
}

.hero-scroll-hint span {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.scroll-line {
  width: 48px;
  height: 1px;
  background: var(--border);
  position: relative;
  overflow: hidden;
}

.scroll-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--accent);
  animation: scroll-pulse 2s ease-in-out infinite;
}

@keyframes scroll-pulse {
  0%   { transform: translateX(-100%); }
  50%  { transform: translateX(0); }
  100% { transform: translateX(100%); }
}

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

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.65rem;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 3px;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-fill {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}

.btn-fill:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px var(--accent-dim);
}

.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--ink-soft);
}

/* ─── SERVICES ─── */
.section-services {
  background: var(--bg-alt);
}

.services-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.services-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2rem 2.5rem 2.25rem;
  max-width: 580px;
}

.services-lead {
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.7;
  margin: 0 0 1.5rem;
}

.services-label {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.5rem;
}

.services-items {
  display: flex;
  flex-direction: column;
  list-style: none;
  margin: 0;
  padding: 0;
}

.service-item {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}

.service-item:last-child { border-bottom: none; }

.service-index {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--ink-faint);
  letter-spacing: 0.05em;
  min-width: 1.5rem;
}

.service-name {
  font-family: var(--serif);
  font-size: 1.15rem;
  color: var(--ink);
}

.services-note {
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin: 0;
  max-width: 40ch;
}

.section-sub {
  font-size: 0.95rem;
  color: var(--ink-soft);
  line-height: 1.7;
  max-width: 50ch;
  margin: -1.5rem 0 2.5rem;
}

/* ─── WORK ─── */
.work-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.work-item {
  border-top: 1px solid var(--border);
}

.work-item:last-child {
  border-bottom: 1px solid var(--border);
}

.work-item a {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 2rem;
  row-gap: 0.15rem;
  align-items: center;
  padding: 1.5rem 0;
  text-decoration: none;
  color: inherit;
  transition: padding-left 0.3s var(--ease);
}

.work-item a:hover {
  padding-left: 1rem;
}

.work-item a:hover .work-arrow {
  color: var(--accent);
  transform: translate(3px, -3px);
}

.work-item a:hover .work-title {
  color: var(--accent);
}

.work-top {
  grid-column: 1;
  grid-row: 1 / 3;
  display: flex;
  align-items: center;
}

.work-count {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--ink-faint);
  min-width: 2rem;
}

.work-title {
  grid-column: 2;
  grid-row: 1;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  font-weight: 400;
  margin: 0;
  transition: color 0.2s;
}

.work-desc {
  grid-column: 2;
  grid-row: 2;
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 0;
}

.work-arrow {
  grid-column: 3;
  grid-row: 1 / 3;
  font-size: 1.25rem;
  color: var(--ink-faint);
  transition: color 0.2s, transform 0.2s;
}

.work-url {
  display: none;
}

/* ─── PARTNERS ─── */
.section-partners {
  background: var(--bg-alt);
}

.partners-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border-radius: 6px;
  overflow: hidden;
}

.partner-card {
  background: var(--surface);
  padding: 2.5rem 2rem;
  text-align: center;
}

.partner-name {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 400;
  margin: 0 0 0.35rem;
  color: var(--ink);
}

.partner-role {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent);
  margin: 0;
  letter-spacing: 0.04em;
}

/* ─── CONTACT ─── */
.section-contact {
  background: var(--ink);
  color: var(--bg);
  padding: 8rem 0;
}

.section-num-light {
  color: var(--accent);
}

.contact-heading {
  font-family: var(--serif);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 400;
  margin: 1rem 0 1.5rem;
  line-height: 1.1;
  color: var(--bg);
}

.contact-heading em {
  color: var(--accent);
  font-style: italic;
}

.contact-sub {
  font-size: 1.05rem;
  color: var(--ink-faint);
  line-height: 1.8;
  margin: 0 0 2.5rem;
  max-width: 36ch;
}

.contact-email {
  font-family: var(--serif);
  font-size: clamp(1.25rem, 3.5vw, 2rem);
  color: var(--accent);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s;
}

.contact-email:hover {
  border-color: var(--accent);
}

.contact-location {
  font-size: 0.85rem;
  color: var(--ink-faint);
  margin: 1.5rem 0 0;
  letter-spacing: 0.04em;
}

/* ─── FOOTER ─── */
.footer {
  padding: 1.75rem 5vw;
  border-top: 1px solid var(--border);
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-mark {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--ink);
}

.footer-line {
  font-size: 0.8rem;
  color: var(--ink-soft);
}

/* ─── SCROLL REVEAL ─── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  .nav {
    position: fixed;
    inset: 0 0 0 25vw;
    background: var(--surface);
    border-left: 1px solid var(--border);
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 3rem 2rem;
    gap: 1.75rem;
    transform: translateX(100%);
    transition: transform 0.35s var(--ease);
    z-index: 99;
  }

  .nav.open { transform: translateX(0); }

  .nav a { font-size: 1.1rem; }

  .menu-toggle {
    display: block;
    z-index: 101;
  }

  body.nav-open { overflow: hidden; }

  .hero-inner {
    flex-direction: column;
    gap: 2.5rem;
  }

  .hero-right { display: none; }

  .hero-heading {
    font-size: clamp(3.5rem, 16vw, 6rem);
  }

  .partners-grid {
    grid-template-columns: 1fr;
  }

  .work-item a {
    grid-template-columns: auto 1fr auto;
    column-gap: 1rem;
  }
}

@media (max-width: 480px) {
  .hero-heading {
    font-size: clamp(2.75rem, 18vw, 4.5rem);
  }

  .hero-line {
    gap: 0.1em;
  }

  .services-card {
    padding: 1.5rem;
  }
}
