/* otmoon — the site's one stylesheet (landing and customer panel). The app's identity: cyan #00E5FF over neutral greys, IBM Plex
   (the same fonts as native/editor/assets/fonts, OFL). Dark only. */

@font-face { font-family: "IBM Plex Sans"; src: url("/static/fonts/IBMPlexSans-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/static/fonts/IBMPlexSans-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/static/fonts/IBMPlexSans-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("/static/fonts/IBMPlexSans-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/static/fonts/IBMPlexMono-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/static/fonts/IBMPlexMono-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }

:root {
  --bg: #1b1d21;
  --bg-2: #2b2d31;
  --bg-3: #34373c;
  --bg-4: #3d4046;
  --line: #4b4f56;
  --line-2: #5c6069;
  --text: #ececec;
  --text-2: #b4b8bf;
  --text-3: #80858e;
  --brand: #00e5ff;
  --brand-dim: rgba(0, 229, 255, .14);
  --brand-ink: #062a2e;
  --ok: #2ecc71;
  --warn: #f0b429;
  --bad: #e74c3c;
  --r: 10px;
  --r-s: 6px;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", Consolas, "SF Mono", monospace;
  --shadow: 0 10px 40px rgba(0, 0, 0, .45);
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); background: var(--bg); color: var(--text); font-size: 15px; line-height: 1.55; min-height: 100vh; -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
.mono { font-family: var(--mono); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--text-3); }
.small { font-size: 13px; }
.hidden { display: none !important; }

/* ---- the brand mark: the moon, drawn like the app's test card logo ---- */
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; letter-spacing: .2px; }
.brand:hover { text-decoration: none; }
.moon { width: 26px; height: 26px; border-radius: 50%; background: var(--brand); position: relative; flex: none; box-shadow: 0 0 18px rgba(0, 229, 255, .35); }
.moon::after { content: ""; position: absolute; left: 7px; top: -2px; width: 22px; height: 22px; border-radius: 50%; background: var(--bg); }
.brand .word { font-size: 19px; }
.brand .word b { color: var(--brand); font-weight: 600; }

/* ---- buttons ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: var(--r-s); border: 1px solid var(--line); background: var(--bg-3); color: var(--text); font-weight: 500; cursor: pointer; transition: background .15s, border-color .15s, color .15s, transform .05s; white-space: nowrap; }
.btn:hover { background: var(--bg-4); border-color: var(--line-2); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); font-weight: 600; }
.btn-primary:hover { background: #33eaff; border-color: #33eaff; }
.btn-ghost { background: transparent; }
.btn-danger { border-color: rgba(231, 76, 60, .5); color: #ff8a7a; background: transparent; }
.btn-danger:hover { background: rgba(231, 76, 60, .12); }
.btn-lg { padding: 13px 24px; font-size: 16px; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-block { width: 100%; }

/* ---- forms ---- */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); text-transform: uppercase; letter-spacing: .6px; margin-bottom: 6px; }
.field input, .field select, .field textarea { width: 100%; padding: 10px 12px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-s); color: var(--text); outline: none; transition: border-color .15s, box-shadow .15s; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-dim); }
.field input::placeholder, .field textarea::placeholder { color: var(--text-3); }
.field .hint { font-size: 12px; color: var(--text-3); margin-top: 5px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 560px) { .grid-2 { grid-template-columns: 1fr; } }

/* ---- alerts, badges, toast ---- */
.alert { display: none; padding: 10px 14px; border-radius: var(--r-s); font-size: 14px; margin-bottom: 14px; border: 1px solid transparent; }
.alert.show { display: block; }
.alert-bad { background: rgba(231, 76, 60, .12); border-color: rgba(231, 76, 60, .4); color: #ff9a8c; }
.alert-ok { background: rgba(46, 204, 113, .12); border-color: rgba(46, 204, 113, .4); color: #6fe3a0; }
.alert-info { background: var(--brand-dim); border-color: rgba(0, 229, 255, .4); color: var(--brand); }
.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 11px; font-weight: 600; letter-spacing: .4px; text-transform: uppercase; }
.badge-ok { background: rgba(46, 204, 113, .15); color: #6fe3a0; }
.badge-warn { background: rgba(240, 180, 41, .15); color: #ffd36a; }
.badge-bad { background: rgba(231, 76, 60, .15); color: #ff9a8c; }
.badge-brand { background: var(--brand-dim); color: var(--brand); }
.badge-grey { background: var(--bg-4); color: var(--text-2); }
#toast { position: fixed; bottom: 24px; right: 24px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--r-s); padding: 12px 18px; font-size: 14px; box-shadow: var(--shadow); opacity: 0; transform: translateY(10px); transition: opacity .2s, transform .2s; pointer-events: none; z-index: 200; max-width: 340px; }
#toast.show { opacity: 1; transform: none; }

/* ---- cards and panels ---- */
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; }
.card h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.card p { color: var(--text-2); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 12px; margin-bottom: 16px; border-bottom: 1px solid var(--line); }
.panel-head h2 { font-size: 15px; font-weight: 600; text-transform: uppercase; letter-spacing: .8px; color: var(--text-2); }

/* ---- the top bar ---- */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(27, 29, 33, .86); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--text-2); font-weight: 500; font-size: 14px; }
.nav a:hover { color: var(--text); text-decoration: none; }
.nav .btn { padding: 8px 14px; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: var(--r-s); width: 38px; height: 38px; cursor: pointer; }
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--text); margin: 4px auto; }
@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; align-items: stretch; background: var(--bg-2); border-bottom: 1px solid var(--line); padding: 14px 20px; gap: 14px; }
  .nav.open { display: flex; }
}

/* ---- tables ---- */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .6px; color: var(--text-3); padding: 8px 10px; border-bottom: 1px solid var(--line); }
td { padding: 11px 10px; border-bottom: 1px solid rgba(75, 79, 86, .5); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
.key { font-family: var(--mono); letter-spacing: 1px; color: var(--brand); font-weight: 500; }

/* ---- modal ---- */
.modal-bg { position: fixed; inset: 0; background: rgba(0, 0, 0, .6); display: none; align-items: center; justify-content: center; z-index: 100; padding: 20px; }
.modal-bg.open { display: flex; }
.modal { background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--r); padding: 26px; width: 100%; max-width: 460px; box-shadow: var(--shadow); }
.modal h3 { font-size: 18px; margin-bottom: 10px; }
.modal p { color: var(--text-2); margin-bottom: 18px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; }

/* ---- footer ---- */
footer { border-top: 1px solid var(--line); padding: 36px 0; color: var(--text-3); font-size: 13px; }
footer .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
footer a { color: var(--text-2); }
