:root {
  /* v8 split */
  --ivory: #f4fafc;
  --cream: #ffffff;
  --espresso: #042830;
  --ink: #0d2a32;
  --mute: #4a6d78;
  --line: #c5dce4;
  --copper: #f0b429;
  --copper-2: #5ec8d8;
  --sage: #1ea672;
  --rose: #e23d4a;
  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Outfit", "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", Consolas, monospace;
  --shadow: 0 18px 50px rgba(4, 40, 48, 0.1);
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--ivory);
  color: var(--ink);
  font: 16px/1.55 var(--sans);
}
body.site { background: #fff; }
body.auth { background: #fff; }
body.auth .foot { background: var(--espresso); }
.site .top, .auth .top {
  background: #042830;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.site .brand, .auth .brand, .site .brand:hover, .auth .brand:hover { color: #fff; }
.site nav a, .auth nav a { color: #b7d4dc; }
.site nav a:hover, .auth nav a:hover { color: #fff; }
.site .brand-name em, .auth .brand-name em { color: #ffd36a; }
a { color: #0e6a7c; text-decoration: none; }
a:hover { color: #083344; }
.wrap { width: min(1120px, calc(100% - 48px)); margin: 0 auto; }

.top {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.top .wrap, nav { display: flex; align-items: center; gap: 22px; }
.top .wrap { justify-content: space-between; height: 70px; }
nav a {
  color: var(--mute); font-size: 14px; font-weight: 500;
  text-decoration: none; letter-spacing: 0.01em;
}
nav a:hover { color: var(--ink); }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.mark {
  width: 34px; height: 34px; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #f0b429, #ffd36a);
  color: #083344;
  font-family: var(--serif); font-weight: 600; font-size: 18px; font-style: italic;
}
.brand-name { font-weight: 600; letter-spacing: 0.04em; font-size: 15px; }
.brand-name em {
  font-style: normal; color: var(--copper); font-weight: 500;
  letter-spacing: 0.18em; font-size: 11px; margin-left: 7px;
}

.btn, nav a.btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(180deg, #ffd36a, #f0b429);
  color: #083344;
  border: 0; padding: 11px 18px; border-radius: 999px;
  font: 600 14px/1 var(--sans); cursor: pointer; text-decoration: none;
  box-shadow: 0 10px 24px rgba(240, 180, 41, 0.35);
}
.btn:hover, nav a.btn:hover { background: linear-gradient(180deg, #ffe08a, #f6c44a); color: #083344; }
.btn.small { padding: 6px 11px; font-size: 12px; border-radius: 999px; box-shadow: none; }
.btn.danger { background: var(--rose); box-shadow: none; color: #fff; }
.btn.ghost {
  background: #fff; color: var(--espresso); border: 1px solid #9ec5d0;
  box-shadow: none;
}
.btn.ghost:hover { background: #e8f4f8; color: var(--espresso); border-color: #5ec8d8; }
.btn.block { width: 100%; margin-top: 8px; }
.inline-form { display: inline-flex; gap: 6px; align-items: center; margin: 0; }
.inline-form input[type="password"] { width: 148px; margin: 0; padding: 7px 9px; }
.actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

.hero { padding: 72px 0 20px; }
.hero-band {
  position: relative;
  overflow: hidden;
  padding: 36px 0 88px;
  background:
    radial-gradient(900px 420px at 12% 10%, rgba(240, 180, 41, 0.22), transparent 55%),
    radial-gradient(800px 480px at 92% 90%, rgba(94, 200, 216, 0.18), transparent 50%),
    linear-gradient(180deg, #06323f, #042830);
  color: #e7f6f8;
}
.hero-band::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.55), transparent 85%);
  pointer-events: none;
}
.hero-band .wrap { position: relative; z-index: 1; }
.hero-band h1 { color: #fff; }
.hero-band h1 em { color: #ffd36a; }
.hero-band .lead { color: #b8d4dc; }
.hero-band .kicker { color: #ffd36a; }
.hero-band .btn.ghost {
  background: transparent; color: #fff; border-color: rgba(255,255,255,0.28);
}
.hero-band .btn.ghost:hover { background: rgba(255,255,255,0.08); color: #fff; border-color: #ffd36a; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.band-light { background: #fff; padding: 48px 0 28px; }
.feat { border-top: 4px solid #f0b429; }
.grid3 .feat:nth-child(2) { border-top-color: #0e6a7c; }
.grid3 .feat:nth-child(3) { border-top-color: #1ea672; }
.kicker {
  margin: 0 0 14px; color: #0e6a7c;
  font-size: 12px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase;
}
h1, h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.03em; }
h1 { font-size: clamp(36px, 5.4vw, 62px); line-height: 1.08; margin: 0 0 16px; }
h1 em { font-style: italic; color: #0e6a7c; font-weight: 500; }
h2 { font-size: clamp(26px, 3.4vw, 40px); margin: 0 0 10px; }
h3 { margin: 0 0 8px; font-size: 17px; font-weight: 600; }
.lead { max-width: 36rem; color: var(--mute); font-size: 18px; margin: 0; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 28px 0 0; }

.stage {
  background: #0a3a48; color: #e7f6f8; border-radius: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  overflow: hidden; border: 1px solid rgba(255,255,255,0.08);
}
.stage-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px; background: #0a3a48; color: #8eb8c4; font-size: 12px;
}
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #3d6a78; }
.dot:nth-child(1) { background: #f0b429; }
.dot:nth-child(2) { background: #5ec8d8; }
.dot:nth-child(3) { background: #1ea672; }
.stage-bar span:last-child { margin-left: 8px; letter-spacing: 0.08em; text-transform: uppercase; font-size: 11px; }
.stage-body { padding: 18px 18px 20px; }
.stage-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 11px 12px; margin-bottom: 8px; border-radius: 10px;
  background: rgba(255,255,255,0.04); font-family: var(--mono); font-size: 12px;
}
.stage-row em { font-style: normal; color: #8fdfb0; font-size: 11px; }
.stage-go {
  margin-top: 10px; width: 100%; border: 0; border-radius: 11px; padding: 12px;
  background: linear-gradient(180deg, #ffd36a, #f0b429); color: #083344; font: 600 14px var(--sans); cursor: default;
}

.section { padding: 18px 0 28px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid3 article, .card, .stat, .install-grid article {
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.feat { position: relative; overflow: hidden; min-height: 180px; }
.feat b {
  font-family: var(--serif); font-size: 42px; color: rgba(14, 106, 124, 0.22);
  display: block; margin-bottom: 8px; font-weight: 600;
}
.ticks { margin: 0; padding-left: 18px; }
.ticks li { margin: 8px 0; }
.ok { color: var(--sage); }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.stat { border-top: 4px solid #f0b429; }
.stats .stat:nth-child(2) { border-top-color: #0e6a7c; }
.stats .stat:nth-child(3) { border-top-color: #1ea672; }
.stat span, .stat .fine { color: var(--mute); font-size: 12px; }
.stat b { display: block; font-family: var(--serif); font-size: 28px; margin: 6px 0 4px; color: var(--espresso); }

.auth-stage { display: grid; grid-template-columns: 1.05fr .95fr; min-height: calc(100vh - 70px - 90px); }
.auth-panel {
  background: linear-gradient(165deg, #0e4a5c 0%, #083344 55%, #0a2a38 100%); color: #e7f6f8; padding: 72px 56px;
  display: flex; flex-direction: column; justify-content: center;
}
.auth-panel h1 { color: #fff; font-size: clamp(32px, 4vw, 52px); }
.auth-panel h1 em { color: #ffd36a; }
.auth-panel .lead { color: #b7d4dc; }
.auth-panel .ticks { color: #c5e4ea; }
.auth-form-wrap { display: flex; align-items: center; justify-content: center; padding: 48px 32px; }
.auth-card { width: min(420px, 100%); background: var(--cream); border: 1px solid var(--line); border-radius: 20px; padding: 28px; box-shadow: var(--shadow); }
.auth-card h1 { font-size: 28px; }
.auth-alt { margin: 18px 0 0; color: var(--mute); font-size: 14px; }

label { display: block; margin: 0 0 14px; font-size: 13px; color: var(--mute); font-weight: 500; }
input, select, textarea {
  width: 100%; margin-top: 6px; padding: 11px 12px; background: #fff; color: var(--ink);
  border: 1px solid var(--line); border-radius: 10px; font: inherit;
}
input[type="checkbox"], input[type="radio"] { width: auto; margin: 0 8px 0 0; accent-color: var(--copper); }
input:focus, select:focus, textarea:focus {
  outline: 0; border-color: #5ec8d8; box-shadow: 0 0 0 4px rgba(94, 200, 216, 0.22);
}
.err { color: var(--rose); margin: 0 0 10px; }
.foot {
  border-top: 0; padding: 28px 0; color: #8eb8c4; font-size: 13px;
  background: #042830;
}
.foot a { color: #ffd36a; }
.foot-row { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.fine { color: var(--mute); font-size: 13px; }
code, .mono { font-family: var(--mono); font-size: 0.9em; }
pre {
  overflow: auto; background: #083344; color: #e7f6f8; padding: 14px 16px;
  border-radius: 12px; font-family: var(--mono); font-size: 13px;
}
.badge {
  display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 600;
}
.badge.on { background: #e4f3ea; color: var(--sage); }
.badge.off { background: #f8e4e2; color: var(--rose); }
.badge.enc { background: #fff3d4; color: #8a6408; }
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 640px; }
th {
  text-align: left; color: var(--mute); font-size: 11px; letter-spacing: .08em;
  text-transform: uppercase; padding: 11px 12px; background: #e8f4f8; font-weight: 600;
}
td { padding: 12px; border-top: 1px solid var(--line); vertical-align: middle; }
tr:hover td { background: #f3fbfd; }
.checks { display: flex; flex-wrap: wrap; gap: 10px; margin: 8px 0 14px; }
.checks label { margin: 0; color: var(--ink); display: inline-flex; align-items: center; }

.app { display: flex; min-height: 100vh; background: #eef6f8; }
.side {
  width: 244px; background: linear-gradient(180deg, #0e4a5c, #083344); color: #d5eef2;
  padding: 22px 14px; flex-shrink: 0; display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh;
}
.side-brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 600; text-decoration: none; }
.side-brand:hover { color: #fff; }
.side-brand .mark { background: linear-gradient(135deg, #f0b429, #ffd36a); color: #083344; }
.side-brand .brand-name em { color: #ffd36a; }
.side-sub { color: #7ea8b4; font-size: 12px; margin: 10px 0 6px; }
.role-pill {
  display: inline-block; font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
  color: #ffd36a; border: 1px solid #14505e; padding: 4px 8px; border-radius: 999px; margin: 0 0 16px;
}
.nav-label { color: #6a8f9a; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; padding: 16px 10px 6px; }
.nav-item {
  display: block; padding: 9px 12px; color: #c5e4ea; border-radius: 10px;
  margin-bottom: 3px; font-weight: 500; font-size: 14px; text-decoration: none;
}
.nav-item:hover { background: #0f4554; color: #fff; text-decoration: none; }
.nav-item.on { background: #125060; color: #fff; box-shadow: inset 3px 0 0 #f0b429; }
.side-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid #125060; }
.who-chip { color: #7ea8b4; font-size: 12px; padding: 0 10px 8px; word-break: break-all; }
.app-main { flex: 1; min-width: 0; }
.app-top {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 28px; border-bottom: 1px solid var(--line); background: var(--cream);
}
.app-top h1 { font-size: 28px; margin: 0; }
.who { color: var(--mute); font-size: 13px; margin: 4px 0 0; font-family: var(--sans); }
.app-body { padding: 24px 28px 56px; }
.app .btn { border-radius: 999px; }

.install { padding: 36px 0 88px; background: #f4fafc; }
.install-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; margin-top: 18px; }
.files-box { margin: 18px 0 0; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.card-head h3 { margin: 0; }
.count { color: var(--mute); font-size: 12px; }
.empty { color: var(--mute); padding: 22px; text-align: center; border: 1px dashed var(--line); border-radius: 12px; background: #fff; }
.flash { padding: 12px 14px; border-radius: 12px; font-weight: 500; margin: 16px 0; }
.app-body .flash { margin: 0 0 16px; }
.flash-ok { background: #e4f3ea; color: var(--sage); }
.flash-err { background: #f8e4e2; color: var(--rose); }
.copy-row { display: flex; gap: 10px; align-items: flex-start; }
.copy-row pre { flex: 1; margin: 0; }
.user-name { font-weight: 600; }
.user-mail { color: var(--mute); font-size: 12px; word-break: break-all; font-family: var(--mono); }
.how { margin: 0; padding-left: 18px; }
.how li { margin: 8px 0; }
.sec-k { font-family: var(--serif); color: #0e6a7c; font-size: 15px; margin-right: 8px; font-style: italic; }

@media (max-width: 900px) {
  .app { flex-direction: column; }
  .side { width: auto; height: auto; position: static; }
  .row2, .hero-grid, .grid3, .auth-stage { grid-template-columns: 1fr; }
  .stage { transform: none; }
  .auth-panel { padding: 40px 24px; }
  .app-body, .app-top { padding-left: 16px; padding-right: 16px; }
  .top .wrap { height: auto; padding: 12px 0; flex-wrap: wrap; }
  nav { flex-wrap: wrap; }
}
