/* ============================================================
   F5 Dev — Global Stylesheet
   ------------------------------------------------------------
   All theme values live in :root as CSS custom properties so
   you can rebrand the entire site by editing this one block.
   ============================================================ */

:root {
  /* Brand palette — pulled from the F5 Dev logo gradient (#205eff → #770fff) */
  --color-bg:           #0a0a0f;
  --color-bg-elevated:  #14141c;
  --color-bg-hover:     #1c1c26;
  --color-border:       #2a2a35;
  --color-border-hover: #3a3a48;

  --color-text:         #f5f5fa;
  --color-text-muted:   #9ca3af;
  --color-text-dim:     #6b7280;

  --color-accent:       #6e7bff;   /* lifted from the logo blue, tuned for legibility on dark */
  --color-accent-hover: #8a95ff;
  --color-accent-soft:  rgba(110, 123, 255, 0.14);
  --color-accent-2:     #8b5cf6;
  --color-accent-2-soft:rgba(139, 92, 246, 0.14);

  --color-success:      #22c55e;
  --color-danger:       #ef4444;

  /* Gradients — match the logo */
  --gradient-brand:     linear-gradient(135deg, #205eff 0%, #770fff 100%);
  --gradient-text:      linear-gradient(135deg, #4d6dff 0%, #8b5cf6 55%, #c084fc 100%);
  --gradient-glow:      radial-gradient(ellipse at top, rgba(110, 123, 255, 0.18), transparent 60%);

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Menlo, Monaco, Consolas, monospace;

  /* Spacing & sizing */
  --max-width: 1200px;
  --radius-sm: 6px;
  --radius:    12px;
  --radius-lg: 20px;

  /* Motion */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================
   Reset / Base
   ============================================================ */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color 0.15s var(--ease);
}
a:hover { color: var(--color-accent-hover); }

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 0.5em;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1em; }

::selection {
  background: var(--color-accent);
  color: var(--color-bg);
}

/* ============================================================
   Layout helpers
   ============================================================ */

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

.section {
  padding-block: clamp(3rem, 8vw, 6rem);
}

.section-narrow {
  padding-block: clamp(2.5rem, 6vw, 4.5rem);
}

.eyebrow {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  margin-bottom: 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border: 1px solid var(--color-accent-soft);
  border-radius: 999px;
}

.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.text-muted { color: var(--color-text-muted); }
.text-center { text-align: center; }

/* ============================================================
   Buttons
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.18s var(--ease);
  white-space: nowrap;
}

.btn-primary {
  color: var(--color-bg);
  background: var(--color-accent);
  border-color: var(--color-accent);
}
.btn-primary:hover {
  color: var(--color-bg);
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 10px 30px -10px var(--color-accent);
}

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

.btn-ghost {
  color: var(--color-text);
  background: transparent;
  padding-inline: 0.25rem;
}
.btn-ghost:hover { color: var(--color-accent); }

/* ============================================================
   Header / Navigation
   ============================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(10, 10, 15, 0.72);
  border-bottom: 1px solid var(--color-border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--color-text);
  letter-spacing: -0.02em;
}
.brand:hover { color: var(--color-text); }

/* Full F5 Development wordmark logo — used in header and footer */
.brand-logo {
  display: block;
  height: 42px;
  width: auto;
  /* Subtle glow that reinforces the logo's own gradient */
  filter: drop-shadow(0 4px 14px rgba(110, 123, 255, 0.25));
}
@media (max-width: 480px) {
  .brand-logo { height: 32px; }
}

/* Footer carries a slightly more generous version */
.site-footer .brand-logo { height: 44px; }

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

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-links a {
  display: inline-block;
  padding: 0.5rem 0.9rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-text-muted);
  border-radius: var(--radius-sm);
  transition: all 0.15s var(--ease);
}
.nav-links a:hover {
  color: var(--color-text);
  background: var(--color-bg-hover);
}
.nav-links a.active {
  color: var(--color-text);
  background: var(--color-bg-hover);
}

.nav-cta { margin-left: 0.75rem; }

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--color-text);
  position: relative;
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: '';
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--color-text);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after  { top:  6px; }

@media (max-width: 768px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute;
    top: 100%;
    right: 1rem;
    flex-direction: column;
    align-items: stretch;
    min-width: 200px;
    padding: 0.5rem;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    display: none;
  }
  .nav.open .nav-links { display: flex; }
  .nav-cta { display: none; }
}

/* ============================================================
   Hero
   ============================================================ */

.hero {
  position: relative;
  padding-block: clamp(4rem, 10vw, 8rem);
  text-align: center;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: -20% 0 auto 0;
  height: 600px;
  background: var(--gradient-glow);
  pointer-events: none;
  z-index: 0;
}
.hero > * { position: relative; z-index: 1; }

.hero h1 { margin-bottom: 1.25rem; }

.hero-lead {
  max-width: 640px;
  margin: 0 auto 2rem;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--color-text-muted);
}

.hero-cta {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

/* ============================================================
   Cards / Grid
   ============================================================ */

.grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.card {
  position: relative;
  padding: 1.75rem;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  transition: all 0.2s var(--ease);
}
.card:hover {
  border-color: var(--color-border-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 40px -16px rgba(0, 0, 0, 0.6);
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: 1rem;
  background: var(--color-accent-soft);
  border-radius: var(--radius-sm);
  color: var(--color-accent);
}
.card-icon svg { width: 22px; height: 22px; }

.card h3 { margin-bottom: 0.5rem; }
.card p { color: var(--color-text-muted); margin-bottom: 0; }

/* ============================================================
   Section heading (centered)
   ============================================================ */

.section-heading {
  max-width: 720px;
  margin: 0 auto 3rem;
  text-align: center;
}
.section-heading p { color: var(--color-text-muted); font-size: 1.075rem; }

/* ============================================================
   Feature row (alt sections)
   ============================================================ */

.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.feature-list { list-style: none; padding: 0; margin: 1rem 0 0; }
.feature-list li {
  position: relative;
  padding: 0.5rem 0 0.5rem 1.75rem;
  color: var(--color-text-muted);
}
.feature-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0.5rem;
  width: 1.25rem;
  height: 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--color-accent);
  background: var(--color-accent-soft);
  border-radius: 50%;
}
.feature-visual {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  /* Soft brand glow that sits behind the inner illustration */
  background-image:
    linear-gradient(135deg, rgba(110, 123, 255, 0.10), transparent 60%),
    radial-gradient(circle at 80% 20%, rgba(139, 92, 246, 0.12), transparent 55%);
}
.feature-visual > img,
.feature-visual > svg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Hover lift to reinforce these are illustrative cards */
.feature-visual::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

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

/* ============================================================
   CTA banner
   ============================================================ */

.cta-banner {
  padding: clamp(2.5rem, 5vw, 4rem);
  text-align: center;
  background:
    linear-gradient(180deg, rgba(0, 212, 255, 0.08), rgba(139, 92, 246, 0.06)),
    var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}
.cta-banner h2 { margin-bottom: 0.75rem; }
.cta-banner p {
  max-width: 560px;
  margin: 0 auto 1.5rem;
  color: var(--color-text-muted);
}

/* ============================================================
   Forms
   ============================================================ */

.form { display: grid; gap: 1.25rem; }

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

.field { display: grid; gap: 0.5rem; }

.field label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 0.75rem 0.95rem;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  transition: all 0.15s var(--ease);
}
.field input::placeholder,
.field textarea::placeholder { color: var(--color-text-dim); }
.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 4px var(--color-accent-soft);
}
.field textarea { min-height: 140px; resize: vertical; }

.form-status {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
}
.form-status.success {
  color: var(--color-success);
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.25);
}
.form-status.error {
  color: var(--color-danger);
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

/* ============================================================
   Page header (non-home pages)
   ============================================================ */

.page-header {
  position: relative;
  padding-block: clamp(3rem, 6vw, 5rem) clamp(2rem, 4vw, 3rem);
  text-align: center;
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
}
.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-glow);
  opacity: 0.6;
  pointer-events: none;
}
.page-header > * { position: relative; }

/* ============================================================
   Long-form (legal) content
   ============================================================ */

.prose {
  max-width: 760px;
  margin: 0 auto;
}
.prose h2 { margin-top: 2.5rem; }
.prose h3 { margin-top: 1.75rem; }
.prose p, .prose ul, .prose ol { color: var(--color-text-muted); }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose ul li, .prose ol li { margin-bottom: 0.5rem; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose hr { border: 0; border-top: 1px solid var(--color-border); margin: 2.5rem 0; }
.prose .meta {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: 999px;
}

/* ============================================================
   Stats
   ============================================================ */

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}
.stat { text-align: center; }
.stat-value {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat-label {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ============================================================
   Footer
   ============================================================ */

.site-footer {
  margin-top: 4rem;
  padding-block: 3rem 2rem;
  background: var(--color-bg-elevated);
  border-top: 1px solid var(--color-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}
@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 0.6rem; }
.footer-col a {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}
.footer-col a:hover { color: var(--color-text); }

.footer-tagline {
  margin-top: 0.75rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  max-width: 320px;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
  font-size: 0.875rem;
  color: var(--color-text-dim);
}
.footer-bottom .socials { display: flex; gap: 0.75rem; }
.footer-bottom .socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  color: var(--color-text-muted);
}
.footer-bottom .socials a:hover {
  color: var(--color-accent);
  border-color: var(--color-accent);
}
.footer-bottom .socials svg { width: 16px; height: 16px; }

/* ============================================================
   Utility / Reveal animation (progressive enhancement)
   ============================================================ */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  }
  .reveal.is-visible {
    opacity: 1;
    transform: none;
  }
}
