/* ============================================================
   True Advize Portal — Architectural Grid Design System
   v2.0 | Dark engineering aesthetic
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Geist:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ─── TOKENS ─── */
:root {
  /* Brand palette — only these 3 colors + derived darks */
  --gray:       #52667A;
  --red:        #D22323;
  --white:      #FFFFFF;

  /* Dark backgrounds */
  --bg-base:    #0B0E13;
  --card:       #12161E;
  --nav:        #080B10;
  --nav-blur:   rgba(8, 11, 16, 0.82);

  /* Tints */
  --red-dim:    rgba(210, 35, 35, 0.14);
  --gray-dim:   rgba(82, 102, 122, 0.18);
  --gray-faint: rgba(82, 102, 122, 0.10);

  /* Text tiers */
  --text:       rgba(255, 255, 255, 0.94);
  --text-2:     rgba(255, 255, 255, 0.55);
  --text-3:     rgba(255, 255, 255, 0.30);

  /* Borders */
  --border:     rgba(82, 102, 122, 0.20);
  --border-s:   rgba(82, 102, 122, 0.35);

  /* Typography */
  --f:          'Geist', system-ui, sans-serif;
  --mono:       'JetBrains Mono', ui-monospace, monospace;

  /* Radii — sharp, structural */
  --r-card:     6px;
  --r-input:    6px;
  --r-button:   6px;
}

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ─── BASE ─── */
html, body { height: 100%; }

body {
  font-family: var(--f);
  background: var(--bg-base);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* ─── ARCHITECTURAL GRID BACKGROUND ─── */
/* Minor 16px + major 80px blueprint grid, vignetted to fade at edges. Pure CSS. */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image:
    linear-gradient(to right,  rgba(82, 102, 122, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(82, 102, 122, 0.05) 1px, transparent 1px),
    linear-gradient(to right,  rgba(82, 102, 122, 0.10) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(82, 102, 122, 0.10) 1px, transparent 1px);
  background-size: 16px 16px, 16px 16px, 80px 80px, 80px 80px;
  background-position: -1px -1px, -1px -1px, -1px -1px, -1px -1px;
  pointer-events: none;
  z-index: 0;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 90%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 90%);
}

/* Subtle red horizon glow */
body::after {
  content: '';
  position: fixed; inset: 0;
  background: radial-gradient(ellipse 70% 40% at 50% 100%, rgba(210, 35, 35, 0.06), transparent 70%);
  pointer-events: none;
  z-index: 1;
}

nav, main, .page-wrap, .state-screen { position: relative; z-index: 10; }

/* ─── NAV ─── */
nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--nav-blur);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  height: 56px;
  display: flex; align-items: center;
  padding: 0 32px;
}
.nav-inner {
  max-width: 1000px; width: 100%; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 600; font-size: 14px; letter-spacing: -0.02em;
  color: var(--text); text-decoration: none; flex-shrink: 0;
}
.logo-mark {
  width: 26px; height: 26px; background: var(--red);
  border-radius: 7px; display: flex; align-items: center;
  justify-content: center; font-size: 10px; font-weight: 700;
  color: #fff; font-family: var(--mono); letter-spacing: 0;
}
.nav-links { display: flex; gap: 2px; list-style: none; }
.nav-links a {
  display: block; padding: 6px 12px; border-radius: 6px;
  font-size: 13px; font-weight: 500; color: var(--text-2);
  text-decoration: none; transition: all 0.13s;
}
.nav-links a:hover { color: var(--text); background: rgba(82, 102, 122, 0.12); }
.nav-links a.active { color: var(--text); background: rgba(82, 102, 122, 0.18); }

.nav-user { display: flex; align-items: center; gap: 10px; }

/* Avatar — used by JS via id="user-avatar" */
.nav-avatar, .user-avatar {
  width: 28px; height: 28px; border-radius: 6px;
  background: rgba(82, 102, 122, 0.22);
  border: 1px solid var(--border-s);
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; color: var(--text);
  font-family: var(--mono); flex-shrink: 0;
}
/* JS also reads id="user-name" */
.nav-name, .user-name { font-size: 12px; font-weight: 500; color: var(--text-2); }

.btn-logout, .logout-btn {
  font-size: 12px; color: var(--text-3); background: none; border: none;
  cursor: pointer; padding: 4px 8px; font-family: var(--f); transition: color 0.13s;
}
.btn-logout:hover, .logout-btn:hover { color: var(--text-2); }

/* ─── MAIN ─── */
main {
  max-width: 1000px; margin: 0 auto; padding: 48px 32px 80px;
}
main.narrow { max-width: 620px; }

/* ─── PAGE HEADER ─── */
.page-header {
  margin-bottom: 32px;
  display: flex; align-items: flex-end; justify-content: space-between;
}
.page-title {
  font-size: 30px; font-weight: 600; letter-spacing: -0.04em;
  color: var(--text); line-height: 1; margin-bottom: 6px;
}
.page-sub { font-size: 13px; color: var(--text-2); }
.page-coord {
  font-family: var(--mono); font-size: 11px;
  color: var(--text-3); letter-spacing: 0.05em;
}
.red-dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--red); margin-right: 8px;
  box-shadow: 0 0 6px rgba(210, 35, 35, 0.6);
  vertical-align: middle;
}

/* ─── CARDS ─── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  overflow: hidden;
  position: relative;
  margin-bottom: 14px;
}
/* CAD corner ticks */
.card::before, .card::after {
  content: '';
  position: absolute;
  width: 10px; height: 10px;
  border-style: solid; border-width: 0;
}
.card::before {
  top: -1px; left: -1px;
  border-top-width: 1px; border-left-width: 1px;
  border-color: rgba(210, 35, 35, 0.4);
}
.card::after {
  bottom: -1px; right: -1px;
  border-bottom-width: 1px; border-right-width: 1px;
  border-color: rgba(210, 35, 35, 0.4);
}
.card-head {
  padding: 14px 22px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.card-head-label, .card-label {
  font-family: var(--mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3);
}
.card-body { padding: 22px; }
.card-body-lg { padding: 28px; }

/* ─── BADGES ─── */
/* badge-dot spans are generated by legacy makeBadge() JS — hide them, use ::before instead */
.badge-dot { display: none; }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px;
  font-family: var(--mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
}
.badge-active {
  background: var(--red-dim); color: var(--red);
  border: 1px solid rgba(210, 35, 35, 0.30);
}
.badge-active::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0;
  background: var(--red); box-shadow: 0 0 6px rgba(210, 35, 35, 0.7);
}
.badge-pending {
  background: var(--gray-dim); color: var(--text);
  border: 1px solid var(--border-s);
}
.badge-pending::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0;
  background: var(--gray);
}
.badge-offline, .badge-empty {
  background: transparent; color: var(--text-3);
  border: 1px dashed var(--border-s);
}
.badge-offline::before, .badge-empty::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0;
  background: var(--text-3);
}

/* ─── SIGNAL PULSE (Board Status hero) ─── */
.signal-wrap {
  position: relative; width: 42px; height: 42px; flex-shrink: 0;
}
.signal-ring {
  position: absolute; inset: 0;
  border: 1px solid var(--border-s); border-radius: 50%;
}
.signal-ring.ring-2 {
  inset: 5px; border-color: rgba(210, 35, 35, 0.30);
}
.signal-core {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 10px rgba(210, 35, 35, 0.7);
  animation: signal-pulse 2.2s ease-in-out infinite;
}
/* State: Pending */
.signal-wrap.is-pending .signal-ring.ring-2 { border-color: rgba(82, 102, 122, 0.30); }
.signal-wrap.is-pending .signal-core { background: var(--gray); box-shadow: none; animation: none; }
/* State: Offline */
.signal-wrap.is-offline .signal-ring.ring-2 { display: none; }
.signal-wrap.is-offline .signal-core { display: none; }

@keyframes signal-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.45; }
}

/* ─── BOARD BANNER ─── */
.board-banner {
  padding: 22px 26px;
  display: flex; align-items: center; justify-content: space-between;
}
.board-left { display: flex; align-items: center; gap: 18px; }
.board-label {
  font-family: var(--mono); font-size: 10px;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-3); margin-bottom: 4px;
}
.board-status-label {
  font-size: 22px; font-weight: 600; letter-spacing: -0.04em; color: var(--text);
}
.board-meta { font-size: 12px; color: var(--text-2); margin-top: 4px; }

/* ─── INVITE BANNER ─── */
/* id="invite-banner" — JS toggles display */
.invite-banner {
  background: rgba(210, 35, 35, 0.06) !important;
  border-color: rgba(210, 35, 35, 0.22) !important;
  padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.invite-banner-text { font-size: 13px; color: var(--text-2); }
.invite-banner-text strong { color: var(--text); font-weight: 500; }

/* ─── SLOTS ─── */
.slots-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px;
}
.slot-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r-card); overflow: hidden; position: relative;
  margin-bottom: 0;
}
/* Slot cards use left stripe instead of CAD corner ticks */
.slot-card::before { display: none; }
.slot-card::after  { display: none; }

.slot-stripe {
  position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--gray);
}
/* Active state — driven by JS adding .is-active */
.slot-card.is-active { border-color: rgba(210, 35, 35, 0.32); }
.slot-card.is-active .slot-stripe {
  background: var(--red);
  box-shadow: 0 0 12px rgba(210, 35, 35, 0.5);
}

.slot-head {
  padding: 16px 22px 0 26px;
  display: flex; align-items: center; justify-content: space-between;
}
.slot-num {
  font-family: var(--mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3);
}
.slot-body { padding: 12px 22px 22px 26px; }

/* id="slot1-title", id="slot2-title" — JS sets textContent and removes .empty */
.slot-title {
  font-size: 15px; font-weight: 600; letter-spacing: -0.025em;
  color: var(--text); margin-bottom: 5px; line-height: 1.3;
}
.slot-title.empty {
  color: var(--text-3); font-weight: 400; font-style: normal; font-size: 14px;
}
/* id="slot1-date", id="slot2-date" — JS sets textContent */
.slot-date {
  font-family: var(--mono); font-size: 11px;
  color: var(--text-2); margin-bottom: 18px;
}

/* ─── RECENT ACTIVITY ─── */
/* id="activity-list" — JS renders activity items into this container */
.activity-list { list-style: none; }
.activity-item {
  display: flex; align-items: center; gap: 16px;
  padding: 12px 22px; border-bottom: 1px solid rgba(82, 102, 122, 0.10);
}
.activity-item:last-child { border-bottom: none; }
.a-tag {
  font-family: var(--mono); font-size: 9px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
  padding: 3px 7px; border: 1px solid var(--border-s);
  color: var(--text-2); flex-shrink: 0; min-width: 76px; text-align: center;
}
.a-tag.published {
  color: var(--red); border-color: rgba(210, 35, 35, 0.4);
  background: rgba(210, 35, 35, 0.05);
}
.a-event { font-size: 13px; color: var(--text-2); flex: 1; line-height: 1.4; }
.a-event strong { color: var(--text); font-weight: 500; }
.a-time {
  font-family: var(--mono); font-size: 11px; color: var(--text-3); flex-shrink: 0;
}
.activity-empty {
  padding: 28px 22px; text-align: center;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.05em; color: var(--text-3);
}

/* ─── BUTTONS ─── */
.btn-primary, .btn-red, .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px; background: var(--red); color: #fff;
  border: none; border-radius: var(--r-button);
  font-size: 12px; font-weight: 600; font-family: var(--f);
  cursor: pointer; transition: opacity 0.15s; text-decoration: none;
}
.btn-primary:hover, .btn-red:hover, .btn:hover { opacity: 0.85; }

.btn-ghost, .btn-outline {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; background: rgba(82, 102, 122, 0.10);
  color: var(--text-2); border: 1px solid var(--border);
  border-radius: var(--r-button); font-size: 12px; font-weight: 500;
  font-family: var(--f); cursor: pointer; transition: all 0.15s; text-decoration: none;
}
.btn-ghost:hover, .btn-outline:hover {
  background: rgba(82, 102, 122, 0.18); color: var(--text); border-color: var(--border-s);
}
.btn-outline.btn-red {
  background: var(--red); color: #fff; border-color: var(--red);
}
.btn-outline.btn-red:hover { opacity: 0.85; }

/* Submit button */
.btn-submit {
  width: 100%; padding: 13px; background: var(--red); color: #fff;
  border: none; border-radius: var(--r-button);
  font-size: 14px; font-weight: 600; font-family: var(--f);
  cursor: pointer; transition: opacity 0.15s; margin-top: 8px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-submit:hover:not(:disabled) { opacity: 0.85; }
.btn-submit:disabled { opacity: 0.45; cursor: not-allowed; }

/* ─── SPINNER ─── */
@keyframes spin { to { transform: rotate(360deg); } }

.spinner {
  width: 26px; height: 26px;
  border: 2px solid var(--border-s); border-top-color: var(--red);
  border-radius: 50%; animation: spin 0.65s linear infinite;
}
.btn-spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3); border-top-color: #fff;
  border-radius: 50%; animation: spin 0.65s linear infinite;
}

/* ─── STATE SCREENS ─── */
/* id="loading-state", id="error-state" — JS toggles display */
.state-screen {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  min-height: calc(100vh - 56px); gap: 12px;
}
.state-title {
  font-size: 13px; font-weight: 500; color: var(--text-2);
  font-family: var(--mono); letter-spacing: 0.06em; text-transform: uppercase;
}
.state-sub { font-size: 13px; color: var(--text-3); }

/* ─── FORM ELEMENTS ─── */
.field { margin-bottom: 20px; }
.field:last-child { margin-bottom: 0; }

label {
  display: block; font-size: 10px; font-weight: 600; margin-bottom: 8px;
  color: var(--text-3); letter-spacing: 0.08em; text-transform: uppercase;
  font-family: var(--mono);
}
label .required { color: var(--red); margin-left: 2px; }
label .hint {
  font-weight: 400; color: var(--text-3); margin-left: 4px;
  text-transform: none; letter-spacing: 0; font-family: var(--f); font-size: 11px;
}

.input, .textarea {
  width: 100%; font-family: var(--f); font-size: 14px; color: var(--text);
  background: rgba(82, 102, 122, 0.08); border: 1px solid var(--border);
  border-radius: var(--r-input); padding: 10px 14px; outline: none;
  transition: border-color 0.15s, box-shadow 0.15s; appearance: none;
}
.input:focus, .textarea:focus {
  border-color: var(--red); box-shadow: 0 0 0 3px rgba(210, 35, 35, 0.10);
  background: rgba(82, 102, 122, 0.10);
}
.input::placeholder, .textarea::placeholder { color: var(--text-3); }
.input:read-only { color: var(--text-2); cursor: default; }
.input:read-only:focus { border-color: var(--border); box-shadow: none; }
.textarea { resize: vertical; min-height: 88px; line-height: 1.5; }

/* ─── SLOT SELECTOR (Submit page) ─── */
/* .slot-options wraps radio cards; JS reads slotNumber value */
.slot-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.slot-option { position: relative; }
.slot-option input[type="radio"] { position: absolute; opacity: 0; width: 0; height: 0; }
.slot-option label {
  display: flex; flex-direction: column; gap: 4px;
  padding: 14px 16px 14px 18px; border-radius: var(--r-card);
  border: 1px solid var(--border);
  background: rgba(82, 102, 122, 0.08); cursor: pointer;
  transition: all 0.15s; margin: 0;
  /* Override global label styles for radio cards */
  text-transform: none; letter-spacing: 0; font-family: var(--f);
  font-size: 14px; font-weight: 400; color: var(--text);
}
.slot-option input:checked + label {
  border-color: rgba(210, 35, 35, 0.50);
  background: rgba(210, 35, 35, 0.06);
  box-shadow: 0 0 0 3px rgba(210, 35, 35, 0.08);
}
.slot-option label .slot-num {
  font-family: var(--mono); font-size: 10px; font-weight: 600;
  color: var(--text-3); letter-spacing: 0.10em; text-transform: uppercase;
}
.slot-option input:checked + label .slot-num { color: var(--red); }
.slot-option label .slot-desc { font-size: 13px; font-weight: 500; color: var(--text); }
.slot-option label .slot-current { font-size: 11px; color: var(--text-3); font-weight: 400; font-family: var(--mono); }

/* ─── FILE UPLOAD ─── */
/* id="file-drop" — JS adds/removes .dragover */
.file-drop {
  border: 1.5px dashed var(--border-s); border-radius: var(--r-card);
  padding: 28px 20px; text-align: center; cursor: pointer;
  transition: all 0.2s; background: rgba(82, 102, 122, 0.06); position: relative;
}
.file-drop:hover, .file-drop.dragover {
  border-color: var(--red); border-style: solid;
  background: rgba(210, 35, 35, 0.05);
}
.file-drop input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.file-drop-icon { font-size: 22px; margin-bottom: 10px; opacity: 0.45; }
.file-drop-title { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.file-drop-sub { font-size: 11px; color: var(--text-3); font-family: var(--mono); letter-spacing: 0.03em; }

/* id="file-selected" — JS toggles .show */
.file-selected {
  display: none; align-items: center; gap: 12px;
  padding: 10px 14px; background: rgba(82, 102, 122, 0.10);
  border: 1px solid var(--border-s); border-radius: var(--r-card); margin-top: 10px;
}
.file-selected.show { display: flex; }
/* id="file-name" */
.file-selected-name {
  font-size: 12px; font-weight: 500; color: var(--text); flex: 1;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--mono);
}
/* id="file-size" */
.file-selected-size { font-size: 11px; color: var(--text-3); white-space: nowrap; font-family: var(--mono); }
.file-remove {
  background: none; border: none; cursor: pointer; font-size: 14px;
  color: var(--text-3); padding: 0 2px; line-height: 1; transition: color 0.15s;
}
.file-remove:hover { color: var(--red); }

/* id="progress-bar" — JS toggles .show; id="progress-fill" gets width */
.progress-bar {
  height: 2px; background: var(--border); border-radius: 2px;
  overflow: hidden; margin-top: 12px; display: none;
}
.progress-bar.show { display: block; }
.progress-fill { height: 100%; background: var(--red); border-radius: 2px; width: 0%; transition: width 0.3s; }

/* ─── RESULT CARDS (success / error) ─── */
/* id="success-card", id="upload-error-card" — JS toggles .show */
.result-card { display: none; padding: 36px 28px; text-align: center; }
.result-card.show { display: block; }
.result-icon { font-size: 36px; margin-bottom: 16px; }
.result-title { font-size: 18px; font-weight: 600; margin-bottom: 8px; letter-spacing: -0.02em; color: var(--text); }
.result-sub { font-size: 13px; color: var(--text-2); line-height: 1.6; }
.result-actions { display: flex; gap: 10px; justify-content: center; margin-top: 24px; flex-wrap: wrap; }

/* ─── GUIDELINES LIST ─── */
.guidelines { list-style: none; }
.guidelines li {
  display: flex; gap: 14px;
  padding: 10px 22px; border-bottom: 1px solid rgba(82, 102, 122, 0.08);
  font-size: 13px; line-height: 1.55; color: var(--text-2);
}
.guidelines li:last-child { border-bottom: none; }
.guidelines .num {
  font-family: var(--mono); font-size: 10px; font-weight: 600; color: var(--red);
  flex-shrink: 0; margin-top: 2px; letter-spacing: 0.04em;
}

/* ─── ACCOUNT — INFO ROWS ─── */
.info-row {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 16px;
  padding: 11px 22px; border-bottom: 1px solid rgba(82, 102, 122, 0.10);
}
.info-row:last-of-type { border-bottom: none; }
.info-key {
  font-family: var(--mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-3); flex-shrink: 0; padding-top: 2px;
}
.info-val { font-size: 13px; font-weight: 500; text-align: right; color: var(--text); }

/* ─── ACCOUNT — FORM ─── */
.fields-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
/* id="save-msg" — JS toggles .show */
.save-row { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.save-msg {
  font-size: 11px; color: var(--red); font-weight: 600;
  font-family: var(--mono); letter-spacing: 0.06em; text-transform: uppercase;
  opacity: 0; transition: opacity 0.3s;
}
.save-msg.show { opacity: 1; }

/* ─── ACCOUNT — TEAM ─── */
.team-member {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 22px; border-bottom: 1px solid rgba(82, 102, 122, 0.10);
}
.team-member:last-of-type { border-bottom: none; }
.member-avatar {
  width: 32px; height: 32px; border-radius: 6px;
  background: var(--gray-dim); border: 1px solid var(--border-s);
  color: var(--text); font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-family: var(--mono);
}
.member-info { flex: 1; }
.member-name { font-size: 13px; font-weight: 500; color: var(--text); }
.member-email { font-size: 11px; color: var(--text-3); margin-top: 2px; font-family: var(--mono); }
.member-badge {
  font-family: var(--mono); font-size: 9px; font-weight: 600;
  padding: 3px 8px; border: 1px solid var(--border-s);
  color: var(--text-3); letter-spacing: 0.08em; text-transform: uppercase;
}
/* id="invite-section" — JS toggles display */
.invite-section {
  padding: 14px 22px; border-top: 1px solid rgba(82, 102, 122, 0.10);
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}
.invite-section p { font-size: 13px; color: var(--text-2); }

/* ─── ACCOUNT — TOS ─── */
/* id="tos-date-row", id="tos-link-row" — JS toggles display */
.tos-status { display: flex; align-items: center; gap: 8px; padding: 14px 22px; }
.tos-check { color: var(--red); font-size: 14px; font-family: var(--mono); }
/* id="tos-text" */
.tos-status span:last-child { font-size: 13px; font-weight: 500; color: var(--text); }

/* ─── ACCOUNT — SUPPORT ─── */
.support-body { padding: 14px 22px 20px; }
.support-body p { font-size: 13px; line-height: 1.6; color: var(--text-2); margin-bottom: 14px; }
.support-links { display: flex; gap: 10px; flex-wrap: wrap; }
.support-link {
  font-size: 12px; color: var(--red); font-weight: 600;
  text-decoration: none; font-family: var(--mono); letter-spacing: 0.03em;
}
.support-link:hover { text-decoration: underline; }

/* ─── TERMS OVERLAY ─── */
/* id="terms-overlay" — JS sets display. Behavior preserved, visual restyled. */
.terms-modal {
  background: var(--card);
  border: 1px solid var(--border-s);
  border-radius: var(--r-card);
  width: 100%; max-width: 640px; max-height: 90vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}
.terms-modal-head {
  background: var(--nav);
  padding: 18px 24px;
  display: flex; align-items: center; gap: 14px; flex-shrink: 0;
  border-bottom: 1px solid var(--border);
}
.terms-modal-head span {
  color: var(--text-2); font-size: 13px; font-weight: 500;
  font-family: var(--mono); letter-spacing: 0.03em;
}
.terms-modal-body { flex: 1; min-height: 0; overflow: hidden; }
.terms-modal-foot {
  padding: 20px 24px; border-top: 1px solid var(--border);
  background: rgba(8, 11, 16, 0.6); flex-shrink: 0;
}
.terms-modal-foot label {
  display: flex; align-items: flex-start; gap: 12px; cursor: pointer;
  margin-bottom: 16px; text-transform: none; letter-spacing: 0;
  font-family: var(--f); font-size: 13px; color: var(--text-2); font-weight: 400;
}
.terms-modal-foot .terms-caption {
  font-size: 11px; color: var(--text-3); text-align: center; margin-top: 10px;
  font-family: var(--mono); letter-spacing: 0.02em;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 700px) {
  nav { padding: 0 16px; }
  .nav-name, .user-name { display: none; }
  main { padding: 24px 16px 60px; }
  .slots-grid { grid-template-columns: 1fr; }
  .slot-options { grid-template-columns: 1fr; }
  .fields-grid { grid-template-columns: 1fr; }
  .page-header { flex-direction: column; align-items: flex-start; gap: 6px; }
  .page-coord { align-self: flex-start; }
  .page-title { font-size: 24px; }
  .board-banner { flex-direction: column; align-items: flex-start; gap: 14px; }
}
