/* =========================================================
   Professional polish layer (loaded after site.css)
   Design tokens, header, buttons, cards, motion details
   and the hero logo motion graphic.
   ========================================================= */
:root {
    --ink: #0f1b3d;
    --muted: #4c5870;
    --line: #e4e8f1;
    --surface: #f5f7fb;
    --ease-out: cubic-bezier(.2, .8, .2, 1);
    --ease-io: cubic-bezier(.65, 0, .35, 1);
    --r-sm: 6px;
    --r-md: 12px;
    --shadow-sm: 0 1px 2px rgba(15, 27, 61, .06), 0 2px 8px rgba(15, 27, 61, .05);
    --shadow-md: 0 4px 12px rgba(15, 27, 61, .08), 0 16px 40px rgba(15, 27, 61, .10);
    --shadow-lg: 0 10px 30px rgba(15, 27, 61, .14), 0 30px 80px rgba(15, 27, 61, .16);
}

html { scroll-padding-top: 90px; }
body { font-size: 15px; line-height: 1.8; color: var(--muted); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
::selection { background: var(--red); color: #fff; }
h1, h2, h3, h4 { color: var(--ink); letter-spacing: -.012em; text-wrap: balance; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 2px; }

/* ---------- scroll progress + back to top ---------- */
.scroll-progress { position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 900; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, var(--red), var(--blue)); pointer-events: none; }
.to-top { position: fixed; right: 22px; bottom: 22px; z-index: 800; width: 46px; height: 46px; border: 0; border-radius: 50%; background: var(--navy); color: #fff; cursor: pointer; box-shadow: var(--shadow-md); display: grid; place-items: center; opacity: 0; visibility: hidden; transform: translateY(12px); transition: opacity .3s, transform .3s var(--ease-out), visibility .3s, background .2s; }
.to-top.is-shown { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--red); }
.to-top svg { width: 18px; height: 18px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: .6em; border-radius: 999px; padding: .75em 1.7em; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; background: linear-gradient(135deg, var(--navy), #1d2a9a); box-shadow: 0 6px 18px rgba(18, 18, 95, .28); transition: transform .3s var(--ease-out), box-shadow .3s, background .3s; }
.btn::after { content: "\2192"; font-size: 1.2em; line-height: 1; transition: transform .3s var(--ease-out); }
.btn:hover { background: linear-gradient(135deg, #1b1b86, #2a3ad0); transform: translateY(-2px); box-shadow: 0 12px 28px rgba(18, 18, 95, .36); }
.btn:hover::after { transform: translateX(4px); }
.btn:active { transform: translateY(0); }
.hero-band .btn { background: #fff; color: var(--navy); box-shadow: 0 10px 26px rgba(0, 0, 0, .22); }
.hero-band .btn:hover { background: var(--navy-deep); color: #fff; }
form .btn[type=submit] { border: 0; }

/* ---------- section titles ---------- */
.background h2, .services-main h2, .clients h2, .about h2, .founders h2, .port-row h2, .history-card h2 { position: relative; padding-bottom: .55em; }
.background h2::after, .services-main h2::after, .about h2::after, .port-row h2::after { content: ""; position: absolute; left: 0; bottom: 0; width: 64px; height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--red), #ff6b3d); }
.clients h2::after, .founders h2::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 64px; height: 3px; margin-left: -32px; border-radius: 3px; background: linear-gradient(90deg, var(--red), #ff6b3d); }
.clients h2, .founders h2 { text-align: center; }
.expertise h2::after { content: ""; display: block; width: 64px; height: 3px; margin-top: .5em; border-radius: 3px; background: var(--red); }
.underlined { border-bottom: 0; position: relative; }
.underlined::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--ink) 0 30%, var(--line) 30%); }

/* ---------- home hero ---------- */
.hero-home::before { content: ""; position: absolute; inset: 0; z-index: 1; background: radial-gradient(ellipse at 50% 38%, rgba(5, 15, 60, 0) 0%, rgba(5, 15, 60, .38) 100%), linear-gradient(rgba(5, 15, 60, .18), rgba(5, 15, 60, 0) 30%, rgba(5, 15, 60, .5)); pointer-events: none; }
.hero-home .logo-motion { z-index: 2; }
.scroll-cue { position: absolute; z-index: 2; left: 50%; bottom: 26px; width: 26px; height: 42px; margin-left: -13px; border: 2px solid rgba(255, 255, 255, .85); border-radius: 14px; }
.scroll-cue::after { content: ""; position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #fff; animation: cue 1.8s var(--ease-io) infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }
.hero-band::before { background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, .14), transparent 45%), linear-gradient(160deg, rgba(42, 116, 184, .95), rgba(13, 61, 130, .96)); }
.hero-band h2 { font-size: clamp(34px, 4.6vw, 56px); letter-spacing: .01em; text-shadow: 0 6px 30px rgba(0, 0, 0, .25); }
.hero-band p { font-size: 14px; letter-spacing: .04em; opacity: .92; margin-bottom: 22px; }

/* ---------- tiles / cards ---------- */
.tiles-row { gap: 0; box-shadow: var(--shadow-md); margin-top: -64px; position: relative; z-index: 3; border-radius: var(--r-md); overflow: hidden; }
.tile { position: relative; overflow: hidden; transition: filter .3s, transform .5s var(--ease-out); font-size: 12.5px; letter-spacing: .05em; }
.tile::before { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, .22) 50%, transparent 70%); transform: translateX(-120%); transition: transform .8s var(--ease-out); }
.tile:hover::before { transform: translateX(120%); }
.tile img { transition: transform .5s var(--ease-out); }
.tile:hover img { transform: translateY(-4px) scale(1.12); }
.tile span { position: relative; padding-bottom: 8px; }
.tile span::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 0; height: 2px; background: #fff; transition: width .4s var(--ease-out), left .4s var(--ease-out); }
.tile:hover span::after { width: 100%; left: 0; }
.tiles-photo { transition: transform 1.2s var(--ease-out); }
.tiles-row:hover .tiles-photo { transform: scale(1.04); }
.tiles-row > :last-child { overflow: hidden; }

.features { background: linear-gradient(160deg, #15156d, var(--navy-deep)); }
.feature-cols > div { padding: 28px 26px; border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--r-md); background: rgba(255, 255, 255, .04); transition: transform .4s var(--ease-out), background .3s, border-color .3s; }
.feature-cols > div:hover { transform: translateY(-6px); background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .28); }
.feature-cols h4 { font-size: 15px; letter-spacing: .02em; }
.feature-cols p { font-size: 12.5px; }
.video-strip { border-radius: var(--r-md); box-shadow: var(--shadow-lg); overflow: hidden; }
.play { transition: transform .4s var(--ease-out), background .3s; }
.video-strip:hover .play { transform: scale(1.12); background: rgba(255, 255, 255, .15); }

.port-list .num { transition: background .3s, color .3s, transform .3s var(--ease-out); }
.port-list li:hover .num { background: var(--red); color: #fff; transform: scale(1.1); }

.framed { border: 0; border-radius: var(--r-md); box-shadow: var(--shadow-lg); padding: 10px; transition: transform .5s var(--ease-out), box-shadow .5s; }
.framed:hover { transform: translateY(-4px); box-shadow: 0 14px 36px rgba(15, 27, 61, .18), 0 40px 90px rgba(15, 27, 61, .2); }
.people.framed:hover { transform: none; }

/* ---------- inner pages ---------- */
.port-row img { border-radius: var(--r-md); box-shadow: var(--shadow-md); transition: transform .6s var(--ease-out), box-shadow .6s; }
.port-row:hover img { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.port-row:nth-of-type(even) { background: var(--surface); }
.hero-ports-text { border-radius: var(--r-md); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: var(--shadow-lg); border: 1px solid rgba(255, 255, 255, .12); }
.tab-cards a { border-radius: var(--r-md); border: 1px solid rgba(255, 255, 255, .14); transition: transform .4s var(--ease-out), background .3s, border-color .3s; }
.tab-cards a:hover { transform: translateY(-6px); background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .4); }
.port-section img.full, .expenses { border-radius: var(--r-md); box-shadow: var(--shadow-md); }
.facilities { border-radius: var(--r-md); overflow: hidden; box-shadow: var(--shadow-md); }

.history-card { box-shadow: var(--shadow-lg); }
.timeline li { padding: 18px 14px; border-radius: var(--r-md); transition: background .3s, transform .4s var(--ease-out), box-shadow .3s; }
.timeline li:hover { background: #fff; transform: translateY(-6px); box-shadow: var(--shadow-md); }
.timeline img { transition: transform .5s var(--ease-out); }
.timeline li:hover img { transform: rotate(-8deg) scale(1.08); }
.founder-grid figure { transition: transform .4s var(--ease-out); }
.founder-grid figure:hover { transform: translateY(-5px); }
.founder-grid img, .people img { box-shadow: 0 6px 20px rgba(15, 27, 61, .2); transition: transform .4s var(--ease-out); }
.founder-grid figure:hover img { transform: scale(1.08); }
.pill-nav { -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); background: rgba(255, 255, 255, .06); }

.checks li { padding-left: 28px; }
.checks li::before { content: "\2713"; display: grid; place-items: center; width: 18px; height: 18px; top: 7px; border-radius: 50%; background: rgba(226, 0, 26, .1); font-size: 11px; }
.expertise { background: linear-gradient(160deg, #15156d, var(--navy-deep)); }
.clients ul { column-gap: 40px; }
.clients li { border-bottom: 1px solid var(--line); padding: 7px 0; transition: color .2s, padding-left .3s var(--ease-out); }
.clients li:hover { color: var(--red); padding-left: 8px; }

/* logos */
.logos { background: var(--surface); border-block: 1px solid var(--line); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); border-image: none; }
.logos img { filter: grayscale(1); opacity: .65; transition: filter .3s, opacity .3s, transform .3s var(--ease-out); }
.logos li:hover img { filter: none; opacity: 1; transform: scale(1.06); }

/* contact + footer */
.cta-card { border-radius: var(--r-md); box-shadow: var(--shadow-lg); }
.cta-schedule { border-radius: var(--r-sm); box-shadow: 0 16px 40px rgba(226, 0, 26, .35); transition: transform .4s var(--ease-out), box-shadow .4s; }
.cta-schedule:hover { transform: translateY(-4px); box-shadow: 0 22px 50px rgba(226, 0, 26, .45); }
.cta-map { border-radius: var(--r-md); overflow: hidden; box-shadow: var(--shadow-md); }
.contact-block .wrap { border-radius: var(--r-md); box-shadow: var(--shadow-lg); }
form input, form textarea { border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); transition: border-color .2s, box-shadow .2s, background .2s; }
form input:focus, form textarea:focus { outline: 0; background: #fff; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(42, 116, 184, .15); }
.map { border-radius: var(--r-md); box-shadow: var(--shadow-md); }
.site-footer { background: linear-gradient(180deg, #162b80, #0e1d63); position: relative; }
.site-footer::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: linear-gradient(90deg, var(--red), var(--blue), var(--red)); }
.site-footer li a { display: inline-block; transition: color .2s, transform .3s var(--ease-out); opacity: .88; }
.site-footer li a:hover { color: #fff; opacity: 1; transform: translateX(5px); }
.copy { letter-spacing: .12em; }
.hero-contact, .hero-services { background-image: radial-gradient(circle at 80% 0, rgba(42, 116, 184, .45), transparent 55%), linear-gradient(160deg, #15156d, var(--navy-deep)); }

/* =========================================================
   Hero logo — motion graphic
   Layers: sonar pings, drawn ring, tick dial, orbit satellite,
   emblem (spins in), wordmark (wipes in), light sheen, waves.
   ========================================================= */
.logo-motion { --cx: 37.3%; position: relative; width: 426px; max-width: 80vw; aspect-ratio: 1400 / 1100; margin-top: 70px; height: fit-content; perspective: 900px; }
.lm-tilt { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .25s var(--ease-out); animation: lm-float 6.5s ease-in-out 3s infinite; will-change: transform, translate; }
.lm-emblem, .lm-wordmark { position: absolute; inset: 0; }
.lm-emblem { filter: drop-shadow(0 8px 22px rgba(0, 10, 50, .38)); }
.lm-wordmark { clip-path: inset(71.5% 0 0 0); }
.lm-emblem img, .lm-wordmark img { display: block; width: 100%; height: 100%; }
/* circular crop is rotation-proof, so the wordmark never shows while the emblem spins */
.lm-emblem img { transform-origin: 50% var(--cx); clip-path: circle(32% at 50% var(--cx)); }
.lm-wordmark img { filter: drop-shadow(0 6px 16px rgba(0, 10, 50, .35)); }
.lm-sheen { position: absolute; inset: 0; pointer-events: none; -webkit-mask: var(--logo) center / 100% 100% no-repeat; mask: var(--logo) center / 100% 100% no-repeat; background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, .95) 50%, transparent 62%) -150% 0 / 250% 100% no-repeat; mix-blend-mode: soft-light; animation: lm-sheen 5.5s var(--ease-io) 3.2s infinite; }

.lm-orbit { position: absolute; width: 105%; aspect-ratio: 1; left: 50%; top: var(--cx); translate: -50% -50%; overflow: visible; pointer-events: none; }
.lm-orbit circle, .lm-orbit line { fill: none; stroke: #fff; vector-effect: non-scaling-stroke; }
.lm-draw { stroke-width: 2; stroke-linecap: round; opacity: .9; stroke-dasharray: 743; stroke-dashoffset: 743; transform: rotate(-90deg); transform-origin: 0 0; }
.lm-dash { stroke-width: 1; stroke-dasharray: 2 9; opacity: .65; transform-origin: 0 0; }
.lm-ticks line { stroke-width: 1; opacity: 0; }
.lm-ticks line.major { stroke-width: 2; }
.lm-sat { transform-origin: 0 0; }
.lm-sat circle { fill: #fff; stroke: none; filter: drop-shadow(0 0 6px #fff); }
.lm-sat .lm-sat-red { fill: var(--red); filter: drop-shadow(0 0 8px var(--red)); }
.lm-ping { position: absolute; left: 50%; top: var(--cx); width: 50.8%; aspect-ratio: 1; translate: -50% -50%; border: 1.5px solid rgba(255, 255, 255, .7); border-radius: 50%; opacity: 0; pointer-events: none; }
.lm-waves { position: absolute; left: 5%; width: 90%; top: 101%; height: 26px; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 22%, #000 78%, transparent); mask-image: linear-gradient(90deg, transparent, #000 22%, #000 78%, transparent); pointer-events: none; }
.lm-waves svg { width: 200%; height: 100%; display: block; }
.lm-waves path { fill: none; stroke: #fff; stroke-width: 1.6; stroke-linecap: round; }
.lm-waves path:nth-child(1) { opacity: .75; animation: lm-wave 5s linear infinite; }
.lm-waves path:nth-child(2) { opacity: .4; animation: lm-wave 8s linear infinite reverse; }

/* before the intro plays everything is hidden (only when JS runs) */
.js .logo-motion:not(.is-playing) :is(.lm-emblem, .lm-wordmark, .lm-waves, .lm-orbit, .lm-sheen) { opacity: 0; }

/* the intro timeline */
.logo-motion.is-playing .lm-emblem img { animation: lm-emblem-in 1.5s var(--ease-out) .15s both; }
.logo-motion.is-playing .lm-wordmark { animation: lm-wordmark-in 1.1s var(--ease-out) .95s both; }
.logo-motion.is-playing .lm-wordmark img { animation: lm-text-in 1.1s var(--ease-out) .95s both; }
.logo-motion.is-playing .lm-draw { animation: lm-draw 1.7s var(--ease-io) .2s forwards; }
.logo-motion.is-playing .lm-dash { animation: lm-fade .8s ease 1.1s both, lm-spin 60s linear 1.1s infinite; }
.logo-motion.is-playing .lm-ticks line { animation: lm-tick .5s ease calc(1s + var(--i) * 14ms) forwards; }
.logo-motion.is-playing .lm-sat { animation: lm-fade .6s ease 1.8s both, lm-spin 14s linear 1.8s infinite; }
.logo-motion.is-playing .lm-ping { animation: lm-ping 4.2s var(--ease-out) calc(1.9s + var(--p) * 1.4s) infinite; }
.logo-motion.is-playing .lm-waves { animation: lm-fade 1s ease 1.6s both; }
.logo-motion.is-playing .lm-sheen { animation: lm-fade .5s ease 2.2s both, lm-sheen 5.5s var(--ease-io) 3.2s infinite; }
.logo-motion.is-playing .lm-orbit { animation: lm-fade .4s ease both; }

@keyframes lm-emblem-in {
    0% { opacity: 0; transform: scale(.45) rotate(-260deg); filter: blur(10px); }
    60% { opacity: 1; }
    100% { opacity: 1; transform: none; filter: blur(0); }
}
@keyframes lm-wordmark-in { from { clip-path: inset(71.5% 100% 0 0); } to { clip-path: inset(71.5% 0 0 0); } }
@keyframes lm-text-in { from { opacity: 0; transform: translateY(16px); letter-spacing: .3em; } to { opacity: 1; transform: none; } }
@keyframes lm-draw { to { stroke-dashoffset: 0; } }
@keyframes lm-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lm-spin { to { transform: rotate(360deg); } }
@keyframes lm-tick { from { opacity: 0; } to { opacity: .55; } }
@keyframes lm-ping { 0% { opacity: 0; transform: scale(1); } 8% { opacity: .75; } 100% { opacity: 0; transform: scale(1.9); } }
@keyframes lm-sheen { 0% { background-position: -150% 0; } 55%, 100% { background-position: 250% 0; } }
@keyframes lm-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -9px; } }
@keyframes lm-wave { to { transform: translateX(-50%); } }

@media (max-width: 980px) {
    .tiles-row { margin-top: -30px; }
    .logo-motion { margin-top: 56px; }
}

@media (prefers-reduced-motion: reduce) {
    .logo-motion :is(.lm-tilt, .lm-emblem img, .lm-wordmark, .lm-wordmark img, .lm-draw, .lm-dash, .lm-sat, .lm-ping, .lm-waves, .lm-waves path, .lm-sheen, .lm-ticks line) { animation: none !important; }
    .js .logo-motion:not(.is-playing) :is(.lm-emblem, .lm-wordmark, .lm-waves, .lm-orbit) { opacity: 1; }
    .lm-draw { stroke-dashoffset: 0; }
    .lm-ticks line { opacity: .5; }
    .lm-ping, .lm-sheen { display: none; }
    .scroll-cue::after { animation: none; opacity: 1; }
    .to-top, .scroll-progress { transition: none; }
}

/* the expenses table image must never be wider than its column */
.expenses { max-width: min(624px, 100%); height: auto; }

/* Transparent signature on the history photograph. */
.hero-history-grid img { display: block; width: min(330px, 85%); height: auto; padding: 0; background: transparent; border: 0; border-radius: 0; box-shadow: none; filter: brightness(0) invert(1) drop-shadow(0 4px 18px rgba(0, 0, 0, .24)); }
.hero-history-grid { gap: 40px; }
.history-card .avatar { display: block; width: min(180px, 65%); height: auto; object-fit: contain; border-radius: 8px; border: 1px solid rgba(200, 161, 74, .65); padding: 5px; background: #fff; margin: -48px auto 24px; box-shadow: 0 12px 28px rgba(0, 0, 0, .22); }
.history-card p { max-width: 64ch; margin-inline: auto; }
