/* DiaFitus website. System fonts only: no third-party requests, so the site sets no cookies and loads nothing from other companies. */
:root {
  --navy: #0b2a4a;
  --blue: #1c7bd0;
  --teal: #0d9e8f;
  --green: #4fa82e;
  --coral: #fa774d;
  --ink: #12263f;
  --muted: #5a6b80;
  --line: #e3e9f0;
  --soft: #f4f8fb;
  --white: #fff;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(11, 42, 74, .08);
  --max: 1120px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); background: var(--white); line-height: 1.65; font-size: 17px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--navy); }
h1, h2, h3, h4 { line-height: 1.2; color: var(--navy); margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
.wrap { width: min(100% - 40px, var(--max)); margin-inline: auto; }
.narrow { width: min(100% - 40px, 780px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 0; background: var(--navy); color: #fff; padding: 10px 16px; z-index: 100; }
.skip:focus { left: 10px; top: 10px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 6px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.92); backdrop-filter: saturate(160%) blur(12px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); font-weight: 800; font-size: 1.25rem; letter-spacing: -.02em; }
.brand img { width: 42px; height: 42px; }
.nav ul { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; align-items: center; }
.nav ul a { display: block; padding: 8px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .96rem; }
.nav ul a:hover, .nav ul a[aria-current="page"] { background: var(--soft); color: var(--blue); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; font: inherit; font-weight: 600; color: var(--navy); cursor: pointer; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 14px 24px; border-radius: 14px; font-weight: 700; text-decoration: none; border: 2px solid transparent; font-size: 1rem; cursor: pointer; }
.btn-primary { background: linear-gradient(135deg, var(--teal), var(--blue)); color: #fff; box-shadow: 0 8px 20px rgba(28,123,208,.28); }
.btn-primary:hover { color: #fff; filter: brightness(1.06); }
.btn-ghost { border-color: var(--line); color: var(--navy); background: #fff; }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn[aria-disabled="true"] { opacity: .85; cursor: default; }

/* Hero */
.hero { background: radial-gradient(1200px 500px at 85% -10%, #dff3ee 0, transparent 60%), radial-gradient(900px 500px at -10% 20%, #e0eefb 0, transparent 60%), #fff; padding: 72px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.eyebrow { display: inline-block; font-weight: 700; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; color: var(--teal); margin-bottom: 14px; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 36em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 14px; }
.fine { font-size: .88rem; color: var(--muted); }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; padding: 0; list-style: none; }
.badges li { background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: .88rem; font-weight: 600; color: var(--navy); }

/* Sections */
section { padding: 80px 0; }
.section-soft { background: var(--soft); }
.section-head { max-width: 720px; margin: 0 auto 48px; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.grid { display: grid; gap: 22px; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.feature { transition: transform .15s ease, box-shadow .15s ease; }
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature h3 { margin-top: 14px; }
.feature p { color: var(--muted); margin: 0; font-size: .98rem; }
.ico { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(135deg, #e1f5f1, #e0eefb); }
.ico svg { width: 26px; height: 26px; stroke: var(--blue); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.feature ul { margin: 12px 0 0; padding-left: 18px; color: var(--muted); font-size: .94rem; }
.stat { text-align: center; }
.stat b { display: block; font-size: 2.4rem; color: var(--teal); letter-spacing: -.02em; line-height: 1.1; }
.stat span { color: var(--muted); font-size: .95rem; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.check { list-style: none; padding: 0; margin: 18px 0 0; }
.check li { position: relative; padding-left: 30px; margin-bottom: 10px; }
.check li::before { content: ""; position: absolute; left: 0; top: .35em; width: 18px; height: 18px; border-radius: 50%; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/12px no-repeat; }
.safety { border-left: 5px solid var(--coral); background: #fff7f3; }
.steps { counter-reset: s; }
.steps .card { position: relative; padding-top: 58px; }
.steps .card::before { counter-increment: s; content: counter(s); position: absolute; top: 20px; left: 26px; width: 30px; height: 30px; border-radius: 50%; background: var(--teal); color: #fff; font-weight: 800; display: grid; place-items: center; }
.integrations { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 0; padding: 0; list-style: none; }
.integrations li { border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: 10px 18px; font-weight: 700; color: var(--navy); }

details { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 20px; margin-bottom: 12px; }
summary { font-weight: 700; cursor: pointer; color: var(--navy); }
details[open] summary { margin-bottom: 8px; }
details p:last-child { margin-bottom: 0; }

.cta-band { background: linear-gradient(135deg, var(--navy), #11507f); color: #fff; text-align: center; border-radius: 28px; padding: 56px 24px; }
.cta-band h2 { color: #fff; }
.cta-band p { color: #cfe0f1; max-width: 560px; margin-inline: auto; }
.cta-band .btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.4); }

/* Footer */
.site-footer { background: var(--navy); color: #c4d3e4; padding: 56px 0 28px; font-size: .94rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; font-size: .95rem; margin-bottom: 12px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer .brand { color: #fff; margin-bottom: 12px; }
.site-footer .brand img { background: #fff; border-radius: 12px; padding: 2px; }
.legal { border-top: 1px solid rgba(255,255,255,.14); margin-top: 36px; padding-top: 22px; font-size: .84rem; color: #9fb3c9; }

/* Legal / document pages */
.page-hero { background: var(--soft); padding: 56px 0 40px; border-bottom: 1px solid var(--line); }
.page-hero p { color: var(--muted); margin: 0; }
.doc { padding: 48px 0 80px; }
.doc h2 { font-size: 1.55rem; margin-top: 2.2em; padding-top: .4em; }
.doc h3 { margin-top: 1.6em; font-size: 1.15rem; }
.doc ul, .doc ol { padding-left: 22px; }
.doc li { margin-bottom: .4em; }
.doc table { width: 100%; border-collapse: collapse; margin: 18px 0 28px; font-size: .94rem; display: block; overflow-x: auto; }
.doc th, .doc td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.doc th { background: var(--soft); color: var(--navy); white-space: nowrap; }
.toc { background: var(--soft); border: 1px solid var(--line); border-radius: 14px; padding: 18px 24px; margin: 24px 0 8px; }
.toc ol { margin: 8px 0 0; columns: 2; column-gap: 32px; }
.toc a { text-decoration: none; }
.callout { background: #eef7ff; border: 1px solid #cfe5fa; border-radius: 14px; padding: 16px 20px; margin: 22px 0; }
.callout.warn { background: #fff7f3; border-color: #ffd9c9; }
.callout p:last-child { margin: 0; }

/* Blog */
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.post-card { display: flex; flex-direction: column; overflow: hidden; padding: 0; text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); color: inherit; }
.post-card .thumb { aspect-ratio: 16 / 9; background: linear-gradient(135deg, #dff3ee, #dbeafb); display: grid; place-items: center; }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-card .thumb .ph { width: 64px; height: 64px; opacity: .85; }
.post-card .body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.post-card h2, .post-card h3 { font-size: 1.15rem; margin: 6px 0 8px; }
.post-card p { color: var(--muted); font-size: .95rem; margin: 0 0 14px; flex: 1; }
.meta { font-size: .85rem; color: var(--muted); }
.chip { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--teal); background: #e3f6f1; border-radius: 999px; padding: 3px 10px; text-decoration: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; }
.chips a { text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-weight: 600; font-size: .9rem; color: var(--navy); background: #fff; }
.chips a:hover, .chips a[aria-current="true"] { border-color: var(--blue); color: var(--blue); background: #f0f7fe; }
.pager { display: flex; justify-content: center; gap: 10px; margin-top: 40px; }
.article { padding: 40px 0 70px; }
.article h1 { font-size: clamp(1.9rem, 4.4vw, 2.8rem); margin: 10px 0 14px; }
.article .cover { border-radius: var(--radius); margin: 24px 0 30px; width: 100%; }
.article-body { font-size: 1.08rem; }
.article-body h2 { margin-top: 1.9em; font-size: 1.6rem; }
.article-body h3 { margin-top: 1.5em; }
.article-body img { border-radius: 12px; margin: 22px 0; }
.article-body blockquote { margin: 22px 0; padding: 4px 20px; border-left: 4px solid var(--teal); color: var(--muted); }
.article-body table { width: 100%; border-collapse: collapse; margin: 22px 0; display: block; overflow-x: auto; }
.article-body th, .article-body td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; }
.article-body th { background: var(--soft); }
.sources { background: var(--soft); border-radius: 14px; padding: 18px 24px; margin-top: 34px; font-size: .95rem; }
.sources h2 { font-size: 1.1rem; margin: 0 0 8px; }
.sources ul { margin: 0; padding-left: 20px; }
.crumbs { font-size: .88rem; color: var(--muted); }
.crumbs a { color: var(--muted); }
.note-box { font-size: .9rem; color: var(--muted); border-top: 1px solid var(--line); margin-top: 36px; padding-top: 18px; }

@media (max-width: 920px) {
  .hero-grid, .split { grid-template-columns: 1fr; }
  .g3, .post-grid { grid-template-columns: repeat(2, 1fr); }
  .g4 { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .toc ol { columns: 1; }
}
@media (max-width: 720px) {
  body { font-size: 16.5px; }
  section { padding: 56px 0; }
  .hero { padding: 44px 0 32px; }
  .menu-btn { display: block; }
  .nav ul { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; align-items: stretch; background: #fff; border-bottom: 1px solid var(--line); padding: 10px 20px 16px; }
  .nav ul.open { display: flex; }
  .g3, .g2, .g4, .post-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }


/* ===================== v2 redesign ===================== */
:root { --navy-2: #0f3a63; --glow: 0 30px 70px -25px rgba(11,42,74,.45); }
body { background: #fff; }
.site-header { background: rgba(255,255,255,.86); }
.nav ul a { font-size: .95rem; }
.btn { transition: transform .15s ease, box-shadow .15s ease, filter .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn-lg { padding: 16px 28px; font-size: 1.05rem; border-radius: 16px; }
.pill-soon { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; font-weight: 700; font-size: .9rem; color: var(--navy); box-shadow: 0 4px 14px rgba(11,42,74,.06); }
.pill-soon i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); display: block; box-shadow: 0 0 0 4px rgba(79,168,46,.2); }

/* Real-screenshot phone frame. Percent padding/radius keep it correct at any size. */
.device { --w: 260px; width: var(--w); max-width: 100%; position: relative; padding: 2.7%; background: linear-gradient(145deg, #1b2538, #0a0f1a); border-radius: 17% / 7.8%; box-shadow: var(--glow), inset 0 0 0 1.5px #3a465c; flex: none; }
.device img { width: 100%; height: auto; border-radius: 14.4% / 6.6%; display: block; background: #f2f2f7; }
.device.sm { --w: 190px; } .device.md { --w: 230px; } .device.lg { --w: 300px; } .device.xl { --w: 330px; }
.cluster { display: flex; justify-content: center; align-items: flex-end; gap: 0; }
.cluster .device + .device { margin-left: -42px; }
.cluster .device:nth-child(odd) { transform: translateY(26px); }
.cluster.tight .device + .device { margin-left: -24px; }

/* Hero */
.hero2 { position: relative; overflow: hidden; padding: 72px 0 40px; background:
  radial-gradient(900px 520px at 88% -8%, #d9f3ec 0, transparent 62%),
  radial-gradient(800px 520px at -8% 10%, #dcecfb 0, transparent 60%), #fff; }
.hero2 .wrap { display: grid; grid-template-columns: 1.02fr 1fr; gap: 40px; align-items: center; }
.hero2 h1 { font-size: clamp(2.3rem, 5.4vw, 3.9rem); letter-spacing: -.03em; }
.hero2 h1 em { font-style: normal; background: linear-gradient(120deg, var(--teal), var(--blue)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-stage { position: relative; min-height: 560px; }
.hero-stage .device { position: absolute; }
.hero-stage .d1 { --w: 255px; left: 0; top: 70px; transform: rotate(-6deg); z-index: 1; }
.hero-stage .d2 { --w: 300px; left: 50%; top: 0; transform: translateX(-50%); z-index: 3; }
.hero-stage .d3 { --w: 255px; right: 0; top: 80px; transform: rotate(6deg); z-index: 2; }
.float { position: absolute; z-index: 5; display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 16px; padding: 10px 14px; box-shadow: 0 14px 34px rgba(11,42,74,.18); font-weight: 700; font-size: .85rem; color: var(--navy); line-height: 1.2; }
.float small { display: block; font-weight: 500; color: var(--muted); font-size: .74rem; }
.float .dot { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #e3f6f1; }
.float .dot svg { width: 18px; height: 18px; stroke: var(--teal); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.f1 { left: -10px; top: 20px; } .f2 { right: -6px; bottom: 90px; } .f3 { left: 6px; bottom: 30px; }
.works-with { padding: 26px 0 8px; text-align: center; }
.works-with p { margin: 0 0 14px; font-size: .85rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

/* What is it */
.what { background: #fff; }
.what-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 40px; }
.what-grid .card h3 { display: flex; align-items: center; gap: 10px; }
.tag { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: 3px 10px; border-radius: 999px; }
.tag.problem { background: #fff1ec; color: #d2512a; } .tag.answer { background: #e3f6f1; color: var(--teal); } .tag.who { background: #e8f1fc; color: var(--blue); }
.loop { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: l; margin-top: 44px; }
.loop .step { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 20px 20px; box-shadow: var(--shadow); }
.loop .step::before { counter-increment: l; content: counter(l); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(135deg, var(--teal), var(--blue)); color: #fff; font-weight: 800; margin-bottom: 12px; }
.loop .step::after { content: ""; position: absolute; right: -14px; top: 38px; width: 10px; height: 10px; border-top: 3px solid #b6c6d8; border-right: 3px solid #b6c6d8; transform: rotate(45deg); }
.loop .step:last-child::after { display: none; }
.loop h3 { font-size: 1.05rem; margin-bottom: 6px; } .loop p { margin: 0; color: var(--muted); font-size: .94rem; }

/* Feature showcase rows */
.show { padding: 84px 0; }
.show.alt { background: var(--soft); }
.show .wrap { display: grid; grid-template-columns: 1fr 1.05fr; gap: 64px; align-items: center; }
.show.rev .wrap { grid-template-columns: 1.05fr 1fr; }
.show.rev .copy { order: 2; }
.show h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); letter-spacing: -.02em; }
.show .copy > p { color: var(--muted); font-size: 1.06rem; }
.show .check li { margin-bottom: 12px; }
.show .check strong { color: var(--navy); }
.stage { display: flex; justify-content: center; position: relative; padding: 20px 0 30px; }
.stage::before { content: ""; position: absolute; inset: 6% 8%; border-radius: 40px; background: linear-gradient(135deg, rgba(13,158,143,.14), rgba(28,123,208,.14)); transform: rotate(-3deg); z-index: 0; }
.show.alt .stage::before { background: linear-gradient(135deg, rgba(28,123,208,.14), rgba(250,119,77,.12)); }
.stage > * { position: relative; z-index: 1; }
.crop { border-radius: 20px; box-shadow: var(--glow); border: 1px solid var(--line); background: #fff; width: min(100%, 440px); }
.stack { display: flex; flex-direction: column; align-items: center; gap: 22px; }

/* Gallery */
.gallery-wrap { position: relative; }
.gallery { display: flex; gap: 26px; overflow-x: auto; padding: 10px max(20px, calc((100vw - var(--max)) / 2)) 40px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.gallery figure { margin: 0; scroll-snap-align: center; text-align: center; flex: none; }
.gallery figcaption { margin-top: 16px; font-weight: 700; color: var(--navy); font-size: .95rem; }
.gallery figcaption small { display: block; font-weight: 500; color: var(--muted); font-size: .84rem; }

/* Dark band */
.band { background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #d6e4f3; }
.band h2, .band h3 { color: #fff; } .band .eyebrow { color: #7fe0d0; }
.band .card { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.14); color: #d6e4f3; }
.band .card p { color: #b9cde2; }
.band .check li { color: #e3eefa; }
.band a { color: #8fd0ff; }

.integ { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.integ .card { text-align: left; }
.integ h3 { display: flex; align-items: center; gap: 10px; }
.integ .ic { width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, #e1f5f1, #e0eefb); display: grid; place-items: center; flex: none; }
.integ .ic svg { width: 20px; height: 20px; stroke: var(--blue); fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

@media (max-width: 1000px) {
  .hero2 .wrap, .show .wrap, .show.rev .wrap { grid-template-columns: 1fr; gap: 36px; }
  .show.rev .copy { order: 0; }
  .hero-stage { min-height: 520px; max-width: 640px; margin-inline: auto; width: 100%; }
  .what-grid, .integ { grid-template-columns: 1fr; }
  .loop { grid-template-columns: repeat(2, 1fr); }
  .loop .step::after { display: none; }
}
@media (max-width: 640px) {
  .hero2 { padding: 40px 0 20px; }
  .hero-stage { min-height: 400px; }
  .hero-stage .d1, .hero-stage .d3 { --w: 150px; top: 60px; } .hero-stage .d2 { --w: 200px; }
  .float { font-size: .75rem; padding: 8px 10px; } .f2 { bottom: 40px; } .f3 { display: none; }
  .show { padding: 56px 0; }
  .device.xl { --w: 280px; } .device.lg { --w: 250px; } .device.md { --w: 200px; }
  .cluster .device.md { --w: 150px; } .cluster .device + .device { margin-left: -28px; }
  .loop { grid-template-columns: 1fr; }
}
.cluster.tri .device { --w: 196px; }
.cluster.tri .device + .device { margin-left: -30px; }
@media (max-width: 640px) { .cluster.tri .device { --w: 138px; } .cluster.tri .device + .device { margin-left: -22px; } }
