:root {
  --ink: #13202f;
  --steel: #526173;
  --line: #dde3ea;
  --mist: #f2f5f8;
  --paper: #ffffff;
  --navy: #1e3a5f;
  --navy-deep: #142a46;
  --frame: #1c232d;
  --max: 1280px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
}

img { max-width: 100%; }
a { color: var(--navy); text-underline-offset: 3px; }
a:hover { color: var(--navy-deep); }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 6px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 32px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--paper); padding: 8px 12px; z-index: 30; }

/* Type */
h1, h2, h3 { color: var(--ink); font-weight: 600; letter-spacing: -0.02em; }
h1 { font-size: clamp(38px, 4.4vw, 60px); line-height: 1.06; letter-spacing: -0.035em; margin: 0 0 24px; }
h2 { font-size: clamp(28px, 3vw, 40px); line-height: 1.12; letter-spacing: -0.03em; margin: 0 0 16px; }
h3 { font-size: 19px; line-height: 1.3; margin: 0 0 8px; }
.lead { font-size: 20px; line-height: 1.55; color: var(--steel); max-width: 36em; margin: 0 0 32px; }
.muted { color: var(--steel); }

/* Header and menu */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgb(255 255 255 / 0.9);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid rgb(19 32 47 / 0.08);
}
.site-header .wrap { position: relative; display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: 18px; letter-spacing: -0.01em; }
.brand:hover { color: var(--ink); }
.brand img { width: 34px; height: 34px; }

.menu-button {
  display: inline-flex; align-items: center; gap: 10px;
  height: 44px; padding: 0 16px 0 14px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--paper); color: var(--ink);
  font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; text-decoration: none;
}
.menu-button:hover { border-color: var(--navy); color: var(--ink); }
.menu-icon { display: grid; gap: 4px; width: 18px; }
.menu-icon span { display: block; height: 2px; border-radius: 2px; background: currentColor; transition: transform 0.2s, opacity 0.2s; }
.menu-button[aria-expanded="true"] .menu-icon span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-button[aria-expanded="true"] .menu-icon span:nth-child(2) { opacity: 0; }
.menu-button[aria-expanded="true"] .menu-icon span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.menu-panel {
  position: absolute; top: 64px; right: 32px; width: 300px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 24px 48px -16px rgb(19 32 47 / 0.25);
  padding: 10px;
}
.menu-panel[hidden] { display: none; }
.menu-panel ul { list-style: none; margin: 0; padding: 0; }
.menu-panel a {
  display: flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 10px;
  color: var(--ink); text-decoration: none; font-weight: 500;
}
.menu-panel a:hover { background: var(--mist); color: var(--ink); }
.menu-panel .sub a { padding-left: 30px; color: var(--steel); font-weight: 400; min-height: 40px; }
.menu-panel a[aria-current="page"] { background: var(--mist); color: var(--navy); box-shadow: inset 3px 0 0 var(--navy); }
@media (prefers-reduced-motion: reduce) { .menu-icon span { transition: none; } }

/* Buttons */
.btn { display: inline-flex; align-items: center; min-height: 46px; padding: 0 22px; border-radius: 999px; font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid var(--navy); }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-deep); color: #fff; }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Home */
.hero { position: relative; overflow: hidden; padding: 112px 0 96px; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: radial-gradient(rgb(30 58 95 / 0.16) 1.2px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 55% 80% at 85% 40%, #000 15%, transparent 70%);
  mask-image: radial-gradient(ellipse 55% 80% at 85% 40%, #000 15%, transparent 70%);
}
.hero h1 { max-width: 13em; }

.facts { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts dl { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; }
.facts dl > div { padding: 26px 24px 26px 0; }
.facts dl > div + div { padding-left: 24px; border-left: 1px solid var(--line); }
.facts dt { font-size: 14px; color: var(--steel); }
.facts dd { margin: 2px 0 0; font-weight: 600; }

.section { padding: 104px 0; }
.split { display: grid; grid-template-columns: 1fr 1.4fr; gap: 64px; align-items: start; }
.split p { margin: 0; font-size: 20px; line-height: 1.6; color: #26364a; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 48px; }
.steps > div { border-top: 2px solid var(--navy); padding-top: 20px; }
.steps p { margin: 0; color: var(--steel); }

.principles { background: var(--navy-deep); color: #e6edf5; padding: 96px 0; }
.principles h2 { color: #fff; }
.principles .intro { color: #b8c6d6; margin: 0; }
.principles-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; margin-top: 56px; }
.principles h3 { color: #fff; margin-top: 18px; }
.principles-grid p { color: #b8c6d6; margin: 0; font-size: 16px; }
.principles svg { width: 28px; height: 28px; stroke: #8fb4dc; }

.teaser { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.teaser h2 { margin-bottom: 6px; }
.teaser p { margin: 0; color: var(--steel); }

/* Inner pages */
.page-head { background: var(--mist); border-bottom: 1px solid var(--line); padding: 80px 0 64px; }
.page-head h1 { font-size: clamp(36px, 4.2vw, 54px); max-width: 16em; }
.page-head .lead { margin-bottom: 0; }
.page-body { padding: 72px 0 112px; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: 24px; letter-spacing: -0.015em; margin: 48px 0 12px; }
.prose p, .prose li { color: #26364a; }
.prose li + li { margin-top: 8px; }
.wrap.prose > * { max-width: 44em; }
.updated { color: var(--steel); margin: 12px 0 0; }

/* Products overview */
.product-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.product-row { display: grid; grid-template-columns: 72px 1fr auto; gap: 28px; align-items: center; padding: 36px 0; border-bottom: 1px solid var(--line); }
.product-row img { width: 72px; height: 72px; border-radius: 18px; box-shadow: 0 2px 6px rgb(19 32 47 / 0.18); }
.product-row h2 { font-size: 26px; margin: 0 0 4px; }
.product-row p { margin: 0; color: var(--steel); max-width: 40em; }
.product-row .badge { margin-bottom: 10px; }

/* Product page */
.product-page { padding: 72px 0 112px; }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.product-head { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.product-head img { width: 64px; height: 64px; border-radius: 16px; box-shadow: 0 2px 6px rgb(19 32 47 / 0.18); }
.product-head h1 { margin: 0; font-size: clamp(38px, 4vw, 54px); }
.product-page .lead { font-size: 19px; margin-bottom: 24px; }
.features { list-style: none; padding: 0; margin: 0 0 32px; display: grid; gap: 12px; }
.features li { position: relative; padding-left: 30px; }
.features li::before {
  content: ""; position: absolute; left: 0; top: 0.3em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--mist) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%231e3a5f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.help-line { margin: 28px 0 0; color: var(--steel); font-size: 15px; }

.product-media {
  position: relative; height: 560px; border-radius: 28px; overflow: hidden;
  display: flex; justify-content: center; align-items: flex-start; gap: 24px; padding-top: 56px;
}
.media-tradeseal { background: #1d1814; }
.media-vankai { background: #15233b; }
.media-jassel { background: #0c1b2e; }
.media-caption { position: absolute; left: 20px; top: 16px; margin: 0; font-size: 13px; font-weight: 500; color: #fff; background: rgb(255 255 255 / 0.14); padding: 6px 12px; border-radius: 999px; }

/* Phone frame: screenshots sit inside a CSS-drawn device */
.phone {
  width: 260px; aspect-ratio: 390 / 844; flex: none;
  border: 9px solid var(--frame); border-radius: 40px;
  background: var(--frame); overflow: hidden;
  box-shadow: 0 40px 70px -24px rgb(0 0 0 / 0.6);
}
.phone img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 31px; }
.pair .phone { width: min(200px, calc(50% - 12px)); }
.pair .phone:nth-child(2) { margin-top: 48px; }

.badge { display: inline-block; font-size: 13px; font-weight: 600; padding: 4px 12px; border-radius: 999px; margin-bottom: 18px; }
.badge-live { background: #dcfce7; color: #166534; }
.badge-beta { background: #e0e7ff; color: #3730a3; }
.badge-dev { background: #eef1f4; color: #364152; }

/* Support cards */
.app-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.app-card { border: 1px solid var(--line); border-radius: 20px; padding: 28px; display: flex; flex-direction: column; }
.app-card img { width: 56px; height: 56px; border-radius: 14px; margin-bottom: 18px; box-shadow: 0 2px 6px rgb(19 32 47 / 0.18); }
.app-card p { color: var(--steel); margin: 0 0 24px; flex: 1; }
.app-card .btn { align-self: flex-start; }

/* Contact */
.contact-card { background: var(--mist); border: 1px solid var(--line); border-radius: 20px; padding: 36px; max-width: 36em; }
.contact-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.contact-list strong { display: inline-block; min-width: 96px; }

table { width: 100%; border-collapse: collapse; margin-top: 16px; }
th, td { overflow-wrap: break-word; text-align: left; padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 14px; color: var(--steel); font-weight: 600; }

/* Footer */
.site-footer { background: var(--mist); border-top: 1px solid var(--line); padding: 64px 0 32px; font-size: 15px; color: var(--steel); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer-grid p { margin: 0; max-width: 22em; }
.footer-grid h2 { font-size: 15px; letter-spacing: 0; color: var(--ink); margin: 6px 0 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: var(--steel); text-decoration: none; }
.site-footer a:hover { color: var(--ink); text-decoration: underline; }
.footer-brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; margin-bottom: 14px; }
.footer-brand img { width: 28px; height: 28px; }
.footer-bottom { margin: 48px 0 0; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; }

@media (max-width: 960px) {
  .split, .product-grid { grid-template-columns: 1fr; gap: 40px; }
  .steps { grid-template-columns: 1fr; gap: 28px; }
  .principles-grid { grid-template-columns: repeat(2, 1fr); }
  .app-cards { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .facts dl { grid-template-columns: repeat(2, 1fr); }
  .facts dl > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .facts dl > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .product-media { height: 500px; }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .brand span { display: none; }
  .menu-panel { right: 16px; left: 16px; width: auto; }
  .hero { padding: 64px 0 56px; }
  .lead { font-size: 18px; }
  .facts dl > div, .facts dl > div + div { padding: 18px 12px 18px 0; }
  .facts dl > div:nth-child(2n) { padding-left: 12px; }
  .section { padding: 64px 0; }
  .split p { font-size: 18px; }
  .principles { padding: 64px 0; }
  .principles-grid { grid-template-columns: 1fr; gap: 32px; margin-top: 40px; }
  .page-head { padding: 56px 0 44px; }
  .page-body, .product-page { padding: 48px 0 80px; }
  .product-row { grid-template-columns: 56px 1fr; gap: 16px; }
  .product-row img { width: 56px; height: 56px; border-radius: 14px; }
  .product-row .btn { grid-column: 2; justify-self: start; }
  .product-media { height: 420px; padding-top: 36px; gap: 14px; }
  .phone { width: 200px; border-width: 7px; border-radius: 32px; }
  .phone img { border-radius: 25px; }
  .pair .phone { width: 150px; border-width: 6px; border-radius: 26px; }
  .pair .phone img { border-radius: 20px; }
  .pair .phone:nth-child(2) { margin-top: 32px; }
  .contact-card { padding: 24px; }
  th, td { padding: 12px 8px; font-size: 15px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px 24px; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}

/* Card titles are h2 for document outline but sized as small headings */
.app-card h2, .contact-card h2 { font-size: 20px; letter-spacing: -0.01em; margin: 0 0 8px; }
.contact-card h2 { margin-bottom: 18px; }

/* Short pages on tall screens: footer sits at the bottom of the window, no blank band below it */
body { min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; }
