:root {
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    "Segoe UI",
    sans-serif;
  color: #18293f;
  background: #f6f8fc;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  line-height: 1.5;
}
button,
input,
textarea,
select {
  font: inherit;
}
button {
  cursor: pointer;
}
a {
  color: #2165d9;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
.nav {
  height: 76px;
  display: flex;
  align-items: center;
  gap: 28px;
  border-bottom: 1px solid #e1e8f1;
}
.logo {
  font-size: 21px;
  font-weight: 850;
  letter-spacing: -0.8px;
  color: #11263b;
  display: flex;
  align-items: center;
  gap: 9px;
}
.logo-mark {
  display: inline-flex;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  align-items: center;
  justify-content: center;
  background: #376deb;
  color: white;
  font-size: 24px;
}
.beta {
  border: 1px solid #c9d5ee;
  color: #5f7693;
  border-radius: 5px;
  padding: 2px 5px;
  font-size: 10px;
  letter-spacing: 1.3px;
}
.nav-hint {
  font-size: 13px;
  color: #70849a;
}
.nav button#logout { margin-left:0; }
.locale-picker { display:flex; gap:8px; align-items:center; margin-left:auto; color:#627992; font-size:12px; }
.locale-picker select { width:auto; min-width:128px; border:1px solid #d2ddf1; background:#fff; color:#263d65; border-radius:9px; padding:8px 9px; cursor:pointer; font-size:13px; }
.locale-picker select:focus-visible {outline:2px solid #4378de; outline-offset:2px;}
@media(max-width:690px){
 .nav{gap:9px;flex-wrap:wrap;height:auto;min-height:76px;padding-top:12px;padding-bottom:12px;}
 .nav-hint{display:none;}
 .locale-picker{gap:0;}
 .locale-picker span{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);}
 .locale-picker select{min-width:108px;max-width:127px;}
}
.hero {
  padding: 54px 0 30px;
}
.eyebrow {
  color: #386be7;
  font-size: 12px;
  letter-spacing: 2px;
  font-weight: 800;
}
.hero h1 {
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.1;
  letter-spacing: -2.6px;
  margin: 10px 0 14px;
  color: #122b44;
}
.hero p:not(.eyebrow) {
  color: #63768a;
  max-width: 650px;
  font-size: 17px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.statgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
}
.card {
  background: #fff;
  border: 1px solid #e1e7f1;
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 8px 26px rgba(38, 68, 107, 0.035);
  margin: 0 0 18px;
}
.card h2 {
  font-size: 21px;
  letter-spacing: -0.6px;
  margin: 0 0 16px;
}
.card h3 {
  margin: 0 0 9px;
  font-size: 16px;
}
.card p {
  color: #6d7f91;
}
.muted,
.hint {
  color: #75889b;
  font-size: 13px;
}
.stat {
  background: #fff;
  border-radius: 15px;
  padding: 19px;
  border: 1px solid #e1e7f1;
}
.stat strong {
  display: block;
  font-size: 25px;
  letter-spacing: -0.7px;
}
.stat span {
  color: #78899d;
  font-size: 12px;
}
.tabs {
  display: flex;
  gap: 8px;
  margin: 8px 0 22px;
  flex-wrap: wrap;
}
.tabs button {
  padding: 9px 19px;
  border-radius: 30px;
  border: 1px solid #d9e3ef;
  background: white;
  color: #52677d;
  font-weight: 600;
}
.tabs button.active {
  background: #346ee9;
  color: white;
  border-color: #346ee9;
}
label {
  display: block;
  color: #51657b;
  font-weight: 650;
  font-size: 13px;
  margin: 12px 0 6px;
}
input,
textarea,
select {
  width: 100%;
  padding: 11px 12px;
  color: #213b56;
  border: 1px solid #ced9e7;
  border-radius: 10px;
  background: #fff;
  outline: none;
}
input:focus,
textarea:focus {
  border-color: #3d74eb;
  box-shadow: 0 0 0 3px #eaf0ff;
}
textarea {
  min-height: 74px;
  resize: vertical;
}
.row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.row > * {
  flex-shrink: 0;
}
button.primary,
button.secondary,
button.ghost {
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid #326de8;
  background: #356fea;
  color: #fff;
  font-weight: 700;
}
button.secondary {
  background: #eef3ff;
  color: #3566cb;
  border-color: #dce7ff;
}
button.ghost {
  background: white;
  color: #53697e;
  border-color: #d9e2ed;
}
button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.notice {
  border-radius: 12px;
  background: #eef5ff;
  border: 1px solid #d4e4ff;
  padding: 13px 16px;
  color: #325780;
  font-size: 13px;
  margin: 14px 0;
}
.warning {
  background: #fff7e8;
  border-color: #f4dfad;
  color: #7c5d22;
}
.err {
  color: #bb3459;
  font-weight: 650;
}
.ok {
  color: #147b58;
  font-weight: 650;
}
.item {
  border-top: 1px solid #edf0f5;
  padding: 15px 0;
}
.item:first-child {
  border-top: 0;
}
.item strong {
  color: #203953;
}
.item .muted {
  margin: 3px 0 7px;
}
code {
  background: #f0f4fb;
  border-radius: 5px;
  padding: 2px 5px;
  font-size: 12px;
  overflow-wrap: anywhere;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #132640;
  color: #d9e9ff;
  border-radius: 12px;
  padding: 15px;
  font-size: 12px;
}
.footer {
  padding: 50px 24px 30px;
  color: #8898ac;
  font-size: 12px;
}
.hidden {
  display: none !important;
}
@media (max-width: 740px) {
  .grid,
  .statgrid {
    grid-template-columns: 1fr;
  }
  .nav-hint {
    display: none;
  }
  .wrap {
    padding: 0 16px;
  }
  .hero {
    padding: 35px 0 20px;
  }
  .card {
    padding: 18px;
  }
}

/* Publisher credentials should be explicitly copied, never shown in alert(). */
.secret-dialog {
  width: min(540px, calc(100vw - 32px));
  max-height: min(85vh, 640px);
  border: 1px solid #d9e2ed;
  border-radius: 16px;
  padding: 24px;
  color: #18293f;
  background: #fff;
  box-shadow: 0 24px 70px #13264033;
}
.secret-dialog::backdrop { background: #132640aa; }
.secret-dialog h2 { margin: 0 0 12px; }
.secret-dialog p { margin: 0 0 16px; }
.secret-dialog input { width: 100%; font-family: ui-monospace, Consolas, monospace; }
.secret-dialog .row { margin-top: 14px; }

/* A readable guided campaign editor; no extra frontend framework needed. */
.campaign-section {
  border: 1px solid #dfe7f2;
  border-radius: 14px;
  padding: 18px;
  margin: 18px 0;
  min-width: 0;
  background: #fbfcff;
}
.campaign-section legend {
  font-size: 16px;
  font-weight: 750;
  color: #173150;
  padding: 0 8px;
}
.campaign-section > .hint { margin-top: 2px; }
.option-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.campaign-estimate {
  margin: 14px 0 0;
  padding: 13px 14px;
  border: 1px solid #cde0f5;
  background: #eef5ff;
  color: #244b81 !important;
  border-radius: 10px;
  font-size: 14px;
}
@media (max-width: 740px) {
  .option-grid { grid-template-columns: 1fr; gap: 0; }
  .campaign-section { padding: 12px; }
}

/* Financial amounts stay legible without making the campaign screen noisy. */
.campaign-budget { margin: 12px 0; }
.campaign-budget-bar {
  width: 100%;
  height: 13px;
  background: #edf2f9;
  border-radius: 999px;
  overflow: hidden;
  display: flex;
}
.campaign-budget-bar > span { display: block; height: 100%; }
.budget-spent { background: #346fe9; }
.budget-reserved { background: #edb153; }
.budget-legend { display: flex; flex-wrap: wrap; gap: 7px 18px; margin: 10px 0; }
.budget-legend span { font-size: 12px; color: #647993; }
.budget-legend strong { font-size: 13px; color: #203953; }
.managed-head { display: flex; gap: 9px; align-items: baseline; flex-wrap: wrap; }
.rename-details { margin-top: 10px; }
.rename-details summary { cursor: pointer; color: #3d70c7; font-size: 13px; }
.rename-details form { max-width: 460px; margin-top: 10px; }
.rename-details form input { margin-bottom: 8px; }

/* Bottom-edge feedback for account actions, independent of scroll position. */
.toast-region {
  position: fixed;
  z-index: 1200;
  right: 22px;
  bottom: max(22px, env(safe-area-inset-bottom));
  width: min(440px, calc(100vw - 32px));
  pointer-events: none;
}
.toast-message {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 14px;
  border: 1px solid #d4e4ff;
  border-radius: 13px;
  background: #f5f9ff;
  box-shadow: 0 12px 36px rgba(19, 38, 64, 0.18);
  color: #264b78;
  font-size: 14px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  pointer-events: auto;
}
.toast-success {
  background: #effbf5;
  border-color: #bfe7d1;
  color: #126a42;
}
.toast-error {
  background: #fff2f0;
  border-color: #f3c6be;
  color: #9b3028;
}
.toast-symbol {
  flex: 0 0 23px;
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  border-radius: 50%;
  color: inherit;
  font-weight: 800;
  background: #e1ebfc;
}
.toast-success .toast-symbol { background: #d4f0df; }
.toast-error .toast-symbol { background: #f9ddd7; }
.toast-text { flex: 1; min-width: 0; padding-top: 1px; }
.toast-dismiss {
  flex-shrink: 0;
  border: 0;
  background: transparent;
  color: inherit;
  opacity: .8;
  padding: 0 4px;
  font-size: 23px;
  line-height: 1;
  cursor: pointer;
}
.toast-dismiss:hover, .toast-dismiss:focus-visible { opacity: 1; }
@media (max-width: 740px) {
  .toast-region {
    left: 16px;
    right: 16px;
    bottom: max(16px, env(safe-area-inset-bottom));
    width: auto;
  }
}

/* Account and Email: lightweight, accessible forms without a new UI framework. */
.mail-check { display:flex; align-items:center; gap:10px; margin:11px 0; }
.mail-check input { width:18px; height:18px; flex:0 0 auto; }
#ticketDetail { margin-top:15px; }
#ticketDetail .item p { white-space:pre-wrap; overflow-wrap:anywhere; }
#newTicket textarea, #newMailing textarea, #ticketReply textarea {
  width:100%; min-height:95px; display:block; border:1px solid #d6dfec;
  border-radius:9px; padding:12px; background:white; color:#173452;
  resize:vertical; margin:9px 0 15px; font:inherit;
}
#emailPreferences button, #newTicket button { margin-top:12px; }


/* B7 official programs: composed editorial board, rather than a notification feed. */
.board-main { margin: 20px 0 34px; }
.board-banner {
  min-height: 300px; border-radius: 27px; overflow: hidden;
  position: relative; isolation: isolate; display: flex; align-items: center;
  background: radial-gradient(circle at 85% 15%,#8a78db 0,transparent 34%),
    linear-gradient(125deg,#182b5d 0%,#253989 52%,#7856af 100%);
  box-shadow: 0 22px 60px rgba(39,53,112,.16); color: white;
}
.board-banner::after {
  content:""; position:absolute; inset:0; z-index:-1; opacity:.23;
  background:repeating-linear-gradient(120deg,transparent 0 34px,#a8b6ff 35px,transparent 36px);
}
.board-copy { padding: 42px 46px; max-width: 700px; position: relative; z-index: 1; }
.board-kicker { color:#c4cfff; letter-spacing:2px; font-size:11px; font-weight:850; }
.board-kicker.ink { color:#6860a5; }
.board-banner h2 {
  font-size:clamp(35px,5vw,58px); letter-spacing:-2.4px;
  line-height:1.08; font-weight:800; margin:12px 0 14px; color:#fff;
}
.board-banner h2 em { font-style:normal; color:#d2ffb7; }
.board-banner p { font-size:16px; max-width:470px; color:#edf0ff; margin:0 0 24px; line-height:1.6; }
.board-banner-note {
  background:#ffffff1a; border:1px solid #ffffff30; border-radius:999px;
  display:inline-flex; align-items:center; gap:9px; padding:8px 14px;
  color:#ecf0ff; font-size:12px; max-width:100%; line-height:1.45;
}
.live-dot { height:8px; width:8px; background:#d0f8a9; border-radius:50%; flex:0 0 auto; }
.board-art { position:absolute; right:0; top:0; height:100%; width:39%; pointer-events:none; }
.board-art span { position:absolute; border-radius:50%; border:1px solid #e5eaff66; }
.orb-a { width:290px; height:290px; right:-20px; top:16px; box-shadow:0 0 0 55px #b3a9f710,0 0 0 115px #b3a9f706; }
.orb-b { width:185px; height:185px; right:32px; top:70px; background:linear-gradient(120deg,#d4d8ff77,#fff5); box-shadow:inset 0 8px 70px #fff6; }
.orb-c { width:84px; height:84px; right:210px; top:38px; background:#cee9ff27; }
.board-art b { position:absolute; right:103px; top:93px; font-size:90px; line-height:1;
  font-weight:950; color:#e0d9ffdf; filter:drop-shadow(0 12px 16px #171a624b); }
.board-heading { display:flex; justify-content:space-between; gap:15px; align-items:end; margin:36px 0 19px; }
.board-heading h2 {font-size:clamp(20px,2.6vw,27px); letter-spacing:-.7px; margin:5px 0 0; color:#1b2949;}
.board-hint { color:#74839c; font-size:12px; line-height:1.6; }
.board-cards { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:17px; }
.program-card {
  position:relative; isolation:isolate; display:flex; flex-direction:column;
  min-height:215px; padding:25px; border-radius:23px;
  border:1px solid #e1e8f7; background:#fff;
  box-shadow:0 12px 35px #334b6b0b; overflow:hidden;
}
.program-featured { min-height:270px; padding:29px; }
.program-featured.program-pub { background:linear-gradient(135deg,#f4f7ff 0%,#eceeff 100%); border-color:#d5dcff; }
.program-featured.program-adv { background:linear-gradient(135deg,#fff7f0 0%,#fff0e8 100%); border-color:#f7e0cc; }
.program-orb { position:absolute; top:-46px; right:-27px; width:175px; height:175px;
  display:grid; place-items:center; border-radius:50%; background:#d5d7ff55;
  color:#5860c062; font-size:86px; transform:rotate(-18deg); z-index:-1; }
.program-adv .program-orb { background:#ffdebc83; color:#d68d5170; }
.program-metadata { display:flex; gap:12px; align-items:center; color:#6a759a; font-size:12px; font-weight:700; }
.board-status {display:inline-block; background:#eff1f6; color:#656e88; border-radius:50px; padding:4px 9px; font-size:11px; font-weight:800;}
.board-status.live {background:#dff9e9; color:#107048;}
.program-card h3 {color:#222e53; font-size:clamp(19px,2.4vw,26px); letter-spacing:-.8px; margin:25px 0 6px; line-height:1.2;}
.program-description {font-size:13px; line-height:1.6; color:#667591; margin:0 0 25px; max-width:400px;}
.program-bottom {margin-top:auto; display:flex; justify-content:space-between; align-items:end; gap:12px;}
.program-bottom strong {color:#213657; display:block; font-size:20px;}
.program-caption { display:block; color:#8792aa; font-size:10px; margin-bottom:4px; }
.program-bottom button {white-space:nowrap; font-size:12px; padding:8px 11px;}
.board-news {border:1px solid #e1e7f1; border-radius:19px; padding:4px 21px; background:#fff;}
.board-news-item {display:flex; gap:16px; padding:19px 0; border-bottom:1px solid #edf0f5;}
.board-news-item:last-child {border-bottom:0;}
.news-icon {height:38px; width:38px; border-radius:13px; display:grid; place-items:center; flex-shrink:0;
  color:#655ba3; background:#f1effd; font-size:22px;}
.board-news-item h3 {font-size:15px; margin:0 0 8px; color:#233556;}
.news-copy {white-space:pre-wrap; font-size:13px; color:#62718d; margin:0 0 8px; max-height:100px; overflow:auto; overflow-wrap:anywhere;}
.board-empty {background:#fff; padding:30px; border:1px dashed #bbc7dc; border-radius:20px; color:#607293; font-size:14px;}
.b7-landing {margin:15px 0 28px;}
.b7-landing+.hero {padding-top:0;}
.board-applications {margin:34px 0;}
.board-application,.board-admin-row {display:flex; align-items:center; justify-content:space-between; gap:15px; padding:15px 0; border-top:1px solid #e8eef5;}
.board-application strong,.board-admin-row strong {font-size:14px; color:#25375d;}
.board-admin-section {margin:55px 0;}
.board-admin-card {min-width:0;}
.board-numbers {display:grid;grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:16px 0;}
.board-numbers>div {background:#f7f9ff; padding:11px; border-radius:12px;}
.board-numbers span {color:#7184a1; font-size:11px; display:block;}
.board-numbers strong {color:#273458; font-size:16px; word-break:break-word;}
.board-admin-card textarea {width:100%; min-height:105px;}
.board-admin-card label {margin-bottom:12px;}
.board-form-columns {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;}
.board-check {display:flex;align-items:center;gap:8px;}
.board-check input {height:16px; width:16px; flex:0 0 auto;}
.board-admin-card h3 {margin:24px 0 12px;}
.board-ledger {padding:7px 0; font-size:12px; color:#536782;}
.board-review {padding:17px 0; border-bottom:1px solid #e9edf5;}
.board-review-top {display:flex;align-items:center;justify-content:space-between; gap:8px;}
.board-evidence {white-space:pre-wrap;overflow-wrap:anywhere;background:#f6f8fc;color:#344969;
  border-radius:10px;padding:12px;font-size:13px;}
.program-dialog {width:min(680px,calc(100vw - 26px)); max-height:88vh; border:1px solid #e1e7f5; border-radius:24px;
  box-shadow:0 32px 110px #17265766; padding:30px; color:#243754;}
.program-dialog::backdrop {background:#12223bbc;}
.program-dialog h2 {font-size:32px;letter-spacing:-1.3px;margin:5px 0 18px;}
.program-dialog h3 {margin:23px 0 8px;}
.program-dialog p {white-space:pre-wrap;color:#566c86;line-height:1.7;overflow-wrap:anywhere;}
.program-dialog-kicker {font-size:11px;letter-spacing:1.8px;color:#6860ac;text-transform:uppercase;font-weight:850;}
.program-dialog-close {position:sticky;float:right;top:0;border:0;background:#eef1f9; border-radius:50%;
  width:36px;height:36px;font-size:23px;cursor:pointer;}
.program-facts {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:22px 0;}
.program-facts>div {background:#f4f6fe;border-radius:12px;padding:13px;}
.program-facts span {display:block;font-size:11px;color:#8190ab;}
.program-facts strong {display:block;font-size:15px; color:#25355b; word-wrap:break-word;}
.program-rules {background:#f8faff;border-left:3px solid #7878ce;padding:10px 14px;border-radius:6px;}
@media(max-width:740px) {
  .board-banner{min-height:250px;border-radius:20px;}
  .board-copy{padding:25px 23px;}
  .board-banner h2{font-size:38px;}
  .board-banner p{font-size:14px;}
  .board-art{width:20%;opacity:.28;}
  .board-cards,.board-form-columns{grid-template-columns:1fr;}
  .program-card,.program-featured{min-height:220px;padding:22px;}
  .board-heading{display:block;margin:30px 0 16px;}
  .board-heading>.board-hint{display:block;margin-top:7px;}
  .board-numbers{grid-template-columns:1fr;}
  .program-dialog{padding:19px;}
  .program-facts{grid-template-columns:1fr;}
  .board-application,.board-admin-row{align-items:flex-start;flex-direction:column;}
}
