/* ============================================
   Le Projet — Duna-inspired dark minimal design
   ============================================ */

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

:root {
  --bg: #0a0a0a;
  --bg-elevated: #111111;
  --bg-card: #161616;
  --bg-card-hover: #1c1c1c;
  --border: rgba(255,255,255,0.08);
  --border-light: rgba(255,255,255,0.12);
  --text: #ffffff;
  --text-secondary: rgba(255,255,255,0.6);
  --text-tertiary: rgba(255,255,255,0.4);
  --accent: #D4440F;
  --accent-light: #F77F00;
  --accent-glow: rgba(247,127,0,0.3);
  --teal: #FFBA08;
  --teal-glow: rgba(255,186,8,0.2);
  --success: #34d399;
  --error: #f87171;
  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --navbar-bg: rgba(10,10,10,0.85);
  --nav-pill-bg: rgba(30,30,30,0.6);
}

/* ===== LIGHT THEME ===== */
[data-theme="light"] {
  --bg: #f5f5f5;
  --bg-elevated: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f0f0;
  --border: rgba(0,0,0,0.08);
  --border-light: rgba(0,0,0,0.12);
  --text: #1a1a1a;
  --text-secondary: rgba(0,0,0,0.6);
  --text-tertiary: rgba(0,0,0,0.4);
  --accent: #C23A0A;
  --accent-light: #E06B00;
  --accent-glow: rgba(224,107,0,0.2);
  --teal: #D49A00;
  --teal-glow: rgba(212,154,0,0.15);
  --success: #059669;
  --error: #dc2626;
  --navbar-bg: rgba(255,255,255,0.85);
  --nav-pill-bg: rgba(240,240,240,0.7);
}
[data-theme="light"] .hero { color: #fff; }
[data-theme="light"] .hero h1 { color: #fff; }
[data-theme="light"] .hero p.lead { color: rgba(255,255,255,0.8); }
[data-theme="light"] .hero-badge { background: rgba(0,0,0,0.4); color: rgba(255,255,255,0.85); }
[data-theme="light"] .hero-content .btn-primary { color: #fff; }
[data-theme="light"] .hero-content .btn-outline { color: #fff; border-color: rgba(255,255,255,0.3); }
[data-theme="light"] .hero h1 .gradient {
  background: linear-gradient(135deg, #FF8C42 0%, #FFD166 100%);
  -webkit-background-clip: text; background-clip: text;
}
[data-theme="light"] .brand-text {
  background: linear-gradient(135deg, var(--accent-light), var(--teal));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
[data-theme="light"] .form-input { background: var(--bg-elevated); }
[data-theme="light"] .ql-editor { background: var(--bg-elevated); color: var(--text); }
[data-theme="light"] .portal-meeting-content { color: var(--text-secondary); }

/* Theme toggle */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-tertiary);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 0.35rem 0.85rem;
  transition: all var(--transition);
  margin-left: 1rem;
}
.theme-toggle:hover { color: var(--text); border-color: var(--border-light); }
.theme-toggle-icon { font-size: 1rem; }

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main { flex: 1; }

a { color: inherit; text-decoration: none; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 2rem; }

/* ========== NAVBAR (Duna-style) ========== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0.75rem 0;
  background: var(--navbar-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-brand {
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--text);
  letter-spacing: -0.02em;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 200px;
}
.brand-text {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent-light), var(--teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: opacity 0.15s;
  white-space: nowrap;
}
.brand-text::after {
  content: '';
  display: inline-block;
  width: 0;
  height: 0;
  border-right: none;
  transition: none;
}
.brand-text.typing::after {
  content: '';
  display: inline-block;
  width: 2px;
  height: 1.1em;
  background: var(--accent-light);
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: blink-caret 0.6s step-end infinite;
}
@keyframes blink-caret {
  50% { opacity: 0; }
}
.badge-flags {
  font-size: 0.9rem;
  letter-spacing: 0.15em;
  margin-left: 0.25rem;
}

/* Center nav pill */
.nav-center {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  background: var(--nav-pill-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 0.3rem;
}
.nav-link {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 400;
  padding: 0.5rem 1.1rem;
  border-radius: 50px;
  transition: all var(--transition);
  white-space: nowrap;
}
.nav-link:hover {
  color: var(--text);
  background: rgba(255,255,255,0.08);
}

/* Right nav */
.nav-right { flex-shrink: 0; }
.btn-nav {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 1.3rem;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-light);
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: all var(--transition);
}
.btn-nav:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.25);
}
.nav-logout { display: inline; }

/* Dropdown */
.nav-item { position: relative; }
.nav-item .nav-link { cursor: pointer; }
.nav-dropdown {
  position: absolute;
  top: calc(100% + 0.75rem);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  display: flex;
  gap: 0;
  background: rgba(30,30,30,0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  min-width: 480px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.nav-item:hover .nav-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.nav-item:hover .nav-link {
  color: var(--text);
  background: rgba(255,255,255,0.1);
}
.dropdown-col {
  flex: 1;
  padding: 0 0.75rem;
}
.dropdown-col + .dropdown-col {
  border-left: 1px solid var(--border);
}
.dropdown-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.75rem;
}
.dropdown-item {
  display: block;
  padding: 0.5rem 0.5rem;
  border-radius: 8px;
  transition: background var(--transition);
  margin-bottom: 0.25rem;
}
.dropdown-item:hover {
  background: rgba(255,255,255,0.06);
}
.dropdown-item strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.1rem;
}
.dropdown-item span {
  font-size: 0.8rem;
  color: var(--text-tertiary);
}

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.75rem;
  border: 1px solid transparent;
  border-radius: 50px;
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
  font-family: inherit;
  gap: 0.5rem;
}
.btn-primary {
  background: var(--text);
  color: var(--bg);
}
.btn-primary:hover {
  background: rgba(255,255,255,0.85);
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border-light);
}
.btn-outline:hover {
  border-color: var(--text);
  background: rgba(255,255,255,0.05);
}
.btn-accent {
  background: var(--accent);
  color: #fff;
  border: none;
}
.btn-accent:hover {
  background: var(--accent-light);
  box-shadow: 0 0 30px var(--accent-glow);
  transform: translateY(-1px);
}
.btn-block { display: flex; width: 100%; }
.btn-sm { padding: 0.4rem 1rem; font-size: 0.85rem; }
.btn-lg { padding: 1rem 2.5rem; font-size: 1rem; }
.btn-group { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ========== AUTH PAGES ========== */
.auth-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
  background: var(--bg);
}
.auth-card {
  background: var(--bg-elevated);
  padding: 3rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 440px;
}
.auth-card h1 {
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
}
.auth-subtitle {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}
.auth-footer {
  margin-top: 2rem;
  text-align: center;
  color: var(--text-tertiary);
  font-size: 0.9rem;
}
.auth-footer a {
  color: var(--text);
  font-weight: 500;
  border-bottom: 1px solid var(--border-light);
  transition: border-color var(--transition);
}
.auth-footer a:hover { border-color: var(--text); }

/* ========== FORMS ========== */
.form-group { margin-bottom: 1.25rem; }
.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  letter-spacing: 0.01em;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  transition: all var(--transition);
  outline: none;
}
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-tertiary);
}
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Standalone form-input (used in portal) */
.form-input {
  padding: 0.6rem 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.9rem;
  font-family: inherit;
  transition: all var(--transition);
  outline: none;
}
.form-input::placeholder { color: var(--text-tertiary); }
.form-input:focus {
  border-color: var(--accent-light);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.form-input option {
  background: var(--bg-elevated);
  color: var(--text);
}
.form-card {
  background: var(--bg-elevated);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  max-width: 700px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* ========== CHECKBOX ========== */
.checkbox-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-top: 0.75rem;
}
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  transition: all var(--transition);
}
.checkbox-label:hover {
  border-color: var(--border-light);
  background: rgba(255,255,255,0.02);
}
.checkbox-label input[type="checkbox"] {
  width: auto;
  accent-color: var(--accent);
}
fieldset { border: none; }
legend {
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.25rem;
}

/* ========== ALERTS ========== */
.alert {
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius);
  margin: 1rem 0;
  font-size: 0.9rem;
  border: 1px solid;
}
.alert-success {
  background: rgba(52,211,153,0.1);
  color: var(--success);
  border-color: rgba(52,211,153,0.2);
}
.alert-error {
  background: rgba(248,113,113,0.1);
  color: var(--error);
  border-color: rgba(248,113,113,0.2);
}

/* ========== HERO ========== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 8rem 2rem 6rem;
  position: relative;
  overflow: hidden;
  background: var(--bg) url('/images/hero-bg.jpg') center/cover no-repeat;
  margin-top: 0;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10,10,10,0.3) 0%,
    rgba(10,10,10,0.1) 40%,
    rgba(10,10,10,0.5) 80%,
    var(--bg) 100%
  );
  pointer-events: none;
}
.hero-content { position: relative; z-index: 1; max-width: 800px; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(30,30,30,0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}
.hero-badge .dot {
  width: 6px;
  height: 6px;
  background: var(--accent-light);
  border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}
.hero h1 .gradient {
  background: linear-gradient(135deg, var(--accent-light) 0%, var(--teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p.lead {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

/* ========== STATS ========== */
.stats-row {
  display: flex;
  justify-content: center;
  gap: 4rem;
  margin-top: 4rem;
  padding-top: 4rem;
  border-top: 1px solid var(--border);
}
.stat { text-align: center; }
.stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}
.stat-value.gradient {
  background: linear-gradient(135deg, var(--accent-light) 0%, var(--teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat-label {
  font-size: 0.85rem;
  color: var(--text-tertiary);
  margin-top: 0.25rem;
}

/* ========== SECTIONS ========== */
.section {
  padding: 6rem 0;
}
.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 4rem;
}
.section-header h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
}
.section-header p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.7;
}
.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}
.text-center { text-align: center; }

/* ========== FEATURE GRID ========== */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

/* ========== CARDS ========== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.card:hover {
  border-color: var(--border-light);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}
.card-icon {
  font-size: 2rem;
  margin-bottom: 1.25rem;
  display: block;
}
.card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}
.card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* Card with top glow */
.card-glow::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-light), transparent);
}

/* ========== FEATURE SHOWCASE (Duna-style) ========== */
.feature-showcase {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 400px;
}
.feature-tabs {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
}
.feature-tab {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.25rem 1.5rem;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  text-align: left;
  transition: all var(--transition);
  font-family: inherit;
  position: relative;
}
.feature-tab:last-child { border-bottom: none; }
.feature-tab:hover {
  background: rgba(255,255,255,0.03);
  color: var(--text);
}
.feature-tab.active {
  background: rgba(247,127,0,0.06);
  color: var(--text);
}
.feature-tab.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(to bottom, var(--accent-light), var(--teal));
  border-radius: 0 3px 3px 0;
}
.feature-tab-icon { font-size: 1.25rem; flex-shrink: 0; }
.feature-tab-title { font-size: 0.9rem; font-weight: 500; }

.feature-panels { position: relative; padding: 2.5rem; }
.feature-panel {
  display: none;
  animation: fadeInPanel 0.35s ease;
}
.feature-panel.active { display: block; }
@keyframes fadeInPanel {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.feature-panel h3 {
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
  background: linear-gradient(135deg, var(--text) 60%, var(--accent-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.feature-panel > p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 2rem;
  max-width: 500px;
}
.feature-visual {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

/* Timeline inside feature panels */
.feature-timeline { display: flex; flex-direction: column; gap: 0; }
.timeline-item {
  display: grid;
  grid-template-columns: 20px 1fr;
  grid-template-rows: auto auto;
  column-gap: 1rem;
  padding: 0.75rem 0;
  position: relative;
}
.timeline-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 9px;
  top: 28px;
  bottom: -4px;
  width: 2px;
  background: var(--border-light);
}
.tl-dot {
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2px solid var(--border-light);
  background: var(--bg-card);
  grid-row: 1 / 3;
  margin-top: 2px;
}
.tl-dot.active {
  border-color: var(--accent-light);
  background: var(--accent-light);
  box-shadow: 0 0 12px var(--accent-glow);
}
.timeline-item.done .tl-dot {
  border-color: var(--teal);
  background: var(--teal);
}
.timeline-item strong { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.timeline-item span { font-size: 0.8rem; color: var(--text-tertiary); }
.timeline-item.active strong { color: var(--accent-light); }

/* Metrics inside feature panels */
.feature-metrics {
  display: flex;
  gap: 2rem;
  justify-content: space-around;
}
.metric { text-align: center; }
.metric-val {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--accent-light), var(--teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.metric-lbl {
  display: block;
  font-size: 0.8rem;
  color: var(--text-tertiary);
  margin-top: 0.25rem;
}

/* Steps inside feature panels */
.feature-steps {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: all var(--transition);
}
.step:hover {
  border-color: var(--accent-light);
  color: var(--text);
}
.step-num {
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--accent-light);
}

/* Responsive feature showcase */
@media (max-width: 768px) {
  .feature-showcase {
    grid-template-columns: 1fr;
  }
  .feature-tabs {
    flex-direction: row;
    overflow-x: auto;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .feature-tab {
    border-bottom: none;
    border-right: 1px solid var(--border);
    white-space: nowrap;
    padding: 1rem;
  }
  .feature-tab.active::before {
    left: 0; right: 0;
    top: auto; bottom: 0;
    width: auto; height: 3px;
    border-radius: 3px 3px 0 0;
  }
  .feature-metrics { flex-direction: column; gap: 1rem; }
}

/* ========== CTA SECTION ========== */
.cta-section {
  text-align: center;
  padding: 8rem 0;
  position: relative;
}
.cta-section::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--teal-glow) 0%, transparent 70%);
  opacity: 0.3;
  pointer-events: none;
}
.cta-section h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
  position: relative;
}
.cta-section p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 2rem;
  position: relative;
}

/* ========== RESULT CARD ========== */
.result-card {
  background: var(--bg-elevated);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  max-width: 600px;
}
.result-card h2 {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, var(--text) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.result-card ul {
  margin: 1.5rem 0;
  padding-left: 1.25rem;
  color: var(--text-secondary);
}
.result-card li { margin-bottom: 0.4rem; }
.result-card .note {
  color: var(--text-tertiary);
  font-size: 0.85rem;
  margin: 1.5rem 0 1rem;
}

/* ========== ESTIMATE PREVIEW ========== */
.estimate-preview {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 1.25rem;
  border-radius: var(--radius);
  margin-bottom: 1.25rem;
  font-size: 1.1rem;
  text-align: center;
}
.estimate-preview span {
  font-weight: 700;
  font-size: 1.5rem;
  background: linear-gradient(135deg, var(--text) 0%, var(--teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ========== DIVIDER ========== */
.divider {
  width: 100%;
  height: 1px;
  background: var(--border);
}

/* ========== FOOTER ========== */
.footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  color: var(--text-tertiary);
  font-size: 0.85rem;
}
.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-links {
  display: flex;
  gap: 2rem;
}
.footer-links a {
  color: var(--text-tertiary);
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--text-secondary); }

/* ========== SCROLL REVEAL ========== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ========== PAGE HERO (sub-pages) ========== */
.page-hero {
  padding: 10rem 0 4rem;
  text-align: center;
}
.page-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.15;
  margin-bottom: 1rem;
}
.page-hero .lead {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ========== CARD LIST ========== */
.card-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}
.card-list li {
  color: var(--text-secondary);
  font-size: 0.9rem;
  padding: 0.35rem 0;
  padding-left: 1.25rem;
  position: relative;
}
.card-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-light);
}

/* ========== CARD TAG ========== */
.card-tag {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.25rem 0.75rem;
  background: rgba(113,75,103,0.15);
  color: var(--accent-light);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 500;
}

/* ========== TIMELINE ========== */
.timeline {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 28px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--border);
}
.timeline-step {
  display: flex;
  gap: 2rem;
  margin-bottom: 3rem;
  position: relative;
}
.timeline-number {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50%;
  font-weight: 700;
  font-size: 1rem;
  color: var(--accent-light);
  position: relative;
  z-index: 1;
}
.timeline-content h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.timeline-content p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}
.timeline-portail {
  margin-top: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.85rem;
  color: var(--text-secondary);
}
.timeline-portail span {
  color: var(--accent-light);
  font-weight: 600;
}

/* ========== STEPS LIST ========== */
.steps-list {
  max-width: 600px;
  margin: 0 auto;
}
.step-item {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}
.step-num {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50%;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--accent-light);
}
.step-item p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* ========== TESTIMONIALS ========== */
.testimonial {
  border: none;
  margin: 0;
  padding: 0;
}
.testimonial p {
  font-size: 1.1rem;
  font-style: italic;
  color: var(--text-secondary);
  line-height: 1.7;
}
.testimonial p::before { content: '"'; }
.testimonial p::after { content: '"'; }

/* ========== FAQ ========== */
.faq-list {
  max-width: 700px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1rem;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
  transition: color var(--transition);
}
.faq-question:hover { color: var(--accent-light); }
.faq-icon {
  font-size: 1.25rem;
  color: var(--text-tertiary);
  transition: transform var(--transition);
  flex-shrink: 0;
  margin-left: 1rem;
}
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.faq-item.open .faq-answer { max-height: 300px; }
.faq-answer p {
  padding-bottom: 1.25rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ========== CONTACT INFO ========== */
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.contact-info-icon { font-size: 1.5rem; }
.contact-info-item strong {
  display: block;
  margin-bottom: 0.15rem;
}
.contact-info-item p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .container { padding: 0 1.25rem; }
  .form-row { grid-template-columns: 1fr; }
  .checkbox-grid { grid-template-columns: 1fr; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .stats-row { flex-direction: column; gap: 2rem; }
  .hero { padding: 6rem 1.5rem 4rem; }
  .page-hero { padding: 7rem 0 3rem; }
  .section { padding: 4rem 0; }
  .nav-center { display: none; }
  .footer-content { flex-direction: column; gap: 1rem; text-align: center; }
  .auth-card { padding: 2rem; }
  .btn-group { flex-direction: column; }
  .nav-dropdown { min-width: 320px; flex-direction: column; }
  .timeline::before { left: 18px; }
  .timeline-number { width: 40px; height: 40px; font-size: 0.85rem; }
}

/* ============================================
   PORTAL — Project Management Styles
   ============================================ */

/* --- Project cards grid --- */
.portal-projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
}
.portal-project-card {
  display: block;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all var(--transition);
  text-decoration: none;
  color: inherit;
}
.portal-project-card:hover {
  border-color: var(--accent-light);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}
.ppc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}
.ppc-status {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.6rem;
  border-radius: 50px;
}
.ppc-status--prospection { background: rgba(99,102,241,0.15); color: #818cf8; }
.ppc-status--active { background: rgba(247,127,0,0.15); color: var(--accent-light); }
.ppc-status--draft { background: rgba(255,255,255,0.06); color: var(--text-tertiary); }
.ppc-status--completed { background: rgba(52,211,153,0.15); color: var(--success); }
.ppc-status--archived { background: rgba(255,255,255,0.04); color: var(--text-tertiary); }
.ppc-members { font-size: 0.8rem; color: var(--text-tertiary); }
.portal-project-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}
.ppc-desc {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.5;
  margin-bottom: 1.25rem;
}
.ppc-progress { margin-bottom: 0.75rem; }
.ppc-progress-bar {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}
.ppc-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-light), var(--teal));
  border-radius: 3px;
  transition: width 0.6s ease;
}
.ppc-hours {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.35rem;
  display: block;
}
.ppc-dates {
  display: flex;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-tertiary);
}

/* --- Portal overview --- */
.portal-overview {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 2rem;
}
.portal-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  text-align: center;
}
.portal-stat-val {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.portal-stat-lbl {
  display: block;
  font-size: 0.8rem;
  color: var(--text-tertiary);
  margin-top: 0.25rem;
}

/* --- Portal blocks --- */
.portal-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 2rem;
}
.portal-block-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}
.portal-objectives { display: flex; flex-direction: column; gap: 0.5rem; }
.portal-obj-item {
  padding: 0.6rem 1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.9rem;
  color: var(--text-secondary);
  position: relative;
  padding-left: 2rem;
}
.portal-obj-item::before {
  content: '→';
  position: absolute;
  left: 0.75rem;
  color: var(--accent-light);
  font-weight: 600;
}

/* --- Portal tabs --- */
.portal-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
}
.portal-tab {
  padding: 0.85rem 1.5rem;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--text-secondary);
  cursor: pointer;
  position: relative;
  transition: all var(--transition);
}
.portal-tab:hover { color: var(--text); }
.portal-tab.active {
  color: var(--accent-light);
  font-weight: 500;
}
.portal-tab.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-light), var(--teal));
  border-radius: 2px 2px 0 0;
}

/* --- Portal panels --- */
.portal-panel {
  display: none;
  padding: 1.5rem 0;
}
.portal-panel.active { display: block; }

/* --- Portal list items --- */
.portal-list { display: flex; flex-direction: column; gap: 0; }
.portal-list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
  text-decoration: none;
  color: inherit;
}
a.portal-list-item:hover { background: var(--bg-card); }
.pli-left { display: flex; flex-direction: column; gap: 0.2rem; }
.pli-left strong { font-size: 0.95rem; }
.pli-date { font-size: 0.8rem; color: var(--text-tertiary); }
.pli-right { display: flex; align-items: center; gap: 0.5rem; }
.pli-badge {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
}
.pli-badge--shared { background: rgba(52,211,153,0.15); color: var(--success); }
.pli-badge--draft { background: rgba(255,255,255,0.06); color: var(--text-tertiary); }
.pli-badge--admin { background: rgba(247,127,0,0.15); color: var(--accent-light); }
.pli-badge--client { background: rgba(255,186,8,0.15); color: var(--teal); }

/* --- Time entry form --- */
.portal-time-form {
  display: flex;
  gap: 0.75rem;
  align-items: flex-end;
  flex-wrap: wrap;
}

/* --- Portal table --- */
.portal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  margin-top: 1rem;
}
.portal-table th {
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid var(--border);
}
.portal-table td {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.portal-table tr:hover td { background: var(--bg-card); }

/* --- Delete / icon button --- */
.btn-icon {
  background: none;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0.25rem;
  transition: color var(--transition);
}
.btn-icon:hover { color: var(--error); }
.btn-sm { font-size: 0.85rem; padding: 0.4rem 1rem; }

/* --- Meeting content rendering --- */
.portal-meeting-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--text-secondary);
}
.portal-meeting-content h1,
.portal-meeting-content h2,
.portal-meeting-content h3 {
  color: var(--text);
  margin: 1.5rem 0 0.75rem;
}
.portal-meeting-content h3 { font-size: 1.15rem; }
.portal-meeting-content ul, .portal-meeting-content ol {
  padding-left: 1.5rem;
  margin: 0.75rem 0;
}
.portal-meeting-content li { margin-bottom: 0.35rem; }
.portal-meeting-content blockquote {
  border-left: 3px solid var(--accent-light);
  padding-left: 1rem;
  margin: 1rem 0;
  color: var(--text-tertiary);
}

/* --- Form styles for portal --- */
.portal-form { display: flex; flex-direction: column; gap: 1.5rem; }
.form-row { display: flex; gap: 1rem; }
.form-row > .form-group { flex: 1; }
.form-actions { display: flex; gap: 0.75rem; margin-top: 1rem; }
.form-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-secondary);
}
.form-checkbox input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--accent-light);
}

/* Quill editor dark theme overrides */
.ql-toolbar.ql-snow {
  border-color: var(--border) !important;
  background: var(--bg-elevated);
  border-radius: var(--radius) var(--radius) 0 0;
}
.ql-container.ql-snow {
  border-color: var(--border) !important;
  border-radius: 0 0 var(--radius) var(--radius);
}
.ql-toolbar .ql-stroke { stroke: var(--text-secondary) !important; }
.ql-toolbar .ql-fill { fill: var(--text-secondary) !important; }
.ql-toolbar .ql-picker-label { color: var(--text-secondary) !important; }
.ql-toolbar button:hover .ql-stroke { stroke: var(--accent-light) !important; }
.ql-toolbar button:hover .ql-fill { fill: var(--accent-light) !important; }
.ql-editor { min-height: 250px; color: var(--text); }
.ql-editor.ql-blank::before { color: var(--text-tertiary) !important; }

@media (max-width: 768px) {
  .portal-stat-grid { grid-template-columns: repeat(2, 1fr); }
  .portal-time-form { flex-direction: column; }
  .form-row { flex-direction: column; }
  .portal-projects-grid { grid-template-columns: 1fr; }
}

