/* Weaver Bird — modern static theme */
:root {
  --bg: #faf8f4;
  --bg-elevated: #ffffff;
  --bg-dark: #141210;
  --bg-dark-soft: #1c1a17;
  --text: #1a1816;
  --text-muted: #5c5852;
  --text-on-dark: #f2efe8;
  --text-muted-on-dark: #a8a29a;
  --accent: #b85c38;
  --accent-hover: #9d4d2e;
  --line: rgba(26, 24, 22, 0.1);
  --line-on-dark: rgba(242, 239, 232, 0.12);
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 24px 60px rgba(20, 18, 16, 0.08);
  --shadow-sm: 0 8px 24px rgba(20, 18, 16, 0.06);
  --font-sans: "Outfit", system-ui, sans-serif;
  --font-display: "Instrument Serif", Georgia, serif;
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --max: 1200px;
  --header-h: 6.5rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

body.nav-open {
  overflow: hidden;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--accent-hover);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap {
  width: min(100% - 2 * var(--space-md), var(--max));
  margin-inline: auto;
}

/* Header — solid dark bar on all pages (incl. home before scroll) */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  color: var(--text-on-dark);
  background: var(--bg-dark);
  border-bottom: 1px solid var(--line-on-dark);
  transition: background 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.site-header.is-scrolled {
  background: var(--bg-dark-soft);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  border-bottom-color: var(--line-on-dark);
}

/* Legacy class: harmless if present; matches solid dark bar */
.site-header.site-header--dark {
  background: var(--bg-dark);
}

.site-header.site-header--dark.is-scrolled {
  background: var(--bg-dark-soft);
}

.site-header__inner {
  width: min(100% - 2 * var(--space-md), var(--max));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.logo {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: inherit;
  text-decoration: none;
  line-height: 1.1;
}

.logo span {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  opacity: 0.75;
  margin-top: 0.15rem;
}

.logo.logo--img {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  flex-shrink: 0;
}

a.logo.logo--img {
  text-decoration: none;
  color: inherit;
}

a.logo.logo--img:hover {
  color: inherit;
}

.logo.logo--img:hover .logo__img,
.logo.logo--img:hover .logo__img--footer {
  opacity: 0.92;
}

.logo__img {
  display: block;
  height: 72px;
  width: auto;
  /* Horizontal lockup: allow full wordmark + icon without clipping */
  max-width: min(96vw, 540px);
  object-fit: contain;
  object-position: left center;
}

@media (min-width: 901px) {
  .logo__img {
    height: 92px;
    max-width: 680px;
  }
}

.logo__img--footer {
  height: 72px;
  max-width: min(96vw, 520px);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
}

@media (min-width: 901px) {
  .logo__img--footer {
    height: 96px;
    max-width: 680px;
  }
}

.site-header .logo {
  color: var(--text-on-dark);
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  flex-shrink: 1;
  min-width: 0;
}

@media (max-width: 1100px) {
  .nav-desktop {
    gap: var(--space-sm);
  }
}

.nav-desktop a {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(242, 239, 232, 0.92);
  text-decoration: none;
  opacity: 0.9;
}

.nav-desktop a:hover {
  opacity: 1;
  color: #e8c4b0;
}

.nav-desktop a[aria-current="page"] {
  opacity: 1;
  color: var(--accent);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: inherit;
  border-radius: var(--radius);
  align-items: center;
  justify-content: center;
}

.nav-toggle svg {
  width: 24px;
  height: 24px;
}

.nav-panel {
  display: none;
}

@media (max-width: 900px) {
  .nav-desktop {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-panel {
    display: flex;
    position: fixed;
    inset: var(--header-h) 0 0 0;
    background: var(--bg-dark);
    flex-direction: column;
    padding: var(--space-lg);
    gap: var(--space-sm);
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease;
    border-bottom: 1px solid var(--line-on-dark);
  }

  .nav-panel.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-panel a {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-on-dark);
    text-decoration: none;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--line-on-dark);
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.btn-ghost:hover {
  border-color: var(--text);
  color: var(--text);
}

.btn-ghost-light {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-on-dark);
  border: 1px solid var(--line-on-dark);
}

.btn-ghost-light:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

/* Typography */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0;
}

.display--xl {
  font-size: clamp(2.75rem, 7vw, 5rem);
}

.display--lg {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
}

.display--md {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
}

.eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 var(--space-sm);
}

.muted {
  color: var(--text-muted);
}

.section {
  padding-block: var(--space-2xl);
}

.section--tight {
  padding-block: var(--space-xl);
}

.section--dark {
  background: var(--bg-dark);
  color: var(--text-on-dark);
}

.section--dark .muted {
  color: var(--text-muted-on-dark);
}

.section--cream {
  background: #f0ebe3;
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-bottom: var(--space-2xl);
  padding-top: calc(var(--header-h) + var(--space-xl));
  color: var(--text-on-dark);
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Slight zoom + upper focus hides tiled footer band on some stock photos */
  object-position: center 28%;
  transform: scale(1.06);
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  /* Bottom-heavy darken masks repeating text watermarks on hero photography */
  background:
    linear-gradient(
      to top,
      rgba(12, 10, 9, 0.97) 0%,
      rgba(12, 10, 9, 0.88) 14%,
      rgba(18, 16, 14, 0.35) 42%,
      transparent 62%
    ),
    linear-gradient(
      160deg,
      rgba(20, 18, 16, 0.58) 0%,
      rgba(20, 18, 16, 0.22) 48%,
      rgba(12, 10, 9, 0.55) 100%
    );
}

.hero__content {
  position: relative;
  z-index: 1;
  width: min(100% - 2 * var(--space-md), var(--max));
  margin-inline: auto;
}

.hero__grid {
  display: grid;
  gap: var(--space-lg);
  align-items: end;
}

@media (min-width: 900px) {
  .hero__grid {
    grid-template-columns: 1.4fr 1fr;
  }
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

.stat {
  border-left: 2px solid var(--accent);
  padding-left: var(--space-md);
  margin-top: var(--space-lg);
}

.stat strong {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 400;
  display: block;
  line-height: 1;
}

.stat span {
  font-size: 0.875rem;
  opacity: 0.85;
}

/* Cards & grid */
.grid-2 {
  display: grid;
  gap: var(--space-lg);
}

@media (min-width: 800px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.grid-3 {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 700px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.grid-projects {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 640px) {
  .grid-projects {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1000px) {
  .grid-projects {
    grid-template-columns: repeat(4, 1fr);
  }
}

.card-project {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-dark-soft);
  aspect-ratio: 3 / 4;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.card-project:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.card-project img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

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

.card-project__meta {
  position: absolute;
  inset: auto 0 0 0;
  padding: var(--space-md);
  background: linear-gradient(transparent, rgba(20, 18, 16, 0.92));
  color: var(--text-on-dark);
}

.card-project__meta h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  margin: 0 0 0.25rem;
}

.card-project__meta p {
  margin: 0;
  font-size: 0.8125rem;
  opacity: 0.85;
}

.card-project__link {
  position: absolute;
  inset: 0;
  z-index: 2;
}

.badge {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  z-index: 1;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--text);
}

/* Split section */
.split {
  display: grid;
  gap: var(--space-xl);
  align-items: center;
}

@media (min-width: 900px) {
  .split {
    grid-template-columns: 1fr 1fr;
  }
}

.split__visual {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.split__visual img {
  width: 100%;
  display: block;
}

/* Quote block */
.quote-block {
  position: relative;
  padding: var(--space-2xl) var(--space-md);
  text-align: center;
  color: var(--text-on-dark);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.quote-block__bg {
  position: absolute;
  inset: 0;
}

.quote-block__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.quote-block__overlay {
  position: absolute;
  inset: 0;
  background: rgba(20, 18, 16, 0.75);
}

.quote-block blockquote {
  position: relative;
  z-index: 1;
  margin: 0 auto;
  max-width: 52rem;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 400;
  line-height: 1.45;
}

.quote-block cite {
  display: block;
  margin-top: var(--space-md);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-style: normal;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.8;
}

/* Values */
.value-card {
  padding: var(--space-lg);
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  height: 100%;
}

.value-card h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  margin: 0 0 var(--space-xs);
}

.value-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.value-card__icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(184, 92, 56, 0.12);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
  font-size: 1.25rem;
}

/* Accordion */
[data-accordion] {
  border-top: 1px solid var(--line-on-dark);
}

[data-accordion-item] {
  border-bottom: 1px solid var(--line-on-dark);
}

[data-accordion-trigger] {
  width: 100%;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-sans);
  font-size: 1rem;
}

[data-accordion-trigger] strong {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 400;
}

.acc-num {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent);
  flex-shrink: 0;
}

[data-accordion-body] {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

[data-accordion-body] p {
  margin: 0 0 var(--space-md);
  padding-left: 2.75rem;
  color: var(--text-muted-on-dark);
  max-width: 40rem;
}

[data-accordion-item].is-open [data-accordion-trigger] strong {
  color: #e8c4b0;
}

/* Footer */
.site-footer {
  background: var(--bg-dark);
  color: var(--text-on-dark);
  padding: var(--space-2xl) 0 var(--space-lg);
}

.site-footer a {
  color: var(--text-on-dark);
  text-decoration: none;
  opacity: 0.88;
}

.site-footer a:hover {
  opacity: 1;
  color: #e8c4b0;
}

.site-footer .is-static {
  opacity: 0.75;
  pointer-events: none;
}

.footer-grid {
  display: grid;
  gap: var(--space-xl);
}

@media (min-width: 800px) {
  .footer-grid {
    grid-template-columns: 1.2fr repeat(3, 1fr);
  }
}

.footer-col h4 {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin: 0 0 var(--space-sm);
  opacity: 0.55;
}

.footer-col p,
.footer-col a {
  display: block;
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
}

.footer-bottom {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--line-on-dark);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  font-size: 0.875rem;
  opacity: 0.7;
}

/* Page hero (inner pages) */
.page-hero {
  padding-top: calc(var(--header-h) + var(--space-2xl));
  padding-bottom: var(--space-xl);
}

.page-hero--compact {
  padding-bottom: var(--space-lg);
}

/* Forms */
.form-grid {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 640px) {
  .form-grid--2 {
    grid-template-columns: 1fr 1fr;
  }
}

.field label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
  opacity: 0.8;
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.9rem 1rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(184, 92, 56, 0.15);
}

.field textarea {
  min-height: 160px;
  resize: vertical;
}

.form-msg {
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius);
  margin-top: var(--space-md);
}

.form-msg--ok {
  background: rgba(46, 125, 50, 0.12);
  color: #1b5e20;
}

.form-msg--err {
  background: rgba(198, 40, 40, 0.1);
  color: #b71c1c;
}

/* Reveal */
[data-reveal].reveal-pending {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Project detail */
.detail-hero {
  position: relative;
  min-height: 55vh;
  display: flex;
  align-items: flex-end;
  padding-bottom: var(--space-xl);
  color: var(--text-on-dark);
}

.detail-hero__bg {
  position: absolute;
  inset: 0;
}

.detail-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(20, 18, 16, 0.9), rgba(20, 18, 16, 0.25));
}

.detail-hero__content {
  position: relative;
  z-index: 1;
  width: min(100% - 2 * var(--space-md), var(--max));
  margin-inline: auto;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  font-size: 0.8125rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.85;
  margin-bottom: var(--space-sm);
}

.prose {
  max-width: 42rem;
}

.prose p {
  margin: 0 0 var(--space-md);
}

/* Utilities */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.stack-lg > * + * { margin-top: var(--space-lg); }

.text-center { text-align: center; }
