/* ─── USPPG Members Portal — Frontend Styles ─────────────────────────────── */
:root {
  --navy: #003366;
  --navy-dark: #001f44;
  --navy-mid: #004080;
  --gold: #c9a032;
  --gold-light: #e8c660;
  --bg: #f0f3f7;
  --card-bg: #ffffff;
  --text: #1a1a2e;
  --text-muted: #5a6478;
  --border: #dde3ec;
  --radius: 6px;
  --shadow: 0 1px 3px rgba(0,0,0,.08);
  --shadow-lg: 0 1px 3px rgba(0,0,0,.08);
}

* { box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif; margin: 0; }

/* ─── TOP NAV ────────────────────────────────────────────────────────────── */
.portal-nav {
  background: var(--navy-dark);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 12px rgba(0,0,0,0.25);
}
.portal-nav-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; height: 60px; padding: 0 24px;
  gap: 16px;
}
.nav-brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; flex-shrink: 0;
}
.nav-logo {
  width: 34px; height: 34px; border-radius: 6px;
  background: var(--navy);
  border: 2px solid var(--gold);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-weight: 800; font-size: 15px;
}
.nav-brand-name { color: #fff; font-weight: 700; font-size: 14px; line-height: 1.2; }
.nav-brand-sub { color: rgba(255,255,255,0.5); font-size: 10px; letter-spacing: 0.5px; text-transform: uppercase; }

.nav-links { display: flex; gap: 2px; flex: 1; justify-content: center; flex-wrap: nowrap; white-space: nowrap; }
.nav-link {
  color: rgba(255,255,255,0.65); text-decoration: none;
  font-size: 13px; font-weight: 500;
  padding: 6px 10px; border-radius: 6px;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}
.nav-link:hover { color: #fff; background: rgba(255,255,255,0.1); text-decoration: none; }
.nav-link.active { color: #fff; background: rgba(255,255,255,0.15); }

.nav-right { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-user-btn {
  display: flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.9); border-radius: 8px; padding: 5px 12px;
  font-size: 13px; cursor: pointer; transition: background 0.15s;
}
.nav-user-btn:hover, .nav-user-btn:focus { background: rgba(255,255,255,0.18); color: #fff; outline: none; box-shadow: none; }
.nav-avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--navy-mid);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 10px; font-weight: 700;
}
.mobile-menu-btn {
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.8); border-radius: 6px; padding: 6px 10px;
  font-size: 14px; cursor: pointer;
}
.mobile-nav-links { background: #00274d; padding: 8px 0; }
.mobile-nav-link {
  display: block; padding: 12px 24px; color: rgba(255,255,255,0.8);
  text-decoration: none; font-size: 14px; border-bottom: 1px solid rgba(255,255,255,0.06);
}
.mobile-nav-link:last-child { border-bottom: none; }
.mobile-nav-link:hover { color: #fff; background: rgba(255,255,255,0.08); text-decoration: none; }
.mobile-nav-sep { height: 1px; background: rgba(255,255,255,0.12); margin: 8px 16px; }
.mobile-nav-signout { color: #e8a0a0 !important; }

.dropdown-menu { border: 1px solid var(--border); box-shadow: var(--shadow); border-radius: 6px; padding: 6px; }
.dropdown-item { border-radius: 4px; font-size: 13px; padding: 8px 14px; color: #333; }
.dropdown-item:hover { background: #f0f3f7; }
.dropdown-item.active { background: #e8eef5; color: var(--navy); font-weight: 600; }

/* More dropdown in primary nav */
.nav-more { position: relative; }
.nav-more > .nav-link { cursor: pointer; }
.nav-more .dropdown-menu {
  background: #fff; min-width: 180px; margin-top: 4px;
}
.nav-more .dropdown-toggle::after { margin-left: 4px; vertical-align: 2px; opacity: 0.7; }

/* USPPG-164: all 8 member nav items inline from 1200px (hamburger below); compact between 1200 and 1399 */
@media (min-width: 1200px) and (max-width: 1399.98px) {
  .nav-link { padding: 6px 7px; font-size: 12.5px; }
  .nav-user-name { display: none !important; }
}

/* ─── MAIN + FOOTER ──────────────────────────────────────────────────────── */
.portal-body { background: var(--bg); }
.portal-main { min-height: calc(100vh - 60px - 60px); }
.portal-footer {
  background: var(--navy-dark); color: rgba(255,255,255,0.5);
  padding: 20px 0; font-size: 12px;
}
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.footer-brand { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,0.6); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: rgba(255,255,255,0.45); text-decoration: none; font-size: 12px; }
.footer-links a:hover { color: rgba(255,255,255,0.8); text-decoration: none; }

/* ─── PAGE HEADER (compact strip; replaces tall portal-hero) ─────────────── */
.page-header {
  background: var(--navy);
  padding: 16px 0 18px;
  position: relative;
}
.page-header-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.page-header-greeting {
  color: rgba(255,255,255,0.7); font-size: 13px; margin-bottom: 2px;
}
.page-header-name {
  color: #fff; font-size: 1.5rem; font-weight: 700; line-height: 1.25; margin: 0;
}
.page-header-meta {
  color: rgba(255,255,255,0.55); font-size: 13px; margin-top: 4px;
}

/* Legacy portal-hero: compact solid (other pages) */
.portal-hero {
  background: var(--navy);
  padding: 16px 0 18px; position: relative; overflow: hidden;
}
.portal-hero::after { display: none; }
.hero-content { max-width: 1200px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }
.hero-greeting { color: rgba(255,255,255,0.7); font-size: 13px; margin-bottom: 2px; }
.hero-name { color: #fff; font-size: 1.5rem; font-weight: 700; margin: 0 0 2px; }
.hero-sub { color: rgba(255,255,255,0.55); font-size: 13px; }
.hero-badges { display: none; } /* status lives in compliance-strip / metrics */

/* ─── PAGE CONTAINER ─────────────────────────────────────────────────────── */
.page-container { max-width: 1200px; margin: 0 auto; padding: 24px 24px 48px; }
.page-title { font-size: 22px; font-weight: 700; color: var(--text); margin: 0 0 4px; }
.page-subtitle { color: var(--text-muted); font-size: 14px; }

/* ─── CARDS ──────────────────────────────────────────────────────────────── */
.card-box {
  background: var(--card-bg); border-radius: var(--radius);
  border: 1px solid var(--border); box-shadow: none;
}
.card-box-body-flush { padding: 0 !important; }
.card-box-body-qa { padding: 4px 0 !important; }
.btn-sm-outline { font-size: 12px !important; padding: 5px 14px !important; }
.card-box-header {
  padding: 16px 22px; border-bottom: 1px solid var(--border);
  font-weight: 600; font-size: 14px; color: var(--text);
  display: flex; align-items: center; justify-content: space-between;
}
.card-box-header .header-icon { color: var(--navy); margin-right: 8px; opacity: 0.7; }
.card-box-body { padding: 22px; }

/* ─── STAT TILES ─────────────────────────────────────────────────────────── */
.stat-tile {
  background: var(--card-bg); border-radius: var(--radius);
  border: 1px solid var(--border); padding: 16px 18px;
  display: flex; align-items: center; gap: 12px;
  box-shadow: none; min-height: 88px; height: 100%;
  transition: border-color 0.15s;
}
.stat-tile:hover { border-color: #c5ceda; }
.stat-tile-link { text-decoration: none; display: block; height: 100%; }
.stat-tile-link:hover { text-decoration: none; }
.stat-tile-icon {
  width: 36px; height: 36px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; flex-shrink: 0;
  background: #eef1f6; color: var(--navy);
}
.ic-blue, .ic-green, .ic-gold, .ic-red { background: #eef1f6; color: var(--navy); }
.stat-tile-num { font-size: 26px; font-weight: 700; color: var(--text); line-height: 1; }
.stat-tile-status { font-size: 18px !important; font-weight: 700; line-height: 1.2; }
.stat-tile-label { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.benefit-summary-tile { flex-direction: column; align-items: flex-start; gap: 8px; }
.benefit-summary-body { min-width: 0; width: 100%; }
.benefit-summary-name { font-weight: 600; color: var(--text); font-size: 13px; margin-bottom: 2px; }
.benefit-pricing-btn { font-size: 11px !important; padding: 4px 10px !important; align-self: flex-start; text-decoration: none; }

/* ─── COMPLIANCE STRIP ───────────────────────────────────────────────────── */
.compliance-strip {
  background: #fffbee; border: 1px solid #ffe58c;
  border-radius: var(--radius); padding: 12px 16px;
  display: flex; align-items: flex-start; gap: 10px; margin-bottom: 20px;
  font-size: 13px; color: #7c5f00;
}
.compliance-strip i { color: #e6a817; font-size: 15px; margin-top: 2px; flex-shrink: 0; }
.compliance-strip a { color: #7c5f00; font-weight: 600; }

/* ─── BENEFIT CARDS ──────────────────────────────────────────────────────── */
.benefit-card {
  background: var(--card-bg); border-radius: var(--radius);
  border: 1px solid var(--border); padding: 16px 18px;
  box-shadow: none; display: flex; align-items: flex-start; gap: 12px;
}
.benefit-card-row {
  border-radius: 0; border: none; border-bottom: 1px solid var(--border);
  box-shadow: none;
}
.benefit-card-main { flex: 1; min-width: 0; }
.benefit-pricing-link {
  font-size: 12px; font-weight: 600; color: var(--navy);
  text-decoration: none; display: inline-block; margin-top: 4px;
}
.benefit-card-icon {
  width: 36px; height: 36px; border-radius: 6px; flex-shrink: 0;
  background: #eef1f6;
  display: flex; align-items: center; justify-content: center;
  color: var(--navy); font-size: 15px;
}
.benefit-card-name { font-weight: 700; font-size: 14px; color: var(--text); margin-bottom: 4px; }
.benefit-card-vendor { font-size: 12px; color: var(--text-muted); }
.benefit-card-badge {
  margin-left: auto; flex-shrink: 0;
  padding: 4px 12px; border-radius: 20px; font-size: 11px; font-weight: 600;
}
.badge-active { background: #e6f7ef; color: #1a8c5b; }
.badge-pending { background: #fff8e1; color: #a07820; }
.badge-na { background: #f4f6fb; color: #aaa; }

/* ─── INFO ROWS ──────────────────────────────────────────────────────────── */
.info-row {
  display: flex; align-items: baseline; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13.5px;
}
.info-row:last-child { border-bottom: none; }
.info-label { color: var(--text-muted); font-size: 12px; min-width: 140px; flex-shrink: 0; }
.info-value { color: var(--text); font-weight: 500; }

/* ─── TABLES ─────────────────────────────────────────────────────────────── */
.portal-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.portal-table th {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.7px;
  color: var(--text-muted); font-weight: 600; padding: 12px 16px;
  background: #f8f9fc; border-bottom: 1px solid var(--border); text-align: left;
}
.portal-table td { padding: 14px 16px; border-bottom: 1px solid var(--border); color: var(--text); vertical-align: middle; }
.portal-table tr:last-child td { border-bottom: none; }
.portal-table tr:hover td { background: #f8f9fc; }

/* ─── EMPTY STATE ────────────────────────────────────────────────────────── */
.empty-state { text-align: center; padding: 40px 20px; }
.empty-state-compact { padding: 24px 16px !important; }
.empty-state .empty-icon {
  width: 40px; height: 40px; border-radius: 50%; background: #eef1f6;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px; font-size: 16px; color: #9aa3b5;
}
.empty-state h5 { font-size: 15px; font-weight: 600; color: #555; margin-bottom: 6px; }
.empty-state p { color: var(--text-muted); font-size: 13px; margin-bottom: 0; }
.empty-cta { display: inline-flex; margin-top: 14px; }

/* ─── BUTTONS ────────────────────────────────────────────────────────────── */
.btn-navy {
  background: var(--navy); color: #fff; border: none;
  padding: 8px 16px; min-height: 36px; border-radius: 8px; font-weight: 600;
  font-size: 13px; line-height: 1.2; cursor: pointer; transition: background 0.2s;
  text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.btn-navy:hover { background: var(--navy-mid); color: #fff; text-decoration: none; }
.btn-outline {
  background: #fff; color: var(--navy);
  border: 1px solid var(--navy); padding: 7px 14px; min-height: 36px;
  border-radius: 8px; font-weight: 600; font-size: 12px; line-height: 1.2;
  cursor: pointer; transition: all 0.2s; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.btn-outline:hover { background: var(--navy); color: #fff; text-decoration: none; }

/* Table / page actions — match Contracts page */
.btn-action {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: var(--navy); color: #fff; border: none;
  padding: 8px 16px; min-height: 36px; border-radius: 8px;
  font-size: 12px; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn-action:hover { background: var(--navy-mid); color: #fff; text-decoration: none; }
.btn-action-outline {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: #fff; color: var(--navy); border: 1px solid var(--navy);
  padding: 7px 12px; min-height: 36px; border-radius: 8px;
  font-size: 12px; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn-action-outline:hover { background: var(--navy); color: #fff; text-decoration: none; }
.btn-action-block { width: 100%; } /* only when intentionally full-width in a narrow actions column */
.actions-cell { text-align: right; white-space: nowrap; }
.actions-cell .btn-action,
.actions-cell .btn-action-outline { margin-left: 6px; vertical-align: middle; }
.actions-cell .btn-action:first-child,
.actions-cell .btn-action-outline:first-child { margin-left: 0; }
.portal-hero-compact { padding: 28px 0 !important; }
.portal-hero-compact .hero-name { font-size: 22px !important; }
.pill-blue { display:inline-block; background:#edf2ff; color:#003366; font-size:11px; font-weight:600; padding:3px 10px; border-radius:12px; white-space:nowrap; }
.pill-green { display:inline-block; background:#e8f5e9; color:#1a5c3a; font-size:11px; font-weight:500; padding:3px 9px; border-radius:20px; }


/* ─── FORMS ──────────────────────────────────────────────────────────────── */
.field-label { font-size: 12px; font-weight: 600; color: #555; margin-bottom: 5px; display: block; }
.field-input {
  height: 42px; border-radius: 8px; border: 1.5px solid var(--border);
  font-size: 13.5px; width: 100%; padding: 0 13px; outline: none;
  transition: border-color 0.15s;
}
.field-input:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(0,51,102,0.08); }

/* ─── AUTH / REGISTER PAGES ──────────────────────────────────────────────── */
.auth-body { background: linear-gradient(135deg, #001830 0%, #003366 60%, #004d99 100%); min-height: 100vh; }
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.auth-card {
  background: #fff; border-radius: 16px; padding: 44px;
  width: 100%; max-width: 420px; box-shadow: 0 24px 64px rgba(0,0,0,0.3);
}
.auth-logo { text-align: center; margin-bottom: 32px; }
.auth-logo .logo-icon-lg {
  width: 56px; height: 56px; border-radius: 14px; margin: 0 auto 12px;
  background: linear-gradient(135deg, #1a5599, var(--gold));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 24px; font-weight: 800;
}
.auth-logo h1 { font-size: 20px; font-weight: 700; color: var(--text); margin: 0 0 4px; }
.auth-logo p { font-size: 11px; color: #aaa; text-transform: uppercase; letter-spacing: 1px; margin: 0; }
.auth-card h2 { font-size: 21px; font-weight: 700; color: var(--text); margin-bottom: 6px; }
.auth-card .subtitle { font-size: 14px; color: var(--text-muted); margin-bottom: 26px; }
.auth-label { font-size: 12px; font-weight: 600; color: #555; margin-bottom: 6px; display: block; }
.form-control { border-radius: 8px; border: 1.5px solid var(--border); font-size: 13.5px; }
.form-control:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(0,51,102,0.08); }
.btn-primary-navy {
  background: var(--navy); border: none; color: #fff;
  padding: 8px 16px; min-height: 36px; border-radius: 8px;
  font-weight: 600; font-size: 13px; line-height: 1.2;
  transition: background 0.2s; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  text-decoration: none;
}
.auth-card .btn-primary-navy,
.auth-page .btn-primary-navy,
.register-form .btn-primary-navy {
  width: 100%; height: 46px; min-height: 46px; padding: 0 16px; font-size: 14px;
}
.btn-primary-navy:hover { background: var(--navy-dark); color: #fff; }
.auth-divider {
  display: flex; align-items: center; gap: 12px; margin: 22px 0;
  color: #ccc; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px;
}
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: #eee; }
.btn-magic-link {
  width: 100%; background: #f4f6fb; border: 1.5px solid var(--border); color: #555;
  height: 44px; border-radius: 8px; font-size: 13.5px; font-weight: 500;
  transition: background 0.2s; cursor: pointer;
}
.btn-magic-link:hover { background: #eaecf4; color: #333; }
.success-box { text-align: center; padding: 10px 0; }
.success-icon {
  width: 64px; height: 64px; border-radius: 50%; background: #e6f7ef;
  display: flex; align-items: center; justify-content: center;
  color: #1a8c5b; font-size: 28px; margin: 0 auto 20px;
}
.success-box h3 { font-size: 20px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.success-box p { color: #666; font-size: 14px; margin-bottom: 5px; }
.success-email { font-weight: 700; color: var(--navy) !important; }

/* ─── ADMIN LAYOUTS (keep existing sidebar for admin) ────────────────────── */
.wrapper { display: flex; width: 100%; align-items: stretch; min-height: 100vh; }
#sidebar {
  width: 260px; min-width: 260px; background: #1a2744;
  display: flex; flex-direction: column; position: fixed;
  top: 0; left: 0; bottom: 0; z-index: 999; overflow-y: auto;
  transition: margin-left 0.3s;
}
#sidebar.active { margin-left: -260px; }
#content { margin-left: 260px; width: calc(100% - 260px); transition: all 0.3s; }
#content.active { margin-left: 0; width: 100%; }
.sidebar-header { padding: 20px 20px 16px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.logo-wrap { display: flex; align-items: center; gap: 10px; }
.logo-icon { width: 36px; height: 36px; border-radius: 8px; background: linear-gradient(135deg,#1a5599,var(--gold)); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; font-size: 16px; }
.logo-text .logo-main { display: block; color: #fff; font-weight: 700; font-size: 15px; line-height: 1.2; }
.logo-text .logo-sub { display: block; color: rgba(200,214,232,0.6); font-size: 10px; letter-spacing: 0.5px; text-transform: uppercase; }
.member-card { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-bottom: 1px solid rgba(255,255,255,0.08); background: rgba(0,0,0,0.15); }
.member-avatar { width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(135deg,#1a5599,#2d5fa8); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 13px; flex-shrink: 0; }
.member-name { color: #fff; font-size: 13px; font-weight: 600; line-height: 1.3; }
.member-email { color: rgba(200,214,232,0.6); font-size: 11px; }
.nav-section { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; color: rgba(200,214,232,0.35); padding: 16px 20px 6px; font-weight: 600; }
.nav-items { padding: 8px 0; flex: 1; }
.nav-item a { display: flex; align-items: center; gap: 10px; padding: 10px 20px; color: rgba(200,214,232,0.75); text-decoration: none; font-size: 13.5px; transition: background 0.15s, color 0.15s; }
.nav-item a:hover { background: rgba(255,255,255,0.07); color: #fff; }
.nav-item.active a { background: rgba(0,58,122,0.8); color: #fff; border-left: 3px solid var(--gold); }
.nav-sub-item a { display: flex; align-items: center; padding: 6px 20px 6px 40px; color: rgba(200,214,232,0.5); text-decoration: none; font-size: 12px; transition: background 0.15s, color 0.15s; }
.nav-sub-item a:hover { color: rgba(200,214,232,0.85); background: rgba(255,255,255,0.04); }
.nav-sub-item.active a { color: var(--gold); }
.nav-item a i { width: 18px; text-align: center; opacity: 0.7; font-size: 13px; }
.nav-item.active a i { opacity: 1; }
.sidebar-footer { padding: 16px 20px; border-top: 1px solid rgba(255,255,255,0.08); }
.logout-btn { display: flex; align-items: center; gap: 8px; color: rgba(200,214,232,0.55); text-decoration: none; font-size: 13px; transition: color 0.15s; }
.logout-btn:hover { color: #fff; text-decoration: none; }
.top-bar { height: 56px; background: #fff; border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 24px; gap: 16px; position: sticky; top: 0; z-index: 100; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.btn-toggle { background: none; border: none; color: #555; font-size: 18px; cursor: pointer; padding: 4px 8px; }
.btn-toggle:hover { color: var(--navy); }
.top-bar-title { font-weight: 600; font-size: 15px; color: var(--text); flex: 1; }
.main-content { padding: 28px 28px 40px; background: var(--bg); min-height: calc(100vh - 56px); }
.form-label-sm { font-size: 12px; font-weight: 600; color: #555; margin-bottom: 5px; display: block; }
.form-control-sm { border-radius: 6px; border: 1.5px solid var(--border); font-size: 13.5px; }
/* USPPG-327: fixed 36px height applies to inputs/selects only; textareas follow their rows (was clipping every small textarea to ~1 line) */
input.form-control-sm, select.form-control-sm { height: 36px !important; }
.form-control-sm:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(0,51,102,0.08); }
.table-panel { background: #fff; border-radius: 10px; border: 1px solid var(--border); overflow: hidden; }
.table-panel table { margin: 0; }
.table-panel .table th { background: #f8f9fc; font-size: 11px; text-transform: uppercase; letter-spacing: 0.7px; color: #888; font-weight: 600; border-bottom: 1px solid var(--border); padding: 12px 16px; }
.table-panel .table td { padding: 13px 16px; vertical-align: middle; font-size: 13.5px; color: #333; }
.table-panel .table tr:last-child td { border-bottom: none; }
.card-panel { background: #fff; border-radius: 10px; border: 1px solid var(--border); box-shadow: var(--shadow); }
.card-panel .card-header-custom { padding: 16px 22px; border-bottom: 1px solid #f0f2f5; font-weight: 600; font-size: 14px; color: var(--text); display: flex; align-items: center; justify-content: space-between; }
.card-panel .card-body-custom { padding: 20px 22px; }
.main-content .page-header {
  background: transparent; padding: 0; margin-bottom: 24px;
}
.main-content .page-header h2 { font-size: 22px; font-weight: 700; color: var(--text); margin: 0 0 4px; }
.main-content .page-header p { color: #888; font-size: 14px; margin: 0; }
.stat-card { background: #fff; border-radius: 10px; padding: 20px 22px; border: 1px solid var(--border); display: flex; align-items: center; gap: 14px; box-shadow: var(--shadow); }
.stat-icon { width: 46px; height: 46px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.stat-icon.blue { background: #e8f0fe; color: var(--navy); }
.stat-icon.green { background: #e6f7ef; color: #1a8c5b; }
.stat-icon.gold { background: #fef9e7; color: var(--gold); }
.stat-icon.red { background: #fee8e8; color: #c0392b; }
.stat-num { font-size: 24px; font-weight: 700; color: var(--text); line-height: 1; }
.stat-label { font-size: 12px; color: #888; margin-top: 3px; }
.status-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f8f9fc; font-size: 13px; color: #555; }
.status-row:last-child { border-bottom: none; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.status-dot.green { background: #27ae60; }
.status-dot.blue { background: #2980b9; }
.status-dot.red { background: #e74c3c; }

@media (max-width: 768px) {
  #sidebar { margin-left: -260px; }
  #sidebar.active { margin-left: 0; }
  #content { margin-left: 0; width: 100%; }
  .main-content { padding: 20px 16px; }
  .page-container { padding: 20px 16px 40px; }
  .auth-card { padding: 32px 24px; }
}


/* ─── DASHBOARD HELPERS ──────────────────────────────────────────────────── */
.org-name { font-weight: 700; font-size: 15px; color: var(--text); margin-bottom: 8px; }
.org-empty { color: var(--text-muted); font-size: 13px; margin: 0; }
.org-empty a { color: var(--navy); font-weight: 600; }
.info-value-sm { font-size: 13px; }
.info-mono { font-family: monospace; letter-spacing: 0.5px; }
.status-pill { font-size: 11px; padding: 3px 10px; border-radius: 20px; font-weight: 600; }

.quick-action-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 18px; border-bottom: 1px solid var(--border);
  text-decoration: none; color: var(--text); transition: background 0.15s;
}
.quick-action-row:hover { background: #f5f7fa; text-decoration: none; color: var(--text); }
.quick-action-row-last { border-bottom: none; }
.qa-title { font-weight: 600; font-size: 13px; color: var(--text); }
.qa-sub { font-size: 12px; color: var(--text-muted); }
.qa-arrow { margin-left: auto; color: #b0b8c4; font-size: 11px; }

/* Enroll modal — formal tokens, no rainbow */
.enroll-modal-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,0.45);
  z-index: 1050; display: flex; align-items: center; justify-content: center; padding: 20px;
}
.enroll-modal {
  background: #fff; border-radius: 6px; max-width: 440px; width: 100%;
  padding: 24px 22px; box-shadow: 0 8px 24px rgba(0,0,0,0.15); position: relative;
  border: 1px solid var(--border);
}
.enroll-modal-close {
  position: absolute; top: 10px; right: 12px; border: none; background: transparent;
  font-size: 20px; color: #888; cursor: pointer; line-height: 1;
}
.enroll-modal-icon {
  width: 40px; height: 40px; border-radius: 6px; background: #eef1f6;
  color: var(--navy); display: flex; align-items: center; justify-content: center;
  margin-bottom: 12px; font-size: 18px;
}
.enroll-modal-title { margin: 0 0 8px; color: var(--text); font-size: 17px; font-weight: 700; }
.enroll-modal-body { margin: 0 0 16px; color: var(--text-muted); font-size: 14px; line-height: 1.5; }
.enroll-modal-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* Contract thumbnails (partials/contract-thumb.hbs) — fixed box, image contained, initial placeholder */
.ct-thumb { width:180px; height:80px; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.ct-thumb img { max-width:100%; max-height:100%; width:auto; height:auto; object-fit:contain; }
.ct-thumb-ph { width:64px; height:64px; border-radius:12px; background:#eef1f6; color:#4a5a78; display:flex; align-items:center; justify-content:center; font-size:26px; font-weight:700; }
.ct-thumb-sm { width:72px; height:40px; }
.ct-thumb-sm .ct-thumb-ph { width:40px; height:40px; border-radius:8px; font-size:16px; }
.ct-cell { display:flex; align-items:center; gap:12px; }

/* USPPG-334: Order History only — wider page, tighter cells, NDC on one line, sticky header + always-visible sideways scroll */
.page-container.oh-wide { max-width: 1600px; }
.oh-scroll { max-height: 70vh; overflow: auto; }
#order-history-table th, #order-history-table td { padding: 8px 10px; }
#order-history-table thead th { position: sticky; top: 0; z-index: 2; background: #f8f9fc; box-shadow: inset 0 -1px 0 var(--border); }
#order-history-table td.oh-ndc { white-space: nowrap; }
