/* =========================================================
   TEKperfect — Design System
   Real brand palette + type, pulled from the official brand
   deck (01-Brand-Assets). Brand purple #410A64 is the anchor —
   the full scale below is generated from its exact hue/saturation.
   Secondary brand colors (orange #FF7D06, cream #EDE0CE, pale
   azure #EDF2F3) are kept as CSS vars in case they're needed,
   but the site design is deliberately all-purple per spec.
   ========================================================= */

@font-face {
  font-family: "Cantarell";
  src: url("/assets/fonts/Cantarell-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cantarell";
  src: url("/assets/fonts/Cantarell-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Raleway";
  src: url("/assets/fonts/Raleway-VariableFont_wght.ttf") format("truetype-variations");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Purple brand scale — generated from brand purple #410A64 (H277 S82 L22) */
  --purple-950: #240638;
  --purple-900: #410A64; /* exact brand hex from brand deck */
  --purple-800: #550D82;
  --purple-700: #7011AC;
  --purple-600: #8C15D5;
  --purple-500: #A22EEA;
  --purple-400: #BD6BF0;
  --purple-200: #E4C3F9;
  --purple-100: #F1DFFC;
  --purple-50:  #F9F1FE;

  /* Secondary brand colors (available, not primary in this design) */
  --brand-orange: #FF7D06;
  --brand-cream: #EDE0CE;
  --brand-pale-azure: #EDF2F3;

  /* Neutrals */
  --ink-900: #14121A;
  --ink-700: #3F3A4A;
  --ink-500: #6B6478;
  --ink-300: #A79FB5;
  --ink-100: #E9E4F0;
  --white: #FFFFFF;

  /* Semantic */
  --bg: var(--white);
  --bg-alt: var(--purple-50);
  --text: var(--ink-900);
  --text-muted: var(--ink-700);
  --brand: var(--purple-700);
  --brand-dark: var(--purple-900);
  --brand-accent: var(--purple-600);
  --border: var(--ink-100);
  --success: #15803D;

  /* Type — brand deck specifies Cantarell for titles, Raleway for body */
  --font-body: "Raleway", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Cantarell", var(--font-body);

  /* Layout */
  --container: 1120px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(30, 11, 61, 0.06), 0 1px 3px rgba(30, 11, 61, 0.08);
  --shadow-md: 0 8px 24px rgba(46, 16, 101, 0.12);
  --shadow-lg: 0 24px 60px rgba(46, 16, 101, 0.18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.2rem, 4vw + 1rem, 3.4rem); }
h2 { font-size: clamp(1.7rem, 2.4vw + 1rem, 2.4rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; color: var(--text-muted); }
.lede { font-size: 1.15rem; color: var(--text-muted); }

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

section { padding: 88px 0; }
section.tight { padding: 56px 0; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: radial-gradient(120% 140% at 10% 0%, var(--purple-800) 0%, var(--purple-950) 60%); color: var(--white); }
.section-dark p, .section-dark .eyebrow { color: var(--purple-200); }
.section-dark h2, .section-dark h3 { color: var(--white); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--brand-accent);
  display: inline-block;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.98rem;
  padding: 14px 26px;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--purple-600), var(--purple-800));
  color: var(--white);
  box-shadow: var(--shadow-md);
}
.btn-primary:hover { box-shadow: var(--shadow-lg); }
.btn-secondary {
  background: transparent;
  border-color: var(--purple-300, var(--purple-400));
  color: var(--brand);
}
.btn-secondary:hover { background: var(--purple-50); }
.btn-on-dark { background: var(--white); color: var(--brand-dark); }
.btn-ghost-on-dark { background: transparent; border-color: rgba(255,255,255,0.35); color: var(--white); }
.btn-block { width: 100%; }
.btn-sm { padding: 10px 18px; font-size: 0.88rem; }

/* Header / Nav */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0;
}
.brand-logo { display: flex; align-items: center; text-decoration: none; }
.brand-logo img { height: 34px; width: auto; display: block; }
.brand-logo .mark {
  width: 34px; height: 34px; border-radius: 9px;
  background: linear-gradient(135deg, var(--purple-500), var(--purple-800));
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 800; font-size: 1rem;
  box-shadow: var(--shadow-sm);
}
.nav-links { display: flex; align-items: center; gap: 32px; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; font-weight: 600; font-size: 0.95rem; color: var(--text); }
.nav-links a:hover { color: var(--brand); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-phone { font-weight: 700; font-size: 0.95rem; color: var(--brand-dark); text-decoration: none; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--text); margin: 5px 0; border-radius: 2px; }

@media (max-width: 900px) {
  .nav-links, .nav-cta .nav-phone { display: none; }
  .nav-toggle { display: block; }
  .nav-cta.mobile-open ~ .nav-links,
  body.nav-open .nav-links {
    display: flex; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white); flex-direction: column; padding: 20px 24px 28px;
    border-bottom: 1px solid var(--border); box-shadow: var(--shadow-md);
    gap: 18px;
  }
}

/* Hero */
.hero { padding: 72px 0 40px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin: 28px 0 22px; }
.hero-note { font-size: 0.85rem; color: var(--ink-500); }
.hero-art {
  position: relative; aspect-ratio: 4/3.2; border-radius: var(--radius-lg);
  background: radial-gradient(120% 120% at 20% 15%, var(--purple-500) 0%, var(--purple-800) 55%, var(--purple-950) 100%);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.hero-art .grid-overlay {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.08) 1px, transparent 1px);
  background-size: 34px 34px;
}
.hero-art .glow { position: absolute; width: 260px; height: 260px; border-radius: 50%; background: var(--purple-400); filter: blur(60px); opacity: 0.55; }
.hero-art .glow.a { top: -60px; right: -40px; }
.hero-art .glow.b { bottom: -60px; left: -30px; background: var(--purple-200); opacity: 0.35; }
.hero-art .card {
  position: absolute; background: rgba(255,255,255,0.96); border-radius: var(--radius-md);
  box-shadow: var(--shadow-md); padding: 16px 18px; font-size: 0.82rem; color: var(--ink-900); font-weight: 600;
}
.hero-art .card.c1 { top: 14%; left: 8%; }
.hero-art .card.c2 { bottom: 12%; right: 8%; }
.hero-art .card .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--success); display: inline-block; margin-right: 8px; }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; aspect-ratio: 16/10; }
}

/* Trust bar */
.trust-bar { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--bg-alt); }
.trust-row { display: flex; flex-wrap: wrap; gap: 28px 48px; justify-content: space-between; align-items: center; padding: 26px 0; }
.trust-item { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--brand-dark); font-size: 0.95rem; }
.trust-item small { display: block; font-weight: 500; color: var(--ink-500); font-size: 0.78rem; }

/* Cards / grid */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
@media (max-width: 900px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.card .icon {
  width: 48px; height: 48px; border-radius: 12px; margin-bottom: 18px;
  background: linear-gradient(135deg, var(--purple-100), var(--purple-200));
  display: flex; align-items: center; justify-content: center; font-size: 1.35rem;
}
.card ul { padding-left: 20px; margin: 14px 0; color: var(--text-muted); font-size: 0.94rem; }
.card ul li { margin-bottom: 6px; }
.card-link { font-weight: 700; color: var(--brand); text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }

/* Pricing */
.price-row { display: flex; align-items: baseline; gap: 6px; margin: 18px 0 6px; }
.price-row .amount { font-size: 1.9rem; font-weight: 800; color: var(--brand-dark); font-family: var(--font-display); }
.price-row .period { color: var(--ink-500); font-size: 0.9rem; }
.price-row { min-height: 49px; }
.price-row .amount.amount-text { font-size: 1.25rem; font-weight: 700; }
.badge {
  display: inline-block; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  background: var(--purple-100); color: var(--brand); padding: 5px 12px; border-radius: 999px; margin-bottom: 12px;
}
.badge.on-dark { background: rgba(255,255,255,0.15); color: var(--white); }


/* FAQ accordion */
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q {
  width: 100%; text-align: left; background: none; border: none; cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: 1.02rem; color: var(--ink-900);
  padding: 20px 0; display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-q .plus { font-size: 1.4rem; color: var(--brand); transition: transform 0.2s ease; flex-shrink: 0; }
.faq-item.open .faq-q .plus { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.25s ease; }
.faq-a p { padding-bottom: 20px; margin: 0; }
.faq-item.open .faq-a { max-height: 400px; }

/* Forms */
.form-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 40px; box-shadow: var(--shadow-md); }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 0.96rem; font-family: inherit; background: var(--white); color: var(--text);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand-accent); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .form-card { padding: 20px; } }
.form-note { font-size: 0.82rem; color: var(--ink-500); margin-top: 10px; }

/* Quiz */
.quiz-shell { max-width: 720px; margin: 0 auto; }
.quiz-progress { height: 6px; background: var(--purple-100); border-radius: 999px; overflow: hidden; margin-bottom: 32px; }
.quiz-progress .bar { height: 100%; background: linear-gradient(90deg, var(--purple-500), var(--purple-700)); width: 0%; transition: width .3s ease; }
.quiz-step { display: none; }
.quiz-step.active { display: block; animation: fadein .25s ease; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
.quiz-options { display: grid; gap: 12px; margin: 20px 0 30px; }
.quiz-option {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px; border: 1.5px solid var(--border);
  border-radius: var(--radius-md); cursor: pointer; font-weight: 600; transition: border-color .15s, background .15s;
}
.quiz-option:hover { border-color: var(--purple-400); background: var(--purple-50); }
.quiz-option.selected { border-color: var(--brand-accent); background: var(--purple-100); }
.quiz-option input { accent-color: var(--brand-accent); width: 18px; height: 18px; }
.quiz-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; }
.quiz-result { text-align: center; }
.score-ring {
  width: 160px; height: 160px; border-radius: 50%; margin: 0 auto 24px;
  display: flex; align-items: center; justify-content: center; font-family: var(--font-display);
  font-size: 2.2rem; font-weight: 800; color: var(--brand-dark);
  background: conic-gradient(var(--purple-600) calc(var(--score, 70) * 1%), var(--purple-100) 0);
  position: relative;
}
.score-ring::after { content: ""; position: absolute; inset: 12px; border-radius: 50%; background: var(--white); }
.score-ring span { position: relative; z-index: 1; }

/* CTA band */
.cta-band {
  border-radius: var(--radius-lg); padding: 56px; text-align: center;
  background: radial-gradient(120% 160% at 50% 0%, var(--purple-700), var(--purple-950));
  color: var(--white);
}
.cta-band h2, .cta-band p { color: var(--white); }
.cta-band .btn-primary { background: var(--white); color: var(--brand-dark); }

/* Footer */
.site-footer { background: var(--purple-950); color: var(--purple-100); padding: 64px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.site-footer h4 { color: var(--white); font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 16px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 10px; }
.site-footer a { text-decoration: none; color: var(--purple-200); font-size: 0.92rem; }
.site-footer a:hover { color: var(--white); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.12); font-size: 0.8rem; color: var(--purple-200); }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.footer-social { display: flex; gap: 14px; margin-top: 16px; }
.footer-social a { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; }

/* Breadcrumb / page header */
.page-header { padding: 56px 0 12px; }
.page-header .eyebrow { }
.pill-list { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0; }
.pill { background: var(--purple-100); color: var(--brand); font-weight: 600; font-size: 0.82rem; padding: 6px 14px; border-radius: 999px; }

/* Utilities */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.max-w-640 { max-width: 640px; }
.mx-auto { margin-left: auto; margin-right: auto; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--brand); color: white; padding: 10px 16px; z-index: 100;
}
.skip-link:focus { left: 16px; top: 16px; }

/* Long-form legal text */
.policy h2, .article h2 { font-size: 1.35rem; margin: 36px 0 10px; }
.policy p, .policy li, .article p, .article li { color: var(--text-muted); }
.policy ul, .article ul, .article ol { padding-left: 22px; margin: 0 0 16px; }
.policy li, .article li { margin-bottom: 8px; }
.article blockquote { margin: 24px 0; padding: 6px 0 6px 20px; border-left: 4px solid var(--purple-500); font-family: var(--font-display); font-size: 1.35rem; font-weight: 700; line-height: 1.35; color: var(--brand-dark); }
.article .article-sign { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); }

/* Blog series */
.article ol { padding-left: 24px; margin: 0 0 16px; }
.article a { color: var(--purple-800); }
.series-nav { margin: 0 0 32px; padding: 16px 20px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 14px; }
.series-nav .series-title { margin: 0 0 8px; font-size: 0.82rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-500); }
.series-nav ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.series-nav li { margin: 0; color: var(--text-muted); }
.series-nav li[aria-current] { color: var(--brand-dark); }
.series-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 40px 0 24px; }
.series-pager a { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border: 1px solid var(--border); border-radius: 14px; text-decoration: none; color: var(--brand-dark); background: var(--white); }
.series-pager a:hover { border-color: var(--purple-500); box-shadow: var(--shadow-md); }
.series-pager .pager-dir { font-size: 0.8rem; font-weight: 700; color: var(--ink-500); text-transform: uppercase; letter-spacing: 0.04em; }
.series-pager .next { grid-column: 2; text-align: right; }
.series-pager .prev { grid-column: 1; }
@media (max-width: 600px) { .series-pager { grid-template-columns: 1fr; } .series-pager .next, .series-pager .prev { grid-column: 1; text-align: left; } }
.flow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 18px 0; }
.flow-step { display: inline-block; padding: 6px 14px; border-radius: 999px; background: var(--bg-alt); border: 1px solid var(--border); color: var(--brand-dark); font-weight: 700; font-size: 0.92rem; }
.flow-arrow { color: var(--ink-500); font-weight: 700; }
ol.flow.vertical { list-style: none; flex-direction: column; align-items: flex-start; gap: 0; padding: 0; margin: 18px 0; }
ol.flow.vertical li { margin: 0; display: flex; flex-direction: column; align-items: flex-start; }
ol.flow.vertical li:not(:last-child)::after { content: "\2193"; color: var(--ink-500); font-weight: 700; padding: 4px 0 4px 14px; }
.defs { display: grid; gap: 12px; margin: 18px 0 22px; }
.def { display: grid; grid-template-columns: auto 1fr; column-gap: 14px; row-gap: 2px; padding: 14px 16px; border: 1px solid var(--border); border-radius: 14px; background: var(--white); }
.def .def-num { grid-row: 1 / span 2; font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; color: var(--purple-500); align-self: center; }
.def strong { color: var(--brand-dark); }
.def span:last-child { color: var(--text-muted); }

/* Long button labels (e.g. the hero call-to-action) must wrap on phones instead of widening the page */
@media (max-width: 520px) { .btn { white-space: normal; text-align: center; } }

/* Team bio card */
.team-card { display: grid; grid-template-columns: 260px 1fr; gap: 32px; align-items: center; max-width: 860px; margin: 32px auto 0; padding: 28px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.team-photo { width: 260px; height: 260px; object-fit: cover; border-radius: var(--radius-lg); display: block; }
.team-bio h3 { margin: 0 0 2px; }
.team-bio .team-role { margin: 0 0 14px; font-weight: 700; color: var(--purple-800); }
.team-bio p { color: var(--text-muted); }
@media (max-width: 700px) { .team-card { grid-template-columns: 1fr; padding: 20px; gap: 20px; } .team-photo { width: 240px; height: 240px; margin: 0 auto; } }
