/* =========================================================
   STBA Global — design system
   Brand: ink #111315, blue #1F4FD8 (on dark #5B8CFF), off-white #F5F5F4, Archivo.
   Motif: the square full stop from the logo (.sq), square corners, hairline grid.
   ========================================================= */

@font-face {
	font-family: "Archivo";
	src: url(../fonts/archivo-latin-wght-normal.woff2) format("woff2");
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
	font-family: "Archivo";
	src: url(../fonts/archivo-latin-ext-wght-normal.woff2) format("woff2");
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
	--ink: #111315;
	--ink-2: #1B1E22;
	--ink-3: #2A2E33;
	--stone: #5B6068;
	--stone-2: #8A8F96;
	--line: #E4E4E1;
	--line-dark: rgba(245, 245, 244, .12);
	--paper: #F5F5F4;
	--white: #FFFFFF;
	--blue: #1F4FD8;
	--blue-hover: #1840B0;
	--blue-light: #5B8CFF;
	--blue-tint: #EEF2FD;
	--ok: #1E7A3C;
	--err: #B42318;

	--font: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

	--fs-xs: .8125rem;
	--fs-sm: .9375rem;
	--fs-md: 1.0625rem;
	--fs-lg: clamp(1.125rem, 1rem + .4vw, 1.3125rem);
	--fs-h3: clamp(1.1875rem, 1.1rem + .3vw, 1.375rem);
	--fs-h2: clamp(1.875rem, 1.4rem + 1.9vw, 3rem);
	--fs-h1: clamp(2.5rem, 1.6rem + 3.8vw, 4.75rem);

	--sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px;
	--sp-6: 32px; --sp-7: 48px; --sp-8: 64px; --sp-9: 96px; --sp-10: 128px;

	--wrap: 1240px;
	--gutter: clamp(16px, 4vw, 40px);
	--hdr-h: 76px;
	--ease: cubic-bezier(.2, .7, .2, 1);
	--shadow: 0 1px 2px rgba(17, 19, 21, .04), 0 12px 32px -16px rgba(17, 19, 21, .18);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--hdr-h) + 16px); }
body { margin: 0; font-family: var(--font); font-size: var(--fs-md); line-height: 1.6; color: var(--ink); background: var(--white); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--blue); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--blue-hover); }
h1, h2, h3, h4 { margin: 0; line-height: 1.12; letter-spacing: -.02em; font-weight: 700; text-wrap: balance; }
p { margin: 0 0 1em; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.sec--ink :focus-visible, .hero :focus-visible, .ftr :focus-visible { outline-color: var(--blue-light); }
::selection { background: var(--blue); color: #fff; }
#main:focus { outline: 0; }

.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--ink); color: #fff; padding: 12px 18px; font-weight: 600; }
.skip:focus { top: 12px; color: #fff; }

/* ---------- Layout ---------- */
.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.wrap--narrow { max-width: calc(760px + var(--gutter) * 2); }
.sec { padding-block: clamp(64px, 5vw + 40px, 128px); }
.sec--paper { background: var(--paper); }
.sec--ink { background: var(--ink); color: var(--paper); }
.sec__head { max-width: 760px; margin-bottom: clamp(40px, 4vw, 64px); }
.sec__head--split { max-width: none; display: grid; gap: var(--sp-5); align-items: end; }
@media (min-width: 900px) { .sec__head--split { grid-template-columns: 1.1fr 1fr; gap: var(--sp-8); } }

.split { display: grid; gap: var(--sp-6); }
@media (min-width: 900px) { .split { grid-template-columns: 5fr 7fr; gap: var(--sp-9); } }

/* ---------- Type ---------- */
.h2 { font-size: var(--fs-h2); font-weight: 750; }
.h3 { font-size: var(--fs-h3); }
.lead { font-size: var(--fs-lg); line-height: 1.55; color: var(--ink); }
.sec--ink .lead { color: var(--paper); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 var(--sp-4); font-size: var(--fs-xs); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--stone); }
.eyebrow--light { color: #B9BCC1; }
.sq { display: inline-block; width: 10px; height: 10px; background: var(--blue); flex: none; }
.eyebrow--light .sq, .sec--ink .sq { background: var(--blue-light); }
.num { font-variant-numeric: tabular-nums; font-weight: 600; letter-spacing: .02em; }

/* ---------- Icons ---------- */
.icon { width: 24px; height: 24px; flex: none; }

/* ---------- Buttons ---------- */
.btn { --bg: var(--ink); --fg: #fff; --bd: var(--bg); display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 12px 22px; border: 1.5px solid var(--bd); border-radius: 0; background: var(--bg); color: var(--fg); font-weight: 600; font-size: var(--fs-sm); line-height: 1.2; letter-spacing: .005em; text-decoration: none; cursor: pointer; transition: background-color .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease), transform .2s var(--ease); }
.btn:hover { color: var(--fg); }
.btn .icon { width: 18px; height: 18px; transition: transform .2s var(--ease); }
.btn:hover .icon { transform: translateX(3px); }
.btn--primary { --bg: var(--blue); --bd: var(--blue); }
.btn--primary:hover { --bg: var(--blue-hover); --bd: var(--blue-hover); }
.btn--ghost { --bg: transparent; --fg: var(--paper); --bd: rgba(245, 245, 244, .35); }
.btn--ghost:hover { --bd: var(--paper); --bg: rgba(245, 245, 244, .06); }
.btn--outline { --bg: transparent; --fg: var(--ink); --bd: var(--ink); }
.btn--outline:hover { --bg: var(--ink); --fg: #fff; }
.btn--sm { min-height: 44px; padding: 10px 18px; }
.btn--lg { min-height: 54px; padding: 14px 28px; font-size: var(--fs-md); }
.btn[disabled], .btn[aria-busy="true"] { opacity: .7; cursor: progress; }
.linkbtn { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; text-underline-offset: .18em; font-size: inherit; cursor: pointer; }

/* ---------- Header (inner pages only) ---------- */
.hdr { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.hdr__in { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-5); height: var(--hdr-h); }
.logo { display: block; color: var(--ink); flex: none; }
.logo__svg { width: clamp(190px, 22vw, 250px); height: auto; }

/* ---------- Hero (landing) ---------- */
.hero { position: relative; display: flex; align-items: center; background: var(--ink); color: var(--paper); overflow: hidden; isolation: isolate; }

/* One-screen landing: hero fills the viewport above a slim footer, no page scroll. */
body.landing { height: 100vh; height: 100svh; display: flex; flex-direction: column; overflow: hidden; background: var(--ink); }
body.landing #main { flex: 1 1 auto; min-height: 0; display: flex; }
body.landing .hero { flex: 1 1 auto; min-height: 0; }
/* Safety net on extremely small screens: the content scrolls inside the hero, the page never does. */
body.landing .hero__in { max-height: 100%; overflow-y: auto; scrollbar-width: none; }
body.landing .hero__in::-webkit-scrollbar { display: none; }
body.landing .ftr { flex: none; border-top: 1px solid var(--line-dark); }
body.landing .ftr__bottom { padding-block: clamp(10px, 2vh, 20px); row-gap: 4px; }
@media (max-width: 640px) { body.landing .ftr__bottom { justify-content: flex-start; column-gap: var(--sp-4); } body.landing .footer__legal a { min-height: 28px; } }
.hero__grid { position: absolute; inset: -96px; z-index: -2; background-image: linear-gradient(var(--line-dark) 1px, transparent 1px), linear-gradient(90deg, var(--line-dark) 1px, transparent 1px); background-size: 96px 96px; -webkit-mask-image: radial-gradient(70% 70% at 70% 40%, #000 10%, transparent 75%); mask-image: radial-gradient(70% 70% at 70% 40%, #000 10%, transparent 75%); opacity: 0; animation: gridIn 1.6s .2s var(--ease) forwards, gridDrift 40s linear infinite; }
@keyframes gridIn { to { opacity: .75; } }
@keyframes gridDrift { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(96px, 96px, 0); } }

/* Floating brand squares */
.hero__sq { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero__sq span { position: absolute; display: block; background: var(--blue); opacity: 0; animation: sqIn 1.2s var(--ease) forwards, sqFloat 9s ease-in-out infinite alternate; }
.hero__sq span:nth-child(1) { width: 96px; height: 96px; right: 8%; top: 14%; animation-delay: .9s, 2.1s; }
.hero__sq span:nth-child(2) { width: 32px; height: 32px; right: 22%; top: 58%; background: transparent; border: 1.5px solid var(--blue-light); animation-delay: 1.2s, 2.4s; animation-duration: 1.2s, 11s; }
.hero__sq span:nth-child(3) { width: 14px; height: 14px; right: 12%; bottom: 16%; background: var(--blue-light); animation-delay: 1.5s, 2.7s; animation-duration: 1.2s, 7s; }
@keyframes sqIn { from { opacity: 0; transform: scale(.4); } to { opacity: .9; transform: scale(1); } }
@keyframes sqFloat { from { translate: 0 0; } to { translate: -18px 22px; } }

.hero__in { padding-block: clamp(24px, 6vh, 96px); margin-block: auto; }
.hero__logo { margin: 0 0 clamp(20px, 5vh, 64px); line-height: 0; }
.hero__logo .logo__svg { width: min(640px, 86vw, 80vh); height: auto; color: #fff; }
.hero__logo .logo__svg rect { transform-box: fill-box; transform-origin: center; animation: dotIn .7s 1s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes dotIn { from { transform: scale(0); } to { transform: scale(1); } }
.hero__text { max-width: 760px; }
.hero__lead { font-size: clamp(1rem, .55rem + 1.3vh + .45vw, 1.75rem); line-height: 1.45; font-weight: 400; color: #F5F5F4; letter-spacing: -.01em; }
.hero__sub { margin-top: clamp(12px, 2.4vh, 24px); font-size: clamp(.875rem, .6rem + .8vh + .2vw, 1.1875rem); line-height: 1.6; color: #A9ADB3; max-width: 680px; }
.hero__cta { margin-top: clamp(20px, 4.5vh, 48px); }

/* Entrance */
.anim { opacity: 0; transform: translateY(16px); animation: rise .9s var(--ease) forwards; }
.anim--1 { animation-delay: .15s; }
.anim--2 { animation-delay: .45s; }
.anim--3 { animation-delay: .7s; }
.anim--4 { animation-delay: 1.2s; }
@keyframes rise { to { opacity: 1; transform: none; } }

@media (max-width: 700px) {
	.hero__sq span:nth-child(1) { width: 32px; height: 32px; right: 16px; top: 12px; }
	.hero__sq span:nth-child(2) { right: 18%; top: auto; bottom: 12%; }
	.hero__sq span:nth-child(3) { right: 32px; bottom: 6%; }
}

/* Very short screens (e.g. 360×568): tighten type so everything still fits. */
@media (max-height: 620px) {
	.hero__lead { font-size: .9375rem; line-height: 1.4; }
	.hero__sub { font-size: .8125rem; line-height: 1.5; }
	.hero__cta .btn--lg { min-height: 46px; padding-block: 10px; }
}

/* ---------- Contact side panel ---------- */
.panel { position: fixed; inset: 0; z-index: 80; visibility: hidden; pointer-events: none; transition: visibility 0s .35s; }
.panel:target, .panel.is-open { visibility: visible; pointer-events: auto; transition-delay: 0s; }
.panel__scrim { position: absolute; inset: 0; background: rgba(10, 11, 12, .55); opacity: 0; transition: opacity .3s var(--ease); cursor: default; }
.panel:target .panel__scrim, .panel.is-open .panel__scrim { opacity: 1; }
.panel__box { position: absolute; top: 0; right: 0; bottom: 0; width: min(520px, 100vw); display: flex; flex-direction: column; background: #fff; color: var(--ink); border-left: 4px solid var(--blue); box-shadow: -24px 0 60px -20px rgba(0, 0, 0, .5); transform: translateX(100%); transition: transform .35s var(--ease); outline: 0; }
.panel:target .panel__box, .panel.is-open .panel__box { transform: none; }
.panel.is-closing .panel__box { transform: translateX(100%); }
.panel.is-closing .panel__scrim { opacity: 0; }
.panel__head { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); padding: var(--sp-5) clamp(20px, 4vw, 40px); border-bottom: 1px solid var(--line); }
.panel__t { font-size: var(--fs-h3); font-weight: 700; }
.panel__x { display: inline-grid; place-items: center; width: 44px; height: 44px; margin-right: -10px; color: var(--ink); }
.panel__x:hover { color: var(--blue); }
.panel__body { flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; padding: clamp(20px, 3vh, 32px) clamp(20px, 4vw, 40px) clamp(24px, 4vh, 40px); }
.panel .cform__grid { grid-template-columns: 1fr; gap: var(--sp-4); }
.panel .field textarea { min-height: 140px; }
.panel .cform__foot { margin-top: var(--sp-5); }
@media (max-width: 520px) { .panel__box { border-left: 0; border-top: 4px solid var(--blue); } }

/* ---------- Forms ---------- */
.cform__grid { display: grid; gap: var(--sp-5) var(--sp-5); }
@media (min-width: 640px) { .cform__grid { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: var(--fs-sm); font-weight: 600; color: var(--ink); }
.field .req { color: var(--blue); }
.field .opt { font-weight: 400; color: var(--stone); font-size: var(--fs-xs); margin-left: 4px; }
.field input, .field select, .field textarea { width: 100%; min-height: 50px; padding: 12px 14px; border: 1.5px solid #CFD1D4; border-radius: 0; background: #fff; font-size: 16px; line-height: 1.4; transition: border-color .15s, box-shadow .15s; appearance: none; }
.field textarea { min-height: 150px; resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--stone-2); }
.field input:focus, .field select:focus, .field textarea:focus { outline: 0; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(31, 79, 216, .18); }
.field [aria-invalid="true"] { border-color: var(--err); }
.field [aria-invalid="true"]:focus { box-shadow: 0 0 0 3px rgba(180, 35, 24, .15); }
.select { position: relative; }
.select::after { content: ""; position: absolute; right: 16px; top: 50%; width: 8px; height: 8px; border-right: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.select select { padding-right: 40px; cursor: pointer; }
.field__hint { margin: 0; font-size: var(--fs-xs); color: var(--stone); }
.field__err { margin: 0; font-size: var(--fs-xs); color: var(--err); font-weight: 500; }
.field__err:empty { display: none; }
.field--check { margin-top: var(--sp-5); }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: var(--fs-sm); color: var(--stone); cursor: pointer; }
.check input { flex: none; appearance: none; width: 22px; height: 22px; min-height: 0; padding: 0; margin: 1px 0 0; border: 1.5px solid #9EA2A8; background: #fff; display: grid; place-content: center; cursor: pointer; transition: background-color .15s, border-color .15s; }
.check input::before { content: ""; width: 12px; height: 7px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.check input:checked { background: var(--blue); border-color: var(--blue); }
.check input:checked::before { opacity: 1; }
.check input:disabled { background: var(--stone-2); border-color: var(--stone-2); }
.check input[aria-invalid="true"] { border-color: var(--err); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.cform__foot { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-4) var(--sp-5); margin-top: var(--sp-6); }
.cform__note { display: flex; gap: 8px; align-items: flex-start; margin: 0; flex: 1 1 260px; font-size: var(--fs-xs); color: var(--stone); }
.cform__note .icon { width: 16px; height: 16px; margin-top: 2px; color: var(--stone-2); }
.cform__note a { color: inherit; }
.cform__status { margin-bottom: var(--sp-5); }
.notice { margin: 0; padding: 14px 16px; font-size: var(--fs-sm); border-left: 3px solid; }
.notice--ok { background: #ECF6EF; border-color: var(--ok); color: #14532D; }
.notice--err { background: #FDF0EE; border-color: var(--err); color: #7A1A12; }
.cform.is-sent .cform__grid, .cform.is-sent .field--check, .cform.is-sent .cform__foot { display: none; }
.spinner { width: 18px; height: 18px; border: 2px solid rgba(255, 255, 255, .4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.grecaptcha-badge { visibility: hidden !important; }

/* ---------- Page header + prose ---------- */
.phead { background: var(--ink); color: var(--paper); padding-block: clamp(56px, 6vw, 96px) clamp(40px, 4vw, 64px); }
.phead__t { font-size: var(--fs-h2); font-weight: 800; color: #fff; max-width: 22ch; }
.phead__meta { margin-top: var(--sp-4); color: var(--stone-2); font-size: var(--fs-sm); }
.prose { font-size: var(--fs-md); color: #2B2F34; }
.prose > * + * { margin-top: 1em; }
.prose h2 { font-size: clamp(1.375rem, 1.2rem + .7vw, 1.75rem); margin-top: 2em; color: var(--ink); }
.prose h3 { font-size: var(--fs-h3); margin-top: 1.6em; color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose ul { list-style: square; }
.prose ul li::marker { color: var(--blue); }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: .4em; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--paper); font-weight: 600; }
.prose blockquote { margin: 1.5em 0; padding-left: 1em; border-left: 3px solid var(--blue); color: var(--stone); }
.list li + li { margin-top: var(--sp-6); padding-top: var(--sp-6); border-top: 1px solid var(--line); }
.list a { color: var(--ink); text-decoration: none; }

/* ---------- Footer ---------- */
.ftr { background: var(--ink); color: var(--stone-2); font-size: var(--fs-xs); }
.ftr__bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-3) var(--sp-6); padding-block: var(--sp-5); }
.ftr__bottom p { margin: 0; }
.ftr a { color: var(--stone-2); text-decoration: none; }
.ftr a:hover { color: #fff; }
.ftr__legal { display: flex; flex-wrap: wrap; gap: var(--sp-4); }
.footer__legal { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5); }
.footer__legal a, .footer__legal .linkbtn { color: var(--stone-2); display: inline-flex; min-height: 32px; align-items: center; }
.footer__legal a:hover, .footer__legal .linkbtn:hover { color: #fff; }
.builtby { display: inline-flex; align-items: center; gap: 8px; opacity: .8; transition: opacity .2s; }
.builtby:hover { opacity: 1; }
.builtby img { width: 64px; height: auto; }

/* ---------- Cookie consent ---------- */
.consent { position: fixed; z-index: 90; left: 16px; right: 16px; bottom: 16px; max-width: 440px; padding: var(--sp-5); background: #fff; color: var(--ink); border-top: 4px solid var(--blue); box-shadow: 0 24px 60px -20px rgba(17, 19, 21, .45); font-size: var(--fs-sm); }
.consent__t { font-weight: 700; font-size: var(--fs-md); margin-bottom: var(--sp-2); }
.consent p { color: var(--stone); }
.consent__opts { display: grid; gap: var(--sp-3); margin: var(--sp-4) 0; }
.consent__btns { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
.consent__btns .btn { flex: 1 1 auto; }

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- Environment ribbon ---------- */
body.env-staging::after { content: "STAGING"; position: fixed; left: 8px; bottom: 8px; z-index: 999; padding: 4px 8px; background: #B26B00; color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .1em; pointer-events: none; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.anim, .hero__grid, .hero__sq span { opacity: 1 !important; transform: none !important; animation: none !important; }
	.hero__grid { opacity: .75 !important; }
	.hero__sq span { opacity: .9 !important; }
	.panel__box, .panel__scrim { transition: none !important; }
	*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
	.js .reveal { opacity: 1; transform: none; }
}

@media print {
	.hdr, .ftr, .consent, .hero__grid, .hero__sq, .panel { display: none !important; }
	.hero, .sec--ink, .phead { background: #fff !important; color: #000 !important; }
}
