/* ————————————————————————————————————————————————————————
   Princip AI — Buzlu Cam (frosted glass), cream edition
   Cream #F4EEDA · warm ink #2B2620 · ember #8A2F2B
   One document, views switched by anchor (like vocaby.ai).
   Home shows the living network in the clear; every other
   view keeps its neurons behind the frosted glass.
   ———————————————————————————————————————————————————————— */
:root{
  --paper:#F4EEDA;
  --ink:#2B2620;
  --spark:#923430;
  --gold:#D6A251;
  --green:#429D78;
  --muted:#8A8272;
  --line:#E2DAC2;
  --sub:#57503F;
  --card:#FCF8EB;
  --card-dim:rgba(252,248,235,.55);
  --glass:rgba(244,238,218,.72);
  --halo:rgba(244,238,218,.4);
  --shadow:rgba(43,38,32,.08);
  --shadow-hover:rgba(43,38,32,.16);
  --mono:ui-monospace,"SF Mono",Menlo,Consolas,monospace;
  --body:-apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,sans-serif;
}
/* In the dark the accent is amber, in the light it is ember red —
   the lens label, eyebrows and sparks all follow the same rule. */
:root[data-theme="dark"]{
  --paper:#121212;
  --ink:#EDE6D6;
  --spark:#D6A251;
  --muted:#9A9184;
  --line:rgba(237,230,214,.12);
  --sub:#B5AC9C;
  --card:#1C1C1C;
  --card-dim:rgba(28,28,28,.55);
  --glass:rgba(18,18,18,.72);
  --halo:rgba(18,18,18,.4);
  --shadow:rgba(0,0,0,.25);
  --shadow-hover:rgba(0,0,0,.4);
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --paper:#121212;
    --ink:#EDE6D6;
    --spark:#D6A251;
    --muted:#9A9184;
    --line:rgba(237,230,214,.12);
    --sub:#B5AC9C;
    --card:#1C1C1C;
    --card-dim:rgba(28,28,28,.55);
    --glass:rgba(18,18,18,.72);
    --halo:rgba(18,18,18,.4);
    --shadow:rgba(0,0,0,.25);
    --shadow-hover:rgba(0,0,0,.4);
  }
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;background:var(--paper);color:var(--ink);font-family:var(--body);
  font-size:16px;line-height:1.6;-webkit-font-smoothing:antialiased;
  display:flex;flex-direction:column;overflow:hidden;
}
a{color:inherit;text-decoration:none}
.wrap{max-width:1120px;margin:0 auto;padding:0 30px;width:100%}

/* ————— Nav: no bar — it sits directly on the ground ————— */
.nav{flex:none;z-index:50;background:transparent}
.nav .wrap{display:flex;align-items:center;gap:20px;padding-top:14px;padding-bottom:14px;flex-wrap:wrap}
/* The identity: four dots in a horizontal row — sage, amber, ember, ink —
   growing under the cursor. The wordmark lives on the right as particles. */
.identity{position:relative;width:72px;height:26px;display:block;flex:none}
.identity span{
  position:absolute;top:8px;width:10px;height:10px;border-radius:50%;
  transition:width .7s cubic-bezier(.19,1,.22,1),height .7s cubic-bezier(.19,1,.22,1),
             margin .7s cubic-bezier(.19,1,.22,1);
}
.identity span:nth-child(1){background:#A4B7B4;left:0}
.identity span:nth-child(2){background:#D6A251;left:18px}
.identity span:nth-child(3){background:#923430;left:36px}
.identity span:nth-child(4){background:var(--ink);left:54px}
.identity span:hover{width:24px;height:24px;margin:-7px 0 0 -7px}
.identity .lbl{
  position:absolute;left:78px;top:7px;display:none;font-style:normal;
  font-family:var(--mono);font-size:9px;letter-spacing:.2em;text-transform:uppercase;
  color:var(--muted);white-space:nowrap;
}
.identity:hover .lbl{display:block}
.nav nav{display:flex;gap:22px;font-size:13px;color:var(--muted);margin-left:auto;flex-wrap:wrap}
.nav nav a:hover{color:var(--ink)}
.nav nav a.is-here{color:var(--ink);font-weight:650}
.nav .cta{
  color:var(--paper);background:var(--ink);padding:8px 17px;border-radius:6px;
  font-weight:600;font-size:12.5px;white-space:nowrap;
}
.nav .cta:hover{opacity:.88}
/* Pinned to the top-right corner of the window; deliberately #1A1A1A in
   both themes. */
.theme-btn{
  position:fixed;top:15px;right:18px;z-index:60;
  border:none;background:#1A1A1A;color:#F4EEDA;
  width:34px;height:34px;border-radius:50%;cursor:pointer;font-size:13px;
  display:flex;align-items:center;justify-content:center;
}
.theme-btn:hover{opacity:.85}
@media(max-width:720px){
  .nav .wrap{gap:12px}
  .nav nav{gap:14px;font-size:12px;order:3;flex-basis:100%;margin-left:0}
}

/* ————— Views: one visible at a time, no page scroll ————— */
main.views{flex:1;position:relative;overflow:hidden;min-height:0}
/* The three.js background from the original principai.co: sized to the
   window by its own scripts, clipped by this container — never stretched. */
canvas.bg3d{position:absolute;top:0;left:0;z-index:0;pointer-events:none}
.view{position:absolute;inset:0;display:none;overflow:hidden;z-index:1}
body.is-home     .v-home,
body.is-services .v-services,
body.is-products .v-products,
body.is-about    .v-about,
body.is-contact  .v-contact{display:block}
/* Only the content column renders in — the ground, nav and background stay
   exactly where they are between views. */
body.is-home .v-home .ov,
body.is-services .v-services .vwrap,
body.is-products .v-products .vwrap,
body.is-about .v-about .vwrap,
body.is-contact .v-contact .vwrap{animation:viewin .3s ease}
@keyframes viewin{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@media(prefers-reduced-motion:reduce){
  body.is-home .v-home .ov,body.is-services .v-services .vwrap,
  body.is-products .v-products .vwrap,body.is-about .v-about .vwrap,
  body.is-contact .v-contact .vwrap{animation:none}
}
/* The content column: anchored left like the hero copy, so the particle
   logo on the right stays in view on every page. */
.vwrap{
  max-width:900px;margin:0;width:100%;
  padding:18px 34px 30px clamp(48px,7vw,110px);
  min-height:100%;display:flex;flex-direction:column;justify-content:center;
}

.eyebrow{
  font-family:var(--mono);font-size:11px;letter-spacing:.22em;text-transform:uppercase;
  color:var(--spark);margin:0 0 10px;
}
h2{
  font-size:clamp(22px,2.8vw,30px);font-weight:700;letter-spacing:-.015em;
  margin:0 0 10px;text-wrap:balance;
}
.lede{font-size:15px;color:var(--sub);max-width:62ch;margin:0 0 8px;line-height:1.65}

/* ————— Home: quiet fabric behind milk glass; the message lives in the
   copy on the left and the service panel on the right. ————— */
.v-home{overflow:hidden}
.hero{position:relative;height:100%;min-height:360px}

/* The old site's tagline, restored above the headline. */
.tagline{
  font-family:var(--mono);font-size:11px;letter-spacing:.24em;text-transform:uppercase;
  color:var(--spark);margin:0 0 16px;
}
.hero .ov{
  position:absolute;inset:0;display:flex;flex-direction:column;justify-content:flex-start;
  padding:clamp(56px,11vh,110px) 34px 0 clamp(48px,7vw,110px);
  max-width:720px;pointer-events:none;
}
.hero h1{
  font-size:clamp(38px,5.6vw,68px);font-weight:750;letter-spacing:-.02em;line-height:1.05;
  margin:0 0 16px;text-wrap:balance;
  text-shadow:0 0 12px var(--paper),0 0 26px var(--paper);
}
.hero h1 .r{color:var(--spark)}
/* The rotating verb — see it · save it · stick it, but ours. The hairline
   stroke keeps the cream-colored word legible on the cream ground. */
.rot{display:inline-block;min-width:3.2em;transition:opacity .28s ease,transform .28s ease}
.rot.out{opacity:0;transform:translateY(.35em)}
@media(prefers-reduced-motion:reduce){.rot{transition:none}.rot.out{opacity:1;transform:none}}
.hero .sub{
  font-size:15px;color:var(--sub);margin:0 0 26px;line-height:1.7;max-width:54ch;
  text-shadow:0 0 10px var(--paper),0 0 20px var(--paper);
}
.hero .btns{display:flex;gap:14px;align-items:center;pointer-events:auto;flex-wrap:wrap}
.btn{
  display:inline-block;background:var(--ink);color:var(--paper);font-size:13.5px;font-weight:600;
  padding:12px 24px;border-radius:6px;
}
.btn:hover{opacity:.88}
.btn.ghost{background:transparent;color:var(--ink);border:1px solid var(--ink)}
.btn.ghost:hover{opacity:1;background:var(--shadow)}
.hero .hint{
  font-family:var(--mono);font-size:10px;letter-spacing:.16em;text-transform:uppercase;
  color:var(--muted);margin:18px 0 0;
}

/* ————— Service cards: cream glass cases, each with its own sharp net ————— */
.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;padding:16px 0 0}
@media(max-width:900px){.cards{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.cards{grid-template-columns:1fr}}
/* Frosted, not painted: no fill color — just the ground blurred through. */
.card{
  background:var(--halo);border:1px solid var(--line);border-radius:10px;padding:12px;
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  box-shadow:0 6px 18px var(--shadow);
}
.card canvas{width:100%;height:96px;display:block}
.card h3{margin:10px 2px 3px;font-size:13.5px;font-weight:650}
.card p{margin:0 2px;font-size:12px;color:var(--muted);line-height:1.55}

/* ————— Products ————— */
.prods{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;padding:14px 0 12px}
@media(max-width:900px){.prods{grid-template-columns:1fr}}
.prod{
  display:flex;flex-direction:column;
  background:var(--halo);border:1px solid var(--line);border-radius:12px;overflow:hidden;
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  box-shadow:0 6px 18px var(--shadow);
  transition:box-shadow .25s,transform .25s;
}
a.prod:hover{box-shadow:0 14px 32px var(--shadow-hover);transform:translateY(-2px)}
.prod canvas{width:100%;height:112px;display:block;border-bottom:1px solid var(--line)}
.prod .body{padding:12px 16px 14px;display:flex;flex-direction:column;flex:1}
.prod .meta{display:flex;align-items:center;gap:10px}
.vertical{
  font-family:var(--mono);font-size:9.5px;letter-spacing:.18em;text-transform:uppercase;
  color:var(--muted);
}
/* The trio: live = green, in development = gold, exploring = quiet. */
.tag{
  font-family:var(--mono);font-size:9.5px;letter-spacing:.16em;text-transform:uppercase;
  color:#F4EEDA;background:var(--green);padding:3px 8px;border-radius:3px;margin-left:auto;
}
.tag.soon{background:var(--muted)}
.tag.dev{background:var(--gold);color:#2B2620}
.tag.house{background:#A4B7B4;color:#2B2620}
.prod h3{margin:10px 0 4px;font-size:17px;font-weight:700}
.prod p{margin:0 0 8px;font-size:12.5px;color:var(--sub);line-height:1.5}
.prod .link{
  margin-top:auto;font-family:var(--mono);font-size:11px;letter-spacing:.06em;color:var(--spark);
}
.prod.dim{background:var(--card-dim)}
.prod.dim h3,.prod.dim p{color:var(--muted)}

/* ————— Model stack strip ————— */
.stack{
  display:flex;align-items:center;gap:10px;flex-wrap:wrap;
  border:1px solid var(--line);border-radius:12px;background:var(--halo);
  backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);
  padding:10px 16px;
}
.stack .cap{
  font-size:12px;color:var(--sub);margin:0;line-height:1.5;flex:1;min-width:220px;
}
.stack .cap b{color:var(--ink)}
.stack .chips{display:flex;gap:8px;flex-wrap:wrap}
.chip{
  display:flex;align-items:center;gap:8px;
  font-family:var(--mono);font-size:10.5px;letter-spacing:.08em;color:var(--sub);
  background:var(--card);border:1px solid var(--line);border-radius:999px;padding:4px 13px 4px 4px;
  white-space:nowrap;
}
.chip b{color:var(--ink);font-weight:600}
/* The brand marks live in ink-on-paper circles so no vendor color ever
   enters the palette — the same mono treatment in both themes. */
.chip .ci{
  width:22px;height:22px;border-radius:50%;background:var(--ink);color:var(--card);
  display:flex;align-items:center;justify-content:center;flex:none;font-style:normal;
}
.chip .ci svg{width:12px;height:12px;display:block;fill:currentColor}

/* ————— About: copy on top, principles as a horizontal timeline below ————— */
.about-copy{max-width:66ch;padding-top:6px}
.about-copy p{margin:0 0 14px;font-size:14.5px;color:var(--sub);line-height:1.7}
.about-copy p b{color:var(--ink)}
.ptl{
  position:relative;display:grid;grid-template-columns:repeat(3,1fr);gap:24px;
  margin-top:26px;
}
.ptl::before{
  content:"";position:absolute;top:5px;left:5px;right:5px;height:1px;background:var(--line);
}
.ptl-item{position:relative;padding-top:26px}
.ptl-item::before{
  content:"";position:absolute;top:0;left:0;width:11px;height:11px;border-radius:50%;
  background:var(--c);box-shadow:0 0 0 4px var(--paper);
}
.ptl-no{
  display:block;font-family:var(--mono);font-size:11px;letter-spacing:.2em;
  color:var(--c);margin-bottom:5px;font-weight:700;
}
.ptl-item b{display:block;font-size:14.5px;margin-bottom:4px;letter-spacing:-.01em}
.ptl-item .tx{display:block;font-size:12.5px;color:var(--sub);line-height:1.6}
@media(max-width:700px){.ptl{grid-template-columns:1fr;gap:20px}.ptl::before{display:none}}

/* ————— Contact ————— */
.contact-grid{display:grid;grid-template-columns:1.4fr 1fr;gap:14px;padding-top:12px;align-items:stretch}
@media(max-width:760px){.contact-grid{grid-template-columns:1fr}}
.cform{
  display:flex;flex-direction:column;gap:10px;
  background:var(--halo);border:1px solid var(--line);border-radius:10px;padding:16px 20px;
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  box-shadow:0 6px 18px var(--shadow);
}
.cform label{
  display:flex;flex-direction:column;gap:6px;
  font-family:var(--mono);font-size:10px;letter-spacing:.14em;text-transform:uppercase;
  color:var(--muted);
}
.cform input,.cform select,.cform textarea{
  background:var(--paper);border:1px solid var(--line);border-radius:6px;
  padding:10px 12px;font-family:var(--body);font-size:13.5px;color:var(--ink);
}
.cform input:focus,.cform select:focus,.cform textarea:focus{
  outline:none;border-color:var(--muted);
}
.cform textarea{resize:none;min-height:64px}
.cform .frow{display:grid;grid-template-columns:1fr 1fr;gap:12px}
@media(max-width:520px){.cform .frow{grid-template-columns:1fr}}
/* Gold from the accent trio in both themes — the cream ink-button read as a
   stray white block on the dark ground. */
.cform .btn{
  border:none;cursor:pointer;align-self:flex-start;font-family:var(--body);
  background:var(--gold);color:#2B2620;font-weight:650;
}
.cform .btn:hover{opacity:.85}
.cform .btn[disabled]{opacity:.55;cursor:default}
.form-note{margin:2px 0 0;font-size:12.5px;line-height:1.5;color:var(--green);font-weight:600}
.form-note.err{color:var(--spark)}
/* The comms panel: frosted like everything else — the ground blurs through. */
.aicard{
  background:var(--halo);color:var(--ink);border:1px solid var(--line);
  border-radius:10px;padding:22px 24px;
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  display:flex;flex-direction:column;gap:14px;box-shadow:0 6px 18px var(--shadow);
  align-self:stretch;height:100%;
}
.aicard .stat{
  display:flex;align-items:center;gap:8px;
  font-family:var(--mono);font-size:10px;letter-spacing:.18em;text-transform:uppercase;
  color:var(--muted);
}
.aicard .dot{
  width:8px;height:8px;border-radius:50%;background:#429D78;
  box-shadow:0 0 8px #429D78;animation:aipulse 2s ease-in-out infinite;
}
@keyframes aipulse{50%{opacity:.35}}
@media(prefers-reduced-motion:reduce){.aicard .dot{animation:none}}
.aicard h3{margin:0;font-size:16.5px;font-weight:650;letter-spacing:-.01em;line-height:1.35}
.aicard .term{
  font-family:var(--mono);font-size:12px;line-height:1.7;color:var(--spark);
  margin:0;min-height:3em;
}
.aicard .term::before{content:"> "}
.aicard .caret{
  display:inline-block;width:7px;height:13px;background:var(--spark);
  vertical-align:-2px;margin-left:3px;animation:aiblink 1s steps(1) infinite;
}
@keyframes aiblink{50%{opacity:0}}
@media(prefers-reduced-motion:reduce){.aicard .caret{animation:none}}
.aicard .note{margin:auto 0 0;font-size:12px;color:var(--muted);line-height:1.6}
.contact-card{
  display:flex;align-items:flex-start;gap:14px;
  background:var(--card);border:1px solid var(--line);border-radius:10px;padding:18px 20px;
  box-shadow:0 6px 18px var(--shadow);font-size:13.5px;line-height:1.55;
}
.contact-card:hover{border-color:var(--muted)}
.contact-card i{color:var(--spark);font-size:16px;margin-top:2px}
.contact-card b{display:block;font-size:12px;font-family:var(--mono);letter-spacing:.12em;
  text-transform:uppercase;color:var(--muted);font-weight:600;margin-bottom:3px}

/* ————— Footer: slim, frosted, no divider — just a breath of fog ————— */
footer{
  flex:none;border:none;background:var(--halo);
  backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);
}
footer .wrap{
  display:flex;align-items:center;gap:18px;flex-wrap:wrap;
  padding-top:12px;padding-bottom:12px;
}
footer svg{color:var(--muted)}
footer .copy{font-size:11.5px;color:var(--muted)}
footer nav{display:flex;gap:16px;margin-left:auto;font-size:11.5px;color:var(--muted)}
footer nav a:hover{color:var(--ink)}
@media(max-width:640px){footer .copy{display:none}}
