/* Si: a painting you can walk into. Rice paper, shan-shui ink wash, brush strokes, a red seal, jade and
   gold flecks; a thin signal-yellow mark for Endfield Industries. The motifs are drawn for this panel; the
   splash art of Si (si-splash-1.webp, icon-si.svg) is official and used at the owner's decision. */

html:has(.theme-si) { color-scheme: only light; background: #f3eee1; }

.theme-si {
  --bg: #f3eee1;
  --bg-soft: #ebe4d2;
  --card: rgb(255 253 247 / .86);
  --card-edge: rgb(11 20 22 / .2);
  --text: #0b1416;
  --muted: #475558;
  --accent: #0c6656;
  --accent-ink: #0b1416;
  --good: #14704a;
  --warn: #7d5200;
  --bad: #a51c27;
  --jade: #77dec8;
  --jade-pale: #a1dbd2;
  --gold: #a27e00;
  --signal: #f7e728;
  --seal: #b3202b;
  --radius: 3px;
  --brush: "Palatino Linotype", "Book Antiqua", Palatino, "Noto Serif", Georgia, serif;
  background: transparent; color: var(--text);
}

.theme-si .backdrop {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    linear-gradient(90deg, rgb(243 238 225 / .82), rgb(243 238 225 / .35) 38%, transparent 62%),
    url("si-landscape-1.svg") center bottom / cover no-repeat,
    radial-gradient(120% 90% at 80% 10%, rgb(161 219 210 / .5), transparent 60%),
    radial-gradient(90% 80% at 10% 100%, rgb(173 188 216 / .35), transparent 60%),
    #f3eee1;
}
.theme-si.with-rail .backdrop, .theme-si:not(.is-home) .backdrop { opacity: .5; }
.theme-si:not(.is-home) .backdrop::after {
  content: ""; position: absolute; right: -120px; bottom: -120px; width: min(58vw, 760px); aspect-ratio: 1; opacity: .34;
  background: url("si-splash-1.webp") center / contain no-repeat;
  -webkit-mask-image: linear-gradient(115deg, transparent 12%, #000 62%); mask-image: linear-gradient(115deg, transparent 12%, #000 62%);
}

.theme-si h1, .theme-si h2, .theme-si h3, .theme-si .brand-text strong { font-family: var(--brush); font-weight: 600; }
.theme-si code { background: rgb(119 222 200 / .28); color: #0b1416; }
.theme-si h2 code { background: none; padding: 0; }
.theme-si a { color: #1f4f82; }

/* the top bar: one broad stroke of ink with a brushed lower edge */
.theme-si .topbar { position: relative; z-index: 3; background: #0b1416; color: #eaf7f2; border-bottom: 0; padding-block: 12px; margin-bottom: 18px; }
.theme-si .topbar::after { content: ""; position: absolute; left: 0; right: 0; top: calc(100% - 2px); height: 30px; background: url("si-edge-1.svg") center top / 100% 100% no-repeat; pointer-events: none; }
.theme-si .topbar::before { content: ""; position: absolute; left: 0; top: 0; width: 132px; height: 4px; background: linear-gradient(110deg, var(--signal) 0 64%, transparent 64% 68%, var(--signal) 68% 76%, transparent 76% 80%, var(--signal) 80% 86%, transparent 86%); }
.theme-si .brand, .theme-si .user-chip { color: #f2fbf9; }
.theme-si .brand-text strong { font-size: 1.25rem; letter-spacing: .02em; }
.theme-si .brand-text small { color: var(--jade-pale); font-style: italic; font-family: var(--brush); }
.theme-si .brand-icon { border-radius: 50%; width: 42px; height: 42px; box-shadow: 0 0 0 2px var(--jade), 0 0 0 3px #0b1416; }
.theme-si .avatar-fallback { background: var(--jade); color: #0b1416; }
.theme-si .topbar .btn-ghost { border: 1px solid var(--jade-pale); color: #f2fbf9; background: none; }
.theme-si .topbar .btn-ghost:hover { background: var(--jade); color: #0b1416; }

/* headings of a page: a brush stroke under the words and the seal at the side */
.theme-si .hud-tag { color: var(--seal); font-family: var(--brush); font-style: italic; letter-spacing: .06em; text-transform: none; font-size: .95rem; }
.theme-si .page-head { position: relative; align-items: center; margin-bottom: 24px; padding-right: 92px; min-height: 78px; }
.theme-si .page-head::after { content: ""; position: absolute; right: 4px; top: 0; width: 72px; height: 72px; background: url("si-seal-1.svg") center / contain no-repeat; transform: rotate(-5deg); opacity: .92; }
.theme-si .page-head h1 { font-size: clamp(2rem, 4.6vw, 3rem); line-height: 1.05; padding-bottom: 20px; margin-bottom: 4px; background: url("si-stroke-jade-1.svg") left bottom / min(100%, 330px) 20px no-repeat; }
.theme-si .lead { color: #33454a; font-size: 1.04rem; }

/* cards: sheets of paper hung from a stroke of ink */
.theme-si .panel, .theme-si .form-card, .theme-si .fatal-card {
  position: relative; border: 0; border-radius: 2px; padding: 24px 22px 20px; margin-top: 10px;
  background: var(--card); box-shadow: 0 1px 0 rgb(11 20 22 / .12), 0 16px 34px -14px rgb(11 20 22 / .28);
}
.theme-si .panel::before, .theme-si .form-card::before, .theme-si .fatal-card::before {
  content: ""; position: absolute; left: -6px; right: -6px; top: -11px; height: 22px; background: url("si-stroke-ink-1.svg") center / 100% 100% no-repeat; pointer-events: none;
}
.theme-si .callout { background: rgb(161 219 210 / .34); border: 0; border-left: 5px solid #2f8f7d; border-radius: 0; }
.theme-si .callout-error { background: rgb(200 50 60 / .12); border-left-color: var(--seal); }
.theme-si .flash { background: rgb(255 253 247 / .94); box-shadow: 0 8px 20px -10px rgb(11 20 22 / .35); border-left: 5px solid var(--muted); border-radius: 0; }
.theme-si .flash-ok { border-left-color: #2f8f7d; }
.theme-si .flash-warning { border-left-color: var(--gold); }
.theme-si .flash-error { border-left-color: var(--seal); }

/* numbers */
.theme-si .stat-label { font-family: var(--brush); font-style: italic; font-size: .98rem; }
.theme-si .stat-value { font-family: var(--brush); font-size: 2.1rem; line-height: 1.2; }
.theme-si .pulse { width: 14px; height: 14px; border-radius: 52% 48% 56% 44% / 46% 55% 45% 54%; }
.theme-si .stat-online .pulse { background: #2f9e86; box-shadow: 0 0 0 4px rgb(119 222 200 / .45); }
.theme-si .stat-offline .pulse { background: var(--seal); box-shadow: 0 0 0 4px rgb(200 50 60 / .2); }

/* the rail: ink on paper, the open page is one stroke */
.theme-si .rail-group { font-family: var(--brush); font-style: italic; text-transform: none; letter-spacing: .02em; font-size: .92rem; color: var(--seal); }
.theme-si .rail-nav a { border-radius: 0; padding: 9px 14px; color: #0b1416; }
.theme-si .rail-nav a:hover { background: url("si-stroke-jade-1.svg") center / 100% 100% no-repeat; }
.theme-si .rail-nav a[aria-current="page"] { background: url("si-brush-ink-1.svg") center / 100% 100% no-repeat; color: #f2fbf9; box-shadow: none; }
.theme-si .rail-nav a[aria-current="page"] .rail-index { color: var(--jade); }
.theme-si .rail-index, .theme-si .server-index, .theme-si .hud-index { font-family: var(--brush); color: var(--seal); letter-spacing: .04em; }
.theme-si .rail-back { color: #1f4f82; }
.theme-si .rail-guild img, .theme-si .server-icon { border-radius: 50%; }
.theme-si .server-initials { background: #0b1416; color: var(--jade); font-family: var(--brush); }

/* servers and links */
.theme-si .server-card { position: relative; border: 0; border-radius: 2px; padding: 18px; background: var(--card); box-shadow: 0 14px 30px -16px rgb(11 20 22 / .4); transition: transform .2s, box-shadow .2s; }
.theme-si .server-card::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -7px; height: 14px; background: url("si-stroke-ink-1.svg") center / 100% 100% no-repeat; opacity: .85; }
.theme-si .server-card:hover, .theme-si .nav-card:hover { transform: translateY(-3px); box-shadow: 0 20px 36px -16px rgb(11 20 22 / .5); }
.theme-si .nav-card { transition: transform .2s, box-shadow .2s; }
.theme-si .badge { border: 1px solid rgb(11 20 22 / .35); border-radius: 2px; }
.theme-si .badge-owner { background: var(--seal); border-color: var(--seal); color: #fdf7ea; }
.theme-si .tag, .theme-si .role-chip { background: rgb(161 219 210 / .35); border-color: rgb(12 102 86 / .35); border-radius: 2px; }
.theme-si .status, .theme-si .state { border-radius: 2px; }
.theme-si .status-ok, .theme-si .state-on { background: rgb(119 222 200 / .3); }
.theme-si .role-dot { box-shadow: 0 0 0 1px rgb(11 20 22 / .25); border-radius: 50%; }

/* buttons: strokes of paint */
.theme-si .btn { border: 0; border-radius: 0; padding: 10px 20px; font-family: var(--brush); font-size: 1.04rem; background: url("si-brush-ink-1.svg") center / 100% 100% no-repeat; color: #f2fbf9; transition: filter .15s, transform .15s; }
.theme-si .btn-primary { background-image: url("si-brush-jade-1.svg"); color: #0b1416; font-weight: 600; }
.theme-si .btn-danger { background-image: url("si-brush-seal-1.svg"); color: #fff7ee; }
.theme-si .btn-ghost { background: none; border: 1px solid rgb(11 20 22 / .5); color: #0b1416; border-radius: 2px; }
.theme-si .btn-ghost:hover { background: #0b1416; color: #f2fbf9; }
.theme-si .btn:hover { transform: translateY(-1px); filter: saturate(1.15) brightness(1.04); }
.theme-si .btn-small { padding: 6px 14px; font-size: .95rem; }
.theme-si .btn-large { padding: 16px 34px; font-size: 1.16rem; }
.theme-si :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  background: rgb(255 255 255 / .82); color: #0b1416; border: 1px solid rgb(11 20 22 / .3); border-bottom: 2px solid #0b1416; border-radius: 2px;
}
.theme-si :focus-visible { outline: 2px solid #2b619a; outline-offset: 2px; }
.theme-si :is(input[type="checkbox"], input[type="radio"]) { accent-color: #0c6656; }
.theme-si .preview { background: rgb(255 255 255 / .6); border-left-color: var(--seal); }
.theme-si .row-remove, .theme-si .chip-remove { color: var(--seal); }

/* the front page */
.theme-si.is-home .hero { min-height: 54vh; display: grid; align-content: center; padding: 34px 0 26px; }
.theme-si.is-home .display { font-size: clamp(2.5rem, 6.4vw, 4.6rem); line-height: 1.04; max-width: 15ch; padding-bottom: 30px; background: url("si-stroke-jade-1.svg") left bottom / min(100%, 520px) 30px no-repeat; margin-bottom: 18px; }
.theme-si.is-home .lead { max-width: 46ch; font-size: 1.12rem; }
.theme-si.is-home { overflow-x: clip; }
.theme-si.is-home .backdrop { opacity: .42; }
.theme-si.is-home .hero { position: relative; isolation: isolate; min-height: min(78vh, 780px); }
.theme-si.is-home .hero::after {
  content: ""; position: absolute; z-index: -1; top: 50%; right: -190px; width: min(62vw, 880px); aspect-ratio: 1; translate: 0 -50%;
  background: url("si-splash-1.webp") center / contain no-repeat; pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 4%, #000 34%); mask-image: linear-gradient(90deg, transparent 4%, #000 34%);
}
.theme-si .footer { color: #24363a; background: linear-gradient(transparent, rgb(243 238 225 / .82)); }

@media (max-width: 760px) {
  .theme-si.is-home .hero::after { right: -34vw; width: 128vw; opacity: .3; top: 42%; }
  .theme-si .page-head { padding-right: 0; }
  .theme-si .page-head::after { display: none; }
}
@media (prefers-reduced-motion: reduce) { .theme-si * { transition: none !important; } }
