/* Global Custom Properties & Design Tokens */
:root {
  --font-heading: 'Outfit', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;

  /* Premium Color Palette (Obsidian Slate, Forest Emerald, Metallic Gold) */
  --bg-main: #070913;
  --bg-gradient: radial-gradient(circle at 50% 0%, #0F162A 0%, #070913 75%);
  --bg-card: rgba(17, 24, 43, 0.55);
  --bg-card-hover: rgba(22, 34, 61, 0.7);
  --bg-input: rgba(10, 15, 28, 0.75);
  
  --primary: #10B981;
  --primary-hover: #059669;
  --primary-glow: rgba(16, 185, 129, 0.15);
  
  --accent: #F59E0B;
  --accent-hover: #D97706;
  --accent-glow: rgba(245, 158, 11, 0.15);

  --success: #10B981;
  --danger: #EF4444;
  --info: #3B82F6;
  
  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  
  --border: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(16, 185, 129, 0.5);
  --border-hover: rgba(255, 255, 255, 0.15);
  
  --border-radius-sm: 8px;
  --border-radius-md: 12px;
  --border-radius-lg: 20px;
  
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-lg: 0 20px 40px -15px rgba(0, 0, 0, 0.7);
  
  --sidebar-width: 280px;
}

/* Reset and Base Styles */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg-main);
  background-image: var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: rgba(7, 9, 19, 0.8);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 5px;
  border: 2px solid var(--bg-main);
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(16, 185, 129, 0.4);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

strong {
  font-weight: 600;
  color: var(--text-primary);
}

/* Visually Hidden Helper (Accessbility) */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* General Layout Components */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-lg);
  transition: var(--transition-normal);
}

.glass-card:hover {
  border-color: var(--border-hover);
}

/* Button UI */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--border-radius-md);
  border: none;
  cursor: pointer;
  transition: var(--transition-normal);
  white-space: nowrap;
  min-height: 48px;
}

.btn-sm {
  padding: 0.4rem 1rem;
  font-size: 0.85rem;
  min-height: 36px;
  border-radius: var(--border-radius-sm);
}

.btn-block {
  display: flex;
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
  color: #052E16;
  box-shadow: 0 4px 14px 0 var(--primary-glow);
}

.btn-primary:hover, .btn-primary:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px 0 rgba(16, 185, 129, 0.35);
  outline: none;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover, .btn-secondary:focus-visible {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--border-hover);
  outline: none;
}

.btn-success {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #042f1a;
  box-shadow: 0 4px 14px 0 var(--primary-glow);
}

.btn-success:hover, .btn-success:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px 0 rgba(16, 185, 129, 0.35);
  outline: none;
}

/* Badge System */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 50px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary);
  border: 1px solid rgba(16, 185, 129, 0.25);
  margin-bottom: 1rem;
}

.badge-tier {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: 4px;
}

.badge-tier-1 {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge-tier-2 {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-secondary);
  border: 1px solid rgba(148, 163, 184, 0.25);
}

/* Header & Main Nav */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 9, 19, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 1rem 2rem;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--primary);
}

.logo-text {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--text-primary);
}

.logo-text .highlight {
  color: var(--primary);
}

.main-nav {
  display: flex;
  gap: 0.75rem;
}

.nav-link {
  background: transparent;
  color: var(--text-secondary);
  border: none;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.nav-link.active {
  color: var(--text-primary);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

/* View Switching (Routing) */
.view-section {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.view-section.active-view {
  display: block;
  opacity: 1;
}

/* VIEW 1: LANDING PAGE SPECIFIC */
.hero-section {
  position: relative;
  text-align: center;
  padding: 5rem 2rem 3rem;
  max-width: 1000px;
  margin: 0 auto;
}

.hero-bg-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 400px;
  height: 400px;
  background: var(--primary);
  filter: blur(140px);
  opacity: 0.06;
  z-index: -1;
  pointer-events: none;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, #FFFFFF 30%, #94A3B8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 750px;
  margin: 0 auto 2.5rem;
}

.stats-ribbon {
  display: flex;
  justify-content: center;
  gap: 4rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 2rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-num {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--primary);
}

.stat-lbl {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
}

/* Landing Page Form Container */
.form-section {
  max-width: 750px;
  margin: 0 auto 6rem;
  padding: 0 1.5rem;
}

.form-card {
  padding: 3rem;
  position: relative;
  overflow: hidden;
}

.form-header {
  margin-bottom: 2.5rem;
  text-align: center;
}

.form-header h2 {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
}

.form-header p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* Form Multi-step Progress Bar */
.form-steps-indicator {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
  padding: 0 1rem;
}

.step-indicator-item {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: var(--transition-fast);
}

.step-indicator-item.active {
  color: var(--primary);
}

.step-indicator-item.completed {
  color: var(--text-secondary);
}

.step-indicator-line {
  flex-grow: 1;
  height: 2px;
  background: rgba(255, 255, 255, 0.05);
  margin: 0 1.5rem;
  position: relative;
}

.step-indicator-line.completed::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  background: var(--primary);
}

/* Form Steps Panels Styling */
.form-step-panel {
  border: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  animation: fadeIn 0.4s ease;
}

.form-step-panel.hidden {
  display: none !important;
}

/* Form Controls Styling */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

label {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-primary);
}

.group-label {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.field-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-top: -0.25rem;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text-primary);
  padding: 0.75rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border-radius: var(--border-radius-md);
  transition: var(--transition-fast);
  min-height: 48px;
  width: 100%;
  outline: none;
}

input[type="text"]:hover,
input[type="email"]:hover,
input[type="tel"]:hover,
input[type="number"]:hover,
select:hover,
textarea:hover {
  border-color: var(--border-hover);
}

input[type="text"]:focus-visible,
input[type="email"]:focus-visible,
input[type="tel"]:focus-visible,
input[type="number"]:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

/* Custom Select appearance */
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394A3B8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1.25rem;
  padding-right: 2.5rem;
}

/* Custom Checkbox Grid styling */
.checkbox-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.checkbox-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
}

.checkbox-item input[type="checkbox"] {
  width: 1.2rem;
  height: 1.2rem;
  border: 2px solid var(--text-muted);
  border-radius: 4px;
  appearance: none;
  cursor: pointer;
  transition: var(--transition-fast);
  position: relative;
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.checkbox-item input[type="checkbox"]:checked {
  background: var(--primary);
  border-color: var(--primary);
}

.checkbox-item input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 0.35rem;
  top: 0.125rem;
  width: 0.3rem;
  height: 0.55rem;
  border: solid #052E16;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-item label {
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.4;
  cursor: pointer;
  user-select: none;
}

.checkbox-item input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--primary);
}

.terms-checkbox {
  align-items: flex-start;
}

/* Custom Range Slider styling */
.range-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.range-val {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary);
}

input[type="range"] {
  appearance: none;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  outline: none;
  margin: 1rem 0;
}

input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
  cursor: pointer;
  transition: transform 0.1s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.range-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Drag-Drop Zone for POF */
.drag-drop-zone {
  border: 2px dashed rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--border-radius-md);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition-normal);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.drag-drop-zone.dragover {
  border-color: var(--primary);
  background: rgba(16, 185, 129, 0.05);
}

.dropzone-icon {
  color: var(--text-muted);
  transition: var(--transition-fast);
}

.drag-drop-zone:hover .dropzone-icon {
  color: var(--primary);
  transform: translateY(-2px);
}

.browse-link {
  color: var(--primary);
  font-weight: 600;
  text-decoration: underline;
}

.file-spec {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.file-details {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.5rem;
  animation: scaleUp 0.2s ease;
}

.file-name {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.btn-remove-file {
  background: transparent;
  color: var(--danger);
  border: none;
  font-size: 1.2rem;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
}

/* Validation Error Messages */
.error-msg {
  font-size: 0.75rem;
  color: var(--danger);
  min-height: 18px;
  margin-top: 0.1rem;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* Loading Spinner */
.loading-spinner {
  animation: spin 1s linear infinite;
  display: inline-block;
}

/* Form Success Overlay */
.form-success-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #0a0e1a;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  z-index: 10;
  animation: fadeIn 0.4s ease;
}

.success-content {
  text-align: center;
  max-width: 500px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.success-icon-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.1);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
}

.success-content h3 {
  font-size: 2rem;
  font-family: var(--font-heading);
}

.success-content p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.success-summary-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  padding: 1.25rem 2rem;
  border-radius: var(--border-radius-md);
  width: 100%;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.success-summary-box p {
  display: flex;
  justify-content: space-between;
}

.notice {
  font-size: 0.8rem !important;
  color: var(--text-muted) !important;
}

/* VIEW 2: WHOLESALER PORTAL SPECIFIC */
.portal-grid {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  min-height: calc(100vh - 73px);
  max-width: 1500px;
  margin: 0 auto;
  padding: 2rem;
  gap: 2rem;
}

/* Sidebar Layout */
.portal-sidebar {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  height: fit-content;
  position: sticky;
  top: 93px;
}

.portal-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
  color: #052E16;
  font-family: var(--font-heading);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-name {
  font-size: 0.95rem;
  font-weight: 600;
}

.user-role {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sidebar-tab-btn {
  background: transparent;
  color: var(--text-secondary);
  border: none;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius-md);
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: var(--transition-fast);
}

.sidebar-tab-btn:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

.sidebar-tab-btn.active {
  background: rgba(16, 185, 129, 0.1);
  color: var(--primary);
  font-weight: 600;
}

/* Portal Tabs content manager */
.portal-content {
  min-width: 0; /* Prevents flex children from breaking layouts */
}

.portal-tab-content {
  display: none;
  animation: fadeIn 0.4s ease;
}

.portal-tab-content.active-tab {
  display: block;
}

.tab-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.tab-kicker {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--primary);
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 0.25rem;
}

.tab-header h2 {
  font-size: 2rem;
}

/* TAB 1: 30-DAY CHECKLIST */
.progress-container {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 250px;
}

.progress-percentage {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: right;
}

.progress-bar-outer {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar-inner {
  height: 100%;
  background: var(--primary);
  border-radius: 4px;
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}

.roadmap-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.week-card {
  padding: 2rem;
}

.week-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

.week-header h3 {
  font-size: 1.15rem;
}

.week-status-badge {
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  color: var(--text-secondary);
}

.week-status-badge.complete {
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary);
}

.task-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.task-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.task-row input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.25rem;
  flex-shrink: 0;
  cursor: pointer;
  accent-color: var(--primary);
}

.task-row label {
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.5;
  cursor: pointer;
}

.task-row input[type="checkbox"]:checked + label {
  text-decoration: line-through;
  color: var(--text-muted);
}

/* TAB 2: PERSONAS */
.personas-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.persona-card {
  padding: 2rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.persona-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--primary);
  transform: translateY(-2px);
}

.persona-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.p-icon {
  font-size: 1.5rem;
}

.persona-card h3 {
  font-size: 1.25rem;
}

.persona-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  flex-grow: 1;
}

.persona-meta {
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.local-notices {
  padding: 2rem;
}

.local-notices h3 {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.notice-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.notice-box {
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--border-radius-md);
  padding: 1.5rem;
  border-left: 4px solid var(--border);
}

.notice-title {
  display: block;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}

.ULA-title {
  color: var(--accent);
  border-color: var(--accent);
}

.SB9-title {
  color: var(--primary);
  border-color: var(--primary);
}

.notice-box p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* TAB 3: OUTREACH SCRIPTS */
.script-tool-grid {
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 2rem;
}

.script-controls {
  padding: 2rem;
  height: fit-content;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.script-display-container {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: relative;
  min-height: 400px;
}

.script-display-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.script-display-header span {
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.script-body {
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text-primary);
  white-space: pre-line;
  overflow-y: auto;
  max-height: 400px;
}

.script-body em {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent);
  padding: 0 0.25rem;
  font-style: normal;
  border-radius: 3px;
  font-weight: 600;
}

.copy-success-badge {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  background: var(--primary);
  color: #052E16;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
  animation: slideUp 0.3s ease;
}

/* TAB 4: CRM DATABASE */
.crm-controls-row {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.search-box {
  flex-grow: 1;
  min-width: 300px;
}

.filters-box {
  display: flex;
  gap: 1rem;
}

.filters-box select {
  min-width: 160px;
}

.crm-table-container {
  overflow-x: auto;
  border-radius: var(--border-radius-md);
}

.crm-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.crm-table th {
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-secondary);
  font-weight: 600;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
  transition: var(--transition-fast);
}

.crm-table th:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.sort-indicator {
  font-size: 0.75rem;
  margin-left: 0.25rem;
  color: var(--text-muted);
}

.crm-table td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
  vertical-align: middle;
}

.crm-table tr:hover td {
  background: rgba(255, 255, 255, 0.01);
}

.buyer-meta-info {
  display: flex;
  flex-direction: column;
}

.buyer-email-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.buyer-markets-cell {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.market-badge {
  font-size: 0.7rem;
  background: rgba(59, 130, 246, 0.1);
  color: #60A5FA;
  border: 1px solid rgba(59, 130, 246, 0.2);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
}

.strategy-badge {
  font-size: 0.7rem;
  background: rgba(16, 185, 129, 0.1);
  color: var(--primary);
  border: 1px solid rgba(16, 185, 129, 0.2);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  margin-right: 0.25rem;
  margin-bottom: 0.25rem;
  display: inline-block;
}

.btn-icon {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  color: var(--text-secondary);
  border-radius: 4px;
  transition: var(--transition-fast);
}

.btn-icon:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--danger);
}

/* TAB 5: DEAL MATCHER */
.matcher-grid {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 2rem;
}

.deal-input-panel {
  padding: 2rem;
  height: fit-content;
}

.deal-input-panel h3 {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
}

.deal-input-panel form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.matches-results-panel {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  min-height: 400px;
}

.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.results-header h3 {
  font-size: 1.25rem;
}

.matches-count {
  font-size: 0.85rem;
  background: rgba(16, 185, 129, 0.15);
  color: var(--primary);
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-weight: 600;
}

.matches-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-y: auto;
  max-height: 450px;
}

.match-item-card {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--border-radius-md);
  padding: 1.25rem;
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 1.5rem;
  align-items: center;
  transition: var(--transition-normal);
}

.match-item-card:hover {
  border-color: var(--primary);
  background: rgba(255, 255, 255, 0.04);
}

.match-score-circle {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 4px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  background: rgba(0, 0, 0, 0.2);
}

.match-score-num {
  font-size: 1.2rem;
  font-weight: 800;
}

.match-score-lbl {
  font-size: 0.6rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.match-score-circle.high-match {
  border-color: var(--primary);
  color: var(--primary);
}

.match-score-circle.mid-match {
  border-color: var(--accent);
  color: var(--accent);
}

.match-details h4 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.match-details p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.match-reasons {
  margin-top: 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.empty-state-matcher {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  padding: 4rem 2rem;
}

/* MODALS LAYOUT */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(3, 5, 12, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  animation: fadeIn 0.3s ease;
  opacity: 1;
}

.modal-overlay.hidden {
  display: none !important;
}

.modal-content {
  width: 100%;
  max-width: 600px;
  padding: 2.5rem;
  position: relative;
  animation: scaleUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-height: 90vh;
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  background: transparent;
  border: none;
  font-size: 2rem;
  color: var(--text-secondary);
  cursor: pointer;
  line-height: 1;
  transition: var(--transition-fast);
}

.modal-close:hover {
  color: var(--text-primary);
}

/* Add Buyer Modal Specs */
#add-buyer-modal h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.75rem;
}

#add-buyer-modal form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Persona Detail Modal styling */
.persona-detail-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.persona-detail-header h3 {
  font-size: 1.6rem;
}

.persona-detail-icon {
  font-size: 2.5rem;
}

.detail-specs-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.detail-spec-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
}

.detail-spec-label {
  font-weight: 600;
  color: var(--text-secondary);
}

.detail-spec-val {
  color: var(--text-primary);
}

.detail-sb9-opportunity {
  margin-top: 1.5rem;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--border-radius-md);
  padding: 1.25rem;
}

.detail-sb9-opportunity h4 {
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.detail-sb9-opportunity p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* SMS Alert Notification Sandbox Preview */
#alert-modal-body {
  margin-top: 1rem;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border);
  padding: 1.5rem;
  border-radius: var(--border-radius-md);
  font-family: var(--font-body);
  line-height: 1.5;
}

.sms-sim-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.sms-bubble {
  background: #1E293B;
  color: var(--text-primary);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  max-width: 85%;
  font-size: 0.9rem;
  line-height: 1.4;
  align-self: flex-start;
  position: relative;
}

.sms-bubble::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: -5px;
  width: 10px;
  height: 10px;
  background: #1E293B;
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
}

.sms-meta {
  font-size: 0.7rem;
  color: var(--text-muted);
  align-self: flex-start;
  margin-left: 0.25rem;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scaleUp {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

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

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Responsive Breakpoints */
@media (max-width: 1100px) {
  .portal-grid {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
  .portal-sidebar {
    position: static;
    width: 100%;
  }
  .sidebar-nav {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .sidebar-tab-btn {
    flex: 1 1 200px;
  }
  .roadmap-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.2rem;
  }
  .stats-ribbon {
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
  }
  .form-card {
    padding: 1.5rem;
  }
  .checkbox-grid {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .personas-grid {
    grid-template-columns: 1fr;
  }
  .notice-columns {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .script-tool-grid {
    grid-template-columns: 1fr;
  }
  .crm-controls-row {
    flex-direction: column;
    align-items: stretch;
  }
  .filters-box {
    flex-direction: column;
  }
  .matcher-grid {
    grid-template-columns: 1fr;
  }
  .match-item-card {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    gap: 1rem;
  }
  .match-item-card button {
    width: 100%;
  }
}
