/* ==========================================================================
   Vivid Concepts — Refined Design System
   thinkvividly.com · Clean, minimal violet palette
   ========================================================================== */

/* ==========================================================================
   1. FONTS
   ========================================================================== */



/* ==========================================================================
   2. CSS CUSTOM PROPERTIES
   ========================================================================== */

:root {
  /* Primary Palette (Violet) */
  --primary-50:  #f5f3ff;
  --primary-100: #ede9fe;
  --primary-200: #ddd6fe;
  --primary-300: #c4b5fd;
  --primary-400: #a78bfa;
  --primary-500: #8b5cf6;
  --primary-600: #7c3aed;
  --primary-700: #6d28d9;
  --primary-800: #5b21b6;
  --primary-900: #4c1d95;

  /* Accent (used sparingly) */
  --accent-cyan:  #06b6d4;
  --accent-pink:  #ec4899;
  --accent-green: #10b981;

  /* Neutrals */
  --gray-50:  #fafafa;
  --gray-100: #f4f4f5;
  --gray-200: #e4e4e7;
  --gray-300: #d4d4d8;
  --gray-400: #a1a1aa;
  --gray-500: #71717a;
  --gray-600: #52525b;
  --gray-700: #3f3f46;
  --gray-800: #27272a;
  --gray-900: #18181b;
  --gray-950: #09090b;

  /* Semantic */
  --background:           #09090b;
  --background-secondary: #18181b;
  --background-tertiary:  #27272a;
  --text-primary:   #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted:     #71717a;

  /* Gradients - used SPARINGLY */
  --gradient-primary: linear-gradient(135deg, var(--primary-500) 0%, var(--primary-700) 100%);
  --gradient-text:    linear-gradient(135deg, var(--primary-300) 0%, var(--primary-400) 100%);

  /* Layout */
  --container-max:     1200px;
  --container-padding: clamp(20px, 5vw, 40px);
  --section-padding:   clamp(60px, 10vw, 120px);
  --nav-height:        80px;

  /* Shadows */
  --shadow-sm:   0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md:   0 4px 6px -1px rgb(0 0 0 / 0.15);
  --shadow-lg:   0 10px 15px -3px rgb(0 0 0 / 0.2);
  --shadow-glow: 0 0 40px -10px var(--primary-500);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;

  /* Radius */
  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   16px;
  --radius-full: 9999px;
}

/* ==========================================================================
   3. RESET + BASE
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

body {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  background: var(--background);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: quiche-sans, 'avenir-next', 'Avenir Next', sans-serif;
  font-weight: 700;
  line-height: 1.15;
  color: var(--text-primary);
}

h2, h3, h4 {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-weight: 700;
}

p {
  color: var(--text-secondary);
  line-height: 1.7;
}

::selection {
  background-color: var(--primary-900);
  color: var(--text-primary);
}

/* ==========================================================================
   4. LAYOUT
   ========================================================================== */

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: var(--section-padding) 0;
}

.bg-secondary {
  background: var(--background-secondary);
}

/* Grid System */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

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

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

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

/* ==========================================================================
   5. TYPOGRAPHY
   ========================================================================== */

h1 { font-size: clamp(40px, 7vw, 72px); }
h2 { font-size: clamp(28px, 5vw, 48px); }
h3 { font-size: clamp(18px, 2.5vw, 24px); }

/* Gradient text - use only on hero headline */
.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Section components */
.section-badge {
  display: inline-block;
  padding: 8px 16px;
  background: var(--primary-900);
  color: var(--primary-300);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  border-radius: var(--radius-full);
  border: 1px solid var(--primary-700);
  margin-bottom: 20px;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 60px;
}

.section-title {
  font-size: clamp(28px, 5vw, 48px);
  margin-bottom: 16px;
  color: var(--text-primary);
}

.section-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 600px;
  margin: 0 auto;
}

/* ==========================================================================
   6. NAVIGATION
   ========================================================================== */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: rgba(9, 9, 11, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition-base), background var(--transition-base);
}

.nav.scrolled {
  background: rgba(9, 9, 11, 0.95);
  border-bottom-color: var(--gray-800);
}

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

.nav-logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.nav-logo-text {
  font-family: quiche-sans, 'avenir-next', 'Avenir Next', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  position: relative;
  padding: 4px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--primary-400);
  transition: width var(--transition-base);
}

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

.nav-link:hover::after {
  width: 100%;
}

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

.nav-link.active::after {
  width: 100%;
}

.nav-cta {
  margin-left: 8px;
}

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.nav-hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-hamburger.open span:nth-child(2) {
  opacity: 0;
}

.nav-hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu */
.nav-mobile-menu {
  position: fixed;
  inset: 0;
  background: var(--background);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-base), visibility var(--transition-base);
  z-index: 999;
}

.nav-mobile-menu.open {
  opacity: 1;
  visibility: visible;
}

.nav-mobile-link {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-secondary);
  opacity: 0;
  transform: translateY(16px);
  transition: color var(--transition-fast), opacity var(--transition-base), transform var(--transition-base);
}

.nav-mobile-menu.open .nav-mobile-link {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays for mobile link entrance */
.nav-mobile-menu.open .nav-mobile-link:nth-child(1) { transition-delay: 80ms; }
.nav-mobile-menu.open .nav-mobile-link:nth-child(2) { transition-delay: 140ms; }
.nav-mobile-menu.open .nav-mobile-link:nth-child(3) { transition-delay: 200ms; }
.nav-mobile-menu.open .nav-mobile-link:nth-child(4) { transition-delay: 260ms; }
.nav-mobile-menu.open .nav-mobile-link:nth-child(5) { transition-delay: 320ms; }

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

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
}

/* ==========================================================================
   7. BUTTONS
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background: var(--primary-600);
  color: white;
  box-shadow: 0 4px 20px -4px rgba(124, 58, 237, 0.4);
}

.btn-primary:hover {
  background: var(--primary-500);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px -4px rgba(124, 58, 237, 0.6), 0 0 40px -8px rgba(124, 58, 237, 0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: transparent;
  color: var(--primary-300);
  border: 2px solid var(--primary-700);
}

.btn-secondary:hover {
  background: var(--primary-900);
  border-color: var(--primary-600);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 14px;
}

.btn-lg {
  padding: 18px 36px;
  font-size: 16px;
}

.btn-full {
  width: 100%;
}

/* ==========================================================================
   8. HERO SECTION
   ========================================================================== */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-height) + 40px) 0 80px;
  position: relative;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.hero-eyebrow {
  display: inline-block;
  padding: 10px 20px;
  background: var(--primary-900);
  border: 1px solid var(--primary-700);
  border-radius: var(--radius-full);
  color: var(--primary-300);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 28px;
}

.hero-title {
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.1;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.hero-subtitle {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 700px;
  margin: 0 auto 40px;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Background orbs with floating animation */
.orb-container {
  position: relative;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  will-change: transform;
  z-index: 0;
}

.orb-1 {
  width: 600px;
  height: 600px;
  background: rgba(124, 58, 237, 0.15);
  top: -200px;
  right: -150px;
  animation: float 8s ease-in-out infinite;
}

.orb-2 {
  width: 500px;
  height: 500px;
  background: rgba(139, 92, 246, 0.10);
  bottom: -100px;
  left: -150px;
  animation: float 10s ease-in-out infinite;
  animation-delay: -3s;
}

.orb-3 {
  width: 400px;
  height: 400px;
  background: rgba(6, 182, 212, 0.06);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: float-center 12s ease-in-out infinite;
  animation-delay: -6s;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-25px); }
}

@keyframes float-center {
  0%, 100% { transform: translate(-50%, -50%) translateY(0px); }
  50% { transform: translate(-50%, -50%) translateY(-25px); }
}

/* ==========================================================================
   9. CARDS
   ========================================================================== */

.card {
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: border-color var(--transition-base), transform var(--transition-base), box-shadow var(--transition-base);
  will-change: transform;
}

.card:hover {
  border-color: var(--primary-700);
  transform: translateY(-4px) translate(var(--mag-x, 0), var(--mag-y, 0));
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-900);
  border: 1px solid var(--primary-700);
  border-radius: var(--radius-md);
  color: var(--primary-400);
  margin-bottom: 20px;
}

.feature-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.feature-body {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Feature Item (smaller variant) */
.feature-item {
  text-align: center;
  padding: 24px 16px;
}

.feature-item .feature-icon {
  margin: 0 auto 16px;
}

.feature-item .feature-title {
  font-size: 16px;
  margin-bottom: 8px;
}

.feature-item .feature-body {
  font-size: 14px;
}

/* ==========================================================================
   10. PRICING CARDS
   ========================================================================== */

.pricing-card {
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  text-align: center;
  transition: border-color var(--transition-base), transform var(--transition-base), box-shadow var(--transition-base);
  will-change: transform;
}

.pricing-card:hover {
  border-color: var(--primary-600);
  box-shadow: 0 0 40px -10px rgba(124, 58, 237, 0.3);
}

.pricing-card.featured {
  border-color: var(--primary-600);
  position: relative;
}

.pricing-featured-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 16px;
  background: var(--primary-600);
  color: white;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: var(--radius-full);
}

.pricing-name {
  display: block;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.pricing-price {
  font-family: quiche-sans, 'avenir-next', 'Avenir Next', sans-serif;
  font-size: 56px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.pricing-price-prefix {
  font-size: 28px;
  vertical-align: top;
  margin-right: 2px;
}

.pricing-period {
  display: block;
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 4px;
  margin-bottom: 12px;
}

.pricing-drop {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--radius-full);
  color: var(--accent-green);
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 24px;
}

.pricing-features {
  text-align: left;
  margin-bottom: 28px;
}

.pricing-features li {
  padding: 10px 0;
  border-bottom: 1px solid var(--gray-800);
  font-size: 14px;
  color: var(--text-secondary);
}

.pricing-features li:last-child {
  border-bottom: none;
}

/* ==========================================================================
   11. PORTFOLIO CARDS
   ========================================================================== */

.portfolio-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  transition: border-color var(--transition-base), transform var(--transition-base), box-shadow var(--transition-base);
  will-change: transform;
}

.portfolio-card:hover {
  border-color: var(--primary-600);
  box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.4), 0 0 30px -10px rgba(124, 58, 237, 0.2);
}

.portfolio-browser {
  background: var(--background-tertiary);
}

.portfolio-browser-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-bottom: 1px solid var(--gray-700);
}

.portfolio-browser-url {
  font-size: 12px;
  color: var(--text-muted);
  font-family: monospace;
}

.portfolio-screenshot-wrap {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--background);
}

.portfolio-screenshot-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-card:hover .portfolio-screenshot-wrap img {
  transform: scale(1.05);
}

.portfolio-label {
  padding: 16px;
}

.portfolio-label-name {
  display: block;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 16px;
}

.portfolio-label-type {
  font-size: 13px;
  color: var(--text-muted);
}

.portfolio-overlay {
  position: absolute;
  inset: 0;
  background: rgba(9, 9, 11, 0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.portfolio-card:hover .portfolio-overlay {
  opacity: 1;
}

.portfolio-overlay-title {
  font-size: 22px;
  margin-bottom: 12px;
}

.portfolio-overlay-description {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  max-width: 280px;
}

.portfolio-overlay-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary-300);
  font-size: 14px;
  font-weight: 600;
}

.portfolio-overlay-link:hover {
  color: var(--primary-400);
}

/* ==========================================================================
   12. PAYMENT ARC (HOW IT WORKS)
   ========================================================================== */

.payment-arc {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px;
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  border-radius: var(--radius-lg);
}

.payment-arc-zones {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
}

.payment-arc-zone-monthly {
  color: var(--primary-400);
}

.payment-arc-zone-ownership {
  color: var(--accent-green);
}

.payment-arc-track {
  height: 8px;
  background: var(--gray-800);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: 16px;
}

.payment-arc-fill {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--primary-600) 0%, var(--primary-600) 75%, var(--accent-green) 75%);
  border-radius: var(--radius-full);
  transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.payment-arc-fill.animate {
  width: 100%;
}

.payment-arc-markers {
  display: flex;
  justify-content: space-between;
  margin-bottom: 32px;
}

.payment-arc-marker {
  text-align: center;
}

.payment-arc-marker-label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.payment-arc-marker-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.payment-arc-marker.milestone .payment-arc-marker-value {
  color: var(--accent-green);
}

.payment-arc-callouts {
  display: flex;
  justify-content: center;
  gap: 48px;
}

.payment-arc-callout {
  text-align: center;
}

.payment-arc-callout-label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.payment-arc-callout-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.payment-arc-callout.highlight .payment-arc-callout-value {
  color: var(--accent-green);
}

/* ==========================================================================
   13. STATS
   ========================================================================== */

.stat-block {
  text-align: center;
  padding: 24px;
}

.stat-block .counter-number {
  display: block;
  font-family: quiche-sans, 'avenir-next', 'Avenir Next', sans-serif;
  font-size: 56px;
  font-weight: 700;
  color: var(--primary-400);
  line-height: 1;
  margin-bottom: 8px;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-block .stat-label {
  font-size: 14px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ==========================================================================
   14. TAGS
   ========================================================================== */

.tag {
  display: inline-block;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: var(--radius-full);
}

.tag-violet {
  background: rgba(124, 58, 237, 0.15);
  color: var(--primary-400);
  border: 1px solid rgba(124, 58, 237, 0.25);
}

.tag-green {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-green);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

/* ==========================================================================
   15. CTA SECTION
   ========================================================================== */

.cta-section {
  text-align: center;
  padding: var(--section-padding) 0;
}

.cta-section .section-title {
  margin-bottom: 16px;
}

.cta-section .section-subtitle {
  margin-bottom: 32px;
}

/* ==========================================================================
   16. FOOTER
   ========================================================================== */

.footer {
  padding: 48px 0;
  border-top: 1px solid var(--gray-800);
  text-align: center;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.footer-logo {
  font-family: quiche-sans, 'avenir-next', 'Avenir Next', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 14px;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--primary-400);
}

.footer-copy {
  font-size: 13px;
  color: var(--text-muted);
}

/* ==========================================================================
   17. FORMS
   ========================================================================== */

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 14px 18px;
  background: var(--background-tertiary);
  border: 1px solid var(--gray-700);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 15px;
  font-family: inherit;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary-600);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--text-muted);
}

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

.form-select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2371717a' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
}

.honeypot-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Form messages */
.form-message {
  padding: 16px;
  border-radius: var(--radius-md);
  font-size: 14px;
  text-align: center;
}

.form-message.success {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--accent-green);
}

.form-message.error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

/* ==========================================================================
   18. CONTACT PAGE
   ========================================================================== */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

@media (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.contact-steps {
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.contact-steps-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.contact-step {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--gray-800);
}

.contact-step:last-child {
  border-bottom: none;
}

.contact-step-number {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-900);
  border: 1px solid var(--primary-700);
  border-radius: 50%;
  color: var(--primary-400);
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.contact-step-content h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.contact-step-content p {
  font-size: 14px;
  color: var(--text-muted);
}

/* ==========================================================================
   19. FAQ
   ========================================================================== */

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

@media (max-width: 768px) {
  .faq-grid {
    grid-template-columns: 1fr;
  }
}

.faq-item {
  padding: 24px;
  background: var(--background-secondary);
  border: 1px solid var(--gray-800);
  border-radius: var(--radius-md);
}

.faq-question {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.faq-answer {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   20. PAGE HERO (Work, Contact pages)
   ========================================================================== */

.page-hero {
  min-height: 50vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-height) + 60px) 0 80px;
  position: relative;
}

.page-hero .container {
  position: relative;
  z-index: 2;
}

.page-hero-title {
  font-size: clamp(40px, 8vw, 72px);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.page-hero-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 auto;
}

/* ==========================================================================
   21. ANIMATIONS
   ========================================================================== */

.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays */
.animate-on-scroll[data-delay="1"] { transition-delay: 100ms; }
.animate-on-scroll[data-delay="2"] { transition-delay: 200ms; }
.animate-on-scroll[data-delay="3"] { transition-delay: 300ms; }
.animate-on-scroll[data-delay="4"] { transition-delay: 400ms; }
.animate-on-scroll[data-delay="5"] { transition-delay: 500ms; }
.animate-on-scroll[data-delay="6"] { transition-delay: 600ms; }

/* Hero word animation */
.hero-title .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.hero-title.words-split .word {
  opacity: 1;
  transform: translateY(0);
}

.hero-title.words-split .word[data-index="0"] { transition-delay: 0ms; }
.hero-title.words-split .word[data-index="1"] { transition-delay: 50ms; }
.hero-title.words-split .word[data-index="2"] { transition-delay: 100ms; }
.hero-title.words-split .word[data-index="3"] { transition-delay: 150ms; }
.hero-title.words-split .word[data-index="4"] { transition-delay: 200ms; }
.hero-title.words-split .word[data-index="5"] { transition-delay: 250ms; }
.hero-title.words-split .word[data-index="6"] { transition-delay: 300ms; }
.hero-title.words-split .word[data-index="7"] { transition-delay: 350ms; }
.hero-title.words-split .word[data-index="8"] { transition-delay: 400ms; }
.hero-title.words-split .word[data-index="9"] { transition-delay: 450ms; }

/* ==========================================================================
   22. UTILITIES
   ========================================================================== */

.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;
}

/* ==========================================================================
   23. NOISE TEXTURE OVERLAY
   ========================================================================== */

body::before {
  content: '';
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' 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='1'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

/* ==========================================================================
   24. CUSTOM SCROLLBAR
   ========================================================================== */

@media (min-width: 769px) {
  ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
  }

  ::-webkit-scrollbar-track {
    background: var(--background);
  }

  ::-webkit-scrollbar-thumb {
    background: var(--primary-800);
    border-radius: var(--radius-full);
  }

  ::-webkit-scrollbar-thumb:hover {
    background: var(--primary-600);
  }
}

/* ==========================================================================
   OFFER PILLS — used on work.html, contact.html, case studies
   ========================================================================== */

.page-hero-offer {
  margin-top: 28px;
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 10px 18px;
  border: 1px solid rgba(172, 79, 198, 0.3);
  background: rgba(172, 79, 198, 0.08);
  border-radius: 999px;
  font-size: 14px;
  color: var(--gray-300, #d4d4d4);
}

.page-hero-offer-pill {
  display: inline-block;
  padding: 4px 12px;
  background: var(--brand, #ac4fc6);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 999px;
  white-space: nowrap;
}

.project-cta-offer {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 12px auto 24px;
  padding: 10px 18px;
  border: 1px solid rgba(172, 79, 198, 0.3);
  background: rgba(172, 79, 198, 0.08);
  border-radius: 999px;
  font-size: 13px;
  color: var(--gray-400, #a3a3a3);
}

.project-cta-pill {
  display: inline-block;
  padding: 3px 10px;
  background: var(--brand, #ac4fc6);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 999px;
  white-space: nowrap;
}

/* ==========================================================================
   EDITORIAL — WORK GALLERY (work.html)
   Image carries the color. UI stays out of the way.
   ========================================================================== */

.work-page {
  background: var(--background);
}

/* Mono micro-meta used across editorial pages */
.eyebrow {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}

/* ----- Editorial hero (work + case studies) ----- */
.editorial-hero {
  padding: clamp(140px, 18vh, 220px) 0 clamp(60px, 8vw, 100px);
  border-bottom: 1px solid var(--gray-800);
}

.editorial-hero .container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  max-width: 1280px;
}

.editorial-hero .eyebrow {
  margin-bottom: 24px;
}

.editorial-hero-title {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(56px, 9vw, 140px);
  line-height: 0.96;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  max-width: 14ch;
}

.editorial-hero-title em {
  font-style: italic;
  color: var(--text-secondary);
}

.editorial-hero-lede {
  font-size: clamp(17px, 1.6vw, 22px);
  line-height: 1.55;
  color: var(--text-secondary);
  max-width: 56ch;
  margin-top: 24px;
}

.editorial-hero-meta {
  display: flex;
  gap: 48px;
  margin-top: 48px;
  flex-wrap: wrap;
}
.editorial-hero-meta .meta-block { display: flex; flex-direction: column; gap: 6px; }
.editorial-hero-meta .meta-block strong { font-size: 15px; font-weight: 500; color: var(--text-primary); }

@media (max-width: 720px) {
  .editorial-hero { padding: clamp(110px, 14vh, 160px) 0 clamp(40px, 8vw, 64px); }
  .editorial-hero-title { font-size: clamp(48px, 13vw, 72px); max-width: none; }
  .editorial-hero-lede { font-size: 15px; margin-top: 18px; }
  .editorial-hero-meta { gap: 24px; margin-top: 32px; }
  .editorial-hero-meta .meta-block strong { font-size: 14px; }
}

/* ----- Gallery list ----- */
.work-gallery {
  padding: clamp(60px, 8vw, 120px) 0 0;
}

.work-gallery-list {
  display: flex;
  flex-direction: column;
}

.work-item {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: clamp(60px, 8vw, 120px) 0;
  border-bottom: 1px solid var(--gray-800);
  position: relative;
}
.work-item:first-child { padding-top: 0; }

.work-item-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.work-item--reverse .work-item-grid {
  grid-template-columns: 1.4fr 1fr;
}
.work-item--reverse .work-item-info {
  order: 2;
}

@media (max-width: 900px) {
  .work-item-grid,
  .work-item--reverse .work-item-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  /* Force uniform image-on-top order on mobile, regardless of source DOM */
  .work-item-image { order: 0; }
  .work-item-info,
  .work-item--reverse .work-item-info { order: 1; }
}

.work-item-info {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.work-item-index {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--text-muted);
}

.work-item-name {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(40px, 5vw, 72px);
  line-height: 1.0;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.work-item-meta {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.work-item-meta span + span::before {
  content: '·';
  margin-right: 16px;
  color: var(--gray-700);
}

.work-item-desc {
  font-size: 17px;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 44ch;
  margin-top: 4px;
}

.work-item-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-primary);
  font-weight: 500;
}
.work-item-link svg {
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.work-item:hover .work-item-link svg {
  transform: translateX(8px);
}

/* Image frame — image carries the color */
.work-item-image {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  background: var(--background-secondary);
  aspect-ratio: 16 / 10;
  isolation: isolate;
}
.work-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform 1.2s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.6s ease;
  filter: saturate(0.92);
}
.work-item:hover .work-item-image img {
  transform: scale(1.04);
  filter: saturate(1.05);
}
.work-item:hover .work-item-name {
  transform: translateX(6px);
}

/* Subtle grain on hover only */
.work-item-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent 60%, rgba(0,0,0,0.4));
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}
.work-item:hover .work-item-image::after { opacity: 1; }

/* ----- Quiet end CTA ----- */
.work-end {
  padding: clamp(120px, 16vw, 200px) 0;
  text-align: center;
  border-top: 1px solid var(--gray-800);
  margin-top: 0;
}
.work-end-title {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-style: italic;
  font-size: clamp(40px, 6vw, 88px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  max-width: 16ch;
  margin: 0 auto 36px;
}
.work-end-link {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--text-primary);
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  font-weight: 500;
  text-decoration: none;
}
.work-end-link svg { transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.work-end-link:hover svg { transform: translateX(8px); }


/* ==========================================================================
   EDITORIAL — CASE STUDY (work/*.html)
   ========================================================================== */

.cs-page { background: var(--background); }

/* Back link, mono caps */
.cs-back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  margin-bottom: 48px;
  transition: color 0.2s ease;
}
.cs-back:hover { color: var(--text-primary); }
.cs-back svg { transition: transform 0.3s ease; }
.cs-back:hover svg { transform: translateX(-4px); }

.cs-hero {
  padding: clamp(120px, 16vh, 200px) 0 clamp(40px, 6vw, 80px);
}
.cs-hero .container { max-width: 1280px; }

.cs-hero-title {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(48px, 6.5vw, 96px);
  line-height: 0.98;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  max-width: 14ch;
  margin: 24px 0 0;
}

.cs-hero-lede {
  font-size: clamp(18px, 1.7vw, 24px);
  line-height: 1.5;
  color: var(--text-secondary);
  max-width: 60ch;
  margin-top: 32px;
}

.cs-hero-actions {
  margin-top: 40px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  align-items: center;
}

/* Reusable case-study split hero: editorial copy on the left,
   diagonal "flag" strip on the right. Used on any /work/*.html page. */
.cs-hero--split {
  min-height: min(980px, 100vh);
  display: flex;
  align-items: center;
  padding: calc(var(--nav-height) + clamp(56px, 8vh, 96px)) 0 clamp(72px, 9vh, 120px);
  overflow: hidden;
}

.cs-hero--split .container {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.58fr);
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}

@media (min-width: 1400px) {
  .cs-hero--split .container {
    grid-template-columns: minmax(0, 0.9fr) minmax(300px, 0.7fr);
    gap: clamp(80px, 7vw, 140px);
  }
}

.cs-hero-copy {
  position: relative;
  z-index: 2;
}

/* The strip = the line + the stack of parallelogram cards,
   treated as one self-contained unit so it can be vertically centered. */
.cs-strip {
  --card-w: clamp(240px, 21vw, 340px);
  --card-step: calc(var(--card-w) * 0.08);
  --card-count: 5;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 2vw, 36px);
  position: relative;
  isolation: isolate;
  padding-left: clamp(72px, 8vw, 120px);
}

.cs-strip-line {
  display: block;
  flex-shrink: 0;
  width: 2px;
  height: 380px;
  align-self: center;
  background: linear-gradient(180deg, transparent, rgba(255,255,255,0.72) 10%, rgba(255,255,255,0.72) 90%, transparent);
  transform: rotate(atan2(calc(var(--card-w) * 0.07), 70px));
  opacity: 0.9;
}

.cs-strip-stack {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(9px, 1.45vh, 13px);
}

.cs-strip-card {
  width: var(--card-w);
  min-height: clamp(64px, 7vh, 76px);
  margin-left: calc(var(--x, 0) * var(--card-step));
  padding: 11px 32px 11px 26px;
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.12);
  clip-path: polygon(7% 0, 100% 0, 92% 100%, 0 100%);
  box-shadow:
    0 30px 60px -34px rgba(0, 0, 0, 0.9),
    0 0 0 1px rgba(0, 0, 0, 0.08);
  color: #111;
}

.cs-strip-card strong {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: clamp(14px, 1vw, 17px);
  font-weight: 700;
  line-height: 1.1;
  color: #111;
}

@media (max-width: 1000px) {
  .cs-hero--split {
    min-height: auto;
    align-items: flex-start;
  }

  .cs-hero--split .container {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .cs-strip {
    margin: 0 auto;
    max-width: 560px;
    padding-left: 0;
  }

  .cs-strip-line {
    display: none;
  }
}

@media (max-width: 620px) {
  .cs-strip {
    --card-w: min(58vw, 240px);
    --card-step: calc(var(--card-w) * 0.05);
    gap: 10px;
    margin: 0 auto;
    max-width: 100%;
  }

  .cs-strip-stack {
    gap: 7px;
  }

  .cs-strip-card {
    min-height: 44px;
    padding: 8px 22px 8px 18px;
  }

  .cs-strip-card strong {
    font-size: 12px;
  }
}

@media (max-width: 420px) {
  .cs-strip {
    --card-w: min(62vw, 220px);
    gap: 8px;
  }

  .cs-strip-card {
    min-height: 38px;
    padding: 7px 20px 7px 16px;
  }

  .cs-strip-card strong {
    font-size: 11px;
  }
}

.cs-text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--text-primary);
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  font-weight: 500;
  text-decoration: none;
}
.cs-text-link svg { transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.cs-text-link:hover svg { transform: translate(6px, -6px); }

.cs-text-link.muted {
  border-bottom-color: var(--gray-700);
  color: var(--text-secondary);
}

/* Full-bleed hero image */
.cs-hero-image {
  margin: clamp(60px, 8vw, 120px) 0;
  width: 100%;
  overflow: hidden;
  background: var(--background-secondary);
}
.cs-hero-image img {
  width: 100%;
  height: auto;
  display: block;
}

/* ============================================================
   BROWSER MOCKUP — repeatable frame for case study screenshots
   ============================================================ */
.mockup-browser {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  border-radius: 14px;
  overflow: hidden;
  background: #1a1a1f;
  box-shadow:
    0 60px 120px -30px rgba(0, 0, 0, 0.55),
    0 30px 60px -30px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}
.mockup-browser .mockup-chrome {
  position: relative;
  height: 38px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  background: linear-gradient(180deg, #2c2c33 0%, #1f1f25 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.mockup-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.25);
}
.mockup-dot-red    { background: #ff5f57; }
.mockup-dot-yellow { background: #febc2e; }
.mockup-dot-green  { background: #28c840; }
.mockup-url {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.55);
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.04em;
  padding: 5px 16px;
  border-radius: 999px;
  max-width: 60%;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mockup-browser > img {
  width: 100%;
  height: auto;
  display: block;
  background: #fff;
}
@media (max-width: 600px) {
  .mockup-browser { border-radius: 10px; }
  .mockup-browser .mockup-chrome { height: 30px; padding: 0 12px; }
  .mockup-dot { width: 9px; height: 9px; }
  .mockup-url { font-size: 9px; padding: 3px 10px; max-width: 50%; }
}

/* Hero variant — gives the mockup a backdrop with subtle spotlight */
.cs-hero-image.has-mockup {
  background: var(--background-secondary);
  padding: clamp(36px, 6vw, 80px) clamp(20px, 4vw, 60px);
  overflow: visible;
}

/* Showcase variant — same backdrop treatment */
.cs-showcase.has-mockup {
  padding: clamp(60px, 8vw, 120px) clamp(20px, 4vw, 60px);
}
.cs-showcase.has-mockup .container {
  padding: clamp(40px, 6vw, 80px) clamp(20px, 4vw, 60px);
  border-radius: 16px;
}
.cs-showcase.has-mockup img { border-radius: 0; }

/* ============================================================
   DEVICE FRAMES - reusable crop windows for long screenshots
   ============================================================ */
.cs-device-showcase {
  padding: clamp(88px, 10vw, 140px) var(--container-padding) clamp(64px, 8vw, 110px);
  overflow: hidden;
}

.cs-device-showcase--hero {
  margin: clamp(60px, 8vw, 120px) 0;
}

.cs-device-stage {
  position: relative;
  max-width: 1240px;
  min-height: clamp(600px, 58vw, 770px);
  margin: 0 auto;
}

.device-frame {
  --frame-y: 0%;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  margin: 0;
  background: #050507;
  border: 10px solid #050507;
  box-shadow:
    0 42px 95px -48px rgba(0, 0, 0, 0.62),
    0 18px 38px -26px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}

.device-frame img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center var(--frame-y);
  background: #fff;
}

.device-frame--desktop {
  width: min(72vw, 960px);
  aspect-ratio: 16 / 10;
  border-width: 12px 12px 44px;
  border-radius: 16px 16px 8px 8px;
}

.device-frame--desktop::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -40px;
  width: 28%;
  height: 30px;
  transform: translateX(-50%);
  border-radius: 0 0 8px 8px;
  background: linear-gradient(180deg, #d7d7d9 0%, #aeb0b4 100%);
  z-index: -1;
}

.device-frame--laptop {
  width: min(52vw, 680px);
  aspect-ratio: 16 / 10;
  border-width: 10px 10px 22px;
  border-radius: 12px 12px 8px 8px;
}

.device-frame--laptop::after {
  content: '';
  position: absolute;
  left: -9%;
  right: -9%;
  bottom: -28px;
  height: 24px;
  border-radius: 0 0 18px 18px;
  background: linear-gradient(180deg, #d3d3d6 0%, #8f9298 100%);
  box-shadow: 0 22px 30px -22px rgba(0, 0, 0, 0.8);
  z-index: -1;
}

.device-frame--tablet {
  width: min(34vw, 390px);
  aspect-ratio: 4 / 3;
  border-width: 14px;
  border-radius: 18px;
}

.device-frame--phone {
  width: min(17vw, 205px);
  aspect-ratio: 9 / 19;
  border-width: 18px 8px 16px;
  border-radius: 24px;
}

.device-frame--phone::before {
  content: '';
  position: absolute;
  top: -12px;
  left: 50%;
  width: 34%;
  height: 8px;
  transform: translateX(-50%);
  border-radius: 0 0 8px 8px;
  background: #050507;
  z-index: 2;
}

.cs-device-stage > .device-frame--desktop {
  position: absolute;
  left: 3%;
  top: 44px;
}

.cs-device-stage > .device-frame--laptop {
  position: absolute;
  right: 0;
  bottom: 58px;
  z-index: 3;
}

.cs-device-stage > .device-frame--tablet {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 4;
}

.cs-device-stage > .device-frame--phone {
  position: absolute;
  left: 37%;
  bottom: 4px;
  z-index: 5;
}

.cs-frame-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(0, 1.35fr);
  gap: clamp(36px, 6vw, 88px);
  align-items: center;
  padding: clamp(76px, 10vw, 140px) var(--container-padding);
  border-top: 1px solid var(--gray-800);
}

.cs-frame-section-copy {
  max-width: 470px;
}

.cs-frame-section-copy .eyebrow {
  display: block;
  margin-bottom: 22px;
}

.cs-frame-section-copy h2 {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(30px, 3.4vw, 48px);
  line-height: 1.08;
  color: var(--text-primary);
  margin-bottom: 22px;
}

.cs-frame-section-copy p {
  font-size: 17px;
  line-height: 1.65;
  max-width: 42ch;
}

.cs-frame-pair {
  position: relative;
  min-height: clamp(390px, 42vw, 600px);
}

.cs-frame-pair .device-frame--desktop {
  width: min(58vw, 760px);
}

.cs-frame-pair .device-frame--laptop {
  width: min(54vw, 690px);
  margin-left: auto;
}

.cs-frame-pair .device-frame--tablet {
  width: min(32vw, 390px);
}

.cs-frame-pair .device-frame--phone {
  width: min(16vw, 190px);
}

.cs-frame-pair--wide .device-frame--phone {
  position: absolute;
  right: 2%;
  bottom: 0;
  z-index: 3;
}

.cs-frame-pair--staggered .device-frame--tablet,
.cs-frame-pair:not(.cs-frame-pair--wide):not(.cs-frame-pair--staggered) .device-frame--phone {
  position: absolute;
  right: 3%;
  bottom: 0;
  z-index: 3;
}

.cs-frame-pair:not(.cs-frame-pair--wide):not(.cs-frame-pair--staggered) .device-frame--tablet {
  margin-left: 8%;
}

@media (max-width: 980px) {
  .cs-device-stage {
    min-height: auto;
    display: grid;
    grid-template-columns: 1fr 0.38fr;
    gap: 18px;
    align-items: end;
  }

  .cs-device-stage > .device-frame--desktop,
  .cs-device-stage > .device-frame--laptop,
  .cs-device-stage > .device-frame--tablet,
  .cs-device-stage > .device-frame--phone {
    position: relative;
    inset: auto;
    width: 100%;
  }

  .cs-device-stage > .device-frame--phone,
  .cs-frame-pair .device-frame--phone {
    max-width: 150px;
    justify-self: center;
    align-self: end;
  }

  .cs-device-stage > .device-frame--desktop,
  .cs-device-stage > .device-frame--laptop {
    grid-column: 1 / -1;
  }

  .cs-frame-section {
    grid-template-columns: 1fr;
  }

  .cs-frame-pair {
    min-height: auto;
    display: grid;
    grid-template-columns: 1fr 0.32fr;
    gap: 18px;
    align-items: end;
  }

  .cs-frame-pair .device-frame--desktop,
  .cs-frame-pair .device-frame--laptop,
  .cs-frame-pair .device-frame--tablet,
  .cs-frame-pair .device-frame--phone,
  .cs-frame-pair--wide .device-frame--phone,
  .cs-frame-pair--staggered .device-frame--tablet,
  .cs-frame-pair:not(.cs-frame-pair--wide):not(.cs-frame-pair--staggered) .device-frame--phone {
    position: relative;
    inset: auto;
    width: 100%;
    margin: 0;
  }

  .cs-frame-pair .device-frame--desktop,
  .cs-frame-pair .device-frame--laptop {
    grid-column: 1 / -1;
  }
}

@media (max-width: 620px) {
  .cs-device-stage,
  .cs-frame-pair {
    grid-template-columns: 1fr;
  }

  .device-frame--desktop,
  .device-frame--laptop,
  .device-frame--tablet,
  .device-frame--phone {
    width: 100%;
  }

  .device-frame--tablet,
  .device-frame--phone {
    max-width: 260px;
    justify-self: center;
  }
}


/* Meta strip */
.cs-meta {
  border-top: 1px solid var(--gray-800);
  border-bottom: 1px solid var(--gray-800);
  padding: 32px 0;
}
.cs-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--container-padding);
}
@media (max-width: 800px) { .cs-meta-grid { grid-template-columns: repeat(2, 1fr); } }
.cs-meta-item .eyebrow { display: block; margin-bottom: 8px; }
.cs-meta-item p { font-size: 16px; color: var(--text-primary); margin: 0; }

/* Sticky scroll feature section */
.cs-features {
  padding: clamp(80px, 12vw, 160px) 0;
}
.cs-features .container {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(40px, 8vw, 120px);
  max-width: 1280px;
  align-items: start;
}
@media (max-width: 900px) {
  .cs-features .container { grid-template-columns: 1fr; gap: 40px; }
  .cs-features-sticky h2 { max-width: none; font-size: clamp(28px, 6.5vw, 36px); }
  .cs-features-sticky p { max-width: none; font-size: 16px; }
}

.cs-features-sticky {
  position: static;
}
@media (min-width: 901px) {
  .cs-features-sticky {
    position: sticky;
    top: calc(var(--nav-height) + 40px);
  }
}
.cs-features-sticky .eyebrow { display: block; margin-bottom: 24px; }
.cs-features-sticky h2 {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(32px, 3.5vw, 48px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  max-width: 14ch;
}
.cs-features-sticky p {
  margin-top: 24px;
  color: var(--text-secondary);
  font-size: 17px;
  line-height: 1.6;
  max-width: 38ch;
}

.cs-features-list { display: flex; flex-direction: column; }
.cs-feature {
  padding: 36px 0;
  border-top: 1px solid var(--gray-800);
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 24px;
}
.cs-feature:last-child { border-bottom: 1px solid var(--gray-800); }
.cs-feature-num {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--text-muted);
  padding-top: 4px;
}
.cs-feature h3 {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(22px, 2vw, 28px);
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.cs-feature p {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 56ch;
}

@media (max-width: 600px) {
  .cs-feature {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 28px 0;
  }
  .cs-feature-num { padding-top: 0; font-size: 11px; }
  .cs-feature h3 { font-size: clamp(20px, 5.5vw, 24px); margin-bottom: 8px; }
  .cs-feature p { font-size: 15px; }
}

/* Pull quote */
.cs-quote {
  padding: clamp(80px, 10vw, 140px) 0;
  border-top: 1px solid var(--gray-800);
  border-bottom: 1px solid var(--gray-800);
}
.cs-quote .container {
  max-width: 1100px;
  text-align: left;
}
.cs-quote-mark {
  font-family: 'quiche-sans', Georgia, serif;
  font-style: italic;
  font-size: 96px;
  line-height: 0.6;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.cs-quote-text {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-style: italic;
  font-size: clamp(24px, 2.6vw, 36px);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  max-width: 28ch;
}
.cs-quote-attr {
  margin-top: 36px;
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Showcase image */
.cs-showcase {
  padding: clamp(80px, 10vw, 140px) 0;
}
.cs-showcase img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* Tech stack — inline middot list */
.cs-tech {
  padding: clamp(60px, 8vw, 100px) 0;
  border-top: 1px solid var(--gray-800);
}
.cs-tech .container { max-width: 1100px; }
.cs-tech .eyebrow { display: block; margin-bottom: 24px; }
.cs-tech-list {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-weight: 400;
  font-size: clamp(13px, 1.1vw, 15px);
  line-height: 1.8;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  row-gap: 4px;
}
.cs-tech-list span { color: var(--text-primary); }
.cs-tech-list span + span::before {
  content: '·';
  color: var(--gray-700);
  margin: 0 14px;
}

/* Next project navigation */
.cs-next {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: clamp(60px, 8vw, 120px) 0;
  border-top: 1px solid var(--gray-800);
  position: relative;
  overflow: hidden;
}
.cs-next-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--container-padding);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: end;
}
.cs-next .eyebrow { display: block; margin-bottom: 16px; }
.cs-next-name {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.cs-next-arrow {
  font-family: 'avenir-next', 'Avenir Next', 'Avenir', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 8px;
}
.cs-next-arrow svg { transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.cs-next:hover .cs-next-arrow svg { transform: translateX(10px); }
.cs-next:hover .cs-next-name { transform: translateX(8px); }

/* Final CTA — quiet, no pills */
.cs-cta {
  padding: clamp(80px, 12vw, 140px) 0;
  text-align: center;
  border-top: 1px solid var(--gray-800);
}
.cs-cta-title {
  font-family: 'quiche-sans', Georgia, serif;
  font-weight: 400;
  font-size: clamp(32px, 3.8vw, 56px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  max-width: 22ch;
  margin: 0 auto 28px;
}
.cs-cta-lede {
  font-size: 17px;
  color: var(--text-secondary);
  max-width: 50ch;
  margin: 0 auto 40px;
}

/* ==========================================================================
   CASE STUDY — MOBILE TYPOGRAPHY + SAFETY
   Prevents long words breaking layouts on phone widths.
   ========================================================================== */
@media (max-width: 720px) {
  .cs-hero-title,
  .cs-features-sticky h2,
  .cs-quote-text,
  .cs-cta-title,
  .cs-next-name,
  .cs-feature h3 {
    overflow-wrap: anywhere;
    word-break: normal;
    hyphens: auto;
  }

  .cs-hero-title {
    font-size: clamp(34px, 9vw, 56px);
    max-width: 18ch;
  }

  .cs-hero-lede {
    font-size: clamp(15px, 4vw, 18px);
    margin-top: 22px;
  }

  .cs-features-sticky h2 {
    font-size: clamp(26px, 7.5vw, 36px);
    max-width: none;
  }

  .cs-features-sticky p {
    font-size: 15px;
  }

  .cs-quote-mark {
    font-size: 64px;
    margin-bottom: 16px;
  }

  .cs-quote-text {
    font-size: clamp(20px, 5.5vw, 26px);
    max-width: none;
  }

  .cs-cta-title {
    font-size: clamp(26px, 7vw, 36px);
    max-width: 22ch;
  }

  .cs-cta-lede {
    font-size: 15px;
  }

  .cs-next-inner {
    grid-template-columns: 1fr;
    gap: 16px;
    align-items: start;
  }

  .cs-next-name {
    font-size: clamp(24px, 7vw, 34px);
  }

  .cs-tech-list {
    font-size: 13px;
    line-height: 1.7;
  }
  .cs-tech-list span + span::before { margin: 0 10px; }
}

@media (max-width: 420px) {
  .cs-hero-title { font-size: clamp(30px, 9.5vw, 40px); }
  .cs-features-sticky h2 { font-size: clamp(24px, 8vw, 30px); }
  .cs-quote-text { font-size: clamp(18px, 6vw, 22px); }
  .cs-cta-title { font-size: clamp(24px, 8vw, 30px); }
}

/* ==========================================================================
   CASE STUDY — LIGHT SECTION VARIANTS (magazine-spread alternation)
   ========================================================================== */
.cs-light {
  background: #f6f5f2;
  color: #0a0a0a;
}
.cs-light .container { color: #0a0a0a; }
.cs-light .eyebrow { color: rgba(10, 10, 10, 0.55); }
.cs-light h2,
.cs-light h3,
.cs-light h4,
.cs-light p { color: inherit; }
.cs-light .cs-features-sticky h2 { color: #0a0a0a; }
.cs-light .cs-features-sticky p { color: rgba(10, 10, 10, 0.65); }
.cs-light .cs-feature { border-top-color: rgba(10, 10, 10, 0.12); }
.cs-light .cs-feature:last-child { border-bottom-color: rgba(10, 10, 10, 0.12); }
.cs-light .cs-feature h3 { color: #0a0a0a; }
.cs-light .cs-feature p { color: rgba(10, 10, 10, 0.65); }
.cs-light .cs-feature-num { color: rgba(10, 10, 10, 0.4); }
.cs-light .cs-quote-text { color: #0a0a0a; }
.cs-light .cs-quote-mark { color: rgba(10, 10, 10, 0.25); }
.cs-light .cs-quote-attr { color: rgba(10, 10, 10, 0.5); }
.cs-light.cs-quote { border-color: rgba(10, 10, 10, 0.1); }
.cs-light .cs-next-name { color: #0a0a0a; }
.cs-light .cs-next-arrow { color: rgba(10, 10, 10, 0.5); }
.cs-light.cs-next { border-top-color: rgba(10, 10, 10, 0.1); }
.cs-light.cs-frame-section { border-top-color: rgba(10, 10, 10, 0.1); }

/* Image-plate sections on light bg — frame the screenshot like a printed plate */
.cs-light.cs-hero-image,
.cs-light.cs-showcase {
  background: #f6f5f2;
}
.cs-light .mockup-browser {
  box-shadow:
    0 60px 120px -40px rgba(0, 0, 0, 0.25),
    0 30px 60px -30px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(0, 0, 0, 0.06);
}

/* ==========================================================================
   CASE STUDY — PAGE TURN TRANSITION (next link)
   ========================================================================== */
.page-turn-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  perspective: 1800px;
  perspective-origin: 0% 50%;
  display: none;
}
.page-turn-overlay.is-active { display: block; }
.page-turn-page {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--background);
  transform-origin: left center;
  transform: rotateY(0deg);
  transition: transform 1s cubic-bezier(0.65, 0.04, 0.27, 1);
  box-shadow:
    inset -40px 0 80px -40px rgba(0, 0, 0, 0.7),
    20px 0 60px -10px rgba(0, 0, 0, 0.5);
  backface-visibility: hidden;
  will-change: transform;
}
.page-turn-overlay.is-turning .page-turn-page {
  transform: rotateY(-180deg);
}

/* ==========================================================================
   NAV — flat layout (no .nav-inner wrapper) + logo sizing
   ========================================================================== */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--container-padding);
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  height: 100%;
}

.nav-logo img {
  height: 28px;
  width: auto;
  display: block;
}

@media (max-width: 600px) {
  .nav-logo img { height: 24px; }
}

/* --- work.html refined markup (article > a.work-item-grid) --- */
a.work-item-grid {
  text-decoration: none;
  color: inherit;
  display: grid;
}
.work-item:hover .work-item-link svg,
a.work-item-grid:hover .work-item-link svg {
  transform: translateX(8px);
}
