/* ============================================
   LEGAL TECH COLLECTIVE — styles.css
   Palette: Rosewood Library
   Fonts: DM Serif Display + Plus Jakarta Sans
   ============================================ */

/* --- CSS Variables --- */
:root {
  --rosewood:    #4A1C2B;
  --plum:        #7D3C50;
  --gold:        #C9A87C;
  --gold-light:  #E2C99A;
  --cream:       #F2EDE4;
  --cream-dark:  #E8DFD0;
  --ink:         #1A0A10;
  --white:       #FDFAF6;

  --font-display: 'DM Serif Display', Georgia, serif;
  --font-body:    'Plus Jakarta Sans', sans-serif;

  --nav-h: 72px;
  --section-pad: clamp(80px, 10vw, 140px);
  --max-w: 1200px;
  --radius: 4px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--rosewood);
  line-height: 1.6;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* --- Typography Scale --- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.1;
  font-weight: 400;
}

h1 { font-size: clamp(3rem, 7vw, 6rem); }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.75rem); }

em { font-style: italic; color: var(--gold); }

p {
  font-size: clamp(0.95rem, 1.2vw, 1.1rem);
  line-height: 1.75;
  color: var(--plum);
  font-weight: 400;
}

.section-label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.25rem;
}

/* --- Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal--delay-1 { transition-delay: 0.12s; }
.reveal--delay-2 { transition-delay: 0.24s; }
.reveal--delay-3 { transition-delay: 0.36s; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border-radius: var(--radius);
  transition: all 0.25s var(--ease-out);
  white-space: nowrap;
}

.btn--primary {
  background: var(--rosewood);
  color: var(--cream);
  border: 2px solid var(--rosewood);
}
.btn--primary:hover {
  background: var(--ink);
  border-color: var(--ink);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(74,28,43,0.25);
}

.btn--ghost {
  background: transparent;
  color: var(--cream);
  border: 2px solid rgba(242,237,228,0.4);
}
.btn--ghost:hover {
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
}

.btn--light {
  background: var(--cream);
  color: var(--rosewood);
  border: 2px solid var(--cream);
}
.btn--light:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.btn--full { width: 100%; justify-content: center; }

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  transition: background 0.4s ease, box-shadow 0.4s ease;
}

.nav.scrolled {
  background: rgba(26, 10, 16, 0.96);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(201,168,124,0.15);
}

.nav__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav__logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  background: var(--gold);
  color: var(--rosewood);
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  border-radius: 2px;
  flex-shrink: 0;
}

.nav__logo-text {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--cream);
  letter-spacing: 0.02em;
}

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

.nav__links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(242,237,228,0.75);
  letter-spacing: 0.02em;
  transition: color 0.2s;
}
.nav__links a:hover { color: var(--gold); }

.nav__cta {
  padding: 0.5rem 1.25rem;
  border: 1.5px solid var(--gold) !important;
  border-radius: var(--radius);
  color: var(--gold) !important;
  transition: background 0.2s, color 0.2s !important;
}
.nav__cta:hover {
  background: var(--gold) !important;
  color: var(--rosewood) !important;
}

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}
.nav__hamburger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--cream);
  border-radius: 2px;
  transition: all 0.3s;
}

.nav__mobile {
  display: none;
  flex-direction: column;
  background: var(--ink);
  padding: 1.5rem 2rem;
  gap: 1.25rem;
  border-top: 1px solid rgba(201,168,124,0.15);
}
.nav__mobile a {
  font-size: 1rem;
  font-weight: 500;
  color: var(--cream);
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(242,237,228,0.08);
  transition: color 0.2s;
}
.nav__mobile a:hover { color: var(--gold); }
.nav__mobile.open { display: flex; }

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  background: var(--ink);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-h) + 60px) 2rem 80px;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 70% 40%, rgba(125,60,80,0.35) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 20% 80%, rgba(74,28,43,0.5) 0%, transparent 60%);
  pointer-events: none;
}

/* Grain texture overlay */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
}

.hero__bg-text {
  position: absolute;
  right: -2%;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-display);
  font-size: clamp(180px, 28vw, 380px);
  font-weight: 400;
  color: transparent;
  -webkit-text-stroke: 1px rgba(201,168,124,0.08);
  line-height: 1;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
}

.hero__eyebrow {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
}

.hero__headline {
  color: var(--cream);
  margin-bottom: 1.75rem;
  max-width: 700px;
}

.hero__sub {
  color: rgba(242,237,228,0.65);
  max-width: 520px;
  margin-bottom: 2.5rem;
  font-size: clamp(1rem, 1.3vw, 1.15rem);
}

.hero__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero__stat-block {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 5rem auto 0;
  width: 100%;
  display: flex;
  align-items: stretch;
  gap: 0;
  border: 1px solid rgba(201,168,124,0.2);
  border-radius: var(--radius);
  overflow: hidden;
}

.hero__stat {
  flex: 1;
  padding: 2rem 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  background: rgba(255,255,255,0.03);
  transition: background 0.3s;
}
.hero__stat:hover { background: rgba(201,168,124,0.06); }

.hero__stat-num {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.5vw, 3rem);
  color: var(--gold);
  line-height: 1;
}

.hero__stat-label {
  font-size: 0.8rem;
  color: rgba(242,237,228,0.5);
  font-weight: 400;
  line-height: 1.4;
}

.hero__stat-divider {
  width: 1px;
  background: rgba(201,168,124,0.2);
  flex-shrink: 0;
}

.hero__scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  z-index: 1;
}
.hero__scroll-hint span {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(242,237,228,0.3);
}
.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, rgba(201,168,124,0.5), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.2); }
}

/* ============================================
   PROBLEM SECTION
   ============================================ */
.problem {
  padding: var(--section-pad) 2rem;
  background: var(--cream);
}

.problem__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.problem__headline {
  margin-bottom: 1.5rem;
  color: var(--rosewood);
}

.problem__text p {
  margin-bottom: 1rem;
}

.problem__visual {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.problem__card {
  padding: 2rem 2.5rem;
  border: 1px solid rgba(74,28,43,0.12);
  border-radius: var(--radius);
  background: var(--white);
  display: flex;
  align-items: center;
  gap: 2rem;
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s;
}
.problem__card:hover {
  transform: translateX(8px);
  box-shadow: -4px 0 0 var(--gold), 0 4px 20px rgba(74,28,43,0.08);
}

.problem__card--accent {
  background: var(--rosewood);
  border-color: var(--rosewood);
}
.problem__card--accent .problem__card-num { color: var(--gold); }
.problem__card--accent .problem__card-text { color: rgba(242,237,228,0.75); }
.problem__card--accent .problem__card-text span { color: var(--gold-light); }

.problem__card-num {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  color: var(--rosewood);
  line-height: 1;
  flex-shrink: 0;
  min-width: 100px;
}

.problem__card-text {
  font-size: 0.9rem;
  color: var(--plum);
  line-height: 1.5;
}
.problem__card-text span {
  font-size: 0.75rem;
  opacity: 0.6;
}

/* ============================================
   SERVICES
   ============================================ */
.services {
  padding: var(--section-pad) 2rem;
  background: var(--rosewood);
  position: relative;
  overflow: hidden;
}

.services::before {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201,168,124,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.services__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.services__header {
  max-width: 600px;
  margin-bottom: 4rem;
}

.services__header h2 { color: var(--cream); }

.services__intro {
  color: rgba(242,237,228,0.6);
  margin-top: 1rem;
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5px;
  background: rgba(201,168,124,0.15);
  border: 1.5px solid rgba(201,168,124,0.15);
  border-radius: var(--radius);
  overflow: hidden;
}

.service-card {
  background: rgba(255,255,255,0.03);
  padding: 3rem 2.5rem;
  position: relative;
  transition: background 0.3s;
}
.service-card:hover { background: rgba(201,168,124,0.07); }

.service-card__number {
  font-family: var(--font-display);
  font-size: 0.75rem;
  color: rgba(201,168,124,0.4);
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
}

.service-card__icon {
  width: 48px; height: 48px;
  color: var(--gold);
  margin-bottom: 1.5rem;
}

.service-card h3 {
  color: var(--cream);
  margin-bottom: 1rem;
  font-size: 1.4rem;
}

.service-card p {
  color: rgba(242,237,228,0.55);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ============================================
   HOW WE WORK
   ============================================ */
.how {
  padding: var(--section-pad) 2rem;
  background: var(--cream-dark);
}

.how__inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.how__header {
  max-width: 640px;
  margin-bottom: 4rem;
}
.how__header h2 { color: var(--rosewood); }
.how__header p { margin-top: 1rem; }

.how__pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  margin-bottom: 4rem;
}

.how__pillar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.how__pillar-line {
  width: 48px;
  height: 3px;
  background: var(--gold);
  border-radius: 2px;
  transition: width 0.4s var(--ease-out);
}
.how__pillar:hover .how__pillar-line { width: 80px; }

.how__pillar-content h3 {
  color: var(--rosewood);
  margin-bottom: 0.75rem;
  font-size: 1.5rem;
}

.how__quote {
  border-left: 3px solid var(--gold);
  padding: 1.5rem 2.5rem;
  background: var(--white);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.how__quote blockquote {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  font-style: italic;
  color: var(--rosewood);
  line-height: 1.4;
}

/* ============================================
   CTA BAND
   ============================================ */
.cta-band {
  background: var(--gold);
  padding: 5rem 2rem;
}

.cta-band__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
}

.cta-band__text h2 {
  color: var(--rosewood);
  font-size: clamp(1.75rem, 3vw, 2.75rem);
  margin-bottom: 0.5rem;
}

.cta-band__text p {
  color: rgba(74,28,43,0.7);
  max-width: 500px;
}

/* ============================================
   CONTACT
   ============================================ */
.contact {
  padding: var(--section-pad) 2rem;
  background: var(--ink);
}

.contact__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 6rem;
  align-items: start;
}

.contact__info .section-label { color: var(--gold); }

.contact__info h2 {
  color: var(--cream);
  margin-bottom: 1.25rem;
}

.contact__info > p {
  color: rgba(242,237,228,0.55);
  margin-bottom: 2.5rem;
}

.contact__details {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact__link {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  color: rgba(242,237,228,0.65);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(242,237,228,0.06);
}
.contact__link:hover { color: var(--gold); }
.contact__link svg { width: 18px; height: 18px; flex-shrink: 0; }

/* Form */
.contact__form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(242,237,228,0.5);
}
.form-group label span { color: var(--gold); }

.form-group input,
.form-group select,
.form-group textarea {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(201,168,124,0.2);
  border-radius: var(--radius);
  padding: 0.875rem 1rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--cream);
  outline: none;
  transition: border-color 0.2s, background 0.2s;
  -webkit-appearance: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(242,237,228,0.2);
}

.form-group select option {
  background: var(--ink);
  color: var(--cream);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--gold);
  background: rgba(201,168,124,0.06);
}

.form-group textarea { resize: vertical; min-height: 120px; }

/* Checkbox */
.form-group--checkbox { flex-direction: row; align-items: center; }

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  font-size: 0.85rem !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
  color: rgba(242,237,228,0.5) !important;
}

.checkbox-label input[type="checkbox"] { display: none; }

.checkbox-custom {
  width: 18px; height: 18px;
  border: 1.5px solid rgba(201,168,124,0.3);
  border-radius: 2px;
  flex-shrink: 0;
  position: relative;
  transition: border-color 0.2s, background 0.2s;
}

.checkbox-label input:checked + .checkbox-custom {
  background: var(--gold);
  border-color: var(--gold);
}
.checkbox-label input:checked + .checkbox-custom::after {
  content: '';
  position: absolute;
  left: 4px; top: 1px;
  width: 6px; height: 10px;
  border: 2px solid var(--rosewood);
  border-top: none; border-left: none;
  transform: rotate(45deg);
}

/* Form success */
.form__success {
  display: none;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: rgba(201,168,124,0.1);
  border: 1px solid rgba(201,168,124,0.3);
  border-radius: var(--radius);
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 500;
}
.form__success svg { width: 20px; height: 20px; flex-shrink: 0; }
.form__success.visible { display: flex; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--ink);
  border-top: 1px solid rgba(201,168,124,0.1);
  padding: 3rem 2rem;
}

.footer__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  text-align: center;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--cream);
}

.footer__tagline {
  font-size: 0.85rem;
  color: rgba(242,237,228,0.35);
}

.footer__links {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
}
.footer__links a {
  font-size: 0.8rem;
  color: rgba(242,237,228,0.4);
  font-weight: 500;
  transition: color 0.2s;
}
.footer__links a:hover { color: var(--gold); }

.footer__copy {
  font-size: 0.75rem;
  color: rgba(242,237,228,0.2);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .problem__inner { grid-template-columns: 1fr; gap: 3rem; }
  .services__grid { grid-template-columns: 1fr; gap: 1.5px; }
  .how__pillars { grid-template-columns: 1fr; gap: 2.5rem; }
  .contact__inner { grid-template-columns: 1fr; gap: 3rem; }
}

@media (max-width: 768px) {
  .nav__links { display: none; }
  .nav__hamburger { display: flex; }

  .hero__stat-block {
    flex-direction: column;
    gap: 0;
  }
  .hero__stat-divider {
    width: 100%; height: 1px;
  }

  .cta-band__inner {
    flex-direction: column;
    text-align: center;
  }

  .form-row { grid-template-columns: 1fr; }

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

@media (max-width: 480px) {
  :root { --section-pad: 60px; }
  .hero { padding-top: calc(var(--nav-h) + 40px); }
  .hero__actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
}