/* Stelix Campaigns, standalone. FRAME is Stelix (obsidian, warm paper, Instrument Sans and Serif, the S mark)
   and the same for every tenant; SIGNAL is the tenant: --tenant on the one primary action and the focus ring.
   Text never goes below 16px; body 17px. */
@font-face { font-family: "Instrument Sans"; src: url("fonts/InstrumentSans-400-latin.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/InstrumentSans-500-latin.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/InstrumentSans-600-latin.woff2") format("woff2"); font-weight: 600 700; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("fonts/InstrumentSerif-400-latin.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root { --obsidian: #0A0908; --paper: #FCFBF9; --line: #E6E6E9; --mute: #5E5E66; }
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font: 400 17px/1.55 "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif; color: #2B2B30; background: var(--paper); -webkit-text-size-adjust: 100%; }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 3px solid var(--tenant); outline-offset: 2px; }

/* ---------------------------------------------------------------- app bar (FRAME + tenant SIGNAL) */
.app-shell { display: flex; flex-direction: column; height: 100vh; height: 100dvh; overflow: hidden; }
.app-bar { flex: none; display: flex; align-items: center; gap: 18px; min-height: 60px; padding: env(safe-area-inset-top) 20px 0 20px;
  background: var(--obsidian); color: #F4F2EE; position: relative; z-index: 5; }
.app-bar__frame { display: inline-flex; align-items: center; gap: 10px; color: #F4F2EE; text-decoration: none; font: 400 24px/1 "Instrument Serif", Georgia, serif; white-space: nowrap; }
.app-tenant { display: inline-flex; align-items: center; gap: 10px; min-width: 0; padding-left: 18px; border-left: 1px solid rgba(255,255,255,.16); }
.app-tenant__badge { flex: none; display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: var(--tenant); color: var(--tenant-on); font-weight: 600; font-size: 16px; }
.app-tenant__logo { flex: none; height: 30px; width: auto; border-radius: 6px; background: #fff; }
.app-tenant__name { font-weight: 600; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-bar__right { margin-left: auto; display: flex; align-items: center; gap: 14px; min-width: 0; }
.app-bar__who { font-size: 16px; color: #CFCBC4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 32ch; }
.app-bar__who small { font-size: 16px; color: #8E8A84; margin-left: 4px; }
.app-bar__out { flex: none; border: 1px solid rgba(255,255,255,.22); background: transparent; color: #F4F2EE; border-radius: 10px; padding: 7px 14px; font-size: 16px; cursor: pointer; white-space: nowrap; }
.app-bar__out:hover { border-color: var(--tenant); }
.app-switch { display: flex; align-items: center; gap: 8px; min-width: 0; }
.app-switch__label { font-size: 16px; color: #8E8A84; }
.app-switch select { min-width: 0; max-width: 220px; background: #1C1B19; color: #F4F2EE; border: 1px solid rgba(255,255,255,.22); border-radius: 10px; padding: 6px 10px; font-size: 16px; }
.app-bar form { margin: 0; }

/* ---------------------------------------------------------------- two panes */
.app-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 300px minmax(0, 1fr); }
#layout-sidebar { min-height: 0; display: flex; flex-direction: column; background: #fff; border-right: 1px solid var(--line); }
#layout-sidebar > .header { flex: none; display: flex; align-items: center; height: 56px; padding: 0 16px; border-bottom: 1px solid var(--line);
  font: 400 24px/1 "Instrument Serif", Georgia, serif; color: var(--obsidian); }
#layout-sidebar > .scroller { flex: 1; min-height: 0; overflow-y: auto; }
#layout-content { min-height: 0; min-width: 0; display: flex; flex-direction: column; }
#layout-content > .header { flex: none; display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 20px; border-bottom: 1px solid var(--line); background: #fff; }
#layout-content > .header .header-title { font: 400 26px/1 "Instrument Serif", Georgia, serif; color: var(--obsidian); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.back-sidebar-button { display: none; flex: none; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 6px 12px; font-size: 16px; cursor: pointer; color: var(--obsidian); }
#layout-content > .sc-scroller { flex: 1; min-height: 0; overflow-y: auto; }
.sc-standalone .sc-content, .sc-standalone .sc-sidebar { --signal: var(--tenant); --signal-ink: var(--tenant-ink); }
.sc-standalone .sc-btn--signal { box-shadow: none; color: var(--tenant-on); }
.sc-standalone .sc-btn--signal:hover:not(:disabled) { background: var(--tenant); filter: brightness(.9); }
.sc-standalone .sc-step { color: var(--tenant-on); }
.sc-toast.is-bad { color: #fff !important; } /* .is-bad paints text red, and the toast's own background is red */
.sc-standalone .sc-main { font-size: 17px; }

/* phones: one pane at a time, like the inbox (campaigns.js shows the content pane on navigation) */
html.layout-phone .app-body { grid-template-columns: minmax(0, 1fr); }
html.layout-phone #layout-sidebar.hidden, html.layout-phone #layout-content.hidden { display: none; }
html.layout-phone .back-sidebar-button { display: inline-block; }
html.layout-phone .app-bar { gap: 10px; padding-left: 12px; padding-right: 12px; }
html.layout-phone .app-bar__frame span, html.layout-phone .app-bar__who, html.layout-phone .app-switch__label { display: none; }
html.layout-phone .app-tenant { padding-left: 10px; }
html.layout-phone .app-switch select { max-width: 120px; }
html.layout-phone #layout-content > .header { padding: 0 12px; }

/* ---------------------------------------------------------------- domain setup */
.sc-dnsbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 0 0 8px; }
.sc-dnsbar p { margin: 0; color: var(--mute); }
.sc-banner { border-radius: 12px; padding: 14px 16px; margin: 0 0 18px; font-size: 17px; }
.sc-banner--ok { background: #E7F4EC; color: #14532D; }
.sc-banner--block { background: #FFF4DC; color: #6B3F00; }
.sc-banner a { color: inherit; font-weight: 600; }
.sc-rec { border-top: 1px solid var(--line); padding: 22px 0 24px; }
.sc-rec__head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 6px; }
.sc-rec__head h2 { margin: 0; font: 400 27px/1.15 "Instrument Serif", Georgia, serif; color: var(--obsidian); }
.sc-rec__purpose { margin: 0 0 14px; color: var(--mute); max-width: 70ch; }
.sc-st { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 2px 12px; font-size: 16px; font-weight: 600; white-space: nowrap; }
.sc-st::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.sc-st--ok { background: #E7F4EC; color: #1F7A4D; }
.sc-st--missing { background: #FDECEA; color: #B42318; }
.sc-st--wrong { background: #FDECEA; color: #B42318; }
.sc-st--pending, .sc-st--unchecked { background: #F1F1F4; color: #5E5E66; }
.sc-kv { display: grid; grid-template-columns: 7.5em minmax(0, 1fr); gap: 10px 14px; margin: 0; align-items: start; }
.sc-kv dt { color: var(--mute); padding-top: 9px; }
.sc-kv dd { margin: 0; min-width: 0; display: flex; gap: 8px; align-items: flex-start; }
.sc-copyval { flex: 1; min-width: 0; font: 16px/1.45 ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: #F7F7F8; border: 1px solid var(--line); border-radius: 10px;
  padding: 8px 12px; overflow-wrap: anywhere; word-break: break-all; color: var(--obsidian); }
.sc-copy { flex: none; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 7px 14px; font-size: 16px; cursor: pointer; color: var(--obsidian); white-space: nowrap; }
.sc-copy:hover { border-color: var(--tenant); }
.sc-found { margin: 14px 0 0; padding: 12px 14px; border-left: 3px solid var(--line); background: #FAFAFB; }
.sc-found--ok { border-left-color: #1F7A4D; }
.sc-found--missing, .sc-found--wrong { border-left-color: #B42318; }
.sc-found p { margin: 0; }
.sc-found code { display: block; margin-top: 6px; font: 16px/1.45 ui-monospace, "SF Mono", Menlo, monospace; overflow-wrap: anywhere; word-break: break-all; color: var(--obsidian); }
.sc-dnsnote { color: var(--mute); margin: 18px 0 0; }
.sc-ns { margin: 8px 0 0; padding-left: 1.2em; }
@media (max-width: 640px) {
  .sc-kv { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .sc-kv dt { padding-top: 8px; }
}
.sc-navdot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #B42318; margin-left: 8px; vertical-align: middle; }

/* ---------------------------------------------------------------- sign in */
.app-login { background: var(--paper); }
.login { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.login--msg { grid-template-columns: 1fr; }
.login__brand { position: relative; overflow: hidden; background: var(--obsidian); color: #F4F2EE; display: flex; flex-direction: column; justify-content: center; padding: 56px; }
.login__field { position: absolute; inset: -20%; background: radial-gradient(40% 35% at 30% 70%, color-mix(in srgb, var(--tenant) 55%, transparent), transparent 70%),
  radial-gradient(35% 30% at 75% 25%, rgba(255,106,0,.28), transparent 70%); filter: blur(30px); opacity: .55; animation: sc-drift 26s ease-in-out infinite alternate; }
@keyframes sc-drift { to { transform: translate(4%, -3%) scale(1.06); } }
@media (prefers-reduced-motion: reduce) { .login__field { animation: none; } }
.login__brandtext { position: relative; max-width: 30ch; }
.login__mark { display: block; margin: 0 0 22px; }
.login__eyebrow { margin: 0 0 10px; font-size: 16px; letter-spacing: .14em; text-transform: uppercase; color: #B9B4AC; }
.login__name { margin: 0 0 14px; font: 400 clamp(44px, 6vw, 72px)/1.02 "Instrument Serif", Georgia, serif; letter-spacing: -.01em; overflow-wrap: anywhere; }
.login__line { margin: 0; color: #CFCBC4; font-size: 18px; }
.login__by { position: absolute; left: 56px; bottom: 32px; margin: 0; font-size: 16px; color: #8E8A84; letter-spacing: .08em; }
.login__pane { display: flex; justify-content: center; align-items: center; padding: 48px 24px 72px; }
.login__form { width: 100%; max-width: 440px; margin-top: -6vh; }
.login__form h2 { margin: 0 0 6px; font: 400 40px/1.1 "Instrument Serif", Georgia, serif; color: var(--obsidian); }
.login__sub { margin: 0 0 22px; color: var(--mute); }
.login__error { margin: 0 0 16px; padding: 10px 14px; border-radius: 10px; background: #FDECEA; color: #B42318; }
.login__form label { display: block; font-weight: 500; margin: 0 0 6px; color: var(--obsidian); }
.login__form input { display: block; width: 100%; min-width: 0; margin: 0 0 16px; padding: 12px 14px; border: 1px solid #D6D3CE; border-radius: 12px; background: #fff; font-size: 17px; }
.login__go { width: 100%; border: 0; border-radius: 12px; padding: 13px 18px; background: var(--tenant); color: var(--tenant-on); font-weight: 600; font-size: 17px; cursor: pointer; }
.login__quick { margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line); }
.login__quick h3 { margin: 0 0 4px; font: 400 26px/1.15 "Instrument Serif", Georgia, serif; color: var(--obsidian); }
.login__qt { margin: 14px 0 8px; font-weight: 600; color: var(--obsidian); }
.login__qrow { display: flex; flex-wrap: wrap; gap: 8px; }
.login__qrow form { margin: 0; }
.login__as { border: 1px solid #D6D3CE; background: #fff; border-radius: 999px; padding: 8px 14px; font-size: 16px; cursor: pointer; color: var(--obsidian); }
.login__as span { color: var(--mute); }
.login__as:hover { border-color: var(--tenant); }
.login__link { border: 0; background: none; color: var(--mute); text-decoration: underline; padding: 0; margin-top: 18px; font-size: 16px; cursor: pointer; }
.pick { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pick form { margin: 0; }
.pick button { width: 100%; display: flex; align-items: center; gap: 14px; text-align: left; border: 1px solid #D6D3CE; background: #fff; border-radius: 14px; padding: 14px 16px; cursor: pointer; }
.pick button:hover { border-color: var(--tenant); }
.pick strong { display: block; color: var(--obsidian); }
.pick small { display: block; color: var(--mute); font-size: 16px; }
@media (max-width: 820px) {
  .login { grid-template-columns: 1fr; }
  .login__brand { min-height: auto; padding: calc(28px + env(safe-area-inset-top)) 24px 28px; }
  .login__mark { margin-bottom: 14px; width: 30px; height: auto; }
  .login__name { font-size: 44px; }
  .login__line { display: none; }
  .login__by { display: none; }
  .login__pane { align-items: flex-start; padding: 28px 20px 48px; }
  .login__form { margin-top: 0; }
}

/* ---------------------------------------------------------------- text floor: campaigns.css sizes under 16px, raised */
.sc-standalone .sc-main,
.sc-standalone .sc-nav__head,
.sc-standalone .sc-nav__add,
.sc-standalone .sc-nav__meta,
.sc-standalone .sc-nav__empty,
.sc-standalone .sc-card h3,
.sc-standalone .sc-step,
.sc-standalone .sc-note, .sc-standalone .sc-sub, .sc-standalone .sc-foot,
.sc-standalone .sc-how li:before,
.sc-standalone .sc-field label,
.sc-standalone .sc-field input, .sc-standalone .sc-field select, .sc-standalone .sc-field textarea,
.sc-standalone .sc-field textarea#f_body_html,
.sc-standalone .sc-field small,
.sc-standalone .sc-btn,
.sc-standalone .sc-btn--sm,
.sc-standalone .sc-pill,
.sc-standalone .sc-nav .sc-pill,
.sc-standalone .sc-badge,
.sc-standalone .sc-st,
.sc-standalone .sc-dirty,
.sc-standalone .sc-preview__bar,
.sc-standalone .sc-preview__mode button,
.sc-standalone .sc-stat__l,
.sc-standalone .sc-stat__s,
.sc-standalone .sc-table th,
.sc-standalone .sc-table--tight td,
.sc-standalone .sc-tabs button,
.sc-standalone .sc-tabs button span,
.sc-standalone .sc-check-all,
.sc-standalone .sc-dlg .sc-field label,
.sc-standalone .sc-toast,
.sc-standalone .sc-chart figcaption { font-size: 16px; }
