/* Tekflux — main company site (tekfluxco.com) */
:root {
  --ink: #0e1f3d;
  --ink-2: #2a3a5c;
  --muted: #5a6a8a;
  --line: #dbe4f3;
  --bg: #ffffff;
  --bg-soft: #f3f7ff;
  --brand: #0b44f0;
  --brand-dark: #0836c4;
  --brand-deep: #0a2a7a;
  --brand-soft: #e6eeff;
  --go: #00a651;
  --go-dark: #008a43;
  --orange: #ff7a00;
  --purple: #7b3ff2;
  --radius: 12px;
  --shadow: 0 10px 30px rgba(11, 68, 240, .10);
  --wrap: 1200px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.6; font-size: 16px; }
img, svg { max-width: 100%; display: block; }
img { height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.02em; font-weight: 800; }
h1 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.15rem; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
[id] { scroll-margin-top: 90px; }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--brand); margin-bottom: 14px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; padding: .85em 1.5em; border-radius: 10px; border: 1.5px solid var(--brand); background: var(--brand); color: #fff; font-weight: 700; text-decoration: none; cursor: pointer; transition: background .15s, transform .15s, box-shadow .15s; }
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); transform: translateY(-1px); box-shadow: 0 8px 20px rgba(11, 68, 240, .25); }
.btn-go { background: var(--go); border-color: var(--go); }
.btn-go:hover { background: var(--go-dark); border-color: var(--go-dark); box-shadow: 0 8px 20px rgba(0, 166, 81, .25); }
.btn-ghost { background: #fff; color: var(--brand); }
.btn-ghost:hover { background: var(--brand-soft); color: var(--brand-dark); }
.btn-white { background: #fff; border-color: #fff; color: var(--brand); }
.btn-white:hover { background: #eef3ff; border-color: #eef3ff; color: var(--brand-dark); }
.btn-outline-white { background: transparent; border-color: rgba(255,255,255,.8); color: #fff; }
.btn-outline-white:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.btn-block { width: 100%; }
.link { color: var(--brand); font-weight: 700; text-decoration: none; }
.link:hover { text-decoration: underline; }

/* Top bar + header */
.topbar { background: var(--ink); color: #c9d4ea; font-size: .84rem; }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 8px; padding-bottom: 8px; }
.topbar a { color: #fff; text-decoration: none; font-weight: 600; }
.topbar a:hover { text-decoration: underline; }
.topbar .tb-right { display: flex; gap: 18px; align-items: center; }
.header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header .wrap { display: flex; align-items: center; gap: 28px; height: 72px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); flex: none; }
.logo-mark { width: 32px; height: 36px; }
.wordmark { font-family: "Montserrat", var(--font); font-weight: 700; font-size: 1.45rem; letter-spacing: -.01em; line-height: 1; }
.wordmark span { color: var(--brand); }
.nav { display: flex; gap: 26px; margin-right: auto; }
.nav a { text-decoration: none; font-weight: 600; color: var(--ink-2); padding: 6px 0; }
.nav a:hover, .nav a.active { color: var(--brand); box-shadow: inset 0 -2px 0 var(--brand); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.header-actions .btn { padding: .6em 1.1em; font-size: .92rem; }
.shop-link { font-weight: 700; color: var(--ink-2); text-decoration: none; font-size: .92rem; padding: 8px 10px; border-radius: 8px; }
.shop-link:hover { background: var(--brand-soft); color: var(--brand); }
.menu-toggle { display: none; width: 42px; height: 42px; border: 0; background: none; border-radius: 8px; cursor: pointer; place-items: center; }
.menu-toggle svg { width: 24px; height: 24px; }
@media (max-width: 900px) {
  .nav { display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 16px; box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav a { padding: 13px 0; border-bottom: 1px solid var(--line); box-shadow: none !important; }
  .nav a.nav-shop { display: block; }
  .menu-toggle { display: grid; }
  .logo { margin-right: auto; }
  .shop-link { display: none; }
  .topbar .hide-sm { display: none; }
}
.nav a.nav-shop { display: none; }
@media (max-width: 420px) {
  .header .wrap { gap: 8px; height: 64px; padding: 0 14px; }
  .nav { top: 64px; }
  .wordmark { font-size: 1.2rem; }
  .logo-mark { width: 26px; height: 29px; }
  .header-actions .btn { padding: .5em .8em; font-size: .82rem; }
}

/* Hero */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, #f3f7ff 0%, #fff 100%); }
.hero::before { content: ""; position: absolute; right: -180px; top: -160px; width: 620px; height: 620px; border-radius: 50%; background: radial-gradient(circle, rgba(11,68,240,.12), transparent 65%); }
.hero .wrap { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 56px; align-items: center; padding-top: 64px; padding-bottom: 72px; }
.hero h1 span { color: var(--brand); }
.hero .lead { font-size: 1.15rem; color: var(--ink-2); max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-note { margin-top: 18px; font-size: .92rem; color: var(--muted); }
.hero-note a { color: var(--brand); font-weight: 700; }
.collage { position: relative; display: grid; grid-template-columns: 1.2fr 1fr; grid-template-rows: 1fr 1fr; gap: 14px; height: 440px; }
.collage img { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; box-shadow: 0 16px 40px rgba(14, 31, 61, .14); }
.collage img:first-child { grid-row: 1 / 3; }
.collage .stat-card { position: absolute; left: -26px; bottom: 26px; background: #fff; border-radius: 14px; padding: 14px 18px; box-shadow: 0 16px 40px rgba(14, 31, 61, .18); display: flex; gap: 12px; align-items: center; }
.stat-card b { display: block; font-size: 1.3rem; color: var(--brand); line-height: 1.1; }
.stat-card span { font-size: .82rem; color: var(--muted); }
.stat-card .dot { width: 40px; height: 40px; border-radius: 10px; background: var(--brand-soft); display: grid; place-items: center; color: var(--brand); font-weight: 800; }
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 36px; padding-top: 40px; padding-bottom: 48px; }
  .collage { height: 320px; }
  .collage .stat-card { left: 12px; bottom: 12px; }
}
@media (max-width: 520px) { .collage { height: 240px; gap: 10px; } .collage .stat-card { padding: 10px 12px; } .stat-card b { font-size: 1.05rem; } }

/* Stats bar */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: #fff; }
.stats .wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 26px 20px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat b { display: block; font-size: 1.6rem; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.stat > span { color: var(--muted); font-size: .92rem; }
@media (max-width: 760px) { .stats .wrap { grid-template-columns: 1fr 1fr; } .stat:nth-child(2) { border-right: 0; } .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); } .stat { padding: 18px 14px; } .stat b { font-size: 1.25rem; } }

/* Sections */
section { padding: 84px 0; }
.soft { background: var(--bg-soft); }
.section-head { max-width: 720px; margin-bottom: 40px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { font-size: 1.08rem; color: var(--muted); margin: 0; }
.split-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 40px; }
.split-head .section-head { margin-bottom: 0; }
@media (max-width: 640px) { section { padding: 56px 0; } .section-head { margin-bottom: 28px; } }

/* Cards */
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: var(--ink); transition: box-shadow .2s, transform .2s, border-color .2s; }
a.card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: #b8cbff; }
.card img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-body p { color: var(--muted); margin: 0; font-size: .96rem; }
.card-body .link { margin-top: auto; padding-top: 10px; }
.tag { align-self: flex-start; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); }
.feature { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 26px; }
.feature .icon { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 16px; }
.feature .icon svg { width: 26px; height: 26px; }
.feature p { color: var(--muted); margin: 0; font-size: .96rem; }
.i-blue { background: #e6eeff; color: var(--brand); }
.i-green { background: #e6f7ee; color: var(--go); }
.i-orange { background: #fff1e3; color: var(--orange); }
.i-purple { background: #f1e9ff; color: var(--purple); }
.ticks { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 8px; color: var(--ink-2); font-size: .95rem; }
.ticks li { padding-left: 26px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--go); font-weight: 800; }
@media (max-width: 1000px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 641px) and (max-width: 900px) { .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; } .card-body { padding: 16px; } }

/* Process steps */
.process { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; counter-reset: s; }
.process .step { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 64px 20px 22px; }
.process .step::before { counter-increment: s; content: counter(s, decimal-leading-zero); position: absolute; top: 20px; left: 20px; font-weight: 800; font-size: .9rem; color: #fff; background: linear-gradient(135deg, #0b44f0, #5b8cff); width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; }
.process .step p { color: var(--muted); font-size: .92rem; margin: 0; }
@media (max-width: 1000px) { .process { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Two-column feature band */
.band { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.band img { width: 100%; border-radius: 18px; box-shadow: var(--shadow); aspect-ratio: 4 / 3; object-fit: cover; }
.band.reverse > :first-child { order: 2; }
@media (max-width: 860px) { .band { grid-template-columns: 1fr; gap: 28px; } .band.reverse > :first-child { order: 0; } }

/* Grading table */
.grades { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.grade { border-radius: 16px; padding: 24px; background: #fff; border: 1px solid var(--line); border-top: 5px solid var(--go); }
.grade:nth-child(2) { border-top-color: var(--brand); }
.grade:nth-child(3) { border-top-color: #ffc400; }
.grade p { color: var(--muted); margin: 0; font-size: .95rem; }

/* CTA band */
.cta { background: linear-gradient(120deg, #0b44f0 0%, #2f6bff 55%, #5b8cff 100%); color: #fff; border-radius: 22px; padding: 52px; display: grid; grid-template-columns: minmax(0, 1.3fr) auto; gap: 28px; align-items: center; }
.cta h2 { color: #fff; margin-bottom: 8px; }
.cta p { color: #e3ebff; margin: 0; font-size: 1.05rem; }
.cta .hero-cta { margin: 0; }
@media (max-width: 800px) { .cta { grid-template-columns: 1fr; padding: 34px 24px; } }

/* Shop strip */
.shop-strip { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 18px; padding: 26px 30px; background: #fff; }
.shop-strip h3 { margin: 0 0 4px; }
.shop-strip p { margin: 0; color: var(--muted); }

/* Page header (inner pages) */
.page-hero { background: linear-gradient(180deg, #f3f7ff 0%, #fff 100%); padding: 56px 0 40px; }
.page-hero h1 { font-size: clamp(2rem, 4vw, 3rem); }
.page-hero .lead { font-size: 1.12rem; color: var(--ink-2); max-width: 60ch; margin: 0; }
.crumbs { font-size: .85rem; color: var(--muted); margin-bottom: 14px; }
.crumbs a { text-decoration: none; color: var(--brand); }

/* Forms */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 30px; box-shadow: var(--shadow); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: .85rem; font-weight: 700; margin-bottom: 5px; }
.field input, .field select, .field textarea { width: 100%; padding: .75em .9em; border: 1px solid #c3d0e8; border-radius: 10px; background: #fff; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--brand); outline-offset: 1px; border-color: var(--brand); }
.quote-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.side-card { background: var(--bg-soft); border-radius: 18px; padding: 26px; position: sticky; top: 96px; }
.side-card h3 { margin-bottom: 10px; }
.contact-line { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.contact-line:first-of-type { border-top: 0; }
.contact-line b { display: block; }
.contact-line a { color: var(--brand); text-decoration: none; font-weight: 600; word-break: break-word; }
@media (max-width: 860px) { .quote-layout { grid-template-columns: 1fr; } .side-card { position: static; } }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } .form-card { padding: 20px; } }

/* FAQ */
.faq { max-width: 820px; }
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 1.3rem; line-height: 1; color: var(--brand); }
details[open] summary::after { content: "−"; }
details p { margin: 10px 0 0; color: var(--ink-2); }
.prose { max-width: 780px; }
.prose h2 { font-size: 1.5rem; margin-top: 1.6em; }

/* Footer */
.footer { background: var(--ink); color: #b9c5de; padding: 64px 0 28px; font-size: .93rem; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; }
.footer h4 { color: #fff; font-size: .95rem; margin-bottom: 12px; }
.footer a { color: #b9c5de; text-decoration: none; display: block; padding: 3px 0; }
.footer a:hover { color: #fff; }
.footer .logo { color: #fff; margin-bottom: 10px; }
.footer .wordmark span { color: #6b9bff; }
.footer .tagline { display: block; font-size: .72rem; letter-spacing: .28em; text-transform: uppercase; font-weight: 700; color: #7f8db0; margin-bottom: 14px; }
.footer-contact { display: grid; gap: 2px; margin-top: 10px; }
.footer-contact b { color: #fff; margin-top: 10px; }
.footer-contact a { display: inline; padding: 0; color: #9fbcff; }
.social { display: flex; gap: 10px; margin-top: 18px; }
.social a { display: grid; place-items: center; width: 38px; height: 38px; padding: 0; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; }
.social a:hover { background: var(--brand); }
.social svg { width: 18px; height: 18px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: .82rem; color: #8090b3; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > div:first-child { grid-column: 1 / -1; } }

/* Email fallback panel + toast */
.email-panel { width: min(560px, calc(100% - 32px)); border: 0; border-radius: 16px; padding: 24px; box-shadow: 0 24px 60px rgba(5, 20, 80, .3); color: var(--ink); }
.email-panel::backdrop { background: rgba(14, 31, 61, .45); }
.email-panel textarea { width: 100%; padding: 10px; border: 1px solid #c3d0e8; border-radius: 8px; font-size: .85rem; background: var(--bg-soft); }
.email-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.email-actions .btn { padding: .65em .8em; font-size: .9rem; }
.email-close { position: absolute; top: 12px; right: 14px; border: 0; background: none; font-size: 1.1rem; cursor: pointer; color: var(--muted); }
@media (max-width: 480px) { .email-actions { grid-template-columns: 1fr; } }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: var(--shadow); transition: transform .25s; z-index: 100; max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); }

/* Phones: swipeable card rows */
.swipe-dots { display: none; }
@media (max-width: 640px) {
  .grid-3, .grid-4, .grades, .process { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 20px; margin-inline: -20px; padding: 4px 20px 16px; scrollbar-width: none; overscroll-behavior-x: contain; }
  .grid-3::-webkit-scrollbar, .grid-4::-webkit-scrollbar, .grades::-webkit-scrollbar, .process::-webkit-scrollbar { display: none; }
  .grid-3 > *, .grid-4 > *, .grades > *, .process > * { flex: 0 0 82%; scroll-snap-align: start; }
  .swipe-dots { display: flex; justify-content: center; gap: 6px; }
  .swipe-dots span { width: 7px; height: 7px; border-radius: 999px; background: #c7d3ea; transition: width .2s, background .2s; }
  .swipe-dots span.on { width: 20px; background: var(--brand); }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
@media (max-width: 640px) { .topbar .tb-left { display: none; } .topbar .wrap { justify-content: center; } }

/* ---------- Image sizing (consistent frames, no odd crops) ---------- */
.hero-media { position: relative; max-width: 560px; margin-left: auto; padding: 0 0 48px 0; }
.hero-media img { border-radius: 18px; box-shadow: 0 18px 44px rgba(14, 31, 61, .16); object-fit: cover; }
.hm-main { width: 88%; aspect-ratio: 4 / 3; }
.hm-side { position: absolute; right: 0; bottom: 0; width: 34%; aspect-ratio: 4 / 5; border: 5px solid #fff; }
.hero-media .stat-card { position: absolute; left: -20px; bottom: 70px; }
.card img { aspect-ratio: 16 / 10; object-position: center; }
.band img { aspect-ratio: 16 / 10; }
.page-hero + section { padding-top: 48px; }
@media (max-width: 900px) {
  .hero-media { margin: 0 auto; max-width: 520px; padding-bottom: 36px; }
  .hero-media .stat-card { left: 10px; bottom: 50px; }
}
@media (max-width: 520px) {
  .hm-main { width: 90%; }
  .hm-side { width: 36%; border-width: 4px; }
  .hero-media .stat-card { left: 8px; bottom: 44px; padding: 8px 12px; }
  .hero-media .stat-card .dot { width: 34px; height: 34px; font-size: .85rem; }
}
.hero-media .stat-card { background: #fff; border-radius: 14px; padding: 12px 16px; box-shadow: 0 16px 40px rgba(14, 31, 61, .18); display: flex; gap: 12px; align-items: center; z-index: 2; }
.band img.full-photo { aspect-ratio: 4 / 3; object-fit: contain; background: #e9e6e1; }
