/**
 * components.css — Cirova Consulting
 * ─────────────────────────────────────────────────────────────
 * Scope    : All site components except the chat widget.
 *            Covers: nav, buttons, hero, services, about,
 *            process, contact, footer.
 * Requires : main.css (design tokens must be loaded first)
 * Authors  : Cirova Consulting (generated)
 * Updated  : 2026
 * ─────────────────────────────────────────────────────────────
 */


/* ─────────────────────────────────────────────────────────────
   1. NAVIGATION
   Fixed top bar. Transparent by default, gains background
   and border on scroll (`.scrolled` applied by main.js).
   ───────────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  inset-block-start: 0;
  inset-inline: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: var(--space-8);
  z-index: 100;
  /* Smooth transition from transparent → opaque */
  transition:
    background-color var(--duration-normal),
    border-color     var(--duration-normal);
  border-bottom: 1px solid transparent;
}

/** State applied by JS when page is scrolled */
.nav.scrolled {
  background-color: rgba(10, 10, 11, 0.92);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-color: var(--color-border);
}

.nav-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.12em;
  color: var(--color-text);
  transition: opacity var(--duration-fast);
}
.nav-logo:hover { opacity: 0.8; }

.nav-links {
  display: flex;
  gap: var(--space-7);
  list-style: none;
}

.nav-links a {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  transition: color var(--duration-fast);
}
.nav-links a:hover { color: var(--color-text); }

/** "Let's Talk" CTA button in nav */
.nav-cta {
  color: var(--color-accent) !important;
  border: 1px solid var(--color-accent-dim);
  padding: 7px 18px;
  border-radius: var(--radius-sm);
  transition:
    background-color var(--duration-fast),
    color            var(--duration-fast) !important;
}
.nav-cta:hover {
  background-color: var(--color-accent);
  color: var(--color-bg) !important;
}

/** Hamburger button — hidden on desktop */
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
  background: none;
  border: none;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background-color: var(--color-text);
  border-radius: 2px;
  transition: transform var(--duration-normal), opacity var(--duration-normal);
}


/* ─────────────────────────────────────────────────────────────
   2. MOBILE MENU
   Full-width dropdown that slides down from nav.
   Toggled by JS adding/removing `.open`.
   ───────────────────────────────────────────────────────────── */
.mobile-menu {
  position: fixed;
  inset-block-start: var(--nav-height);
  inset-inline: 0;
  background-color: rgba(10, 10, 11, 0.98);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--color-border);
  padding: var(--space-5) var(--space-8) var(--space-7);
  z-index: 99;
  /* Hidden by default — slides up off-screen */
  transform: translateY(-110%);
  transition: transform 0.35s var(--ease-out);
  pointer-events: none;
}

.mobile-menu.open {
  transform: translateY(0);
  pointer-events: all;
}

.mobile-menu ul { list-style: none; }

.mobile-menu li {
  padding-block: var(--space-4);
  border-bottom: 1px solid var(--color-border);
}
.mobile-menu li:last-child { border-bottom: none; }

.mobile-menu a {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--color-text);
  transition: color var(--duration-fast);
}
.mobile-menu a:hover { color: var(--color-accent); }


/* ─────────────────────────────────────────────────────────────
   3. BUTTONS
   Two variants: primary (filled accent) and ghost (outlined).
   Used across hero, about, contact sections.
   ───────────────────────────────────────────────────────────── */

/** Filled accent button */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background-color: var(--color-accent);
  color: var(--color-bg);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  border: none;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color var(--duration-fast),
    transform        var(--duration-fast),
    box-shadow       var(--duration-fast);
}
.btn-primary:hover {
  background-color: var(--color-accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 28px rgba(91, 156, 246, 0.3);
}
.btn-primary:active { transform: translateY(0); }

/** Outlined ghost button */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background-color: transparent;
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border-hi);
  text-decoration: none;
  cursor: pointer;
  transition:
    color        var(--duration-fast),
    border-color var(--duration-fast);
}
.btn-ghost:hover {
  color: var(--color-text);
  border-color: rgba(255, 255, 255, 0.28);
}


/* ─────────────────────────────────────────────────────────────
   4. HERO SECTION
   Full-viewport opening section with layered decorative
   background (grid + radial glow).
   ───────────────────────────────────────────────────────────── */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  padding-block-start: calc(var(--nav-height) + var(--space-7));
  padding-block-end: var(--space-9);
  padding-inline: var(--space-6);
  overflow: hidden;
}

/** Decorative background container */
.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

/**
 * Subtle grid overlay.
 * Uses mask-image to fade the grid toward edges,
 * preventing a harsh cutoff at viewport boundaries.
 */
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--color-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-border) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
}

/** Accent colour glow centred behind headline */
.hero-glow {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, var(--color-accent-glow) 0%, transparent 70%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 820px;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-6);
}

.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: var(--space-6);
}

/** Italic serif word for tonal contrast */
.hero-headline em {
  font-style: italic;
  font-family: 'Fraunces', serif;
  font-weight: 300;
  color: var(--color-accent);
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  line-height: 1.75;
  margin-bottom: var(--space-8);
}

.hero-actions {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
}

/** Animated scroll indicator at bottom of hero */
.hero-scroll-hint {
  position: absolute;
  bottom: var(--space-7);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--color-text-dim);
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--color-text-dim), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; }
  50%       { opacity: 1; }
}


/* ─────────────────────────────────────────────────────────────
   5. SERVICES SECTION
   2×2 grid of service cards.
   Cards are separated by single-pixel dividers using
   a gap + background trick to avoid double-border issues.
   ───────────────────────────────────────────────────────────── */
.services {
  padding-block: var(--space-10);
  border-top: 1px solid var(--color-border);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  /* 1px gap + border background = divider lines between cards */
  gap: 1px;
  background-color: var(--color-border);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.service-card {
  background-color: var(--color-bg);
  padding: 44px 40px;
  transition: background-color var(--duration-normal);
}
.service-card:hover { background-color: var(--color-bg-2); }

.service-num {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--color-text-dim);
  letter-spacing: 0.1em;
  margin-bottom: var(--space-5);
}

.service-icon {
  font-size: 1.6rem;
  color: var(--color-accent);
  line-height: 1;
  margin-bottom: var(--space-4);
}

.service-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-3);
}

.service-card p {
  font-size: 0.92rem;
  color: var(--color-text-muted);
  line-height: 1.72;
  margin-bottom: var(--space-5);
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  list-style: none;
}

.service-tags li {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--color-text-dim);
  border: 1px solid var(--color-border-hi);
  padding: 3px 10px;
  border-radius: 100px;
}


/* ─────────────────────────────────────────────────────────────
   6. ABOUT SECTION
   Two-column layout: stat cards on left, biography on right.
   ───────────────────────────────────────────────────────────── */
.about {
  padding-block: var(--space-10);
  background-color: var(--color-bg-2);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: var(--space-8) var(--space-10);
  align-items: center;
}

.about-visual {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.about-card {
  background-color: var(--color-bg-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
}
.about-card--sm { padding: 22px 28px; }

/** Large numeric stat */
.about-stat {
  font-family: var(--font-display);
  font-size: 3.6rem;
  font-weight: 800;
  line-height: 1;
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

/** Smaller text stat */
.about-stat-sm {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-1);
}

.about-stat-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  letter-spacing: 0.05em;
}

.about-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: var(--space-5);
}

.about-copy p {
  color: var(--color-text-muted);
  font-size: 0.97rem;
  line-height: 1.8;
  margin-bottom: var(--space-4);
}

.about-copy .btn-primary { margin-top: var(--space-3); }


/* ─────────────────────────────────────────────────────────────
   7. PROCESS SECTION
   Numbered steps in a vertical list with dividers.
   Rendered as <ol> in HTML for correct semantics.
   ───────────────────────────────────────────────────────────── */
.process {
  padding-block: var(--space-10);
  border-bottom: 1px solid var(--color-border);
}

.process-steps { list-style: none; }

.process-step {
  display: flex;
  gap: var(--space-8);
  align-items: flex-start;
  padding-block: var(--space-7);
  border-bottom: 1px solid var(--color-border);
}
.process-step:last-child { border-bottom: none; }

.step-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--color-accent);
  letter-spacing: 0.1em;
  min-width: 32px;
  padding-top: 6px; /* Align with h3 cap-height */
}

.step-content h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.step-content p {
  font-size: 0.93rem;
  color: var(--color-text-muted);
  max-width: 540px;
  line-height: 1.7;
}


/* ─────────────────────────────────────────────────────────────
   8. CONTACT SECTION
   Two-column: Calendly CTA on left, contact details on right.
   <address> used for contact details (correct HTML semantics).
   ───────────────────────────────────────────────────────────── */
.contact {
  padding-block: var(--space-10);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8) var(--space-10);
  align-items: center;
}

.contact-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: var(--space-4);
}

.contact-copy p {
  color: var(--color-text-muted);
  font-size: 0.97rem;
  margin-bottom: var(--space-6);
}

/** <address> element reset — browser adds italic by default */
.contact-details {
  font-style: normal;
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.contact-item {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding-bottom: var(--space-6);
  border-bottom: 1px solid var(--color-border);
}
.contact-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.contact-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text-dim);
}

.contact-value {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text);
  text-decoration: none;
  transition: color var(--duration-fast);
}
a.contact-value:hover { color: var(--color-accent); }


/* ─────────────────────────────────────────────────────────────
   9. FOOTER
   ───────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--color-border);
  padding-block: var(--space-7);
  background-color: var(--color-bg);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
}

.footer-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
}

.footer-copy {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--color-text-dim);
  letter-spacing: 0.05em;
}

.footer-links {
  display: flex;
  gap: var(--space-5);
}

.footer-links a {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--color-text-dim);
  text-decoration: none;
  letter-spacing: 0.06em;
  transition: color var(--duration-fast);
}
.footer-links a:hover { color: var(--color-text-muted); }


/* ─────────────────────────────────────────────────────────────
   10. RESPONSIVE OVERRIDES
   ───────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  /* Swap desktop nav for hamburger */
  .nav { padding-inline: var(--space-5); }
  .nav-links { display: none; }
  .nav-burger { display: flex; }

  /* Stack grid sections */
  .services-grid { grid-template-columns: 1fr; }
  .about-grid    { grid-template-columns: 1fr; gap: var(--space-7); }
  .contact-grid  { grid-template-columns: 1fr; gap: var(--space-7); }

  /* Reduce section vertical rhythm */
  .services,
  .about,
  .process,
  .contact { padding-block: var(--space-9); }

  /* Stack footer */
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}

@media (max-width: 540px) {
  .hero-actions { flex-direction: column; align-items: center; }
  .service-card { padding: 32px 24px; }
  .process-step { gap: var(--space-5); }
}
