/* Arcandum — Coming Soon v6.3: no jump on erase (NBSP + reserved width/height + persistent scrollbar) */
:root{
  --bg: #fbfcfe;
  --ink: #0d1b2a;
  --muted: #5b6775;
  --accent: #164ea6;
  --card: #ffffff;
  --grid-size: 22px;
  --grid-strong: 110px;
  --reveal-r: 120px;
  --mx: 50%;
  --my: 50%;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
html{ overflow-y: scroll; } /* keep scrollbar to avoid page shift */
body{
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
  overflow-x: hidden;
}

/* Background blueprint with mask reveal (subtle) */
.blueprint{
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
  background-image:
    linear-gradient(to right, rgba(22,78,166,.12) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(22,78,166,.12) 1px, transparent 1px),
    linear-gradient(to right, rgba(22,78,166,.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(22,78,166,.06) 1px, transparent 1px);
  background-size:
    calc(var(--grid-strong)) var(--grid-strong),
    var(--grid-strong) calc(var(--grid-strong)),
    var(--grid-size) var(--grid-size),
    var(--grid-size) var(--grid-size);
  background-position: center;
  -webkit-mask-image: radial-gradient(circle var(--reveal-r) at var(--mx) var(--my), rgba(0,0,0,.95) 30%, rgba(0,0,0,.85) 50%, rgba(0,0,0,0) 68%);
  mask-image: radial-gradient(circle var(--reveal-r) at var(--mx) var(--my), rgba(0,0,0,.95) 30%, rgba(0,0,0,.85) 50%, rgba(0,0,0,0) 68%);
  transition: -webkit-mask-position .12s ease, mask-position .12s ease, -webkit-mask-size .18s ease, mask-size .18s ease;
}

/* Cursor ring — precise centering via left/top + translate */
.cursor-vfx{ position: fixed; inset: 0; pointer-events: none; z-index: -1; }
.cursor-vfx .ring{
  position: absolute;
  left: 50%; top: 50%;
  width: 96px; height: 96px;
  border-radius: 50%;
  border: 1px solid rgba(22,78,166,.24);
  transform: translate(-50%,-50%);
  will-change: left, top;
}

/* Header */
.site-header{
  width: min(1100px, 92vw);
  margin: 28px auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand{ display: flex; align-items: center; gap: 14px; }
.logo{ display:block; object-fit: contain; border-radius: 8px; background: #eaf2ff; }
.wordmark{ font-weight: 800; letter-spacing: .2px; font-size: 1.2rem; }
.tag{ color: var(--muted); font-size: .9rem; margin-left: 4px; }

.controls{ display: flex; align-items: center; gap: 10px; }
.pill{
  display: inline-flex; align-items: center;
  padding: 6px 10px; border-radius: 999px;
  font-weight: 600; font-size: .85rem;
  border: 1px solid rgba(13,27,42,.12);
  background: #fff; color: #174ea6;
}

.btn{
  border: 1px solid rgba(13,27,42,.12);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  color: var(--ink);
  background: transparent;
  transition: transform .1s ease, border-color .15s ease;
}
.btn:hover{ transform: translateY(-1px); }
.btn:active{ transform: translateY(0); }

/* Hero */
.hero{
  width: min(1100px, 92vw);
  margin: clamp(56px, 12vh, 120px) auto 0;
  padding-bottom: 32px;
}
.stack{ display: grid; gap: 12px; contain: layout size; } /* isolate layout */
.headline{
  font-size: clamp(2rem, 1.2rem + 3vw, 3.4rem);
  line-height: 1.12;
  margin: 0;
}
/* Outer container reserves width to stop layout shift; height set via JS */
.type{
  position: relative;
  display: inline-block;
  white-space: nowrap;
  min-height: 1.1em;
}
/* Caret attached to inner span so it follows actual text end */
#lineText{
  position: relative;
  white-space: nowrap;
}
#lineText::after{
  content: "";
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  width: 1.5ch; height: 1.1em;
  border-left: 2px solid #174ea6;
  opacity: .9;
  animation: caret .9s steps(1) infinite;
}
@keyframes caret{ 0%,49%{ opacity:.9 } 50%,100%{ opacity:0 } }

.lede{
  color: var(--muted);
  font-size: clamp(1.02rem, .9rem + .6vw, 1.25rem);
  margin: 0;
}

.features{
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 10px;
  margin-top: 10px;
}
.feature{
  padding: 12px; border-radius: 12px; background: var(--card);
  border: 1px solid rgba(13,27,42,.08);
}
.ftitle{ font-weight: 700; margin-bottom: 4px; }
.ftext{ color: var(--muted); }

.meta{
  display:flex; align-items:center; gap:10px; flex-wrap:wrap;
  margin-top: 8px;
}
.label{ color: var(--muted); }
.value{ font-weight: 700; letter-spacing:.3px; }

/* Footer */
.site-footer{
  width: min(1100px, 92vw);
  margin: 42px auto 28px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: .95rem;
  margin-top: auto; /* stick to bottom */
}
.site-footer a{ color: inherit; text-decoration: none; border-bottom: 1px dotted rgba(91,103,117,.5); }
.site-footer .dot{ opacity: .5; }

@media (max-width: 760px){
  .features{ grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce){
  *{ animation: none !important; transition: none !important; }
}
