/* ==========================================================================
   Mythosme LLC — "Facet"
   Palette sampled from the identity mark. Dark by design.
   ========================================================================== */

:root{
  color-scheme: dark;

  --bg:      #070B11;
  --panel:   #0C1219;
  --panel-2: #101822;
  --ink:     #EDF2F7;
  --mute:    #8FA1B4;
  --dim:     #5D7183;
  --line:    #18222E;
  --line-2:  #223040;
  --blue:    #3E8FCC;
  --ice:     #9FD0EE;
  --green:   #1F9E74;

  --shell:  min(68rem, 100% - 3rem);
  --step:   clamp(2.4rem, 1.5rem + 3.2vw, 4.2rem);

  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --disp: Archivo, "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

body{
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.58;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--ice); text-underline-offset: .18em; }
a:hover { color: var(--ink); }

:focus-visible{
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 1px;
}

.skip{
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--blue); color: #04080D; padding: .6rem 1rem;
  font-family: var(--mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase;
}
.skip:focus { left: .75rem; top: .75rem; }

/* ---------- layout primitives ---------- */

.shell { width: var(--shell); margin-inline: auto; }

.section { padding-block: var(--step); }
.section--tight { padding-block: calc(var(--step) * .62); }

/* angular break — the facet language applied to structure */
.section--cut{
  background: var(--panel);
  clip-path: polygon(0 2rem, 100% 0, 100% 100%, 0 100%);
  padding-top: calc(var(--step) + 2rem);
  margin-top: -2rem;
}
.section--cut-up{
  background: var(--panel);
  clip-path: polygon(0 0, 100% 2rem, 100% 100%, 0 100%);
  padding-top: calc(var(--step) + 2rem);
  margin-top: -2rem;
}

/* ---------- type ---------- */

.eyebrow{
  font-family: var(--mono);
  font-size: .68rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--blue);
  margin: 0 0 .8rem;
}

h1, h2, h3 { font-family: var(--disp); margin: 0; text-wrap: balance; }

h1{
  font-weight: 800;
  font-size: clamp(2.2rem, 1.2rem + 4vw, 4.1rem);
  line-height: 1.02;
  letter-spacing: -.038em;
  max-width: 16ch;
}
h2{
  font-weight: 700;
  font-size: clamp(1.55rem, 1.1rem + 1.6vw, 2.2rem);
  line-height: 1.12;
  letter-spacing: -.028em;
  max-width: 22ch;
}
h3{
  font-weight: 700;
  font-size: 1.02rem;
  line-height: 1.35;
  letter-spacing: -.008em;
}

.grad{
  background: linear-gradient(96deg, var(--ice) 0%, var(--blue) 40%, var(--green) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

p { margin: 0 0 .8rem; max-width: 62ch; }
p:last-child { margin-bottom: 0; }

.lede{
  font-size: 1.06rem;
  color: var(--mute);
  max-width: 50ch;
}
.prose p { color: var(--mute); }
.prose strong { color: var(--ink); font-weight: 600; }

/* ---------- header ---------- */

.masthead{
  position: sticky; top: 0; z-index: 40;
  background: rgba(7, 11, 17, .82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.masthead .shell{
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 4rem; flex-wrap: wrap;
}
.brand{
  display: flex; align-items: center; gap: .7rem;
  text-decoration: none; color: var(--ink);
}
.brand img { width: 30px; height: 30px; object-fit: contain; }
.brand b{
  font-family: var(--disp); font-weight: 700; font-size: 1.06rem; letter-spacing: -.015em;
}
.brand i { font-style: normal; color: var(--blue); }

.nav { display: flex; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav a{
  color: var(--mute); text-decoration: none;
  font-size: .84rem; letter-spacing: .01em;
  padding-block: .25rem;
  border-bottom: 1px solid transparent;
  transition: color .18s ease, border-color .18s ease;
}
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--blue); }

/* ---------- hero ---------- */

.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero canvas{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  display: block; z-index: 0;
  pointer-events: none;
  /* keep the mesh off the type: fade in from the left, out at the edges */
  -webkit-mask-image:
    linear-gradient(100deg, transparent 4%, rgba(0,0,0,.35) 34%, #000 72%),
    linear-gradient(to bottom, transparent 0%, #000 22%, #000 74%, transparent 100%);
  mask-image:
    linear-gradient(100deg, transparent 4%, rgba(0,0,0,.35) 34%, #000 72%),
    linear-gradient(to bottom, transparent 0%, #000 22%, #000 74%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}
.hero .shell { position: relative; z-index: 1; }
.hero--home { padding-block: clamp(3rem, 2rem + 4.2vw, 5.4rem); }
.hero--home .lede { margin-top: 1.25rem; }
.hero--page { padding-block: clamp(2.2rem, 1.7rem + 2.2vw, 3.4rem); border-bottom: 1px solid var(--line); }
@media (max-width: 48rem){
  .hero canvas{
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 26%, #000 72%, transparent 100%);
    mask-image: linear-gradient(to bottom, transparent 0%, #000 26%, #000 72%, transparent 100%);
    opacity: .55;
  }
}

.hero-actions{
  display: flex; gap: 1.6rem; align-items: center; flex-wrap: wrap;
  margin-top: 1.7rem;
}
.btn{
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--mono); font-size: .74rem; letter-spacing: .13em; text-transform: uppercase;
  text-decoration: none;
  padding: .82rem 1.35rem;
  background: var(--blue); color: #04080D; font-weight: 500;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - .5rem), calc(100% - .5rem) 100%, 0 100%);
  transition: background .18s ease;
}
.btn:hover { background: var(--ice); color: #04080D; }
.btn--ghost{
  background: transparent; color: var(--ink);
  border: 1px solid var(--line-2);
  clip-path: none;
}
.btn--ghost:hover { background: var(--panel-2); color: var(--ink); border-color: var(--blue); }

/* ---------- rail of standing facts ---------- */

.rail{
  display: flex; flex-wrap: wrap; gap: 2.6rem;
  margin-top: 3rem; padding-top: 1.6rem;
  border-top: 1px solid var(--line);
}
.rail div { display: grid; gap: .1rem; }
.rail b{
  font-family: var(--disp); font-weight: 700; font-size: 1.15rem;
  letter-spacing: -.015em; font-variant-numeric: tabular-nums;
}
.rail span{
  font-family: var(--mono); font-size: .64rem; letter-spacing: .15em;
  text-transform: uppercase; color: var(--dim);
}

/* ---------- service grid ---------- */

.grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  margin-top: 1.9rem;
}
.grid > article{
  background: var(--panel);
  padding: 1.25rem 1.25rem 1.4rem;
  display: grid;
  gap: .55rem;
  align-content: start;
}
.grid .n{
  font-family: var(--mono); font-size: .64rem; letter-spacing: .14em;
  color: var(--blue); margin-bottom: .35rem;
}
.grid p { margin: 0; font-size: .88rem; color: var(--mute); line-height: 1.6; max-width: none; }

/* ---------- numbered practice list ---------- */

.entries { display: grid; gap: 0; margin-top: 2rem; border-top: 1px solid var(--line); max-width: 52rem; }
.entries > article{
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 1.5rem;
  padding-block: 1.35rem;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.entries .k{
  font-family: var(--mono); font-size: .68rem; letter-spacing: .12em;
  color: var(--blue); padding-top: .35rem;
}
.entries h3 { margin-bottom: .55rem; font-size: 1.12rem; }
.entries p { margin: 0; color: var(--mute); font-size: .94rem; }
@media (max-width: 34rem){
  .entries > article { grid-template-columns: 1fr; gap: .5rem; }
  .entries .k { padding-top: 0; }
}

/* ---------- sector chips ---------- */

.chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 1.5rem 0 0; padding: 0; }
.chips li{
  font-family: var(--mono); font-size: .72rem; letter-spacing: .05em;
  color: var(--ink); background: var(--panel-2);
  border: 1px solid var(--line-2);
  padding: .45rem .85rem;
}

/* ---------- two-column split ---------- */

.split{
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
}
@media (min-width: 52rem){
  .split { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 3rem; }
}
.aside{
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 1.25rem 1.3rem 1.35rem;
  align-self: start;
}
.aside h3{
  font-family: var(--mono); font-size: .68rem; font-weight: 500;
  letter-spacing: .16em; text-transform: uppercase; color: var(--green);
  margin-bottom: 1rem;
}
.aside ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .55rem; }
.aside li { display: flex; gap: .7rem; font-size: .88rem; color: var(--mute); line-height: 1.55; }
.aside li::before { content: "◆"; color: var(--blue); font-size: .6rem; padding-top: .38rem; flex: 0 0 auto; }

/* ---------- credentials ---------- */

.creds { margin: 2.2rem 0 0; padding: 0; list-style: none; border-top: 1px solid var(--line); max-width: 52rem; }
.creds li{
  display: grid; grid-template-columns: 9rem 1fr; gap: 1.5rem;
  padding-block: .95rem; border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.creds .yr{
  font-family: var(--mono); font-size: .68rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--dim);
}
.creds strong { display: block; font-weight: 600; font-size: .95rem; }
.creds span { color: var(--mute); font-size: .88rem; }
@media (max-width: 34rem){
  .creds li { grid-template-columns: 1fr; gap: .25rem; }
}

/* ---------- entity record ---------- */

.record{
  border: 1px solid var(--line-2);
  background: var(--panel);
  padding: 1.4rem 1.4rem 1.5rem;
  margin-top: 2rem;
  max-width: 44rem;
}
.record dl { margin: 0; display: grid; }
.record .row{
  display: grid; grid-template-columns: 1fr; gap: .15rem;
  padding-block: .68rem;
  border-bottom: 1px solid var(--line);
}
.record .row:first-child { padding-top: 0; }
.record .row:last-child { border-bottom: 0; padding-bottom: 0; }
@media (min-width: 34rem){
  .record .row { grid-template-columns: 10rem 1fr; gap: 1.5rem; align-items: baseline; }
}
.record dt{
  font-family: var(--mono); font-size: .66rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--dim);
}
.record dd { margin: 0; font-size: .96rem; }
.record a { color: var(--ice); }

.mailto{
  font-family: var(--mono);
  font-size: clamp(1.05rem, .85rem + 1.1vw, 1.6rem);
  letter-spacing: -.02em;
  color: var(--ice);
  text-decoration: none;
  border-bottom: 1px solid var(--line-2);
  padding-bottom: .2rem;
  transition: border-color .2s ease, color .2s ease;
  display: inline-block;
  word-break: break-word;
}
.mailto:hover { color: var(--ink); border-bottom-color: var(--blue); }

/* ---------- call to action band ---------- */

.cta{
  background: linear-gradient(112deg, #0B1622 0%, #0A1A1B 100%);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.cta .shell{
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 1.6rem; padding-block: calc(var(--step) * .62);
}
.cta h2 { max-width: 18ch; }
.cta p { color: var(--mute); margin: .9rem 0 0; font-size: .95rem; }

/* ---------- footer ---------- */

.foot { border-top: 1px solid var(--line); }
.foot .shell{
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem;
  padding-block: 1.6rem 2.2rem;
  font-family: var(--mono); font-size: .68rem; letter-spacing: .09em;
  text-transform: uppercase; color: var(--dim);
}
.foot a { color: var(--dim); text-decoration: none; }
.foot a:hover { color: var(--ink); }
.foot-nav { display: flex; gap: 1.3rem; list-style: none; margin: 0; padding: 0; }

/* ---------- entrance ---------- */

/* Reveals only exist once JS has confirmed it can un-hide them.
   Without JS, .has-reveal is never set and every .rise stays visible. */
@media (prefers-reduced-motion: no-preference){
  .has-reveal .rise { opacity: 0; transform: translateY(14px); }
  .has-reveal .rise.in{
    opacity: 1; transform: none;
    transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.3,1);
  }
  .has-reveal .rise:nth-child(2).in { transition-delay: .07s; }
  .has-reveal .rise:nth-child(3).in { transition-delay: .14s; }
  .has-reveal .rise:nth-child(4).in { transition-delay: .21s; }
  .has-reveal .rise:nth-child(5).in { transition-delay: .28s; }
}

@media (max-width: 44rem){
  .nav { gap: 1.1rem; font-size: .8rem; }
  .masthead .shell { min-height: 3.6rem; padding-block: .6rem; }
}

/* ---------- print ----------
   This site gets read by people doing diligence, and some of them
   will print it or save it as PDF. Make that legible. */
@media print{
  :root{
    --bg:#fff; --panel:#fff; --panel-2:#fff;
    --ink:#000; --mute:#333; --dim:#555;
    --line:#bbb; --line-2:#999; --blue:#15486E; --ice:#15486E; --green:#0B5B44;
  }
  html, body { background:#fff !important; color:#000 !important; }
  .masthead, .hero canvas, .cta, .skip, .foot-nav, .hero-actions { display:none !important; }
  .has-reveal .rise{ opacity:1 !important; transform:none !important; }
  .section, .section--tight { padding-block:1.2rem; }
  .section--cut, .section--cut-up{
    clip-path:none; margin-top:0; padding-top:1.2rem;
    border-top:1px solid var(--line);
  }
  .hero--home, .hero--page { padding-block:1rem 1.4rem; }
  .grad{ -webkit-text-fill-color:#000; color:#000 !important; background:none; }
  .grid{ border-color:var(--line); }
  .grid > article{ break-inside:avoid; }
  .entries > article, .creds li, .record .row { break-inside:avoid; }
  a{ color:#15486E; }
  a[href^="mailto:"]::after{ content:" (" attr(href) ")"; font-size:.75em; color:#555; }
  .mailto::after{ content:none; }
}

/* ---------- practice index ----------
   The page is a list of five; this is its contents, not decoration.
   Doubles as in-page navigation on a long scroll. */
.index{
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
  max-width: 46rem;
  border-top: 1px solid var(--line);
}
@media (min-width: 44rem){
  .index{
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(3, auto);
    grid-auto-flow: column;
    column-gap: 2.75rem;
  }
}
.index a{
  display: grid;
  grid-template-columns: 2.1rem 1fr;
  gap: .5rem;
  align-items: baseline;
  padding-block: .58rem;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
  font-size: .89rem;
  transition: color .18s ease, border-color .18s ease;
}
.index a:hover{ color: var(--blue); border-bottom-color: var(--line-2); }
.index .n{
  font-family: var(--mono);
  font-size: .66rem;
  letter-spacing: .1em;
  color: var(--blue);
}
/* keep anchor targets clear of the sticky masthead */
.entries > article{ scroll-margin-top: 5.5rem; }

/* ---------- masthead right cluster + language selector ---------- */
.mast-right{ display: flex; align-items: center; gap: 1.6rem; flex-wrap: nowrap; }
.langsel{
  display: flex; align-items: center; gap: .45rem;
  font-family: var(--mono); font-size: .7rem; letter-spacing: .1em;
  padding-left: 1.1rem; border-left: 1px solid var(--line);
}
.langsel span, .langsel a{
  padding-block: .25rem;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
/* active language gets the same blue underline as the active nav item */
.langsel span[aria-current="true"]{ color: var(--ink); border-bottom-color: var(--blue); }
.langsel a{ color: var(--dim); transition: color .18s ease; }
.langsel a:hover{ color: var(--blue); }
@media (max-width: 44rem){
  .mast-right{ gap: 1rem; }
  .langsel{ padding-left: .8rem; }
}
