/* ==========================================================================
   Rizanni Architects — Stylesheet
   ========================================================================== */

/* Reset & Base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

:root {
  --bg: #ffffff;
  --bg-alt: #f7f5f0;
  --text: #0a0a0a;
  --text-muted: #666666;
  --text-light: #999999;
  --border: #eaeaea;
  --border-dark: #1a1a1a;
  --accent: #1a1a1a;
  --terracotta: #a75c48;
  --terracotta-dark: #8a4a3a;
  --overlay: rgba(0, 0, 0, 0.45);

  --font-display: 'Fraunces', 'Times New Roman', Georgia, serif;
  --font-body: 'Manrope', system-ui, sans-serif;

  --container: 1400px;
  --container-narrow: 1100px;
  --gutter: clamp(1.25rem, 3vw, 2.5rem);

  --header-h: 88px;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  font-weight: 400;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: opacity 0.2s ease, color 0.2s ease; }
a:hover { opacity: 0.7; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul, ol { list-style: none; }

/* Typography
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--text);
}

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  display: block;
}

.h-display {
  font-size: clamp(3rem, 9vw, 8rem);
  font-weight: 400;
  letter-spacing: -0.025em;
}

.h-xl { font-size: clamp(2.5rem, 5vw, 4.5rem); }
.h-lg { font-size: clamp(2rem, 3.5vw, 3rem); }
.h-md { font-size: clamp(1.5rem, 2.5vw, 2.25rem); }
.h-sm { font-size: clamp(1.25rem, 2vw, 1.5rem); font-weight: 600; }

.lead {
  font-size: clamp(1.125rem, 1.5vw, 1.25rem);
  line-height: 1.55;
  color: var(--text);
  max-width: 65ch;
}

p { margin-bottom: 1em; max-width: 70ch; }
p:last-child { margin-bottom: 0; }

/* Layout utilities
   ========================================================================== */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.container--narrow { max-width: var(--container-narrow); }

.section {
  padding: clamp(4rem, 9vw, 8rem) 0;
}

.section--tight { padding: clamp(3rem, 6vw, 5rem) 0; }

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

/* Header
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  z-index: 100;
  display: flex;
  align-items: center;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0 var(--gutter);
}

.site-header__logo {
  display: flex;
  align-items: center;
  height: 100%;
  text-decoration: none;
}
.site-header__logo-img {
  display: block;
  height: 44px;
  width: auto;
  transition: opacity 0.3s ease;
}
/* Default: show dark (charcoal) version, hide white version */
.site-header__logo-img--light { display: none; }
.site-header__logo-img--dark { display: block; }

/* Over-hero (transparent header AND not yet scrolled): show white version */
.site-header--transparent:not(.site-header--solid) .site-header__logo-img--light { display: block; }
.site-header--transparent:not(.site-header--solid) .site-header__logo-img--dark { display: none; }

@media (max-width: 768px) {
  .site-header__logo-img { height: 36px; }
}

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

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

.site-nav__list a {
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  position: relative;
  padding: 0.5rem 0;
}

.site-nav__list a.is-active::after,
.site-nav__list a:hover::after {
  content: '';
  position: absolute;
  bottom: 0.25rem;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--terracotta);
}

.site-nav__list a:hover { opacity: 1; color: var(--terracotta); }

.phone-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 1.25rem;
  background: white;
  color: var(--text);
  border-radius: 100px;
  font-size: 0.9rem;
  font-weight: 500;
  border: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}
.phone-pill:hover {
  opacity: 1;
  color: var(--terracotta);
  border-color: var(--terracotta);
}
.phone-pill svg { width: 14px; height: 14px; }

.menu-toggle {
  width: 32px;
  height: 32px;
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Header variants */
.site-header--transparent {
  color: white;
}
.site-header--transparent .phone-pill {
  background: white;
  color: var(--text);
}

.site-header--solid {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text);
  border-bottom-color: var(--border);
}

/* Mobile menu drawer */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 200;
  padding: 6rem var(--gutter) 3rem;
  transform: translateY(-100%);
  transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1);
  overflow-y: auto;
}
.mobile-menu.is-open { transform: translateY(0); }
.mobile-menu__close {
  position: absolute;
  top: 1.5rem;
  right: var(--gutter);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.mobile-menu__list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.mobile-menu__list a {
  font-family: var(--font-display);
  font-size: clamp(2rem, 8vw, 3.5rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  display: block;
  padding: 0.5rem 0;
}

/* Hero
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  overflow: hidden;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.5) 100%);
  z-index: 1;
}
.hero__media img,
.hero__media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 var(--gutter);
  max-width: var(--container);
}

.hero__title {
  font-size: clamp(3.5rem, 13vw, 11rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 0.95;
  color: white;
}
.hero__title em {
  font-style: italic;
  font-weight: 400;
  color: var(--terracotta);
}

.hero__scroll {
  position: absolute;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: white;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.hero__scroll::after {
  content: '';
  display: block;
  width: 1px;
  height: 40px;
  background: var(--terracotta);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { transform: scaleY(0.3); transform-origin: top; opacity: 0.5; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* Page hero (smaller hero for inner pages) */
.page-hero {
  padding: calc(var(--header-h) + 5rem) 0 4rem;
  background: var(--bg-alt);
}
.page-hero__breadcrumb {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  letter-spacing: 0.05em;
}
.page-hero__breadcrumb a { text-decoration: underline; text-underline-offset: 3px; }
.page-hero__title {
  font-size: clamp(3rem, 9vw, 7rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 0.98;
  margin-bottom: 0;
}

/* Stats
   ========================================================================== */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 3rem 4rem;
  padding: 4rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat__num {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 0.75rem;
}
.stat__label {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Two-column intro
   ========================================================================== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
}
.two-col__title { line-height: 1.05; }
.two-col__body { font-size: 1.05rem; line-height: 1.65; color: var(--text); }
.two-col__body p + p { margin-top: 1em; }

@media (max-width: 768px) {
  .two-col { grid-template-columns: 1fr; gap: 2rem; }
}

/* Category list (home page)
   ========================================================================== */
.cats {
  display: flex;
  flex-direction: column;
}
.cat {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  padding: 3rem 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
  transition: background-color 0.3s ease;
}
.cat:hover { background: var(--bg-alt); }
.cat__label {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.cat__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2.25rem);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.02em;
  max-width: 60ch;
}
@media (max-width: 768px) {
  .cat { grid-template-columns: 1fr; gap: 1rem; padding: 2rem 0; }
}

/* Marquee text (large repeating text band)
   ========================================================================== */
.marquee {
  overflow: hidden;
  white-space: nowrap;
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.marquee__track {
  display: inline-block;
  animation: marquee 30s linear infinite;
}
.marquee__text {
  display: inline-block;
  font-family: var(--font-display);
  font-size: clamp(4rem, 10vw, 9rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.03em;
  padding: 0 1.5rem;
  color: var(--text);
}
.marquee__text::after {
  content: '◆';
  font-style: normal;
  font-size: 0.4em;
  vertical-align: middle;
  margin-left: 1.5rem;
  color: var(--text-muted);
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Pull quote / VR callout
   ========================================================================== */
.pullquote {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 3rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.25;
  max-width: 1100px;
  margin: 0 auto;
  color: var(--text);
}
.pullquote em {
  font-style: italic;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
}

/* Portfolio grid
   ========================================================================== */
.portfolio-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  margin-bottom: 3rem;
  gap: 2rem;
  flex-wrap: wrap;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

.project-card {
  display: block;
  group: relative;
}
.project-card__media {
  position: relative;
  overflow: hidden;
  background: var(--bg-alt);
  aspect-ratio: 4/3;
  margin-bottom: 1.25rem;
}
.project-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.project-card:hover .project-card__media img {
  transform: scale(1.04);
}
.project-card__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}
.project-card__cat {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.project-card__title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--text);
}
.project-card:hover { opacity: 1; }
.project-card:hover .project-card__title { text-decoration: underline; text-underline-offset: 4px; }

/* Filter
   ========================================================================== */
.filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}
.filter__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-right: 1rem;
  align-self: center;
}
.filter__btn {
  padding: 0.6rem 1.1rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: all 0.2s ease;
  background: transparent;
}
.filter__btn:hover {
  color: var(--text);
  border-color: var(--text);
}
.filter__btn.is-active {
  background: var(--text);
  color: white;
  border-color: var(--text);
}

/* Buttons & links
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 1.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--text);
  background: transparent;
  color: var(--text);
  border-radius: 100px;
  transition: all 0.2s ease;
}
.btn:hover {
  background: var(--text);
  color: white;
  opacity: 1;
}
.btn--filled {
  background: var(--text);
  color: white;
}
.btn--filled:hover { background: transparent; color: var(--text); }
.btn--ghost {
  border-color: transparent;
  padding: 1rem 0;
  border-bottom: 1px solid var(--text);
  border-radius: 0;
}
.btn--ghost:hover { background: transparent; opacity: 0.6; }

.link-arrow {
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  transition: color 0.2s ease, opacity 0.2s ease;
}
.link-arrow::after {
  content: '→';
  display: inline-block;
  transition: transform 0.2s ease, color 0.2s ease;
}
.link-arrow:hover { opacity: 1; color: var(--terracotta); }
.link-arrow:hover::after { transform: translateX(4px); color: var(--terracotta); }

/* Process page
   ========================================================================== */
.process-step-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  counter-reset: step;
}
.process-step {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 2rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
}
.process-step__num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: -0.02em;
}
.process-step__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}
.process-step__body { color: var(--text-muted); max-width: 60ch; }

.feature-block {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
  margin-bottom: 5rem;
}
.feature-block:nth-child(even) {
  grid-template-columns: 1.5fr 1fr;
}
.feature-block:nth-child(even) .feature-block__media {
  order: 2;
}
.feature-block__title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  line-height: 1.15;
}
.feature-block__media img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
@media (max-width: 768px) {
  .feature-block, .feature-block:nth-child(even) {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .feature-block:nth-child(even) .feature-block__media { order: 0; }
}

/* Approach pillars (4-up grid)
   ========================================================================== */
.pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 3rem;
}
.pillar {
  padding-top: 1.5rem;
  border-top: 2px solid var(--text);
}
.pillar__title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 1rem;
}
.pillar__body { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; }

/* Careers / job listings
   ========================================================================== */
.job {
  padding: 3rem 0;
  border-bottom: 1px solid var(--border);
}
.job:last-child { border-bottom: none; }
.job__title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}
.job h3 {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text);
  margin: 2rem 0 1rem;
}
.job ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.job ul li {
  position: relative;
  padding-left: 1.25rem;
  color: var(--text);
  line-height: 1.55;
}
.job ul li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--text-muted);
}

/* Contact page
   ========================================================================== */
.offices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 3rem;
  margin-bottom: 5rem;
}
.office__label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.office h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 0.75rem;
}
.office__field {
  margin-bottom: 1.5rem;
}
.office__field-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

/* Contact form */
.contact-form {
  display: grid;
  gap: 1.5rem;
  max-width: 600px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }

.form-field label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  display: block;
}
.form-field input,
.form-field textarea {
  width: 100%;
  padding: 0.85rem 0;
  font-family: inherit;
  font-size: 1rem;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  transition: border-color 0.2s ease;
}
.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-bottom-color: var(--terracotta);
}
.form-field textarea {
  min-height: 120px;
  resize: vertical;
}

/* Footer
   ========================================================================== */
.site-footer {
  background: var(--text);
  color: white;
  padding: clamp(4rem, 8vw, 6rem) 0 2rem;
  position: relative;
  overflow: hidden;
}
.site-footer__brand {
  font-family: var(--font-display);
  font-size: clamp(4rem, 14vw, 12rem);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.04em;
  line-height: 0.9;
  margin-bottom: 4rem;
  opacity: 0.95;
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 3rem;
  padding-top: 3rem;
  border-top: 1px solid rgba(255,255,255,0.15);
}
@media (max-width: 768px) {
  .site-footer__grid { grid-template-columns: 1fr; gap: 2rem; }
}

.site-footer h4 {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  color: rgba(255,255,255,0.6);
}
.site-footer ul { display: flex; flex-direction: column; gap: 0.6rem; }
.site-footer ul a { color: rgba(255,255,255,0.85); transition: color 0.2s ease; }
.site-footer ul a:hover { color: var(--terracotta); opacity: 1; }
.site-footer__copy {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Mobile adjustments
   ========================================================================== */
@media (max-width: 900px) {
  .site-nav__list { display: none; }
  .menu-toggle { display: flex; }
  .phone-pill { display: none; }
}

/* Reveal on scroll — disabled for guaranteed visibility across all clients/tools.
   The .reveal class remains in HTML as a no-op for future use.
   ========================================================================== */
.reveal,
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Print
   ========================================================================== */
@media print {
  .site-header, .site-footer, .menu-toggle, .filter { display: none; }
  body { color: black; background: white; }
}
