/* =========================================================
   Cascadia Beacon — site styles
   Tokens follow brand guide v1.0
   ========================================================= */

:root {
  --navy: #0E2A47;
  --navy-2: #081a2c;
  --evergreen: #1F5641;
  --evergreen-2: #143b2c;
  --teal: #2B8A9A;
  --teal-2: #1f6b78;
  --teal-text: #1A7282;
  --slate: #4A5662;
  --slate-2: #6B7785;
  --mist: #F4F6F8;
  --mist-2: #ECEFF3;
  --hairline: #E4E7EB;
  --hairline-2: #D5DAE0;
  --bg: #FFFFFF;
  --dark: #0A1E33;

  --max: 1200px;
  --gutter: clamp(20px, 4vw, 40px);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;

  --shadow-sm: 0 1px 2px rgba(14, 42, 71, 0.04), 0 1px 3px rgba(14, 42, 71, 0.06);
  --shadow-md: 0 6px 16px -8px rgba(14, 42, 71, 0.18), 0 2px 6px rgba(14, 42, 71, 0.06);
  --shadow-lg: 0 24px 48px -24px rgba(14, 42, 71, 0.25);

  --font: 'Inter', 'Helvetica Neue', system-ui, -apple-system, Arial, sans-serif;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--navy);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; margin: 0; }
button { font: inherit; cursor: pointer; }

.skip-link {
  position: absolute; left: -9999px; top: 8px;
  background: var(--navy); color: #fff; padding: 8px 12px;
  border-radius: 6px; z-index: 1000;
}
.skip-link:focus { left: 8px; }

/* Layout */
.container { max-width: var(--max); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* Type */
h1, h2, h3, h4 { font-weight: 600; letter-spacing: -0.02em; color: var(--navy); margin: 0; }
h1 { font-size: clamp(2.2rem, 1.4rem + 3vw, 3.6rem); line-height: 1.08; letter-spacing: -0.03em; text-wrap: balance; }
h2 { font-size: clamp(1.7rem, 1.2rem + 1.6vw, 2.5rem); line-height: 1.15; }
h3 { font-size: 1.15rem; line-height: 1.3; }
h4 { font-size: 0.95rem; }
p  { margin: 0; color: var(--slate); }
.eyebrow {
  font-size: 12px; font-weight: 600; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--teal-text); margin: 0 0 14px;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 22px; border-radius: 10px;
  font-weight: 600; font-size: 0.96rem; letter-spacing: -0.005em;
  border: 1px solid transparent; transition: transform .15s ease, background .2s ease, border-color .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn-sm { padding: 10px 16px; font-size: 0.88rem; border-radius: 8px; }
.btn-lg { padding: 16px 28px; font-size: 1rem; }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-2); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--hairline-2); }
.btn-ghost:hover { border-color: var(--navy); background: var(--mist); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease;
  will-change: transform;
}
.site-header.scrolled { border-bottom-color: var(--hairline); box-shadow: 0 1px 0 rgba(14,42,71,0.02); }
.header-inner { display: flex; align-items: center; gap: 24px; padding-block: 14px; }
.brand img { height: 64px; width: auto; }
.primary-nav { display: flex; gap: 28px; margin-left: auto; }
.primary-nav a {
  font-size: 0.94rem; font-weight: 500; color: var(--slate);
  padding: 6px 0; position: relative;
}
.primary-nav a:hover { color: var(--navy); }
.primary-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px;
  background: var(--teal); transform: scaleX(0); transform-origin: left; transition: transform .2s ease;
}
.primary-nav a:hover::after { transform: scaleX(1); }
.nav-toggle {
  display: none; background: none; border: 0; padding: 12px; margin-left: auto;
  flex-direction: column; gap: 5px; min-width: 44px; min-height: 44px;
  align-items: center; justify-content: center;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--navy); border-radius: 2px; }
.mobile-nav { display: none; flex-direction: column; gap: 10px; padding: 16px var(--gutter) 20px; border-top: 1px solid var(--hairline); background: #fff; }
.mobile-nav a { padding: 10px 0; color: var(--navy); font-weight: 500; border-bottom: 1px solid var(--hairline); }
.mobile-nav .btn { margin-top: 8px; }

@media (max-width: 880px) {
  .primary-nav, .header-inner > .btn { display: none; }
  .nav-toggle { display: flex; }
  .mobile-nav:not([hidden]) { display: flex; }
}

/* HERO */
.hero {
  position: relative;
  padding-top: clamp(48px, 6vw, 96px);
  padding-bottom: clamp(48px, 6vw, 96px);
  background: linear-gradient(180deg, #D4F5F9 0%, #E8FAFB 40%, #FFFFFF 100%);
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(32px, 4vw, 64px); align-items: center;
}
.hero-copy h1 { margin-top: 4px; }
.hero-copy .lede { font-size: clamp(1.05rem, 0.9rem + 0.4vw, 1.18rem); color: var(--slate); margin-top: 18px; max-width: 56ch; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.hero-meta {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px; margin-top: 40px; padding-top: 28px;
  border-top: 1px solid var(--hairline);
}
.hero-meta li {
  display: flex; flex-direction: column; gap: 2px;
  font-size: 0.82rem; color: var(--slate); letter-spacing: 0.02em;
}
.hero-meta strong { color: var(--navy); font-size: 1.05rem; font-weight: 600; letter-spacing: -0.01em; }

.hero-visual {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--mist);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 1 / 1;
}
.hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-trust {
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
  margin-top: clamp(40px, 5vw, 72px);
  padding-top: 28px; border-top: 1px solid var(--hairline);
}
.hero-trust > span {
  font-size: 11px; font-weight: 600; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--slate);
}
.hero-trust ul {
  display: flex; flex-wrap: wrap; gap: 8px 18px;
  font-size: 0.88rem; color: var(--slate); font-weight: 500;
}
.hero-trust li { position: relative; padding-right: 18px; }
.hero-trust li::after {
  content: ""; position: absolute; right: 0; top: 50%;
  width: 3px; height: 3px; border-radius: 50%; background: var(--hairline-2);
  transform: translateY(-50%);
}
.hero-trust li:last-child { padding-right: 0; }
.hero-trust li:last-child::after { display: none; }

@media (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; }
}
@media (max-width: 520px) {
  .hero-meta { grid-template-columns: 1fr; gap: 12px; }
}

/* Sections */
.section { padding-top: clamp(64px, 7vw, 112px); padding-bottom: clamp(64px, 7vw, 112px); }
.section-light { background: var(--mist); }
.section-mist { background: var(--mist); }
.section-dark { background: linear-gradient(180deg, var(--navy) 0%, var(--dark) 100%); color: #fff; }
.section-dark h2, .section-dark h3, .section-dark .eyebrow { color: #fff; }
.section-dark .eyebrow { color: var(--teal); }
.section-dark p { color: rgba(255,255,255,0.78); }

.section-head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head.wide { max-width: 820px; }
.section-head.on-dark .eyebrow { color: #4FB3C4; }
.section-sub { margin-top: 14px; font-size: 1.04rem; color: var(--slate); }
.section-dark .section-sub { color: rgba(255,255,255,0.78); }

/* Grid helpers */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 980px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-3 { grid-template-columns: 1fr; } }

/* Value items */
.value-grid { gap: 40px; }
.value-card {
  display: grid; grid-template-columns: 52px 1fr;
  grid-template-rows: auto auto; column-gap: 20px;
  padding: 0;
}
.value-icon {
  width: 52px; height: 52px; border-radius: 14px;
  background: var(--mist); display: grid; place-items: center;
  grid-row: 1 / -1;
}
.value-icon svg { width: 26px; height: 26px; }
.value-card h3 { margin-bottom: 4px; align-self: end; }
.value-card p { grid-column: 2; }

/* Services */
.service-grid { gap: 20px; grid-template-columns: repeat(2, 1fr); }
.service-card {
  background: #fff; border: 1px solid var(--hairline); border-radius: var(--radius-md);
  padding: 32px 28px;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.service-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--hairline-2); }
.service-num {
  font-size: 0.78rem; letter-spacing: 0.18em; font-weight: 600;
  color: var(--teal); display: block; margin-bottom: 14px;
}
.service-card h3 { margin-bottom: 10px; }
.service-card p { font-size: 0.96rem; }
.service-tags {
  display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px;
  padding-top: 18px; border-top: 1px solid var(--hairline);
}
.service-tags li {
  font-size: 12px; color: var(--slate);
  padding: 4px 10px; border: 1px solid var(--hairline);
  border-radius: 100px; background: var(--mist);
}
@media (max-width: 640px) { .service-grid { grid-template-columns: 1fr; } }

/* Process */
.process {
  counter-reset: step;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px; position: relative;
}
.process::before {
  content: ""; position: absolute; left: 30px; right: 30px; top: 24px; height: 1px;
  background: linear-gradient(90deg, rgba(255,255,255,0.05), rgba(79,179,196,0.45) 20%, rgba(79,179,196,0.45) 80%, rgba(255,255,255,0.05));
}
.process li {
  position: relative; padding-top: 64px;
}
.process .step {
  position: absolute; top: 0; left: 0;
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(79, 179, 196, 0.5);
  color: #4FB3C4; font-weight: 600; font-size: 0.9rem;
  display: grid; place-items: center;
  backdrop-filter: blur(8px);
}
.process h3 { color: #fff; margin-bottom: 6px; }
.process p { color: rgba(255,255,255,0.72); font-size: 0.94rem; }

@media (max-width: 1000px) {
  .process { grid-template-columns: repeat(2, 1fr); }
  .process::before { display: none; }
}
@media (max-width: 520px) {
  .process { grid-template-columns: 1fr; }
}

/* Split (who we help) */
.split {
  display: grid; grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(32px, 5vw, 80px); align-items: center;
}
.split-copy h2 { margin-top: 4px; }
.split-copy p { margin-top: 16px; max-width: 44ch; }
.industry-list {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0;
  border-top: 1px solid var(--hairline);
}
.industry-list li {
  padding: 18px 4px;
  border-bottom: 1px solid var(--hairline);
  font-weight: 500; color: var(--navy);
  display: flex; align-items: center; gap: 12px;
  font-size: 0.98rem;
}
.industry-list li::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--teal); flex: 0 0 6px;
}
.industry-list li:nth-child(odd) { padding-right: 16px; }
.industry-list li:nth-child(even) { padding-left: 16px; }

@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; }
  .industry-list { grid-template-columns: 1fr; }
  .industry-list li:nth-child(odd), .industry-list li:nth-child(even) { padding-left: 4px; padding-right: 4px; }
}

/* Use cases */
.usecase-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 0;
  border-top: 1px solid var(--hairline);
  border-left: 1px solid var(--hairline);
  background: #fff; border-radius: var(--radius-md); overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.usecase {
  padding: 26px 28px;
  border-right: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  background: #fff;
  transition: background .2s ease;
}
.usecase:hover { background: var(--mist); }
.usecase h3 { font-size: 1rem; margin-bottom: 6px; }
.usecase p { font-size: 0.92rem; color: var(--slate); }

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

/* Why */
.why {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.why-copy p { margin-top: 16px; max-width: 52ch; }
.highlight-list { display: grid; gap: 14px; }
.highlight-list li {
  padding: 18px 22px; background: var(--mist);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-sm);
  font-size: 0.98rem; color: var(--slate);
}
.highlight-list li strong { color: var(--navy); font-weight: 600; }

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

/* CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--navy) 0%, var(--evergreen) 100%);
  color: #fff;
  padding-block: clamp(64px, 7vw, 100px);
  position: relative; overflow: hidden;
}
.cta-band::before {
  content: ""; position: absolute; right: -120px; top: -120px;
  width: 480px; height: 480px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(43,138,154,0.30), transparent);
  pointer-events: none;
}
.cta-inner {
  display: grid; grid-template-columns: 1fr 1.4fr; gap: 48px;
  align-items: center; position: relative;
}
.cta-copy h2 { color: #fff; }
.cta-copy p { color: rgba(255,255,255,0.82); margin-top: 14px; font-size: 1.04rem; max-width: 52ch; }
.cta-actions { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.cta-band .btn-primary { background: #fff; color: var(--navy); }
.cta-band .btn-primary:hover { background: var(--mist); }
.cta-email { color: rgba(255,255,255,0.85); font-weight: 500; border-bottom: 1px solid rgba(255,255,255,0.4); padding-bottom: 2px; }
.cta-email:hover { color: #fff; border-color: #fff; }

/* Contact details */
.contact-details { display: grid; gap: 14px; margin-top: 28px; }
.contact-details li {
  display: flex; align-items: center; gap: 12px;
  color: rgba(255,255,255,0.85); font-size: 0.98rem;
}
.contact-details svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--teal); }
.contact-details a {
  color: rgba(255,255,255,0.85);
  border-bottom: 1px solid rgba(255,255,255,0.3); padding-bottom: 1px;
}
.contact-details a:hover { color: #fff; border-color: #fff; }

/* Contact form */
.contact-form {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: grid; gap: 16px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 0.84rem; font-weight: 600;
  color: rgba(255,255,255,0.72); letter-spacing: 0.02em;
}
.form-group input,
.form-group textarea {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font: inherit; font-size: 0.95rem; color: #fff;
  transition: border-color .2s ease, background .2s ease;
  outline: none;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: rgba(255,255,255,0.32); }
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--teal); background: rgba(255,255,255,0.12);
}
.form-group textarea { resize: vertical; min-height: 120px; }
.contact-submit { width: 100%; justify-content: center; }
.contact-submit:disabled { opacity: .65; cursor: not-allowed; transform: none; }
.form-result { font-size: 0.9rem; font-weight: 500; min-height: 1.4em; }
.form-result--ok  { color: #6EE7B7; }
.form-result--err { color: #FCA5A5; }

@media (max-width: 820px) {
  .cta-inner { grid-template-columns: 1fr; }
}
@media (max-width: 580px) {
  .form-row { grid-template-columns: 1fr; }
  .contact-form { padding: 24px 20px; }
}

/* Footer */
.site-footer { background: var(--dark); color: rgba(255,255,255,0.78); padding-top: 72px; padding-bottom: 32px; }
.footer-grid {
  display: grid; grid-template-columns: 1.2fr 1.5fr 0.7fr 1.2fr; gap: 40px;
  padding-bottom: 48px;
}
.footer-logo { height: 60px; margin-bottom: 18px; margin-left: -14px; }
.footer-brand p { color: rgba(255,255,255,0.72); max-width: 32ch; font-size: 0.94rem; }
.footer-col h4 {
  color: #fff; font-size: 0.82rem; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  margin-top: 22px; margin-bottom: 16px;
}
.footer-col ul { display: grid; gap: 10px; }
.footer-col a { color: rgba(255,255,255,0.72); font-size: 0.94rem; }
.footer-col a:hover { color: #fff; }

.footer-base {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 0.84rem; color: rgba(255,255,255,0.65);
}
.footer-tag { letter-spacing: 0.18em; text-transform: uppercase; font-size: 11px; }

@media (max-width: 820px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* Focus visibility */
a:focus-visible, button:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
