/* ═══════════════════════════════════════════════════════════════════════════
   Pipeline by ABHITO LLC — Master Stylesheet
   /assets/assets-style.css
   RULE: NO inline styles anywhere. All styles live here only.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── GOOGLE FONTS ─────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&family=DM+Mono:wght@300;400;500&display=swap');

/* ─── CSS CUSTOM PROPERTIES ────────────────────────────────────────────────── */
:root {
  /* Brand Blues */
  --brand-primary:        #1A5BB7;
  --brand-primary-dark:   #0F3E82;
  --brand-primary-light:  #2E78D4;
  --brand-primary-xlight: #D6E6FA;

  /* Brand Cyan */
  --brand-cyan:           #00C2E0;
  --brand-cyan-light:     #7EEAF8;
  --brand-cyan-xlight:    #E0F9FD;

  /* Neutrals */
  --neutral-900: #0C1929;
  --neutral-800: #152236;
  --neutral-700: #1E3550;
  --neutral-600: #2D4A6A;
  --neutral-500: #4A6585;
  --neutral-400: #7A93AE;
  --neutral-300: #B0C4D8;
  --neutral-200: #D7E5F0;
  --neutral-100: #EDF4FA;
  --neutral-50:  #F5F9FD;
  --white:       #FFFFFF;

  /* Accents */
  --accent-gold:       #F5A623;
  --accent-gold-light: #FDE8BC;

  /* Status */
  --status-open:           #1A5BB7;
  --status-open-bg:        #D6E6FA;
  --status-review:         #7C3AED;
  --status-review-bg:      #EDE9FE;
  --status-submitted:      #0891B2;
  --status-submitted-bg:   #CFFAFE;
  --status-won:            #059669;
  --status-won-bg:         #D1FAE5;
  --status-lost:           #DC2626;
  --status-lost-bg:        #FEE2E2;
  --status-draft:          #6B7280;
  --status-draft-bg:       #F3F4F6;

  /* Semantic */
  --success:    #059669;
  --success-bg: #D1FAE5;
  --warning:    #D97706;
  --warning-bg: #FEF3C7;
  --error:      #DC2626;
  --error-bg:   #FEE2E2;
  --info:       #0891B2;
  --info-bg:    #E0F9FD;

  /* Typography */
  --font-display: 'Syne', sans-serif;
  --font-body:    'DM Sans', sans-serif;
  --font-mono:    'DM Mono', monospace;

  /* Border Radius */
  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   16px;
  --radius-xl:   24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm:  0 1px 3px rgba(26,91,183,0.08);
  --shadow-md:  0 4px 16px rgba(26,91,183,0.12);
  --shadow-lg:  0 12px 40px rgba(26,91,183,0.16);
  --shadow-xl:  0 24px 64px rgba(26,91,183,0.20);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--neutral-900);
  background: var(--neutral-50);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; }
a { color: var(--brand-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── UTILITY ───────────────────────────────────────────────────────────────── */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border-width: 0;
}
.mb-0  { margin-bottom: 0; }
.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.text-center { text-align: center; }
.text-right  { text-align: right; }
.d-flex      { display: flex; }
.align-center { align-items: center; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.w-full { width: 100%; }

/* ─── GRID HELPERS ──────────────────────────────────────────────────────────── */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

/* ─── BUTTONS ───────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1.4;
}
.btn:focus-visible {
  outline: 3px solid var(--brand-cyan);
  outline-offset: 2px;
}
.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
}

.btn-primary {
  background: var(--brand-primary);
  color: var(--white);
  border-color: var(--brand-primary);
  box-shadow: 0 2px 8px rgba(26,91,183,0.30);
}
.btn-primary:hover:not(:disabled) {
  background: var(--brand-primary-dark);
  border-color: var(--brand-primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(26,91,183,0.40);
  text-decoration: none;
}
.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: var(--white);
  color: var(--brand-primary);
  border-color: var(--brand-primary);
}
.btn-secondary:hover:not(:disabled) {
  background: var(--brand-primary-xlight);
  text-decoration: none;
}

.btn-ghost {
  background: transparent;
  color: var(--neutral-600);
  border-color: var(--neutral-200);
}
.btn-ghost:hover:not(:disabled) {
  background: var(--neutral-100);
  color: var(--neutral-800);
  border-color: var(--neutral-300);
  text-decoration: none;
}

.btn-danger {
  background: var(--white);
  color: var(--error);
  border-color: var(--error);
}
.btn-danger:hover:not(:disabled) {
  background: var(--error-bg);
  text-decoration: none;
}

.btn-ai {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-cyan));
  color: var(--white);
  border-color: transparent;
  box-shadow: 0 2px 12px rgba(0,194,224,0.30);
}
.btn-ai:hover:not(:disabled) {
  box-shadow: 0 4px 20px rgba(0,194,224,0.50);
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-sm  { padding: 6px 12px; font-size: 12px; }
.btn-lg  { padding: 12px 28px; font-size: 15px; }
.btn-xl  { padding: 14px 36px; font-size: 16px; }

/* ─── FORM ELEMENTS ─────────────────────────────────────────────────────────── */
.form-group    { margin-bottom: 18px; }
.form-group:last-child { margin-bottom: 0; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-700);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}
.form-label.required::after {
  content: ' *';
  color: var(--error);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid var(--neutral-200);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--neutral-900);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  box-sizing: border-box;
}
.form-input,
.form-textarea {
  -webkit-appearance: none;
  appearance: none;
}
.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--neutral-300);
  font-weight: 400;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 4px rgba(26,91,183,0.10);
}
.form-input.is-invalid,
.form-select.is-invalid,
.form-textarea.is-invalid {
  border-color: var(--error);
  box-shadow: 0 0 0 4px rgba(220,38,38,0.08);
}

.form-select {
  background-color: var(--white);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%234A6585' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px 16px;
  padding-right: 40px;
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.form-textarea {
  resize: vertical;
  min-height: 90px;
  line-height: 1.6;
}

.form-helper {
  font-size: 12px;
  color: var(--neutral-400);
  margin-top: 5px;
  line-height: 1.5;
}
.form-error {
  font-size: 12px;
  color: var(--error);
  margin-top: 5px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Password input wrapper (for show/hide toggle) */
.form-input-wrap {
  position: relative;
}
.form-input-wrap .form-input {
  padding-right: 44px;
}
.password-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--neutral-400);
  font-size: 16px;
  padding: 4px;
  transition: color 0.15s;
  line-height: 1;
}
.password-toggle:hover { color: var(--brand-primary); }

/* Checkbox */
.checkbox-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.checkbox-wrap input[type="checkbox"] {
  width: 18px;
  height: 18px;
  border: 2px solid var(--neutral-300);
  border-radius: 4px;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  background: var(--white);
  transition: all 0.15s;
  flex-shrink: 0;
  position: relative;
}
.checkbox-wrap input[type="checkbox"]:checked {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
}
.checkbox-wrap input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 5px;
  height: 8px;
  border: 2px solid white;
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}
.checkbox-wrap .checkbox-label {
  font-size: 13px;
  color: var(--neutral-600);
  font-weight: 500;
}

/* ─── CAPTCHA ────────────────────────────────────────────────────────────────── */
.captcha-box {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--neutral-50);
  border: 2px solid var(--neutral-200);
  border-radius: var(--radius-lg);
  padding: 12px 16px;
  flex-wrap: wrap;
}
.captcha-image-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}
.captcha-image-wrap img {
  border-radius: var(--radius-sm);
  height: 52px;
  width: auto;
}
.captcha-sep {
  color: var(--neutral-400);
  font-size: 18px;
  flex-shrink: 0;
}
.captcha-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 140px;
}
.captcha-input {
  width: 110px !important;
  text-align: center;
  letter-spacing: 0.25em;
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 500;
}
.captcha-refresh {
  width: 36px;
  height: 36px;
  background: var(--neutral-100);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 16px;
  color: var(--neutral-500);
  flex-shrink: 0;
}
.captcha-refresh:hover {
  background: var(--brand-primary-xlight);
  color: var(--brand-primary);
  border-color: var(--brand-primary);
  transform: rotate(180deg);
}

/* ─── ALERTS ────────────────────────────────────────────────────────────────── */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.5;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.alert:last-child { margin-bottom: 0; }

.alert-success { background: var(--success-bg); color: var(--success); border: 1px solid rgba(5,150,105,0.2); }
.alert-error   { background: var(--error-bg);   color: var(--error);   border: 1px solid rgba(220,38,38,0.2); }
.alert-warning { background: var(--warning-bg); color: var(--warning); border: 1px solid rgba(217,119,6,0.2); }
.alert-info    { background: var(--info-bg);    color: var(--info);    border: 1px solid rgba(8,145,178,0.15); }

/* ─── ═══════════════════════════════════════════════════════════════════════
   AUTH LAYOUT
   ═══════════════════════════════════════════════════════════════════════ */

/* Full-screen split layout */
.auth-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--neutral-50);
}

/* Left panel — dark brand panel */
.auth-panel {
  background: linear-gradient(145deg, var(--neutral-900) 0%, var(--brand-primary-dark) 65%, var(--neutral-800) 100%);
  padding: 56px 52px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  min-height: 100vh;
}

/* Glowing radial accent */
.auth-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 25% 85%, rgba(0,194,224,0.15) 0%, transparent 60%),
              radial-gradient(ellipse 50% 40% at 80% 20%, rgba(26,91,183,0.20) 0%, transparent 50%);
  pointer-events: none;
}

/* Subtle grid overlay */
.auth-panel-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}

.auth-panel-content {
  position: relative;
  z-index: 1;
}

.auth-panel-brand {
  margin-bottom: 52px;
}
.auth-panel-brand-name {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.02em;
}
.auth-panel-brand-sub {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--brand-cyan);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-top: 3px;
}

.auth-panel-tagline {
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.12;
  letter-spacing: -0.025em;
  margin-bottom: 20px;
}
.auth-panel-tagline span { color: var(--brand-cyan); }

.auth-panel-desc {
  font-size: 15px;
  color: var(--neutral-300);
  line-height: 1.75;
  max-width: 380px;
  font-weight: 400;
}

.auth-panel-features {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.auth-feature {
  display: flex;
  align-items: center;
  gap: 14px;
}
.auth-feature-icon {
  width: 34px;
  height: 34px;
  background: rgba(0,194,224,0.12);
  border: 1px solid rgba(0,194,224,0.2);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.auth-feature-text {
  font-size: 13.5px;
  color: var(--neutral-300);
  font-weight: 500;
  line-height: 1.4;
}

.auth-panel-footer {
  position: relative;
  z-index: 1;
}
.auth-panel-footer p {
  font-size: 12px;
  color: var(--neutral-500);
}

/* Right panel — form */
.auth-form-panel {
  background: var(--white);
  padding: 60px 52px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;        /* ← centres .auth-form-inner horizontally */
  overflow-y: auto;
}

.auth-form-inner {
  max-width: 420px;
  width: 100%;
  margin: 0 auto;
  flex-shrink: 0;             /* ← prevents flex from squishing the inner box */
}

/* Fallback: if a login page wraps form directly inside .auth-form-panel
   without .auth-form-inner, cap the form element's width here */
.auth-form-panel > form {
  max-width: 420px;
  width: 100%;
}

.auth-form-header {
  margin-bottom: 32px;
}
.auth-form-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--brand-cyan);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 8px;
  font-weight: 400;
}
.auth-form-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 800;
  color: var(--neutral-900);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.auth-form-sub {
  font-size: 14px;
  color: var(--neutral-500);
  line-height: 1.65;
  font-weight: 400;
}

/* Divider row */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0;
  color: var(--neutral-400);
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--neutral-200);
}

/* Inline link row (e.g. "Already have an account?") */
.auth-link-row {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--neutral-500);
}
.auth-link-row a {
  color: var(--brand-primary);
  font-weight: 600;
}
.auth-link-row a:hover { text-decoration: underline; }

/* Forgot password inline link */
.auth-forgot-link {
  font-size: 13px;
  color: var(--brand-primary);
  font-weight: 600;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}
.auth-forgot-link:hover { text-decoration: underline; }

/* Remember device + forgot row */
.auth-form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

/* ─── STEP INDICATOR ────────────────────────────────────────────────────────── */
.step-indicator {
  display: flex;
  align-items: center;
  margin-bottom: 32px;
}

.step {
  display: flex;
  align-items: center;
  gap: 8px;
}

.step-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid var(--neutral-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--neutral-400);
  font-family: var(--font-display);
  flex-shrink: 0;
  transition: all 0.25s ease;
  background: var(--white);
}

.step.done .step-circle {
  background: var(--success);
  border-color: var(--success);
  color: var(--white);
}
.step.active .step-circle {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: var(--white);
  box-shadow: 0 0 0 4px rgba(26,91,183,0.15);
}

.step-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--neutral-400);
  white-space: nowrap;
}
.step.active .step-label { color: var(--brand-primary); }
.step.done .step-label   { color: var(--success); }

.step-line {
  flex: 1;
  height: 2px;
  background: var(--neutral-200);
  margin: 0 8px;
  min-width: 16px;
  transition: background 0.25s ease;
}
.step.done + .step-line { background: var(--success); }

/* ─── SECURITY BADGE ────────────────────────────────────────────────────────── */
.security-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-primary-xlight);
  border: 1px solid rgba(26,91,183,0.15);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 12px;
  color: var(--brand-primary-dark);
  font-weight: 500;
  margin-top: 16px;
  line-height: 1.5;
}

/* ─── INFO CALLOUT (registration panel) ────────────────────────────────────── */
.info-callout {
  background: rgba(0,194,224,0.08);
  border: 1px solid rgba(0,194,224,0.20);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  margin-top: 36px;
}
.info-callout-label {
  font-size: 11px;
  color: var(--brand-cyan);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 6px;
  font-weight: 400;
}
.info-callout-text {
  font-size: 13px;
  color: var(--neutral-300);
  line-height: 1.65;
}

/* ─── VERIFY PAGE — CODE INPUT ─────────────────────────────────────────────── */
.verify-code-inputs {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 8px 0 4px;
}
.verify-digit {
  width: 52px;
  height: 60px;
  border: 2px solid var(--neutral-200);
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  text-align: center;
  color: var(--brand-primary-dark);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
.verify-digit:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 4px rgba(26,91,183,0.12);
}
.verify-digit.filled {
  border-color: var(--brand-primary-light);
  background: var(--brand-primary-xlight);
}

.verify-resend {
  text-align: center;
  font-size: 13px;
  color: var(--neutral-500);
  margin-top: 16px;
}
.verify-resend a,
.verify-resend button {
  color: var(--brand-primary);
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-size: 13px;
  font-family: var(--font-body);
}
.verify-resend a:hover,
.verify-resend button:hover { text-decoration: underline; }

/* ─── PASSWORD STRENGTH ─────────────────────────────────────────────────────── */
.password-strength {
  margin-top: 8px;
}
.password-strength-bar {
  height: 4px;
  background: var(--neutral-200);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: 6px;
}
.password-strength-fill {
  height: 100%;
  border-radius: var(--radius-full);
  transition: width 0.3s ease, background 0.3s ease;
  width: 0%;
}
.password-strength-fill.strength-weak   { width: 25%; background: var(--error); }
.password-strength-fill.strength-fair   { width: 50%; background: var(--warning); }
.password-strength-fill.strength-good   { width: 75%; background: var(--brand-primary-light); }
.password-strength-fill.strength-strong { width: 100%; background: var(--success); }
.password-strength-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--neutral-400);
}
.password-strength-label.strength-weak   { color: var(--error); }
.password-strength-label.strength-fair   { color: var(--warning); }
.password-strength-label.strength-good   { color: var(--brand-primary); }
.password-strength-label.strength-strong { color: var(--success); }

/* ─── RESET SUCCESS STATE ───────────────────────────────────────────────────── */
.auth-success-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--success-bg);
  border: 2px solid rgba(5,150,105,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 24px;
  animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes popIn {
  from { transform: scale(0.5); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}

/* ─── INVITE ACCEPT PAGE ────────────────────────────────────────────────────── */
.invite-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-primary-xlight);
  border: 1px solid var(--brand-primary-light);
  border-radius: var(--radius-full);
  padding: 5px 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--brand-primary-dark);
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  margin-bottom: 20px;
}

/* ─── ═══════════════════════════════════════════════════════════════════════
   APP CHROME (sidebar + topbar) — post-login
   ═══════════════════════════════════════════════════════════════════════ */

.app-layout {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--neutral-900);
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  padding: 20px 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-logo {
  padding: 0 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 12px;
}
.sidebar-logo-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  color: var(--white);
  letter-spacing: -0.02em;
}
.sidebar-logo-sub {
  font-size: 11px;
  color: var(--brand-cyan);
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
}

.sidebar-section { padding: 0 12px; margin-bottom: 4px; }
.sidebar-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--neutral-500);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 8px 8px 4px;
}
.sidebar-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.15s;
  color: var(--neutral-400);
  font-size: 13.5px;
  font-weight: 500;
  text-decoration: none;
}
.sidebar-item:hover {
  background: rgba(255,255,255,0.06);
  color: var(--white);
  text-decoration: none;
}
.sidebar-item.active {
  background: rgba(26,91,183,0.25);
  color: var(--white);
}
.sidebar-item.active .sidebar-icon { color: var(--brand-cyan); }
.sidebar-icon { font-size: 16px; width: 20px; text-align: center; flex-shrink: 0; }

.sidebar-badge {
  margin-left: auto;
  background: var(--brand-primary);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: var(--radius-full);
}

.sidebar-footer {
  margin-top: auto;
  padding: 16px 20px 0;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.sidebar-user { display: flex; align-items: center; gap: 10px; }
.sidebar-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-cyan));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}
.sidebar-user-name { font-size: 13px; font-weight: 600; color: var(--white); }
.sidebar-user-role { font-size: 11px; color: var(--neutral-400); }

.main-content {
  flex: 1;
  background: var(--neutral-50);
  min-height: 100vh;
  overflow: auto;
}

.topbar {
  background: var(--white);
  border-bottom: 1px solid var(--neutral-200);
  padding: 0 28px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 10;
}
.topbar-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--neutral-900);
}

/* Left group: back link + title */
.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Right group: search + buttons — gap prevents overlap */
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.page-body { padding: 28px; }

/* ─── APP FOOTER — see Ticket Module section below ─────────────────────────────── */

/* ─── RESPONSIVE ────────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }
  .auth-panel {
    display: none;
  }
  .auth-form-panel {
    padding: 40px 24px;
    min-height: 100vh;
    align-items: center;      /* keep form centred on mobile */
  }
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .grid-3 {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 520px) {
  .auth-form-panel {
    padding: 32px 20px;
  }
  .auth-form-title {
    font-size: 22px;
  }
  .verify-code-inputs {
    gap: 6px;
  }
  .verify-digit {
    width: 44px;
    height: 52px;
    font-size: 22px;
  }
  .captcha-box {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 320px) {
  .auth-form-panel {
    padding: 24px 16px;
  }
}
/* ============================================================
   PIPELINE — TICKET MODULE CSS
   Append to: /assets/assets-style.css
   ============================================================ */


/* ── Status filter bar ─────────────────────────────────────── */
.status-filter-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}


/* ── Ticket Thread ─────────────────────────────────────────── */
.ticket-thread {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ticket-message {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

/* Staff messages aligned to the right */
.ticket-message-staff {
  flex-direction: row-reverse;
}

.ticket-message-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--brand-primary-xlight);
  color: var(--brand-primary);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ticket-message-avatar.avatar-staff {
  background: var(--brand-cyan-xlight);
  color: var(--brand-cyan);
}

.ticket-message-bubble {
  max-width: 70%;
  background: var(--neutral-100);
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  flex: 1;
}

.ticket-message-bubble.bubble-staff {
  background: var(--brand-cyan-xlight);
  border-color: rgba(0, 194, 224, 0.25);
}

.ticket-message-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.ticket-message-name {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 13px;
  color: var(--neutral-800);
}

.ticket-message-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neutral-400);
}

.ticket-message-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--neutral-200);
  color: var(--neutral-600);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ticket-message-badge.badge-staff {
  background: var(--brand-cyan-xlight);
  color: var(--brand-cyan);
}

.ticket-message-text {
  font-size: 14px;
  color: var(--neutral-700);
  line-height: 1.65;
  white-space: pre-line;
}

.ticket-attachment {
  margin-top: 10px;
  padding: 8px 10px;
  background: var(--white);
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--neutral-600);
  display: flex;
  align-items: center;
  gap: 6px;
}


/* ── Badge: WIP ────────────────────────────────────────────── */
.badge-wip {
  background: var(--accent-gold-light);
  color: var(--warning);
}


/* ── Ticket Modal ──────────────────────────────────────────── */
.ticket-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 25, 41, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 500;
  display: none;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 72px 24px 24px;
}

.ticket-modal-overlay.open {
  display: flex;
}

.ticket-modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  width: 440px;
  max-width: calc(100vw - 32px);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: ticketSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
}

@keyframes ticketSlideUp {
  from { transform: translateY(40px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.ticket-modal-header {
  background: var(--neutral-900);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(0, 194, 224, 0.2);
  flex-shrink: 0;
}

.ticket-modal-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 8px;
}

.ticket-modal-close {
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--white);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.ticket-modal-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.ticket-modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
}

/* ── Ticket success state inside modal ─────────────────────── */
.ticket-success {
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 0;
  gap: 8px;
}

.ticket-success-icon {
  font-size: 40px;
  margin-bottom: 8px;
}

.ticket-success-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--neutral-900);
}

.ticket-success-sub {
  font-size: 14px;
  color: var(--neutral-500);
  max-width: 300px;
}

.ticket-success-ref {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--brand-primary);
  font-weight: 600;
  margin-top: 4px;
}

/* ── Footer ────────────────────────────────────────────────── */
.app-footer {
  background: var(--neutral-900);
  padding: 12px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  gap: 12px;
  flex-wrap: wrap;
}

.footer-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.footer-link {
  font-size: 12px;
  color: var(--neutral-500);
  cursor: pointer;
  transition: color 0.15s;
  text-decoration: none;
}

.footer-link:hover {
  color: var(--neutral-300);
}

.footer-security {
  font-size: 11px;
  color: var(--neutral-600);
  font-family: var(--font-mono);
}

.footer-ticket-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(26, 91, 183, 0.18);
  border: 1px solid rgba(26, 91, 183, 0.4);
  color: var(--brand-primary-light);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  padding: 7px 16px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.footer-ticket-btn:hover {
  background: rgba(26, 91, 183, 0.32);
  border-color: rgba(26, 91, 183, 0.6);
}

/* ── Upload zone (compact variant for modal) ───────────────── */
.upload-zone-sm .upload-label {
  font-size: 13px;
  padding: 12px;
}

/* ── Utility ───────────────────────────────────────────────── */
.mono-sm {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--neutral-500);
}

.td-muted {
  font-size: 12px;
  color: var(--neutral-400);
}

.btn-block {
  width: 100%;
}



/* ═══════════════════════════════════════════════════════════════════════════════
   Pipeline — Settings Layout CSS Additions
   Append to: /assets/assets-style.css
   ═══════════════════════════════════════════════════════════════════════════════ */


/* ── Settings subnav bar (tabs left, action right) ───────────────────────── */
.settings-subnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--neutral-200);
  margin-bottom: 28px;
  padding-bottom: 0;
}

.settings-subnav-tabs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 4px 0;
}

.settings-subnav-action {
  flex-shrink: 0;
}

.settings-tab {
  display: inline-flex;
  align-items: center;
  padding: 7px 16px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--neutral-600);
  background: var(--white);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-full);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.settings-tab:hover {
  background: var(--brand-primary-xlight);
  color: var(--brand-primary);
  border-color: var(--brand-primary-light);
  text-decoration: none;
}
.settings-tab.active {
  background: var(--brand-primary);
  color: var(--white);
  border-color: var(--brand-primary);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(26,91,183,0.25);
}

.settings-body {
  max-width: 820px;
}

/* ── Settings sections within content ───────────────────────────────────── */
.settings-section {
  margin-bottom: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--neutral-200);
}

.settings-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.settings-section-title {
  font-family: 'Syne', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--neutral-900);
  margin-bottom: 4px;
}

.settings-section-sub {
  font-size: 13px;
  color: var(--neutral-500);
  margin-bottom: 20px;
  line-height: 1.5;
}

.settings-section-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

/* ── Form layout helpers ─────────────────────────────────────────────────── */
.form-row {
  margin-bottom: 16px;
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row-3 {
  display: grid;
  grid-template-columns: 1fr 100px 120px;
  gap: 16px;
}



.form-actions {
  padding-top: 8px;
  display: flex;
  gap: 12px;
}

.input-prefix-wrap {
  display: flex;
  align-items: center;
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-sm, 6px);
  overflow: hidden;
  background: var(--white, #fff);
}

.input-prefix {
  padding: 0 10px;
  font-weight: 700;
  color: var(--neutral-500);
  font-size: 14px;
  background: var(--neutral-100);
  border-right: 1px solid var(--neutral-300);
  align-self: stretch;
  display: flex;
  align-items: center;
}

.input-prefix-wrap .form-input {
  border: none;
  border-radius: 0;
  flex: 1;
}

.input-prefix-wrap .form-input:focus {
  box-shadow: none;
}

/* ── Toggle switch ───────────────────────────────────────────────────────── */
.toggle-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm, 6px);
  overflow: hidden;
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  background: var(--white, #fff);
  border-bottom: 1px solid var(--neutral-100);
}

.toggle-row:last-child {
  border-bottom: none;
}

.toggle-info {
  flex: 1;
}

.toggle-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--neutral-800);
}

.toggle-sub {
  font-size: 13px;
  color: var(--neutral-500);
  margin-top: 2px;
  line-height: 1.4;
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--neutral-300);
  border-radius: 24px;
  transition: background 0.2s;
}

.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  top: 3px;
  background: var(--white, #fff);
  border-radius: 50%;
  transition: transform 0.2s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--brand-primary);
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(20px);
}

/* ── Integration cards ───────────────────────────────────────────────────── */
.integration-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm, 6px);
  margin-bottom: 8px;
  background: var(--white, #fff);
  transition: border-color 0.15s;
}

.integration-card-active {
  border-color: var(--neutral-200);
}

.integration-card-inactive {
  opacity: 0.6;
  border-style: dashed;
}

.integration-card-icon {
  font-size: 22px;
  width: 36px;
  text-align: center;
  flex-shrink: 0;
}

.integration-card-body {
  flex: 1;
  min-width: 0;
}

.integration-card-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--neutral-800);
}

.integration-card-meta {
  font-size: 12px;
  color: var(--neutral-500);
  margin-top: 3px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
}

.integration-url {
  color: var(--neutral-400);
  word-break: break-all;
}

.integration-card-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.integration-empty {
  font-size: 13px;
  color: var(--neutral-400);
  padding: 16px 0;
  font-style: italic;
}

.integration-empty a {
  color: var(--brand-primary);
  font-style: normal;
  font-weight: 600;
}

.integration-always-on {
  flex-shrink: 0;
}

/* ── Misc utilities ──────────────────────────────────────────────────────── */
.badge-admin {
  background: var(--accent-gold-light);
  color: var(--accent-gold);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full, 999px);
  vertical-align: middle;
  margin-left: 6px;
}



/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .settings-subnav {
    flex-wrap: wrap;
    gap: 8px;
  }
  .settings-tab {
    padding: 6px 12px;
    font-size: 12px;
  }
  .settings-body {
    max-width: 100%;
  }
  .form-row-2,
  .form-row-3 {
    grid-template-columns: 1fr;
  }
}

/* ─── MISSING UTILITIES & ADDITIONS ─────────────────────────────────────────── */

/* form-hint — used on all <small class="form-hint"> throughout the app */
.form-hint {
  font-size: 12px;
  color: var(--neutral-400);
  margin-top: 4px;
  line-height: 1.5;
  display: block;
}

/* form-optional — label modifier for optional fields */
.form-optional {
  font-weight: 400;
  color: var(--neutral-400);
  font-size: 11px;
  margin-left: 2px;
}

/* Readonly/disabled form inputs */
.form-input[readonly],
.form-select[disabled],
.form-textarea[readonly] {
  background: var(--neutral-50);
  color: var(--neutral-500);
  cursor: default;
  border-color: var(--neutral-200);
}

/* .form-group gets both margin AND flex-column — unified definition */
/* The base margin is already set above; add flex layout for settings context */
.settings-body .form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 0;
}

/* Sidebar additions */
.sidebar-wallet {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--brand-cyan-light);
  background: rgba(0, 194, 224, 0.12);
  padding: 2px 7px;
  border-radius: var(--radius-full);
}

.sidebar-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--neutral-400);
  font-size: 14px;
  text-decoration: none;
  margin-left: auto;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}
.sidebar-logout:hover {
  background: rgba(220, 38, 38, 0.2);
  color: #FC8181;
  text-decoration: none;
}

/* Margin utilities — additions (complete set at top of file, additions here) */
.mt-4  { margin-top:  4px;  }
.mt-32 { margin-top: 32px;  }
.mb-4  { margin-bottom:  4px;  }
.mb-12 { margin-bottom: 12px; }

/* Flex helpers */
.flex-row    { display: flex; flex-direction: row; }
.flex-end    { display: flex; justify-content: flex-end; }

/* Typography helpers */
.text-small  { font-size: 12px; }
.text-muted  { color: var(--neutral-400); }
.text-warning { color: var(--warning); }
.font-mono   { font-family: var(--font-mono); }
.font-bold   { font-weight: 700; }
.ml-auto     { margin-left: auto; }


/* ═══════════════════════════════════════════════════════════════════════════════
   Pipeline — Missing Component Classes
   Ported from pipeline-mockups.html — all classes that were in the mockup
   design but absent from this stylesheet.
   ═══════════════════════════════════════════════════════════════════════════════ */

/* ─── TABS (used on Leads, Library, Proposals, Tickets) ─────────────────────── */
.tab-row {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--neutral-200);
  margin-bottom: 24px;
  overflow-x: auto;
  scrollbar-width: none;
}
.tab-row::-webkit-scrollbar { display: none; }
.tab {
  padding: 10px 18px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--neutral-500);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  white-space: nowrap;
  transition: all 0.15s;
  text-decoration: none;
}
.tab.active { color: var(--brand-primary); border-bottom-color: var(--brand-primary); }
.tab:hover  { color: var(--neutral-700); text-decoration: none; }

/* ─── CARDS ─────────────────────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}
.card-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--neutral-700);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--neutral-100);
}

/* ─── BADGES (status indicators) ────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.badge-open      { background: var(--status-open-bg);      color: var(--status-open);      } .badge-open::before      { background: var(--status-open); }
.badge-review    { background: var(--status-review-bg);    color: var(--status-review);    } .badge-review::before    { background: var(--status-review); }
.badge-submitted { background: var(--status-submitted-bg); color: var(--status-submitted); } .badge-submitted::before { background: var(--status-submitted); }
.badge-won       { background: var(--status-won-bg);       color: var(--status-won);       } .badge-won::before       { background: var(--status-won); }
.badge-lost      { background: var(--status-lost-bg);      color: var(--status-lost);      } .badge-lost::before      { background: var(--status-lost); }
.badge-draft     { background: var(--status-draft-bg);     color: var(--status-draft);     } .badge-draft::before     { background: var(--status-draft); }
.badge-closed    { background: var(--neutral-100);         color: var(--neutral-500);      } .badge-closed::before    { background: var(--neutral-400); }

/* ─── TABLE ─────────────────────────────────────────────────────────────────── */
.table-wrap {
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background: var(--white);
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}
.data-table thead {
  background: var(--neutral-50);
  border-bottom: 2px solid var(--neutral-200);
}
.data-table th {
  padding: 11px 16px;
  text-align: left;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  color: var(--neutral-500);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--neutral-100);
  color: var(--neutral-700);
  vertical-align: middle;
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--brand-primary-xlight); cursor: pointer; }
.td-primary { font-weight: 600; color: var(--neutral-900); }
.td-mono    { font-family: var(--font-mono); font-size: 12px; color: var(--neutral-400); margin-top: 2px; }
.td-actions { display: flex; gap: 6px; }

/* ─── STATS GRID ─────────────────────────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-xl);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}
.stat-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-cyan));
}
.stat-icon  { position: absolute; top: 18px; right: 18px; font-size: 22px; opacity: 0.15; }
.stat-label { font-size: 12px; font-weight: 600; color: var(--neutral-500); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
.stat-value { font-family: var(--font-display); font-size: 32px; font-weight: 800; color: var(--neutral-900); line-height: 1; }
.stat-delta { font-size: 12px; color: var(--success); margin-top: 6px; font-weight: 600; }
.stat-delta.neg { color: var(--error); }

/* ─── SECTION HEADINGS ───────────────────────────────────────────────────────── */
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.section-title  { font-family: var(--font-display); font-size: 18px; font-weight: 800; color: var(--neutral-900); }
.section-sub    { font-size: 13px; color: var(--neutral-500); margin-top: 3px; }
.divider        { height: 1px; background: var(--neutral-200); margin: 24px 0; }

/* ─── PROGRESS BAR ───────────────────────────────────────────────────────────── */
.progress-wrap { height: 6px; background: var(--neutral-200); border-radius: var(--radius-full); overflow: hidden; }
.progress-fill { height: 100%; border-radius: var(--radius-full); background: linear-gradient(90deg, var(--brand-primary), var(--brand-cyan)); }

/* ─── TAGS ───────────────────────────────────────────────────────────────────── */
.tag      { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: var(--radius-full); background: var(--neutral-100); color: var(--neutral-600); font-size: 12px; font-weight: 500; }
.tag-blue   { background: var(--brand-primary-xlight); color: var(--brand-primary); }
.tag-cyan   { background: var(--brand-cyan-xlight); color: var(--status-submitted); }
.tag-purple { background: #EDE9FE; color: #6D28D9; }

/* ─── WALLET BALANCE CARD ────────────────────────────────────────────────────── */
.wallet-balance {
  background: linear-gradient(135deg, var(--brand-primary-dark), var(--brand-primary));
  color: var(--white);
  border-radius: var(--radius-xl);
  padding: 24px 28px;
}

/* ─── UPLOAD ZONE ────────────────────────────────────────────────────────────── */
.upload-zone {
  border: 2px dashed var(--neutral-300);
  border-radius: var(--radius-xl);
  padding: 36px 24px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--neutral-50);
}
.upload-zone:hover { border-color: var(--brand-primary); background: var(--brand-primary-xlight); }
.upload-icon {
  width: 52px; height: 52px;
  background: var(--brand-primary-xlight);
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px;
  font-size: 22px;
}

/* ─── SOURCE CARDS (AutoFetch) ───────────────────────────────────────────────── */
.source-card {
  background: var(--white);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-xl);
  padding: 18px 20px;
  display: flex; align-items: center; gap: 14px;
  transition: all 0.2s; cursor: pointer;
}
.source-card:hover { border-color: var(--brand-primary); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.source-icon   { width: 42px; height: 42px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.source-meta   { flex: 1; }
.source-name   { font-weight: 700; font-size: 14px; color: var(--neutral-900); }
.source-detail { font-size: 12px; color: var(--neutral-400); margin-top: 2px; }
.source-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.source-status.active { background: var(--success); box-shadow: 0 0 6px var(--success); }
.source-status.idle   { background: var(--neutral-300); }

/* ─── AI PANEL (proposal generation) ────────────────────────────────────────── */
.ai-panel {
  background: var(--neutral-900);
  border: 1px solid rgba(0,194,224,0.2);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0,194,224,0.08);
}
.ai-panel-header {
  background: rgba(0,194,224,0.07);
  border-bottom: 1px solid rgba(0,194,224,0.15);
  padding: 14px 18px;
  display: flex; align-items: center; gap: 12px;
}
.ai-icon {
  width: 30px; height: 30px;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-cyan));
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; flex-shrink: 0;
}
.ai-title    { font-family: var(--font-display); font-size: 13px; font-weight: 700; color: var(--white); }
.ai-subtitle { font-size: 11px; color: var(--neutral-400); }
.ai-thinking { margin-left: auto; display: flex; align-items: center; gap: 4px; font-family: var(--font-mono); font-size: 10px; color: var(--brand-cyan); }
.ai-dot {
  width: 5px; height: 5px;
  background: var(--brand-cyan);
  border-radius: 50%;
  animation: aiThink 1.4s ease-in-out infinite;
}
.ai-dot:nth-child(2) { animation-delay: 0.2s; }
.ai-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes aiThink {
  0%, 80%, 100% { transform: scale(1); opacity: 0.4; }
  40%           { transform: scale(1.4); opacity: 1; }
}
.ai-body   { padding: 16px 18px; }
.ai-stream { font-family: var(--font-mono); font-size: 12.5px; color: var(--neutral-300); line-height: 1.7; }
.ai-cursor {
  display: inline-block; width: 2px; height: 13px;
  background: var(--brand-cyan); margin-left: 2px;
  vertical-align: text-bottom;
  animation: aiCursorBlink 1s step-end infinite;
}
@keyframes aiCursorBlink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* ─── INLINE EDIT ────────────────────────────────────────────────────────────── */
.inline-edit { display: flex; align-items: center; gap: 8px; }
.inline-edit-field {
  border: none; background: transparent;
  font-family: var(--font-body); font-size: 14px; color: var(--neutral-700);
  padding: 4px 8px; border-radius: var(--radius-sm);
  transition: all 0.15s; width: 100%;
}
.inline-edit-field:focus { background: var(--neutral-100); outline: none; }

/* ─── CHECKBOX ROW ───────────────────────────────────────────────────────────── */
.checkbox-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.15s;
}
.checkbox-row:hover { border-color: var(--brand-primary); background: var(--brand-primary-xlight); }
.checkbox {
  width: 18px; height: 18px;
  border: 2px solid var(--neutral-300);
  border-radius: 4px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.checkbox.checked { background: var(--brand-primary); border-color: var(--brand-primary); color: var(--white); font-size: 11px; }

/* ─── INPUT GROUP (prefix button) ────────────────────────────────────────────── */
.input-group { display: flex; gap: 0; }
.input-group .form-input { border-radius: var(--radius-md) 0 0 var(--radius-md); border-right: none; }
.input-group .btn        { border-radius: 0 var(--radius-md) var(--radius-md) 0; }

/* ─── TOPBAR SEARCH ──────────────────────────────────────────────────────────── */
.topbar-search,
button.topbar-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--neutral-50);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-md);
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--neutral-400);
  min-width: 200px;
  width: 230px;
  cursor: text;
  appearance: none;
  -webkit-appearance: none;
  text-align: left;
  transition: border-color 0.15s;
}
button.topbar-search:hover,
button.topbar-search:focus-within {
  border-color: var(--brand-primary);
  outline: none;
}

/* ─── BUTTON VARIANTS ────────────────────────────────────────────────────────── */
.btn-icon-only { padding: 8px; }

/* ─── TYPOGRAPHY UTILITIES ───────────────────────────────────────────────────── */
.text-sm      { font-size: 12px; }
.text-mono    { font-family: var(--font-mono); }
.text-primary { color: var(--brand-primary); }
.fw-600       { font-weight: 600; }

/* ─── LAYOUT HELPERS ─────────────────────────────────────────────────────────── */
.flex-between { display: flex; align-items: center; justify-content: space-between; }

/* ─── RESPONSIVE ─────────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .stats-grid { grid-template-columns: 1fr; }
}

/* ── Page toolbar (tabs left, actions right) ─────────────────────────────────
   Used on Leads, Library, Proposals — anywhere a tab-row needs inline actions.
   ─────────────────────────────────────────────────────────────────────────── */
.page-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 2px solid var(--neutral-200);
  margin-bottom: 24px;
}

.page-toolbar .tab-row {
  border-bottom: none;
  margin-bottom: 0;
  flex: 1;
}

.page-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 8px;
  flex-shrink: 0;
}

.page-toolbar-actions .topbar-search {
  min-width: 220px;
}

.page-toolbar-actions .topbar-search input {
  border: none;
  background: transparent;
  outline: none;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--neutral-700);
  width: 100%;
}

.page-toolbar-actions .form-select {
  width: auto;
  padding: 7px 32px 7px 12px;
  font-size: 13px;
  border-color: var(--neutral-200);
  font-weight: 500;
}

@media (max-width: 768px) {
  .page-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .page-toolbar-actions {
    flex-wrap: wrap;
    padding-bottom: 4px;
  }
  .page-toolbar-actions .topbar-search {
    min-width: 0;
    flex: 1;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   ENTRY FORM (entry.php / entry-verify.php)
   ═══════════════════════════════════════════════════════════════════════════ */

body.entry-page {
  background: linear-gradient(145deg, var(--neutral-900), var(--brand-primary-dark));
  min-height: 100vh;
}

.entry-layout {
  display: flex;
  min-height: 100vh;
}

/* Narrow variant for verify page */
.entry-layout-narrow .entry-hero {
  display: none;
}
.entry-layout-narrow .entry-form-wrap {
  max-width: 520px;
  margin: 60px auto;
  width: 100%;
  padding: 0 16px;
}

/* Left hero panel */
.entry-hero {
  flex: 0 0 380px;
  background: linear-gradient(160deg, var(--neutral-900) 0%, var(--brand-primary-dark) 100%);
  display: flex;
  align-items: flex-start;
  padding: 52px 36px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}

.entry-hero-short {
  height: auto;
  position: static;
  padding: 32px 36px;
}

.entry-hero-inner {
  width: 100%;
}

.entry-hero-brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 36px;
}

.entry-hero-brand-name {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  color: var(--white);
  letter-spacing: 0.02em;
}

.entry-hero-brand-by {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--brand-cyan);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 500;
}

.entry-eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--brand-cyan);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.entry-title {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 14px;
}

.entry-title-accent {
  color: var(--brand-cyan);
}

.entry-subtitle {
  font-size: 14px;
  color: var(--neutral-300);
  line-height: 1.75;
  margin-bottom: 32px;
  max-width: 300px;
}

.entry-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.entry-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--neutral-300);
}

.entry-feature-icon {
  font-size: 16px;
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

/* Right form panel */
.entry-form-wrap {
  flex: 1;
  padding: 48px 32px;
  overflow-y: auto;
}

.entry-form-card {
  max-width: 600px;
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-xl);
}

.entry-form-header {
  margin-bottom: 28px;
}

.entry-form-eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--brand-cyan);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.entry-form-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: var(--neutral-900);
  margin-bottom: 6px;
}

.entry-form-sub {
  font-size: 14px;
  color: var(--neutral-500);
}

.entry-submit-btn {
  width: 100%;
  margin-top: 8px;
}

.entry-privacy-note {
  margin-top: 16px;
  font-size: 12px;
}

/* 2-col and 3-col form rows */
.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row-3 {
  display: grid;
  grid-template-columns: 1fr 80px 100px;
  gap: 12px;
}

/* Success state */
.entry-success {
  text-align: center;
  padding: 16px 0;
}

.entry-success-icon {
  font-size: 48px;
  margin-bottom: 16px;
  display: block;
}

.entry-success-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--neutral-900);
  margin-bottom: 12px;
}

.entry-success-body {
  font-size: 15px;
  color: var(--neutral-600);
  line-height: 1.7;
  margin-bottom: 24px;
}

.entry-success-steps {
  background: var(--neutral-50);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 20px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.entry-success-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
  color: var(--neutral-700);
  line-height: 1.5;
}

.entry-success-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: var(--brand-primary);
  color: var(--white);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

/* Responsive */
@media (max-width: 900px) {
  .entry-layout {
    flex-direction: column;
  }
  .entry-hero {
    flex: none;
    height: auto;
    position: static;
    padding: 36px 24px;
  }
  .entry-title {
    font-size: 26px;
  }
  .entry-form-wrap {
    padding: 24px 16px;
  }
  .entry-form-card {
    padding: 28px 20px;
  }
}

@media (max-width: 540px) {
  .form-row-2 {
    grid-template-columns: 1fr;
  }
  .form-row-3 {
    grid-template-columns: 1fr 1fr;
  }
  .form-row-3-city {
    grid-column: 1 / -1;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   ADMIN ENTRY APPROVALS (admin-entry-approvals.php)
   ═══════════════════════════════════════════════════════════════════════════ */

/* Admin sidebar dark theme overrides */
.sidebar-admin {
  background: #0a0f1a;
}

.sidebar-logo-name-admin {
  color: var(--brand-cyan);
}

.sidebar-logo-sub-admin {
  color: var(--accent-gold);
}

.sidebar-badge-gold {
  background: var(--accent-gold);
  color: #000;
}

.sidebar-avatar-admin {
  background: linear-gradient(135deg, var(--accent-gold), #F97316);
}

.sidebar-user-role-admin {
  color: var(--accent-gold);
}

/* Admin topbar */
.topbar-admin {
  background: var(--neutral-900);
  border-color: rgba(255,255,255,0.08);
}

.topbar-title-admin {
  color: var(--white);
}

.badge-admin-pending {
  display: inline-block;
  background: var(--accent-gold);
  color: #000;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  letter-spacing: 0.06em;
}

.badge-admin-clear {
  display: inline-block;
  background: var(--success-bg);
  color: var(--success);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  letter-spacing: 0.06em;
}

/* Approval cards list */
.entry-approvals-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.entry-approval-card {
  background: var(--white);
  border: 1px solid var(--neutral-200);
  border-left: 4px solid var(--accent-gold);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.entry-approval-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}

.entry-approval-name {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--neutral-900);
  margin-bottom: 3px;
}

.entry-approval-meta {
  font-size: 13px;
  color: var(--neutral-500);
}

/* Details grid */
.entry-approval-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 18px;
  padding: 14px;
  background: var(--neutral-50);
  border-radius: var(--radius-md);
}

.entry-approval-label {
  font-size: 10px;
  color: var(--neutral-400);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 3px;
}

.entry-approval-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-800);
}

.entry-approval-value a {
  color: var(--brand-primary);
  text-decoration: none;
}

/* Action row */
.entry-approval-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.entry-approval-form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  flex-wrap: wrap;
}

.entry-plan-select-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 240px;
}

.entry-plan-select {
  font-size: 13px;
}

.entry-plan-preview {
  font-size: 12px;
  color: var(--neutral-600);
  background: var(--brand-primary-xlight);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  line-height: 1.6;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(12, 25, 41, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-md {
  max-width: 560px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 0;
  margin-bottom: 16px;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  color: var(--neutral-900);
}

.modal-close {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  color: var(--neutral-500);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  line-height: 1;
}

.modal-close:hover {
  background: var(--neutral-100);
  color: var(--neutral-900);
}

.modal-body {
  padding: 0 24px 24px;
}

.modal-footer-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--neutral-200);
}

/* Responsive approval cards */
@media (max-width: 768px) {
  .entry-approval-details {
    grid-template-columns: 1fr 1fr;
  }
  .entry-approval-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .entry-approval-form {
    flex-direction: column;
    align-items: stretch;
  }
  .entry-plan-select-wrap {
    min-width: 0;
  }
}

@media (max-width: 480px) {
  .entry-approval-details {
    grid-template-columns: 1fr;
  }
}

/* mb-32 utility */
.mb-32 { margin-bottom: 32px; }


/* ═══════════════════════════════════════════════════════════════════════════════
   Pipeline — Library Module CSS
   Append to: /assets/assets-style.css
   ═══════════════════════════════════════════════════════════════════════════════ */


/* ── Parse status indicators ─────────────────────────────────────────────────── */
.parse-status {
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.parse-status--ok      { color: var(--success); }
.parse-status--err     { color: var(--error); }
.parse-status--pending { color: var(--warning); }
.parse-status--na      { color: var(--neutral-400); }


/* ── Document cell (icon + title + meta row) ─────────────────────────────────── */
.doc-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.doc-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.doc-icon-lg {
  font-size: 30px;
  line-height: 1;
  flex-shrink: 0;
}


/* ── Library stats grid (3-col override on library page) ─────────────────────── */
.library-stats-grid {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 900px) {
  .library-stats-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .library-stats-grid { grid-template-columns: 1fr; }
}


/* ── Dropdown action menu ─────────────────────────────────────────────────────── */
.dropdown-wrap {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  background: var(--white);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  min-width: 180px;
  z-index: 100;
  overflow: hidden;
}

.dropdown-menu.open { display: block; }

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  font-size: 13px;
  color: var(--neutral-700);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
}
.dropdown-item:hover { background: var(--neutral-100); text-decoration: none; color: var(--neutral-900); }
.dropdown-item--danger { color: var(--error); }
.dropdown-item--danger:hover { background: var(--error-bg); color: var(--error); }

.dropdown-divider {
  height: 1px;
  background: var(--neutral-200);
  margin: 4px 0;
}


/* ── Pagination ───────────────────────────────────────────────────────────────── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.pagination-info {
  font-size: 13px;
  color: var(--neutral-500);
}

.pagination-links {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}


/* ── Empty state ──────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 64px 24px;
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.empty-state-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--neutral-700);
  margin-bottom: 8px;
}

.empty-state-sub {
  font-size: 14px;
  color: var(--neutral-500);
  line-height: 1.65;
}

.empty-state-sub a { color: var(--brand-primary); font-weight: 600; }


/* ── Modal (delete confirmation, generic) ────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 25, 41, 0.55);
  backdrop-filter: blur(4px);
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.open { display: flex; }

.modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  width: 460px;
  max-width: 100%;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: ticketSlideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--neutral-200);
}

.modal-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--neutral-900);
}

.modal-body {
  padding: 20px 24px;
  font-size: 14px;
  color: var(--neutral-700);
  line-height: 1.6;
}

.modal-footer {
  padding: 16px 24px 20px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  border-top: 1px solid var(--neutral-200);
}


/* ── Upload layout (two-column) ──────────────────────────────────────────────── */
.upload-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}

@media (max-width: 900px) {
  .upload-layout { grid-template-columns: 1fr; }
}

.upload-form-col {}
.upload-info-col {}


/* ── Source type tabs (inside upload form) ───────────────────────────────────── */
.source-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.source-tab {
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--neutral-600);
  background: var(--white);
  border: 1.5px solid var(--neutral-200);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.source-tab:hover { background: var(--brand-primary-xlight); color: var(--brand-primary); border-color: var(--brand-primary-light); }
.source-tab.active { background: var(--brand-primary); color: var(--white); border-color: var(--brand-primary); font-weight: 600; }


/* ── Upload zone states ──────────────────────────────────────────────────────── */
.upload-zone--selected {
  border-color: var(--success);
  background: var(--success-bg);
}

.upload-zone--drag {
  border-color: var(--brand-primary);
  background: var(--brand-primary-xlight);
  transform: scale(1.01);
}

.upload-zone-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--neutral-700);
  margin-bottom: 4px;
}

.upload-zone-sub {
  font-size: 12px;
  color: var(--neutral-400);
}

.upload-zone-title .text-primary { color: var(--brand-primary); }


/* ── Format list (upload info panel) ────────────────────────────────────────── */
.format-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.format-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--neutral-700);
}


/* ── Category guide (upload info panel) ──────────────────────────────────────── */
.category-guide {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cat-guide-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.cat-guide-desc {
  font-size: 12.5px;
  color: var(--neutral-500);
  line-height: 1.5;
  padding-top: 2px;
}


/* ── Upload steps list ───────────────────────────────────────────────────────── */
.upload-steps {
  padding-left: 18px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.upload-steps li {
  font-size: 13.5px;
  color: var(--neutral-600);
  line-height: 1.5;
}


/* .topbar-left — defined in APP CHROME section above */


/* ── Edit layout (library-edit.php) ──────────────────────────────────────────── */
.edit-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 24px;
  align-items: start;
}

@media (max-width: 900px) {
  .edit-layout {
    grid-template-columns: 1fr;
  }
}

.edit-info-col {}
.edit-text-col {}


/* ── Document meta header (edit page) ────────────────────────────────────────── */
.doc-meta-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
}

.doc-meta-title {
  font-weight: 700;
  color: var(--neutral-900);
  font-size: 14px;
  line-height: 1.4;
}

.doc-meta-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}


/* ── Parsed text area (large, mono) ──────────────────────────────────────────── */
.parsed-text-area {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--neutral-800);
  min-height: 520px;
  resize: vertical;
}


/* ── Original file box ────────────────────────────────────────────────────────── */
.original-file-box {
  padding: 16px;
  background: var(--neutral-50);
  border: 1px dashed var(--neutral-300);
  border-radius: var(--radius-md);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.original-file-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-700);
  word-break: break-word;
}


/* ── Topbar: search form wrapper ────────────────────────────────────────────── */
.topbar-search-form {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
}

/* Input inside .topbar-search (div or button wrapper) */
.topbar-search-input {
  background: none;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--neutral-700);
  flex: 1;
  min-width: 0;
  cursor: text;
}

.topbar-search-input::placeholder { color: var(--neutral-400); }

/* ── form-select-sm (compact) ────────────────────────────────────────────────── */
.form-select-sm {
  padding: 6px 32px 6px 12px;
  font-size: 13px;
  border-color: var(--neutral-200);
  height: auto;
  background-size: 14px 14px;
  background-position: right 10px center;
}


/* ── Responsive: hide info col on mobile for library pages ───────────────────── */
@media (max-width: 640px) {
  .upload-info-col,
  .edit-info-col {
    order: -1;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   PROPOSALS MODULE — proposals-index.php & proposals-view.php
   ═══════════════════════════════════════════════════════════════════════ */

/* ── Filter bar (proposals-index.php) ─────────────────────────────────────── */
.proposals-filter-bar {}

.proposals-filter-form {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.proposals-filter-select {
  width: auto;
  min-width: 160px;
}

/* ── Table cell helpers (proposals-index.php) ─────────────────────────────── */
.proposals-lead-cell {
  font-size: 12px;
  color: var(--neutral-600);
}
.proposals-lead-agency {
  font-weight: 600;
}
.proposals-lead-ref {
  font-family: var(--font-mono);
  color: var(--neutral-500);
}
.proposals-generated-by {
  font-size: 13px;
  color: var(--neutral-800);
}
.proposals-cost {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--neutral-700);
}
.proposals-date {
  font-size: 12px;
  color: var(--neutral-400);
  white-space: nowrap;
}
.proposals-count-note {
  margin-top: 12px;
  font-size: 12px;
  color: var(--neutral-400);
  font-family: var(--font-mono);
}

/* ── Kimi tag variant ─────────────────────────────────────────────────────── */
.tag-kimi {
  background: rgba(0,194,224,0.10);
  color: var(--brand-cyan);
}

/* ── Empty state (proposals-index.php) ───────────────────────────────────── */
.proposals-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 72px 24px;
  text-align: center;
}
.proposals-empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}
.proposals-empty-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--neutral-700);
  margin-bottom: 8px;
}
.proposals-empty-sub {
  font-size: 14px;
  color: var(--neutral-400);
  max-width: 400px;
  line-height: 1.6;
}

/* ── Proposal view grid (proposals-view.php) ─────────────────────────────── */
.proposal-view-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 20px;
  align-items: start;
}

@media (max-width: 1024px) {
  .proposal-view-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Left sidebar: meta list ─────────────────────────────────────────────── */
.proposal-view-sidebar {}

.proposal-meta-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.proposal-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.proposal-meta-label {
  font-size: 12px;
  color: var(--neutral-400);
  flex-shrink: 0;
}

.proposal-meta-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-800);
  text-align: right;
}

.proposal-meta-link {
  color: var(--brand-primary);
  text-decoration: none;
}
.proposal-meta-link:hover {
  text-decoration: underline;
}

.proposal-meta-cost {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--neutral-800);
}

/* ── Version history list ────────────────────────────────────────────────── */
.proposal-version-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.proposal-version-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--neutral-50);
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
}

.proposal-version-row.proposal-version-current {
  background: var(--brand-primary-xlight);
  border-color: var(--brand-primary);
}

.proposal-version-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.proposal-version-date {
  font-size: 12px;
  color: var(--neutral-500);
}

.proposal-version-viewing {
  font-size: 12px;
  color: var(--brand-primary);
  font-weight: 600;
}

/* ── Download buttons list ───────────────────────────────────────────────── */
.proposal-download-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

/* ── Proposal preview card ───────────────────────────────────────────────── */
.proposal-preview-card {
  height: fit-content;
}

.proposal-preview-body {
  font-family: var(--font-body);
  font-size: 13.5px;
  color: var(--neutral-800);
  line-height: 1.75;
  max-height: 640px;
  overflow-y: auto;
}

/* Headings inside the rendered proposal body */
.proposal-preview-body strong {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--brand-primary);
  display: block;
  margin-top: 20px;
  margin-bottom: 8px;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   Pipeline — Billing Module CSS Additions
   Append to: /assets/assets-style.css
   ═══════════════════════════════════════════════════════════════════════════════ */


/* ── Wallet balance card ─────────────────────────────────────────────────────── */
/* Note: .wallet-balance base styles already exist in assets-style.css          */

.wallet-balance-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 6px;
}

.wallet-balance-amount {
  font-family: var(--font-display);
  font-size: 44px;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
  margin-bottom: 6px;
}

.wallet-balance-meta {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 12px;
}

.wallet-balance-est {
  font-family: var(--font-mono);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
}

.wallet-low-alert {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  background: rgba(245, 166, 35, 0.2);
  border: 1px solid rgba(245, 166, 35, 0.4);
  color: var(--accent-gold);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-full);
}


/* ── Transaction table amounts ───────────────────────────────────────────────── */
.txn-credit {
  color: var(--success);
  font-weight: 700;
  font-family: var(--font-mono);
}

.txn-debit {
  color: var(--error);
  font-weight: 700;
  font-family: var(--font-mono);
}

.font-mono {
  font-family: var(--font-mono);
}


/* ── Section header (title + inline action) ──────────────────────────────────── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.section-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--neutral-800);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}


/* ── Billing top-up preview card ────────────────────────────────────────────── */
.billing-topup-preview {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.billing-pricing-note {
  font-size: 13px;
  color: var(--neutral-500);
  margin-bottom: 16px;
  line-height: 1.5;
}

.billing-preset-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}


/* ── Gateway selection ───────────────────────────────────────────────────────── */
.billing-gateway-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.billing-gateway-option {
  flex: 1;
  min-width: 180px;
  cursor: pointer;
  border: 2px solid var(--neutral-200);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  transition: all 0.2s;
  background: var(--white);
  display: block;
}

.billing-gateway-option:hover {
  border-color: var(--brand-primary-light);
  background: var(--brand-primary-xlight);
}

.billing-gateway-option.selected {
  border-color: var(--brand-primary);
  background: var(--brand-primary-xlight);
  box-shadow: 0 0 0 3px rgba(26, 91, 183, 0.10);
}

/* Hide the native radio */
.billing-gateway-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.billing-gateway-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}

.billing-gateway-icon {
  font-size: 22px;
  flex-shrink: 0;
  width: 36px;
  text-align: center;
}

.billing-gateway-name {
  font-weight: 700;
  font-size: 14px;
  color: var(--neutral-900);
}

.billing-gateway-sub {
  font-size: 12px;
  color: var(--neutral-500);
  margin-top: 2px;
}


/* ── Top-up summary line ─────────────────────────────────────────────────────── */
.billing-summary-line {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--brand-primary-xlight);
  border: 1px solid var(--brand-primary-light);
  border-radius: var(--radius-md);
  padding: 10px 16px;
  font-size: 14px;
  color: var(--brand-primary-dark);
  margin-top: 8px;
  flex-wrap: wrap;
}

.billing-summary-line strong {
  font-weight: 700;
  color: var(--brand-primary);
}


/* ── Pricing table (info panel) ──────────────────────────────────────────────── */
.billing-pricing-table {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.billing-pricing-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.billing-pricing-icon {
  width: 32px;
  height: 32px;
  background: var(--brand-primary-xlight);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  color: var(--brand-primary);
}

.billing-pricing-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-700);
}

.billing-pricing-value {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--brand-primary);
  margin-top: 1px;
}


/* ── Responsive ──────────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .wallet-balance-amount {
    font-size: 32px;
  }
  .billing-gateway-row {
    flex-direction: column;
  }
  .billing-gateway-option {
    min-width: unset;
  }
}

/* ═══════════════════════════════════════════════════════════════════════════
   ADMIN CSS — Append to /assets/assets-style.css
   Covers: admin sidebar dark theme, admin topbar, admin pages, approval cards,
   config rows, client table helpers, balance modal, toolbar.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Sidebar: Admin dark theme ──────────────────────────────────────────────── */
.sidebar-admin {
  background: #0a0f1a;
}
.sidebar-logo-name-admin {
  color: var(--brand-cyan);
}
.sidebar-logo-sub-admin {
  color: var(--accent-gold);
}
.sidebar-label-admin {
  color: var(--accent-gold);
  opacity: 0.8;
}
.sidebar-badge-gold {
  background: var(--accent-gold);
  color: #000;
  font-size: 10px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: var(--radius-full);
  margin-left: auto;
}
.sidebar-avatar-admin {
  background: linear-gradient(135deg, var(--accent-gold), #F97316);
}
.sidebar-user-role-admin {
  color: var(--accent-gold);
}
.sidebar-logout {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: var(--neutral-500);
  text-decoration: none;
  padding: 6px 0;
}
.sidebar-logout:hover {
  color: var(--error);
  text-decoration: none;
}

/* ── Admin topbar ───────────────────────────────────────────────────────────── */
.topbar-admin {
  background: var(--neutral-900);
  border-bottom-color: rgba(255,255,255,0.08);
}
.topbar-title-admin {
  color: var(--white);
}
.badge-admin-panel {
  display: inline-block;
  background: var(--accent-gold);
  color: #000;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  letter-spacing: 0.06em;
}
.badge-admin-pending {
  display: inline-block;
  background: var(--accent-gold);
  color: #000;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  letter-spacing: 0.06em;
}
.badge-admin-clear {
  display: inline-block;
  background: var(--success-bg);
  color: var(--success);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  letter-spacing: 0.06em;
}

/* ── Stat card value variants ───────────────────────────────────────────────── */
.stat-value-gold { color: var(--accent-gold); }
.stat-value-lg   { font-size: 26px; }

/* ── Config pricing rows ────────────────────────────────────────────────────── */
.config-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
}
.config-price-row-blue    { background: var(--brand-primary-xlight); }
.config-price-row-cyan    { background: var(--brand-cyan-xlight); }
.config-price-row-neutral { background: var(--neutral-100); }
.config-price-label {
  font-weight: 700;
  font-size: 13px;
  color: var(--neutral-800);
}
.config-price-sub {
  font-size: 11px;
  color: var(--neutral-500);
  margin-top: 2px;
}
.config-price-input-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.config-price-symbol {
  font-weight: 600;
  color: var(--neutral-500);
  font-size: 14px;
}
.config-price-input {
  width: 110px;
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 800;
  text-align: center;
}
.config-provider-select { width: 160px; }

/* ── Config environment summary ─────────────────────────────────────────────── */
.config-env-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--neutral-100);
  font-size: 13px;
}
.config-env-row:last-child { border-bottom: none; }
.config-env-label {
  width: 130px;
  flex-shrink: 0;
  color: var(--neutral-500);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.config-env-value { color: var(--neutral-800); font-size: 13px; }

/* ── Section divider inside card ────────────────────────────────────────────── */
.section-divider {
  font-size: 11px;
  font-weight: 700;
  color: var(--neutral-400);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-bottom: 1px solid var(--neutral-200);
  padding-bottom: 8px;
}

/* ── Entry Approvals ────────────────────────────────────────────────────────── */
.entry-approvals-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.entry-approval-card {
  background: var(--white);
  border: 1px solid var(--neutral-200);
  border-left: 4px solid var(--neutral-300);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.entry-approval-card-faded { opacity: 0.65; }
.entry-approval-card-border-gold    { border-left-color: var(--accent-gold); }
.entry-approval-card-border-success { border-left-color: var(--success); }
.entry-approval-card-border-neutral { border-left-color: var(--neutral-300); }

.entry-approval-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}
.entry-approval-name {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--neutral-900);
}
.entry-approval-meta {
  font-size: 13px;
  color: var(--neutral-500);
  margin-top: 2px;
}
.entry-approval-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 14px;
  background: var(--neutral-50);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
}
.entry-approval-field-label {
  font-size: 11px;
  color: var(--neutral-400);
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 3px;
  letter-spacing: 0.04em;
}
.entry-approval-field-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-800);
}
.entry-approval-reviewed {
  font-size: 12px;
  color: var(--neutral-400);
  margin-bottom: 12px;
}
.entry-approval-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.entry-approval-plan-select {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: 4px;
}
.entry-approval-plan-select .form-label {
  white-space: nowrap;
  margin-bottom: 0;
  font-size: 12px;
}

/* ── Client table helpers ────────────────────────────────────────────────────── */
.td-warning  { color: var(--warning); }
.td-small    { font-size: 12px; color: var(--neutral-600); }
.td-muted    { color: var(--neutral-400); }
.td-bold     { font-weight: 700; }
.action-btns { display: flex; gap: 6px; align-items: center; }
.inline-form { display: inline; }

/* ── Balance modal ───────────────────────────────────────────────────────────── */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(12,25,41,0.7);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 480px;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--neutral-200);
}
.modal-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--neutral-900);
}
.modal-close {
  background: none;
  border: none;
  font-size: 16px;
  color: var(--neutral-400);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  line-height: 1;
}
.modal-close:hover { background: var(--neutral-100); color: var(--neutral-800); }
.modal-body { padding: 20px 24px 24px; }
.modal-footer-btns { display: flex; gap: 10px; justify-content: flex-end; }
.form-static-value {
  font-weight: 700;
  font-size: 14px;
  color: var(--neutral-800);
  padding: 8px 12px;
  background: var(--neutral-100);
  border-radius: var(--radius-sm);
}

/* ── Input with $ prefix ─────────────────────────────────────────────────────── 
.input-prefix-wrap { position: relative; display: flex; align-items: center; }
.input-prefix {
  position: absolute;
  left: 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--neutral-500);
  pointer-events: none;
}
.input-with-prefix { padding-left: 36px; }
*/


/* ── Mono input ──────────────────────────────────────────────────────────────── */
.form-input-mono {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.02em;
}

/* ── Toolbar (filter bar on clients page) ───────────────────────────────────── */
.toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.toolbar-search  { flex: 1; min-width: 200px; }
.toolbar-filters { display: flex; gap: 4px; flex-wrap: wrap; }
.toolbar-count   { font-size: 12px; color: var(--neutral-500); white-space: nowrap; margin-left: auto; }
.filter-btn-active {
  background: var(--brand-primary-xlight);
  color: var(--brand-primary);
  border-color: var(--brand-primary-light);
}

/* ── Responsive ──────────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .entry-approval-grid       { grid-template-columns: repeat(2, 1fr); }
  .config-price-row          { flex-direction: column; align-items: flex-start; gap: 8px; }
  .config-price-input-wrap   { align-self: flex-end; }
}
@media (max-width: 600px) {
  .entry-approval-grid       { grid-template-columns: 1fr 1fr; }
  .entry-approval-actions    { flex-direction: column; align-items: flex-start; }
  .toolbar                   { flex-direction: column; align-items: stretch; }
  .toolbar-count             { margin-left: 0; }
}

/* ── Super Admin link in normal sidebar ─────────────────────────────────────
   Append to /assets/assets-style.css
   ─────────────────────────────────────────────────────────────────────────── */

.sidebar-item-superadmin {
  color: var(--accent-gold);
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 4px;
  padding-top: 12px;
}
.sidebar-item-superadmin:hover {
  background: rgba(245,166,35,0.10);
  color: var(--accent-gold);
}

.sidebar-item-ticket {
  color: var(--neutral-300);
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 4px;
  padding-top: 12px;
}
.sidebar-item-ticket:hover {
  background: rgba(255,255,255,0.06);
  color: var(--white);
}


/* -- entry.php: Industry Multi-Select widget --------------------------------
   Replaces inline styles on the NAICS checkbox widget in entry.php.
   Page-level layout (.pg-wrap .pg-card .pg-brand etc.) stays in entry.php
   <style> block intentionally -- those classes are page-specific, not shared.
   -------------------------------------------------------------------------- */

.entry-city-col { grid-column: 1 / 2; }
.alert-sm { font-size: 12px; }

.industry-count-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--brand-primary);
  margin-left: 6px;
}
.industry-count-badge.hidden { display: none; }

.industry-multiselect {
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-md);
  background: var(--white);
  max-height: 220px;
  overflow-y: auto;
  padding: 6px 0;
}

.industry-sector-header {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--neutral-400);
  padding: 8px 12px 4px;
  background: var(--neutral-50);
  border-top: 1px solid var(--neutral-100);
  position: sticky;
  top: 0;
  z-index: 1;
}

.industry-option {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 6px 12px;
  cursor: pointer;
}
.industry-option:hover { background: var(--neutral-50); }

.industry-checkbox {
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--brand-primary);
  width: 15px;
  height: 15px;
  cursor: pointer;
}

.industry-name {
  font-size: 13.5px;
  color: var(--neutral-800);
  line-height: 1.4;
}

.industry-naics-code {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neutral-400);
  margin-left: 4px;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   AI Spend Tracker — admin-ai-spend.php + billing-index.php AI Usage
   APPEND to /assets/assets-style.css
   ═══════════════════════════════════════════════════════════════════════════════ */

/* ── Summary Cards Row ─────────────────────────────────────────────────────── */
.ai-spend-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.ai-spend-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  border-left: 4px solid var(--neutral-300);
  box-shadow: var(--shadow-sm);
}
.ai-spend-card-blue { border-left-color: var(--brand-primary); }
.ai-spend-card-cyan { border-left-color: var(--brand-cyan); }
.ai-spend-card-gold { border-left-color: var(--accent-gold); }

.ai-spend-card-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--neutral-400);
  margin-bottom: 6px;
}
.ai-spend-card-value {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--neutral-900);
  margin-bottom: 4px;
}
.ai-spend-card-sub {
  font-size: 12px;
  color: var(--neutral-500);
}

/* ── Tabs ──────────────────────────────────────────────────────────────────── */
.ai-spend-tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--neutral-200);
}
.ai-spend-tab {
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--neutral-500);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color 0.2s, border-color 0.2s;
}
.ai-spend-tab:hover {
  color: var(--neutral-800);
  text-decoration: none;
}
.ai-spend-tab-active {
  color: var(--brand-primary);
  border-bottom-color: var(--brand-primary);
}

/* ── Filter Row ───────────────────────────────────────────────────────────── */
.ai-spend-filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.ai-spend-filters .form-input {
  max-width: 220px;
}
.ai-spend-date {
  max-width: 160px !important;
}

/* ── Table tweaks ─────────────────────────────────────────────────────────── */
.td-truncate {
  max-width: 280px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mono-sm {
  font-family: var(--font-mono);
  font-size: 12px;
}
.mt-32 { margin-top: 32px; }

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .ai-spend-cards {
    grid-template-columns: 1fr;
  }
  .ai-spend-filters {
    flex-direction: column;
    align-items: stretch;
  }
  .ai-spend-filters .form-input {
    max-width: 100%;
  }
  .ai-spend-date {
    max-width: 100% !important;
  }
}
