/* ==========================================================================
   OPERAFLOW - EDITORIAL HUMAN-DESIGNED CSS SYSTEM
   Single Font Family: Inter Throughout
   Visual Identity: Premium, Minimalist, High-Contrast Black & White
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Color Palette - Restrained Editorial B&W */
  --bg-primary: #000000;
  --bg-secondary: #08080A;
  --bg-card: #0D0D0F;
  --bg-card-hover: #141417;
  
  --border-subtle: #1C1C20;
  --border-strong: #2A2A30;
  --border-focus: #FFFFFF;

  --text-primary: #FFFFFF;
  --text-secondary: #A1A1AA;
  --text-muted: #71717A;
  --text-dim: #52525B;

  --accent-white: #FFFFFF;

  /* Typography Scale — Single Font Family Throughout */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Layout & Spacing */
  --container-max: 1240px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-pill: 9999px;

  --header-height: 84px;
  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  font-family: var(--font-family);
  font-size: 16px;
  line-height: 1.6;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

:focus-visible {
  outline: 2px solid var(--border-focus);
  outline-offset: 4px;
}

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

@media (min-width: 768px) {
  .container {
    padding-left: 2.5rem;
    padding-right: 2.5rem;
  }
}

/* Typography Scale — All Inter */
h1, h2, h3, h4 {
  font-family: var(--font-family);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--text-primary);
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(1.85rem, 3.2vw, 2.75rem);
  letter-spacing: -0.025em;
}

h3 {
  font-size: clamp(1.2rem, 1.8vw, 1.5rem);
  font-weight: 600;
}

p {
  color: var(--text-secondary);
  font-size: 1.025rem;
}

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

/* Buttons — Pill CTAs Matching Reference Image */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.6rem;
  font-family: var(--font-family);
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: var(--radius-pill);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  border: 1px solid transparent;
}

.btn-primary {
  background-color: var(--accent-white);
  color: #000000;
  border-color: var(--accent-white);
}

.btn-primary:hover {
  background-color: #E4E4E7;
  border-color: #E4E4E7;
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: transparent;
  color: var(--text-primary);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.06);
  border-color: var(--text-primary);
}

.btn-arrow {
  font-size: 1.1rem;
  line-height: 1;
  transition: transform var(--transition-fast);
}

.btn:hover .btn-arrow {
  transform: translateX(3px);
}

/* Section Layout */
.section {
  padding-top: clamp(4rem, 7vw, 6.5rem);
  padding-bottom: clamp(4rem, 7vw, 6.5rem);
  border-bottom: 1px solid var(--border-subtle);
}

.section-header {
  max-width: 720px;
  margin-bottom: clamp(2.5rem, 4vw, 3.5rem);
}

.section-header p {
  margin-top: 0.85rem;
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Grids */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

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

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

/* Minimalist Editorial Cards */
.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  transition: all var(--transition-fast);
}

.card:hover {
  background-color: var(--bg-card-hover);
  border-color: var(--border-strong);
}

/* Header & Logo */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  gap: 0.75rem;
}

.brand-logo img {
  height: 46px;
  width: auto;
  object-fit: contain;
  filter: brightness(1.1);
  display: block;
}

.nav-menu {
  display: none;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

@media (min-width: 992px) {
  .nav-menu {
    display: flex;
  }
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-primary);
}

.mobile-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 8px;
  color: var(--text-primary);
}

@media (min-width: 992px) {
  .mobile-toggle {
    display: none;
  }
}

.mobile-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
}

/* Mobile Drawer */
.mobile-drawer {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.98);
  z-index: 999;
  padding: 2.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
  transition: all var(--transition-smooth);
  border-bottom: 1px solid var(--border-strong);
}

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

.mobile-nav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.mobile-nav-links a {
  color: var(--text-primary);
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
}

/* Hero Section */
.hero-section {
  padding-top: calc(var(--header-height) + clamp(3.5rem, 6vw, 5.5rem));
  padding-bottom: clamp(4rem, 7vw, 6.5rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3.5rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

.hero-content h1 {
  margin-bottom: 1.5rem;
  max-width: 680px;
}

.hero-content p.hero-lead {
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  color: var(--text-secondary);
  margin-bottom: 2.25rem;
  max-width: 600px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.6rem;
}

.hero-subcaption {
  font-size: 0.8rem;
  color: var(--text-muted);
  padding-left: 0.5rem;
}

/* Hero Geometric Line Artwork */
.hero-artwork {
  width: 100%;
  aspect-ratio: 1 / 0.85;
  border-radius: var(--radius-md);
  background-color: #000000;
  border: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-artwork svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.85;
}

/* Bottlenecks Card Grid */
.problem-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 240px;
}

.problem-icon {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.problem-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--text-primary);
}

.problem-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.6rem;
}

.problem-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Solutions Cards */
.solution-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.solution-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.solution-icon {
  width: 36px;
  height: 36px;
  margin-bottom: 1.25rem;
}

.solution-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--text-primary);
}

/* Selected Work / Case Studies */
.case-study-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: clamp(2rem, 3.5vw, 3rem);
  margin-bottom: 2rem;
}

.case-study-badge {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
  display: block;
}

.case-study-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 992px) {
  .case-study-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.case-study-box {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.case-study-box h4 {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.case-study-box p {
  font-size: 0.9rem;
}

.metric-number {
  font-size: clamp(2.25rem, 4vw, 3.25rem);
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.metric-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

/* Testimonial Card & Video Container — Perfectly Constrained Card Layout */
.testimonial-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: clamp(1.5rem, 3vw, 2rem);
  max-width: 720px;
  margin: 0 auto;
  overflow: hidden;
}

.testimonial-video-container {
  position: relative;
  width: 100%;
  max-height: 420px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-strong);
  margin-bottom: 1.25rem;
  background-color: #000000;
  box-shadow: 0 16px 36px rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.testimonial-video-container video,
.testimonial-video-container img {
  width: 100%;
  max-height: 420px;
  object-fit: contain;
  display: block;
  background-color: #000000;
  border-radius: var(--radius-md);
}

.testimonial-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding-left: 0.25rem;
}

.testimonial-author {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-primary);
}

.testimonial-role {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Developer Bio Grid — Natural Color Photo */
.developer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 992px) {
  .developer-grid {
    grid-template-columns: 0.8fr 1.2fr;
  }
}

.developer-image-wrap {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.developer-image-wrap img {
  width: 100%;
  height: auto;
  display: block;
  filter: none; /* NO greyscale filter */
}

.developer-values {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 1.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border-subtle);
}

.developer-value-item h4 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.developer-value-item p {
  font-size: 0.825rem;
  color: var(--text-muted);
}

/* Process Timeline */
.process-timeline {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

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

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

.process-step {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.step-number {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
}

.process-step h3 {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.process-step p {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Final CTA */
.cta-box {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: clamp(3rem, 5vw, 4.5rem) clamp(1.5rem, 3vw, 2.5rem);
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.cta-box h2 {
  margin-bottom: 1rem;
}

.cta-box p {
  max-width: 540px;
  margin: 0 auto 2rem auto;
  font-size: 1.05rem;
}

/* Footer Matching Reference Right Panel */
.footer {
  background-color: #000000;
  border-top: 1px solid var(--border-subtle);
  padding-top: 3.5rem;
  padding-bottom: 2.5rem;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}

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

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 300px;
}

.footer-column h4 {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.footer-column ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-column a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color var(--transition-fast);
}

.footer-column a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: center;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-dim);
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
