/* RuneSight Security. Shared stylesheet */

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

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

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

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

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* ------------------------------------------------------------------
   Tokens
------------------------------------------------------------------ */
:root {
  /* Colors. Preserved from existing site */
  --navy-deep: #1e3c72;
  --navy: #2a5298;
  --navy-darker: #15294f;
  --accent: #ff6b35;
  --accent-hover: #e55a2b;
  --dark: #0f1419;
  --light: #f8f9fa;
  --white: #ffffff;
  --text: #1f2937;
  --text-muted: #6b7280;
  --text-light: rgba(255, 255, 255, 0.82);
  --text-light-muted: rgba(255, 255, 255, 0.6);
  --border: rgba(30, 60, 114, 0.12);
  --border-light: rgba(255, 255, 255, 0.12);

  /* Typography */
  --font-sans: 'IBM Plex Sans', system-ui, -apple-system, sans-serif;
  --font-serif: 'IBM Plex Serif', Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  /* Layout */
  --max-width: 1200px;
  --content-width: 760px;
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-6: 3rem;
  --space-8: 4rem;
  --space-12: 6rem;
  --space-16: 8rem;

  /* Effects */
  --shadow-sm: 0 2px 8px rgba(15, 20, 25, 0.06);
  --shadow: 0 8px 24px rgba(15, 20, 25, 0.08);
  --shadow-lg: 0 16px 48px rgba(15, 20, 25, 0.12);
  --radius: 8px;
  --radius-lg: 14px;
}

/* ------------------------------------------------------------------
   Typography
------------------------------------------------------------------ */
body {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--navy-darker);
}

h1 {
  font-size: clamp(2.25rem, 4.5vw, 3.5rem);
  font-weight: 500;
}

h2 {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
}

h3 {
  font-size: clamp(1.25rem, 2vw, 1.625rem);
}

h4 {
  font-size: 1.125rem;
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.01em;
}

p {
  margin-bottom: 1rem;
}

p:last-child {
  margin-bottom: 0;
}

.lead {
  font-size: 1.2rem;
  line-height: 1.55;
  color: var(--text-muted);
  font-weight: 400;
  max-width: 60ch;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
  display: inline-block;
}

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

.eyebrow.light {
  color: rgba(255, 255, 255, 0.7);
}

/* ------------------------------------------------------------------
   Layout helpers
------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

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

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

.section--dark {
  background: var(--navy-darker);
  color: var(--text-light);
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--white);
}

.section--gray {
  background: var(--light);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-header {
  margin-bottom: var(--space-6);
  max-width: 720px;
}

.section-header h2 {
  margin-bottom: 1rem;
}

/* ------------------------------------------------------------------
   Header / Nav
------------------------------------------------------------------ */
.site-header {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.875rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 1.15rem;
  color: var(--navy-darker);
  letter-spacing: -0.01em;
}

.brand img {
  width: 68px;
  height: 68px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-text small {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 2px;
}

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

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--navy);
}

.nav-cta {
  background: var(--navy-darker);
  color: var(--white) !important;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem !important;
  transition: background 0.2s !important;
}

.nav-cta:hover {
  background: var(--navy);
}

/* ------------------------------------------------------------------
   Buttons
------------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.005em;
  transition: all 0.2s ease;
  text-decoration: none;
  border: 1.5px solid transparent;
  white-space: nowrap;
}

.btn--primary {
  background: var(--accent);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(255, 107, 53, 0.28);
}

.btn--primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 107, 53, 0.38);
}

.btn--secondary {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn--secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.7);
}

.btn--ghost {
  background: transparent;
  color: var(--navy-darker);
  border-color: var(--border);
}

.btn--ghost:hover {
  border-color: var(--navy);
  color: var(--navy);
}

.btn--lg {
  padding: 1rem 1.75rem;
  font-size: 1rem;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
  align-items: center;
}

/* ------------------------------------------------------------------
   Hero
------------------------------------------------------------------ */
.hero {
  position: relative;
  background:
    radial-gradient(ellipse at 75% 30%, rgba(255, 107, 53, 0.10), transparent 55%),
    radial-gradient(ellipse at 15% 80%, rgba(42, 82, 152, 0.5), transparent 50%),
    linear-gradient(135deg, var(--navy-darker) 0%, var(--navy-deep) 60%, var(--navy) 100%);
  color: var(--white);
  padding: var(--space-12) 0 var(--space-8);
  overflow: hidden;
  border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

.hero::before {
  /* subtle grid pattern */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  pointer-events: none;
}

.hero__inner {
  position: relative;
  max-width: 880px;
}

.hero h1 {
  color: var(--white);
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

.hero__sub {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  color: var(--text-light);
  max-width: 640px;
  margin-bottom: 2.25rem;
  font-weight: 400;
}

.hero--service {
  padding: var(--space-8) 0 var(--space-6);
}

/* ------------------------------------------------------------------
   Credentials strip
------------------------------------------------------------------ */
.credentials {
  background: var(--dark);
  border-top: 1px solid var(--border-light);
  padding: 1.5rem 0;
  color: var(--text-light);
}

.credentials__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  align-items: center;
}

.credentials__item {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.75);
  text-align: center;
}

.credentials__item strong {
  display: block;
  color: var(--white);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  margin-bottom: 0.25rem;
}

/* ------------------------------------------------------------------
   Audience cards (Who this is for)
------------------------------------------------------------------ */
.audience-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.audience-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.75rem;
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.audience-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--navy);
}

.audience-card__label {
  font-family: var(--font-serif);
  font-size: 1.875rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--navy-darker);
  margin-bottom: 1rem;
}

.audience-card p {
  color: var(--text-muted);
  font-size: 0.975rem;
  line-height: 1.6;
}

/* ------------------------------------------------------------------
   Service grid
------------------------------------------------------------------ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.service-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem 1.5rem;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--navy);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.25s ease;
}

.service-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: var(--navy);
}

.service-card:hover::before {
  transform: scaleY(1);
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.625rem;
  color: var(--navy-darker);
}

.service-card p {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.service-card__link {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: gap 0.2s;
}

.service-card:hover .service-card__link {
  gap: 0.6rem;
}

/* ------------------------------------------------------------------
   Two-column "Why" section
------------------------------------------------------------------ */
.why-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-top: 2.5rem;
}

.why-block h4 {
  color: var(--white);
  margin-bottom: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--accent);
}

.why-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.why-list li {
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-light);
  font-size: 1rem;
  line-height: 1.5;
}

.why-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 0.6rem;
  height: 1.5px;
  background: var(--accent);
}

/* ------------------------------------------------------------------
   Deliverables / Process / Detail lists (used on service pages)
------------------------------------------------------------------ */
.detail-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  margin-top: 2.5rem;
}

@media (max-width: 768px) {
  .detail-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

.detail-label {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding-top: 0.25rem;
}

.detail-content h3 {
  margin-bottom: 1rem;
}

.detail-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.detail-list li {
  padding-left: 1.5rem;
  position: relative;
  line-height: 1.55;
}

.detail-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 600;
}

/* Scroll offset so sticky header does not cover jump targets */
section[id],
.section-anchor {
  scroll-margin-top: 108px;
}

/* Page section jump nav (used in hero on service pages) */
.page-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 2.25rem;
  padding-top: 1.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.page-nav a {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 0.375rem 0.875rem;
  border-radius: 3px;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  text-decoration: none;
}

.page-nav a:hover {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.06);
}

/* Divided variant: clear visual separation between items */
.detail-list--divided {
  gap: 0;
}

.detail-list--divided li {
  padding-top: 0.875rem;
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--border);
}

.detail-list--divided li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.process-steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  counter-reset: step;
  margin-top: 2rem;
}

.process-step {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 1.25rem;
  padding: 1.25rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  align-items: start;
  counter-increment: step;
}

.process-step__num {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--accent);
  line-height: 1;
}

.process-step__num::before {
  content: counter(step, decimal-leading-zero);
}

.process-step h4 {
  margin-bottom: 0.375rem;
  color: var(--navy-darker);
}

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

/* Pull quote / framing block */
.framing-block {
  border-left: 3px solid var(--accent);
  padding: 0.5rem 0 0.5rem 1.5rem;
  margin: 2rem 0;
  font-family: var(--font-serif);
  font-size: 1.2rem;
  line-height: 1.55;
  color: var(--navy-darker);
}

/* ------------------------------------------------------------------
   Related services
------------------------------------------------------------------ */
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
}

.related-card {
  display: block;
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  transition: border-color 0.2s, transform 0.2s;
  text-decoration: none;
  color: inherit;
}

.related-card:hover {
  border-color: var(--navy);
  transform: translateY(-2px);
}

.related-card h4 {
  color: var(--navy-darker);
  margin-bottom: 0.375rem;
}

.related-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0;
}

/* ------------------------------------------------------------------
   Final CTA section
------------------------------------------------------------------ */
.final-cta {
  background: var(--navy-darker);
  color: var(--text-light);
  padding: var(--space-12) 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.final-cta::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(255, 107, 53, 0.08), transparent 60%);
  pointer-events: none;
}

.final-cta__inner {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
}

.final-cta h2 {
  color: var(--white);
  margin-bottom: 1rem;
}

.final-cta p {
  color: var(--text-light);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.final-cta .btn-row {
  justify-content: center;
}

/* ------------------------------------------------------------------
   Footer
------------------------------------------------------------------ */
.site-footer {
  background: var(--dark);
  color: var(--text-light);
  padding: 3rem 0 2rem;
}

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

.site-footer h4 {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 1rem;
  font-weight: 500;
}

.site-footer__brand p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
  max-width: 380px;
}

.site-footer__links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.site-footer__links a {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.2s;
}

.site-footer__links a:hover {
  color: var(--accent);
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  font-family: var(--font-mono);
}

/* ------------------------------------------------------------------
   Responsive
------------------------------------------------------------------ */
@media (max-width: 960px) {
  .audience-grid,
  .services-grid,
  .related-grid {
    grid-template-columns: 1fr 1fr;
  }

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

  .why-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

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

  .nav-links.nav-links--mobile-cta {
    display: flex;
  }

  .nav-links.nav-links--mobile-cta li:not(:last-child) {
    display: none;
  }

  .audience-grid,
  .services-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .credentials__grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    text-align: center;
  }

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

  .hero {
    padding: var(--space-8) 0 var(--space-6);
  }

  .site-footer__grid {
    grid-template-columns: 1fr;
  }

  .site-footer__bottom {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }

  .process-step {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
}
