/* ============================================
  TWINSTIE – Global styles
   Creative, minimal. Hostinger-ready static.
   ============================================ */

/* --- Design tokens --- */
body[data-page="profile"] {
  --account-bg-start: var(--color-bg);
  --account-bg-end: var(--color-surface-soft);
  --account-panel: var(--color-bg-glass);
  --account-panel-strong: var(--color-bg-glass-strong);
  --account-border: var(--color-border-glass);
  --account-border-strong: var(--color-border-glass-strong);
  --account-muted: var(--color-text-muted);
  --account-accent: var(--color-primary);
  --account-accent-soft: var(--color-primary-soft);
  --account-success: #2f9d73;
  --account-danger: #c84c5c;
  --mentor-surface: var(--color-bg-glass);
  --mentor-surface-strong: var(--color-bg-glass-strong);
  --mentor-surface-soft: var(--color-bg-card);
  --mentor-shadow: var(--shadow-glass);
  --profile-page-bg: linear-gradient(180deg, var(--color-surface-soft) 0%, var(--color-bg) 100%);
  --profile-panel-glow-primary: var(--color-primary-soft);
  --profile-panel-glow-secondary: var(--color-accent-soft);
  --profile-avatar-border: var(--color-border-glass-strong);
  --profile-avatar-shadow: var(--shadow);
  --profile-card-fill: var(--color-bg-card);
  --profile-card-fill-strong: var(--color-bg-glass-strong);
  --profile-divider: var(--color-border);
  --profile-input-border: var(--color-border-glass);
  --profile-input-focus: var(--color-primary);
  --profile-input-ring: var(--color-primary-soft);
  --profile-select-option-bg: var(--color-surface);
  --profile-select-option-text: var(--color-text);
  --profile-cover-overlay: linear-gradient(180deg, rgba(7, 11, 19, 0.16) 0%, var(--color-overlay) 100%);
  --profile-cover-hero-text: #ffffff;
  --profile-cover-hero-copy: rgba(255, 255, 255, 0.88);
  --profile-cover-chip-bg: rgba(255, 255, 255, 0.1);
  --profile-cover-chip-border: rgba(255, 255, 255, 0.16);
  --profile-cover-flag-bg: linear-gradient(135deg, var(--color-bg-glass-strong) 0%, var(--color-bg-glass) 100%);
  --profile-premium-outline: rgba(122, 79, 255, 0.18);
  --profile-premium-outline-strong: rgba(122, 79, 255, 0.34);
}

body[data-page="profile"][data-theme="light"] {
  --profile-page-bg: linear-gradient(180deg, #f7fbf9 0%, #ffffff 100%);
  --profile-panel-glow-primary: rgba(11, 133, 112, 0.12);
  --profile-panel-glow-secondary: rgba(27, 118, 103, 0.08);
  --profile-avatar-border: rgba(255, 255, 255, 0.92);
  --profile-divider: rgba(5, 17, 13, 0.08);
  --profile-input-border: rgba(5, 17, 13, 0.08);
  --profile-input-focus: #0b8570;
  --profile-input-ring: rgba(11, 133, 112, 0.14);
  --profile-premium-outline: rgba(122, 79, 255, 0.2);
  --profile-premium-outline-strong: rgba(122, 79, 255, 0.38);
}

body[data-page="profile"][data-theme="dark"] {
  --profile-page-bg: linear-gradient(180deg, #08111d 0%, #050b14 100%);
  --profile-panel-glow-primary: rgba(73, 224, 197, 0.14);
  --profile-panel-glow-secondary: rgba(126, 233, 216, 0.1);
  --profile-avatar-border: rgba(24, 37, 56, 0.9);
  --profile-divider: rgba(148, 163, 184, 0.16);
  --profile-input-border: rgba(148, 163, 184, 0.2);
  --profile-input-focus: #49e0c5;
  --profile-input-ring: rgba(73, 224, 197, 0.16);
  --profile-premium-outline: rgba(150, 120, 255, 0.24);
  --profile-premium-outline-strong: rgba(150, 120, 255, 0.42);
}

body[data-page="profile"] .profile-page {
  padding-top: calc(var(--space-2xl) + 12px);
  padding-bottom: var(--space-3xl);
}

.btn--danger {
  color: #fff;
  background: linear-gradient(135deg, #ce4343 0%, #8d1826 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 36px rgba(141, 24, 38, 0.28);
}

.btn--danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 40px rgba(141, 24, 38, 0.35);
}

.account-empty,
.account-shell,
.profile-public {
  color: #f5f8fc;
}

.account-empty {
  min-height: 58vh;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 18px;
  padding: 72px 24px;
  border-radius: 36px;
  background:
    radial-gradient(circle at top left, rgba(215, 161, 107, 0.22), transparent 28%),
    radial-gradient(circle at bottom right, rgba(84, 139, 194, 0.18), transparent 26%),
    linear-gradient(155deg, var(--account-panel-strong) 0%, rgba(8, 14, 25, 0.9) 100%);
  border: 1px solid var(--account-border);
  box-shadow: 0 32px 80px rgba(2, 8, 17, 0.38);
}

.account-empty h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.account-empty p {
  max-width: 620px;
  margin: 0;
  color: var(--account-muted);
  line-height: 1.7;
}

.account-empty__eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--account-border);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.72rem;
}

.account-empty__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.account-empty__pulse {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, rgba(215, 161, 107, 0.85) 0%, rgba(215, 161, 107, 0.18) 42%, transparent 72%);
  animation: profilePulse 2.6s ease-in-out infinite;
}

@keyframes profilePulse {
  0%, 100% { transform: scale(0.94); opacity: 0.74; }
  50% { transform: scale(1.05); opacity: 1; }
}

.account-shell,
.profile-public {
  display: grid;
  gap: 28px;
}

.account-hero,
.profile-public__hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 28px;
  padding: 32px;
  border-radius: 36px;
  border: 1px solid var(--account-border);
  background:
    radial-gradient(circle at top left, rgba(215, 161, 107, 0.18), transparent 30%),
    radial-gradient(circle at bottom right, rgba(81, 144, 208, 0.18), transparent 28%),
    linear-gradient(155deg, rgba(15, 24, 39, 0.96) 0%, rgba(8, 15, 26, 0.9) 100%);
  box-shadow: 0 32px 90px rgba(3, 8, 17, 0.38);
}

.account-hero::after,
.profile-public__hero::after {
  content: "";
  position: absolute;
  inset: auto -80px -120px auto;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle at center, rgba(215, 161, 107, 0.24), transparent 72%);
  pointer-events: none;
}

.account-hero__visual,
.profile-public__visual {
  display: grid;
  align-content: start;
  gap: 18px;
}

.account-avatar,
.profile-public__avatar {
  width: min(280px, 100%);
  aspect-ratio: 1;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.26), rgba(78, 126, 177, 0.18)),
    rgba(255, 255, 255, 0.04);
  box-shadow: 0 28px 56px rgba(0, 0, 0, 0.28);
}

.account-avatar img,
.profile-public__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.account-avatar--placeholder,
.profile-public__avatar--placeholder {
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5.2rem);
  color: rgba(255, 255, 255, 0.9);
}

.account-hero__media-actions,
.account-hero__actions,
.profile-cropper__actions,
.profile-delete-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.account-hero__body,
.profile-public__body {
  display: grid;
  align-content: start;
  gap: 18px;
}

.account-hero__eyebrow,
.profile-public__eyebrow,
.account-panel__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--account-border);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.72);
}

.account-hero h1,
.profile-public__body h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  line-height: 0.95;
}

.account-hero__lead,
.profile-public__lead {
  max-width: 760px;
  margin: 0;
  color: var(--account-muted);
  line-height: 1.7;
  font-size: 1rem;
}

.account-hero__chips,
.profile-public__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.account-hero__chip,
.profile-public__chip {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--account-border);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.88rem;
}

.account-hero__hint {
  align-self: center;
  color: var(--account-muted);
  font-size: 0.9rem;
}

.account-layout,
.profile-public__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.9fr);
  gap: 24px;
}

.account-main,
.account-sidebar {
  display: grid;
  gap: 24px;
}

.profile-public__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.profile-public__media {
  grid-column: 1 / -1;
}

.account-panel,
.profile-public__panel {
  position: relative;
  overflow: hidden;
  padding: 28px;
  border-radius: 28px;
  border: 1px solid var(--account-border);
  background: linear-gradient(160deg, var(--account-panel-strong) 0%, var(--account-panel) 100%);
  box-shadow: 0 24px 56px rgba(4, 9, 18, 0.26);
}

.account-panel--danger {
  border-color: rgba(239, 107, 107, 0.32);
  background:
    linear-gradient(160deg, rgba(48, 13, 19, 0.9) 0%, rgba(29, 12, 19, 0.9) 100%);
}

.account-panel__header {
  display: grid;
  gap: 8px;
  margin-bottom: 22px;
}

.account-panel__header h2,
.profile-public__panel h2 {
  margin: 0;
  font-size: 1.3rem;
}

.account-panel__header p,
.profile-public__panel p {
  margin: 0;
  color: var(--account-muted);
  line-height: 1.7;
}

.profile-public__list {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  display: grid;
  gap: 14px;
}

.profile-public__list li {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.profile-public__list span {
  color: var(--account-muted);
  font-size: 0.84rem;
}

.profile-public__list strong {
  font-size: 1rem;
}

.profile-public__media video,
.account-media-card video {
  width: 100%;
  display: block;
  border-radius: 22px;
  margin-top: 16px;
  background: rgba(0, 0, 0, 0.28);
}

.account-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 16px;
}

.account-field {
  display: grid;
  gap: 10px;
}

.account-field span {
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.88rem;
}

.account-field--full {
  grid-column: 1 / -1;
}

.account-field textarea.form-input {
  min-height: 140px;
  resize: vertical;
}

.account-actions {
  display: flex;
  justify-content: flex-start;
}

.account-sidebar {
  align-content: start;
}

.account-media-card {
  display: grid;
  gap: 14px;
}

.account-media-card h3 {
  margin: 0;
  font-size: 1rem;
}

.account-media-card p {
  margin: 0;
  color: var(--account-muted);
  line-height: 1.6;
}

.account-media-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.account-status {
  margin-bottom: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid transparent;
  line-height: 1.6;
}

.account-status--success {
  color: #e8fff3;
  background: rgba(100, 215, 168, 0.12);
  border-color: rgba(100, 215, 168, 0.28);
}

.account-status--error {
  color: #ffeaea;
  background: rgba(239, 107, 107, 0.12);
  border-color: rgba(239, 107, 107, 0.26);
}

.account-status--info {
  color: #f4efe7;
  background: rgba(215, 161, 107, 0.12);
  border-color: rgba(215, 161, 107, 0.24);
}

.account-progress {
  display: none;
  width: 100%;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}

.account-progress.is-visible {
  display: block;
}

.account-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #d7a16b 0%, #6cb6ff 100%);
  transition: width 0.2s ease;
}

.profile-crop-modal {
  max-width: min(980px, calc(100vw - 32px));
}

.profile-cover-crop-modal {
  max-width: min(1120px, calc(100vw - 32px));
}

.profile-cover-actions-modal {
  max-width: min(640px, calc(100vw - 32px));
}

.profile-crop-modal__copy {
  color: var(--color-text-muted);
  margin: 0 0 20px;
  line-height: 1.7;
}

.profile-cover-actions-modal__copy {
  color: var(--color-text-muted);
  margin: 0 0 20px;
  line-height: 1.7;
}

.profile-cover-actions {
  display: grid;
  gap: 14px;
}

.profile-cover-option {
  width: 100%;
  display: grid;
  gap: 6px;
  padding: 18px 20px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04)),
    rgba(8, 12, 18, 0.16);
  color: var(--color-text);
  text-align: left;
  cursor: pointer;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.profile-cover-option:hover,
.profile-cover-option:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(215, 161, 107, 0.42);
  box-shadow: 0 22px 38px rgba(7, 11, 19, 0.18);
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.06)),
    rgba(8, 12, 18, 0.2);
}

.profile-cover-option:focus-visible {
  outline: 2px solid rgba(108, 182, 255, 0.5);
  outline-offset: 2px;
}

.profile-cover-option:disabled {
  opacity: 0.58;
  cursor: wait;
  transform: none;
  box-shadow: none;
}

.profile-cover-option__title {
  font-size: 1rem;
  font-weight: 700;
}

.profile-cover-option__copy {
  color: var(--color-text-muted);
  line-height: 1.6;
}

.profile-cover-option--danger {
  border-color: rgba(185, 72, 72, 0.22);
  background:
    linear-gradient(155deg, rgba(185, 72, 72, 0.12), rgba(255, 255, 255, 0.03)),
    rgba(8, 12, 18, 0.16);
}

.profile-cover-option--danger:hover,
.profile-cover-option--danger:focus-visible {
  border-color: rgba(185, 72, 72, 0.42);
  box-shadow: 0 22px 38px rgba(68, 16, 16, 0.18);
}

.profile-cover-actions-modal__footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 20px;
}

.profile-cropper {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.8fr);
  gap: 24px;
  align-items: start;
}

.profile-cover-cropper {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.75fr);
  gap: 24px;
  align-items: start;
}

.profile-cropper__viewport {
  position: relative;
  width: min(100%, 420px);
  aspect-ratio: 1;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 28px;
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.14), rgba(108, 182, 255, 0.12)),
    rgba(7, 12, 21, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
  touch-action: none;
}

.profile-cover-cropper__viewport {
  position: relative;
  width: min(100%, 640px);
  aspect-ratio: 16 / 6;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 30px;
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.14), rgba(108, 182, 255, 0.12)),
    rgba(7, 12, 21, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
  touch-action: none;
}

.profile-cropper__viewport::after {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.28);
  pointer-events: none;
}

.profile-cover-cropper__viewport::after {
  content: "";
  position: absolute;
  inset: 16px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.28);
  pointer-events: none;
}

.profile-cropper__viewport img,
.profile-cover-cropper__viewport img {
  position: absolute;
  left: 50%;
  top: 50%;
  user-select: none;
  max-width: none;
  max-height: none;
  cursor: grab;
}

.profile-cropper__controls {
  display: grid;
  gap: 16px;
}

.profile-cover-cropper__controls {
  display: grid;
  gap: 16px;
}

.profile-cover-cropper__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.profile-cover-cropper__remove {
  margin-right: auto;
}

.profile-delete-modal p {
  color: var(--color-text-muted);
  line-height: 1.7;
}

.profile-public__back {
  width: fit-content;
}

.profile-card--firebase a {
  display: block;
}

.profile-card__avatar--placeholder {
  display: grid;
  place-items: center;
  color: var(--color-text);
  font-family: var(--font-display);
  font-size: 2rem;
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.26), rgba(108, 182, 255, 0.18)),
    rgba(255, 255, 255, 0.05);
}

.profile-card__cta {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.06);
  border: 1px solid rgba(15, 23, 42, 0.08);
  font-weight: 600;
  color: var(--color-text);
}

.chatbot-mentor-card__avatar--placeholder {
  display: grid;
  place-items: center;
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.24), rgba(108, 182, 255, 0.18)),
    rgba(255, 255, 255, 0.04);
  color: var(--color-text);
  font-weight: 700;
}

@media (max-width: 1040px) {
  .account-layout,
  .profile-public__grid,
  .account-hero,
  .profile-public__hero,
  .profile-cropper,
  .profile-cover-cropper {
    grid-template-columns: 1fr;
  }

  .account-hero__visual,
  .profile-public__visual {
    justify-items: center;
  }

  .account-avatar,
  .profile-public__avatar {
    width: min(320px, 100%);
  }
}

@media (max-width: 720px) {
  .account-hero,
  .profile-public__hero,
  .account-panel,
  .profile-public__panel,
  .account-empty {
    padding: 22px;
    border-radius: 26px;
  }

  .account-form-grid {
    grid-template-columns: 1fr;
  }

  .account-field--full {
    grid-column: auto;
  }

  .account-hero__actions,
  .account-hero__media-actions,
  .account-empty__actions,
  .profile-cropper__actions,
  .profile-cover-cropper__actions,
  .profile-cover-actions-modal__footer,
  .profile-delete-modal__actions {
    flex-direction: column;
  }

  .account-hero__actions .btn,
  .account-hero__media-actions .btn,
  .account-empty__actions .btn,
  .profile-cropper__actions .btn,
  .profile-cover-cropper__actions .btn,
  .profile-cover-actions-modal__footer .btn,
  .profile-delete-modal__actions .btn {
    width: 100%;
  }

  .profile-cover-cropper__remove {
    margin-right: 0;
  }
}

:root {
  /* Palette: Premium Light Theme (White & Emerald) */
  --color-primary: #0B8570;
  --color-primary-hover: #076552;
  --color-primary-soft: rgba(11, 133, 112, 0.12);
  --color-primary-glass: rgba(11, 133, 112, 0.22);

  --color-accent: #1B7667;
  --color-accent-soft: rgba(27, 118, 103, 0.12);
  --color-accent-glass: rgba(27, 118, 103, 0.2);

  --color-bg: #ffffff;
  --color-text: #050505;
  --color-text-muted: #586664;

  /* Premium Frosted Glass Layers */
  --color-bg-card: rgba(255, 255, 255, 0.6);
  --color-bg-glass: rgba(255, 255, 255, 0.7);
  --color-bg-glass-strong: rgba(255, 255, 255, 0.85);

  /* Precise Matte Borders */
  --color-border: rgba(5, 17, 13, 0.06);
  --color-border-glass: rgba(255, 255, 255, 0.2);
  --color-border-glass-strong: rgba(255, 255, 255, 0.4);
  --color-ring: rgba(11, 133, 112, 0.16);
  --color-surface: #ffffff;
  --color-surface-soft: #f7fbf9;
  --color-sidebar: rgba(250, 250, 250, 0.9);
  --color-overlay: rgba(0, 0, 0, 0.25);
  --color-overlay-strong: rgba(0, 0, 0, 0.35);
  --color-input-bg: rgba(255, 255, 255, 0.7);
  --color-input-bg-strong: rgba(255, 255, 255, 0.85);
  --color-card-hover: rgba(255, 255, 255, 0.95);
  --color-avatar-border: #ffffff;
  --mesh-primary: rgba(11, 133, 112, 0.11);
  --mesh-accent: rgba(79, 170, 146, 0.08);

  /* Typography – High Contrast */
  --font-display: "DM Sans", "Inter", sans-serif;
  --font-body: "DM Sans", "Inter", sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --max-width: 1200px;
  /* Wider for Bento */

  /* Radii - Smoother, larger arcs for Bento */
  --radius: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
  --radius-3xl: 48px;

  /* iOS Matte Shadows & Inner Light */
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.03);
  --shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.05), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  --shadow-hover: 0 24px 60px -12px rgba(0, 0, 0, 0.08), 0 8px 16px -8px rgba(0, 0, 0, 0.04), inset 0 1px 1px rgba(255, 255, 255, 0.8);
  --shadow-glass: 0 12px 32px rgba(0, 0, 0, 0.04), inset 0 1px 1px rgba(255, 255, 255, 0.5);
  --shadow-glass-hover: 0 20px 48px rgba(0, 0, 0, 0.06), inset 0 1px 1px rgba(255, 255, 255, 0.7);

  /* Deep Blurs */
  --blur: 24px;
  --blur-strong: 60px;
}

body[data-theme="dark"] {
  --color-primary: #49E0C5;
  --color-primary-hover: #72EAD5;
  --color-primary-soft: rgba(73, 224, 197, 0.14);
  --color-primary-glass: rgba(73, 224, 197, 0.22);
  --color-accent: #7EE9D8;
  --color-accent-soft: rgba(126, 233, 216, 0.12);
  --color-accent-glass: rgba(126, 233, 216, 0.16);
  --color-bg: #08111d;
  --color-text: #edf4ff;
  --color-text-muted: #99abc4;
  --color-bg-card: rgba(12, 20, 33, 0.82);
  --color-bg-glass: rgba(14, 24, 39, 0.76);
  --color-bg-glass-strong: rgba(18, 30, 47, 0.92);
  --color-border: rgba(148, 163, 184, 0.16);
  --color-border-glass: rgba(148, 163, 184, 0.18);
  --color-border-glass-strong: rgba(148, 163, 184, 0.24);
  --color-ring: rgba(73, 224, 197, 0.18);
  --color-surface: #182538;
  --color-surface-soft: #111c2c;
  --color-sidebar: rgba(7, 13, 23, 0.94);
  --color-overlay: rgba(3, 7, 14, 0.56);
  --color-overlay-strong: rgba(3, 7, 14, 0.68);
  --color-input-bg: rgba(16, 27, 43, 0.86);
  --color-input-bg-strong: rgba(21, 35, 55, 0.98);
  --color-card-hover: rgba(19, 33, 51, 0.98);
  --color-avatar-border: #0d1726;
  --mesh-primary: rgba(73, 224, 197, 0.14);
  --mesh-accent: rgba(126, 233, 216, 0.12);
  --shadow-sm: 0 10px 26px rgba(0, 0, 0, 0.32);
  --shadow: 0 26px 64px rgba(0, 0, 0, 0.34), inset 0 1px 1px rgba(255, 255, 255, 0.03);
  --shadow-hover: 0 30px 78px rgba(0, 0, 0, 0.42), 0 10px 26px rgba(0, 0, 0, 0.2);
  --shadow-glass: 0 20px 52px rgba(0, 0, 0, 0.34), inset 0 1px 1px rgba(255, 255, 255, 0.03);
  --shadow-glass-hover: 0 28px 62px rgba(0, 0, 0, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.04);
}

/* ============================================
   Basic Resets & Base Styles
   ============================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

/* Scroll-snap only on globe page */
body[data-page="globe"] {
  scroll-snap-type: y mandatory;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  position: relative;
  height: 100%;
}

/* Snap containers belong only to the cinematic globe experience. */
body[data-page="globe"] main > section,
body[data-page="globe"] .site-footer {
  min-height: 100vh;
  /* Force full screen height */
  scroll-snap-align: start;
  /* Lock to the top of the section */
  scroll-snap-stop: always;
  /* Force it to stop at every section */
  display: flex;
  flex-direction: column;
  justify-content: center;
  /* Center content vertically if it doesn't fill the screen */
}

/* Base Body Background Mesh */
body::before,
body::after {
  content: "";
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  z-index: -1;
  pointer-events: none;
  animation: meshFloat 30s infinite alternate cubic-bezier(0.4, 0, 0.2, 1);
}

body::before {
  top: -15%;
  left: -15%;
  width: 70vw;
  height: 70vw;
  min-width: 500px;
  min-height: 500px;
  background: radial-gradient(circle, var(--mesh-primary) 0%, transparent 60%);
}

body::after {
  bottom: -15%;
  right: -15%;
  width: 60vw;
  height: 60vw;
  min-width: 400px;
  min-height: 400px;
  background: radial-gradient(circle, var(--mesh-accent) 0%, transparent 60%);
  animation-delay: -15s;
  animation-duration: 35s;
}

/* We will create a fresh full-screen pseudo element for the frosted noise */
.noise-overlay {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.035;
  /* Keep it very subtle */
}

@keyframes meshFloat {
  0% {
    transform: translate(0, 0) scale(1);
  }

  33% {
    transform: translate(3vw, 5vh) scale(1.05);
  }

  66% {
    transform: translate(-3vw, 2vh) scale(0.95);
  }

  100% {
    transform: translate(2vw, -4vh) scale(1.02);
  }
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none !important;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--color-primary-hover);
  text-decoration: none !important;
}

/* --- Typography --- */
h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  margin-top: 0;
  letter-spacing: -0.03em;
  /* Tighter spacing for modern feel */
  color: var(--color-text);
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
  font-size: 1.25rem;
}

p {
  margin: 0 0 var(--space-md);
  color: var(--color-text-muted);
}

p:last-child {
  margin-bottom: 0;
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-lg);
  padding-right: var(--space-lg);
}

/* --- Header / Nav – Floating & Animated --- */
.site-header {
  padding: 14px 0;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
}

body[data-theme="light"] .site-header::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(92vw, 1240px);
  height: 2px;
  transform: translateX(-50%);
  background: linear-gradient(
    90deg,
    rgba(11, 133, 112, 0) 0%,
    rgba(11, 133, 112, 0.08) 14%,
    rgba(11, 133, 112, 0.18) 34%,
    rgba(11, 133, 112, 0.28) 50%,
    rgba(11, 133, 112, 0.18) 66%,
    rgba(11, 133, 112, 0.08) 86%,
    rgba(11, 133, 112, 0) 100%
  );
  clip-path: polygon(0 0, 100% 0, 100% 100%, 64% 100%, 50% 42%, 36% 100%, 0 100%);
  pointer-events: none;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  max-width: none;
  padding-right: var(--space-xl);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.pill-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: var(--color-bg-glass-strong);
  border: 1px solid var(--color-border-glass);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  animation: slideDownFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  opacity: 0;
}

.pill-toggle:nth-child(1) {
  animation-delay: 0.05s;
}

.pill-toggle:nth-child(2) {
  animation-delay: 0.08s;
}

.pill-toggle__button {
  border: 0;
  background: transparent;
  color: var(--color-text-muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.pill-toggle__button:hover {
  color: var(--color-text);
}

.pill-toggle__button.is-active {
  color: var(--color-text);
  background: var(--color-surface);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.pill-toggle__button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--color-ring);
}

body[data-theme="dark"] .pill-toggle {
  background: rgba(12, 20, 33, 0.82);
  border-color: rgba(148, 163, 184, 0.16);
}

body[data-theme="dark"] .pill-toggle__button.is-active {
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.34);
}

/* Entrance Animations for Header */
@keyframes slideDownFade {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.logo {
  font-family: var(--font-display);
  font-size: 1.1rem;
  /* Smaller logo */
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--color-text);
  transition: color 0.3s ease, transform 0.3s ease;
  z-index: 1002;
  animation: slideDownFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.logo:hover {
  color: var(--color-primary);
  text-decoration: none !important;
  transform: scale(1.02);
}

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 46px;
  height: 46px;
  margin-left: 10px;
  background: var(--color-bg-glass-strong);
  border: 1px solid var(--color-border-glass);
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  cursor: pointer;
  padding: 0;
  z-index: 1002;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
  animation: slideDownFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
  opacity: 0;
}

.menu-toggle:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.menu-toggle:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--color-ring), var(--shadow-sm);
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: var(--color-text);
  border-radius: 999px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, width 0.25s ease, background 0.25s ease;
  transform-origin: center;
  box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
}

.menu-toggle span:nth-child(2) {
  width: 16px;
}

.menu-toggle span:nth-child(3) {
  width: 12px;
}

.menu-toggle.active span {
  background: var(--color-primary);
}

.menu-toggle.active span:nth-child(1) {
  width: 20px;
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.menu-toggle.active span:nth-child(3) {
  width: 20px;
  transform: translateY(-7px) rotate(-45deg);
}

body[data-theme="dark"] .menu-toggle {
  background: rgba(12, 20, 33, 0.82);
  border-color: rgba(148, 163, 184, 0.16);
}

/* Sidebar styling */
.sidebar {
  position: fixed;
  top: 0;
  right: -340px;
  width: 340px;
  max-width: 85vw;
  height: 100vh;
  background: var(--color-sidebar);
  /* Premium glassmorphism */
  backdrop-filter: saturate(200%) blur(40px);
  -webkit-backdrop-filter: saturate(200%) blur(40px);
  box-shadow: -10px 0 50px rgba(0, 0, 0, 0.1);
  border-left: 1px solid var(--color-border);
  padding: 120px var(--space-2xl) var(--space-3xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  transition: right 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1000;
}

.sidebar.active {
  right: 0;
}

.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: var(--color-overlay);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.sidebar-overlay.active {
  opacity: 1;
  visibility: visible;
}

.sidebar-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.sidebar-links li {
  width: 100%;
}

.sidebar-links a {
  display: block;
  font-size: 1.5rem;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--color-text);
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-lg);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  background: transparent;
  border: 1px solid transparent;
}

.sidebar-links a:hover {
  background: var(--color-surface);
  color: var(--color-primary);
  transform: translateX(-6px) scale(1.02);
  border-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}

body[data-theme="dark"] .sidebar {
  box-shadow: -18px 0 60px rgba(0, 0, 0, 0.45);
}

body[data-theme="dark"] .sidebar-links a:hover {
  background: rgba(20, 33, 51, 0.94);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  border: none;
  border-radius: var(--radius-3xl);
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  text-align: center;
}

.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.4) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
  pointer-events: none;
}

.btn:hover::before {
  opacity: 1;
}

.btn--primary {
  background: var(--color-primary);
  color: #fff !important;
  box-shadow: 0 4px 14px rgba(73, 224, 197, 0.3), inset 0 1px 1px rgba(255, 255, 255, 0.4);
}

.btn--primary:hover {
  text-decoration: none !important;
  box-shadow: 0 8px 30px rgba(73, 224, 197, 0.42), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  transform: translateY(-3px) scale(1.02);
}

body[data-theme="light"] .btn--primary {
  box-shadow: 0 10px 24px rgba(11, 133, 112, 0.18), inset 0 1px 1px rgba(255, 255, 255, 0.4);
}

body[data-theme="light"] .btn--primary:hover {
  box-shadow: 0 16px 36px rgba(11, 133, 112, 0.24), inset 0 1px 1px rgba(255, 255, 255, 0.55);
}

.btn--secondary {
  background: var(--color-bg-glass-strong);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow-sm);
}

.btn--secondary:hover {
  border-color: var(--color-primary-glass);
  color: var(--color-primary);
  text-decoration: none !important;
  background: var(--color-surface);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-3px) scale(1.02);
}

body[data-theme="dark"] .btn::before {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, transparent 100%);
}

body[data-theme="dark"] .btn--secondary:hover {
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.32);
}

/* --- Split Hero Layout --- */
.split-hero {
  padding: calc(var(--space-3xl) + 20px) 0 var(--space-2xl);
  /* Reduced top padding significantly */
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  width: 100%;
  /* Removed min-height: 85vh because 'main > section' sets it to 100vh */
}

.split-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(244, 34, 80, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(15, 23, 42, 0.04) 0%, transparent 50%),
    radial-gradient(ellipse 50% 30% at 20% 80%, rgba(244, 34, 80, 0.04) 0%, transparent 50%);
  pointer-events: none;
}

body[data-theme="light"] .split-hero::before {
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(11, 133, 112, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(27, 118, 103, 0.05) 0%, transparent 50%),
    radial-gradient(ellipse 50% 30% at 20% 80%, rgba(11, 133, 112, 0.05) 0%, transparent 50%);
}

body[data-theme="dark"] .split-hero::before {
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(73, 224, 197, 0.16) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(126, 233, 216, 0.12) 0%, transparent 50%),
    radial-gradient(ellipse 50% 30% at 20% 80%, rgba(73, 224, 197, 0.08) 0%, transparent 50%);
}

.split-hero__container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  /* Left (pictures) slightly larger */
  gap: var(--space-3xl);
  align-items: center;
  position: relative;
  z-index: 1;
  max-width: 1400px;
  /* Make the container wider */
  width: 95%;
  /* Use more of the screen width */
  margin: 0 auto;
  /* Center it */
}

.split-hero__left {
  width: 100%;
}

.split-hero__right {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
}

/* --- Home: Hero – glassy, vibrant --- */
.hero {
  padding: calc(var(--space-3xl) + 20px) 0 var(--space-2xl);
  /* Reduced top padding significantly */
  text-align: center;
  position: relative;
  align-items: center;
  display: flex;
  flex-direction: column;
}

.hero .container {
  position: relative;
  z-index: 1;
  max-width: 900px;
}

/* --- Browse page --- */
.page-header {
  text-align: center;
  margin-bottom: var(--space-2xl);
  padding-top: calc(var(--space-2xl) + 60px);
  /* Account for floating header */
}

.page-header__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 6px 16px;
  margin-bottom: var(--space-md);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-bg-glass);
  border: 1px solid var(--color-border);
  border-radius: 999px;
}

.page-header__badge svg {
  width: 1rem;
  height: 1rem;
}

.page-header p.lead {
  max-width: 600px;
  margin: var(--space-sm) auto 0;
}

/* Spotlight Banner */
.spotlight-banner {
  background: var(--color-bg-card);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-radius: var(--radius-2xl);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow);
  padding: var(--space-xl) var(--space-2xl);
  margin-bottom: var(--space-2xl);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2xl);
  overflow: hidden;
  position: relative;
}

.spotlight-banner::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, var(--color-primary-soft) 0%, transparent 70%);
  pointer-events: none;
}

.spotlight-banner__content {
  flex: 1;
  position: relative;
  z-index: 1;
}

.spotlight-banner__content h2 {
  font-size: 1.8rem;
  margin-bottom: var(--space-sm);
}

.spotlight-banner__content p {
  color: var(--color-text-muted);
  font-size: 1.05rem;
}

.spotlight-banner__visual {
  flex: 0 0 auto;
  display: flex;
  gap: -15px;
  /* Overlap avatars slightly */
  align-items: center;
}

.spotlight-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 3px solid #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  object-fit: cover;
  transition: transform 0.3s ease;
}

.spotlight-avatar:hover {
  transform: translateY(-4px) scale(1.1);
  z-index: 10;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 6px 16px;
  margin-bottom: var(--space-lg);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-primary);
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease;
  align-self: flex-start;
}

.hero__badge:hover {
  transform: translateY(-2px);
}

.hero__badge svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.hero h1 {
  margin-bottom: var(--space-md);
}

.hero .lead {
  font-size: 1.25rem;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--space-xl);
  color: var(--color-text-muted);
}

.hero .hero__sub {
  font-size: 1rem;
  color: var(--color-text-muted);
  margin-top: var(--space-lg);
  font-weight: 500;
}

.hero .btn {
  min-width: 220px;
  padding: 16px 32px;
  font-size: 1.1rem;
}

.split-hero__right h1 {
  margin-bottom: var(--space-md);
  text-align: left;
}

.split-hero__right .lead {
  font-size: 1.25rem;
  max-width: 100%;
  margin-right: 0;
  margin-left: 0;
  margin-bottom: var(--space-xl);
  color: var(--color-text-muted);
  text-align: left;
}

.split-hero__right .hero__sub {
  font-size: 1rem;
  color: var(--color-text-muted);
  margin-top: var(--space-lg);
  font-weight: 500;
  text-align: left;
}

.split-hero__actions {
  display: flex;
  align-items: flex-start;
}

.split-hero__actions .btn {
  min-width: 220px;
  padding: 16px 32px;
  font-size: 1.1rem;
}

/* --- Features / Bento Grid section --- */
.features {
  padding: var(--space-xl) 0;
  /* Reduced to fit better in 100vh */
  position: relative;
  z-index: 2;
}

.features__header {
  text-align: center;
  margin-bottom: var(--space-lg);
  /* Reduced to fit better in 100vh */
}

.features__eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-primary);
  padding: 6px 14px;
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  margin-bottom: var(--space-sm);
  box-shadow: var(--shadow-sm);
}

.features__eyebrow:hover {
  transform: translateY(-2px);
}

.features__title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: var(--space-sm);
}

.features__sub {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* The Bento Grid (now optimized for a larger split layout) */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-lg);
  /* Slightly more breathing room */
  grid-auto-rows: minmax(200px, auto);
  /* Reduced slightly to ensure it all fits inside 100vh on laptops */
}

.bento-item {
  background: var(--color-bg-card);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-radius: var(--radius-2xl);
  /* Slightly smaller radius */
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.bento-item:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: var(--shadow-hover);
  background: #ffffff;
  border-color: #ffffff;
}

/* specific sizes spanning columns (out of 12) */
.bento-item--large {
  grid-column: span 8;
  flex-direction: row;
  /* Horizontal layout for large card */
}

.bento-item--tall {
  grid-column: span 4;
  grid-row: span 2;
}

.bento-item--wide {
  grid-column: span 12;
  flex-direction: row;
}

.bento-item--standard {
  grid-column: span 4;
}

.bento-item__img-wrap {
  width: 100%;
  flex: 1;
  overflow: hidden;
  background: #fdfdfd;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
  /* Reduced padding to close gap */
}

.bento-item__multi-img-wrap {
  width: 100%;
  flex: 1;
  background: #fdfdfd;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-evenly;
  padding: var(--space-sm);
  /* Reduced padding to close gap */
  overflow: hidden;
  gap: var(--space-sm);
}

.multi-img-item {
  width: 130px;
  height: 130px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #ffffff;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
  border: 4px solid #ffffff;
}

.bento-item__multi-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.bento-item:hover .bento-item__multi-img-wrap img {
  transform: scale(1.08) translateY(-4px);
}

/* Horizontal overrides */
.bento-item--large .bento-item__img-wrap,
.bento-item--wide .bento-item__img-wrap {
  flex: 1;
  height: 100%;
}

.bento-item__img-wrap img {
  width: 90%;
  height: 90%;
  object-fit: cover;
  background: #ffffff;
  border-radius: var(--radius-xl);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
  border: 4px solid #ffffff;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.bento-item:hover .bento-item__img-wrap img {
  transform: scale(1.08) translateY(-4px);
}

.bento-item__body {
  padding: var(--space-md) var(--space-lg) var(--space-xs) var(--space-lg);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.bento-item--large .bento-item__body,
.bento-item--wide .bento-item__body {
  flex: 1;
  padding: var(--space-md) var(--space-lg);
}

.bento-item__body h3 {
  font-size: 1.5rem;
  margin-bottom: var(--space-xs);
}

.bento-item__body p {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.compact-h3 {
  font-size: 1.25rem;
  /* Larger text for features */
  margin-bottom: var(--space-xs);
}

.compact-p {
  font-size: 0.95rem;
  /* Better readability */
  color: var(--color-text-muted);
  line-height: 1.5;
  margin: 0;
}

/* --- Stats section – glass cards --- */
.stats {
  padding: var(--space-3xl) 0;
  position: relative;
}

.stats__title {
  text-align: center;
  margin-bottom: var(--space-2xl);
  position: relative;
  z-index: 2;
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-lg);
  position: relative;
  z-index: 2;
}

.stat-card {
  background: var(--color-bg-card);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-radius: var(--radius-2xl);
  padding: var(--space-2xl);
  text-align: center;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.8);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.stat-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  background: #ffffff;
}

.stat-card__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: var(--color-primary);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.stat-card__icon svg {
  width: 28px;
  height: 28px;
}

.stat-card__value {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.05em;
  color: var(--color-text);
  margin: 0 0 var(--space-xs);
}

.stat-card__label {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--color-text-muted);
  margin: 0;
}

/* --- Chart section – glass --- */
.chart-section {
  padding: var(--space-3xl) 0;
  position: relative;
  z-index: 2;
}

.chart-section__title {
  text-align: center;
  margin-bottom: var(--space-xs);
}

.chart-section__sub {
  text-align: center;
  color: var(--color-text-muted);
  margin-bottom: var(--space-2xl);
}

.chart {
  max-width: 520px;
  margin: 0 auto;
  padding: var(--space-xl);
  background: var(--color-bg-card);
  backdrop-filter: saturate(180%) blur(var(--blur));
  -webkit-backdrop-filter: saturate(180%) blur(var(--blur));
  border-radius: var(--radius-2xl);
  border: 1px solid var(--color-border-glass-strong);
  border-top: 1px solid rgba(255, 255, 255, 1);
  border-left: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-glass);
  transition: box-shadow 0.3s ease;
}

.chart:hover {
  box-shadow: var(--shadow-glass-hover);
}

.chart__bars {
  flex: 1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-sm);
  min-height: 180px;
}

.chart__bar-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.chart__bar {
  width: 100%;
  max-width: 48px;
  height: calc(160px * var(--h, 50) / 100);
  min-height: 24px;
  background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
  border-radius: var(--radius) var(--radius) 0 0;
  transition: transform 0.2s;
  animation: chartBarGrow 0.6s ease-out backwards;
}

.chart__bar-wrap:nth-child(1) .chart__bar {
  animation-delay: 0.05s;
}

.chart__bar-wrap:nth-child(2) .chart__bar {
  animation-delay: 0.1s;
}

.chart__bar-wrap:nth-child(3) .chart__bar {
  animation-delay: 0.15s;
}

.chart__bar-wrap:nth-child(4) .chart__bar {
  animation-delay: 0.2s;
}

.chart__bar-wrap:nth-child(5) .chart__bar {
  animation-delay: 0.25s;
}

.chart__bar-wrap:nth-child(6) .chart__bar {
  animation-delay: 0.3s;
}

@keyframes chartBarGrow {
  from {
    transform: scaleY(0);
    transform-origin: bottom;
  }

  to {
    transform: scaleY(1);
    transform-origin: bottom;
  }
}

/* Chart bars only animate when the chart section is visible */
.chart__bar {
  animation: none !important;
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.7s cubic-bezier(0.34, 1.2, 0.64, 1);
}

.chart--visible .chart__bar {
  transform: scaleY(1);
}

.chart--visible .chart__bar-wrap:nth-child(1) .chart__bar {
  transition-delay: 0.05s;
}

.chart--visible .chart__bar-wrap:nth-child(2) .chart__bar {
  transition-delay: 0.12s;
}

.chart--visible .chart__bar-wrap:nth-child(3) .chart__bar {
  transition-delay: 0.19s;
}

.chart--visible .chart__bar-wrap:nth-child(4) .chart__bar {
  transition-delay: 0.26s;
}

.chart--visible .chart__bar-wrap:nth-child(5) .chart__bar {
  transition-delay: 0.33s;
}

.chart--visible .chart__bar-wrap:nth-child(6) .chart__bar {
  transition-delay: 0.4s;
}

.chart__bar:hover,
.chart__bar--active {
  transform: scaleY(1.02);
  opacity: 1;
}

.chart__bar--active {
  box-shadow: 0 -2px 12px rgba(73, 224, 197, 0.28);
}

.chart__label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-text-muted);
}

/* --- How it works --- */
.how-it-works {
  padding: var(--space-3xl) 0;
}

.how-it-works__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-xl);
  margin-top: var(--space-xl);
}

.how-card {
  background: var(--color-bg-card);
  backdrop-filter: saturate(180%) blur(var(--blur));
  -webkit-backdrop-filter: saturate(180%) blur(var(--blur));
  border-radius: var(--radius-2xl);
  padding: var(--space-xl);
  border: 1px solid var(--color-border-glass-strong);
  border-top: 1px solid rgba(255, 255, 255, 1);
  border-left: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-glass);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
}

.how-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(255, 255, 255, 1);
  background: var(--color-bg-glass-strong);
  box-shadow: var(--shadow-hover);
}

.how-card__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--color-primary);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  border-radius: 50%;
  margin-bottom: var(--space-md);
}

.how-card h3 {
  margin: 0 0 var(--space-sm);
  font-size: 1.1rem;
}

.how-card p {
  margin: 0;
  font-size: 0.95rem;
}

/* --- CTA section – glass --- */
.cta-section {
  padding: var(--space-3xl) 0;
  text-align: center;
  position: relative;
}

.cta-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 50%, var(--color-primary-soft) 0%, transparent 70%);
  pointer-events: none;
}

.cta-section .container {
  position: relative;
  z-index: 1;
}

.cta-section h2 {
  margin-bottom: var(--space-sm);
}

.cta-section p {
  margin-bottom: var(--space-xl);
  color: var(--color-text-muted);
}

/* --- Browse Section --- */
.browse-section {
  justify-content: flex-start !important;
  /* Override snap centering — cards need to start at top */
  padding-top: 160px;
  /* Account for floating header */
  padding-bottom: var(--space-xl);
}

.browse-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
}

.browse-header__text h1 {
  font-size: 1.6rem;
  margin: 0;
}

.browse-header__sub {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin: var(--space-xs) 0 0;
}

/* --- Browse Toolbar --- */
.browse-toolbar {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}

.search-wrap {
  position: relative;
  flex: 1;
  min-width: 220px;
}

.search-wrap__icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 10px 14px 10px 42px;
  font-size: 0.9rem;
  font-family: var(--font-body);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-glass);
  background: var(--color-input-bg);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  color: var(--color-text);
  outline: none;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-ring);
  background: var(--color-input-bg-strong);
}

.search-input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.7;
}

.browse-filters {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.browse-select {
  padding: 9px 32px 9px 14px;
  font-size: 0.85rem;
  font-family: var(--font-body);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-glass);
  background: var(--color-input-bg);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  color: var(--color-text);
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2352525B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.browse-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-ring);
}

.results-count {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin: 0 0 var(--space-md);
}

/* Profile card field badge */
.profile-card__field {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.72rem;
  font-weight: 600;
  border-radius: 999px;
  background: var(--color-primary-soft);
  color: var(--color-primary);
  margin-bottom: var(--space-xs);
  letter-spacing: 0.02em;
}

.profile-card__university {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin: 0 0 var(--space-sm);
  font-weight: 500;
}

/* --- Cards (Browse) --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-lg);
  position: relative;
  z-index: 2;
}

.profile-card {
  background: var(--color-bg-card);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-radius: var(--radius-2xl);
  overflow: visible;
  box-shadow: var(--shadow);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid var(--color-border-glass);
}

.profile-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-6px);
  background: var(--color-card-hover);
}

.profile-card--transitioning {
  transform: scale(0.95);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.profile-card a {
  color: inherit;
  text-decoration: none;
  display: block;
}

.profile-card a:hover {
  text-decoration: none;
}

/* Compact banner + avatar */
.profile-card__banner {
  height: 110px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at 18% 18%, rgba(122, 167, 255, 0.34) 0%, rgba(122, 167, 255, 0) 42%),
    linear-gradient(135deg, rgba(10, 18, 31, 0.96) 0%, rgba(26, 38, 58, 0.88) 52%, rgba(55, 76, 107, 0.72) 100%);
  border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
}

.profile-card__banner::before {
  content: "";
  position: absolute;
  inset: -24px;
  z-index: 0;
  background:
    radial-gradient(circle at 82% 22%, rgba(255, 255, 255, 0.26) 0%, rgba(255, 255, 255, 0) 34%),
    radial-gradient(circle at 14% 78%, rgba(115, 149, 209, 0.28) 0%, rgba(115, 149, 209, 0) 42%);
  filter: blur(18px);
  transform: scale(1.04);
}

.profile-card__banner-image,
.profile-card__banner-overlay {
  position: absolute;
  inset: 0;
}

.profile-card__banner-image {
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.profile-card__banner-overlay {
  z-index: 2;
  background:
    linear-gradient(180deg, rgba(6, 10, 18, 0.08) 0%, rgba(6, 10, 18, 0.42) 100%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0) 52%);
}

.profile-card__banner--with-image .profile-card__banner-overlay {
  background:
    linear-gradient(180deg, rgba(6, 10, 18, 0.14) 0%, rgba(6, 10, 18, 0.58) 100%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 48%);
}

.profile-card__flag {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(7, 12, 22, 0.36);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 12px 24px rgba(4, 9, 17, 0.28);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.profile-card__flag-emoji {
  font-size: 1.16rem;
  line-height: 1;
}

.profile-card__avatar {
  width: 80px;
  height: 80px;
  margin: -40px auto 0;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid var(--color-avatar-border);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  position: relative;
  z-index: 1;
  background: var(--color-bg);
  transition: transform 0.4s ease;
}

.profile-card:hover .profile-card__avatar {
  transform: scale(1.05) translateY(-3px);
}

.profile-card__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-card__body {
  padding: var(--space-md) var(--space-lg) var(--space-lg);
  text-align: center;
}

.profile-card__name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 0 0 var(--space-xs);
  color: var(--color-text);
  font-weight: 700;
}

.profile-card__location {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin-bottom: var(--space-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.profile-card__email {
  font-size: 0.82rem;
  color: var(--color-primary);
  margin-bottom: var(--space-sm);
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* Masked Email Styles */
.email-masked {
  filter: blur(4px);
  user-select: none;
  cursor: help;
  transition: filter 0.3s ease;
  position: relative;
}

/* Tooltip implementation for masked email */
.email-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.email-locked-icon {
  position: absolute;
  color: var(--color-text);
  z-index: 2;
  opacity: 0.8;
  pointer-events: none;
}

.email-wrapper:hover .email-masked {
  filter: blur(5px);
  /* slightly more blur on hover to emphasize it's locked */
}

.email-wrapper::after {
  content: "Login to view email";
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background: var(--color-text);
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
  z-index: 10;
}

.email-wrapper:hover::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.profile-card__tagline {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin: 0;
  line-height: 1.5;
}

.profile-card--locked a {
  position: relative;
}

.profile-card__lock-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  color: var(--color-text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: var(--space-xs);
}

.profile-card__name--preview {
  margin-bottom: var(--space-sm);
}

.profile-card__private {
  filter: blur(7px);
  user-select: none;
  pointer-events: none;
}

.profile-card__redacted {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.22), rgba(148, 163, 184, 0.48), rgba(148, 163, 184, 0.22));
  margin: 0 auto 10px;
}

.profile-card__redacted--full {
  width: 100%;
}

.profile-card__redacted--lg {
  width: 78%;
}

.profile-card__redacted--md {
  width: 58%;
}

.profile-card__redacted--short {
  width: 66%;
  margin-bottom: 0;
}

.profile-card__cta--locked {
  color: var(--color-primary);
}

.profile-card__veil {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: var(--space-md);
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.88);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

/* --- Filter chips (Browse) --- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  align-items: center;
}

.filter-bar .label {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-right: var(--space-sm);
}

.chip {
  display: inline-block;
  padding: 6px 16px;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 999px;
  background: var(--color-input-bg);
  border: 1px solid var(--color-border-glass);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-sm);
}

.chip:hover {
  background: var(--color-surface-soft);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.chip.active {
  border-color: var(--color-primary);
  color: #ffffff;
  background: var(--color-primary);
  box-shadow: 0 6px 16px var(--color-primary-glass);
  transform: translateY(-2px);
}

/* --- Profile page --- */
.profile-page {
  padding: calc(var(--space-2xl) + 20px) 0 var(--space-3xl);
  /* Reduced top padding significantly */
}

.profile-page .back-link {
  display: inline-block;
  margin-bottom: var(--space-lg);
}

body[data-page="profile"] {
  --profile-surface: rgba(13, 20, 31, 0.72);
  --profile-surface-strong: rgba(16, 24, 37, 0.9);
  --profile-border-soft: rgba(164, 179, 201, 0.16);
  --profile-border-strong: rgba(164, 179, 201, 0.24);
  --profile-chip-bg: rgba(236, 242, 255, 0.05);
  --profile-chip-text: rgba(237, 244, 255, 0.92);
  --profile-muted: rgba(153, 171, 196, 0.92);
}

#profile-root .profile-shell {
  width: min(1060px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

#profile-root .profile-topbar {
  display: flex;
  justify-content: flex-start;
  padding-top: var(--space-md);
}

#profile-root .profile-back-link {
  border-color: var(--profile-border-soft);
  color: var(--profile-chip-text);
}

#profile-root .profile-hero,
#profile-root .profile-story,
#profile-root .profile-premium-lock {
  background: linear-gradient(168deg, var(--profile-surface-strong) 0%, var(--profile-surface) 100%);
  border: 1px solid var(--profile-border-soft);
  box-shadow: 0 22px 42px rgba(2, 7, 14, 0.35);
  border-radius: var(--radius-2xl);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

#profile-root .profile-hero {
  display: grid;
  grid-template-columns: 320px 1fr;
  align-items: stretch;
  overflow: hidden;
}

#profile-root .profile-hero__media {
  position: relative;
  min-height: 380px;
}

#profile-root .profile-hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(10, 16, 25, 0.28), rgba(10, 16, 25, 0.06));
}

#profile-root .profile-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#profile-root .profile-hero__content {
  padding: clamp(22px, 3vw, 36px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--space-lg);
}

#profile-root .profile-hero__name {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.02em;
}

#profile-root .profile-meta-chips {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-sm);
}

#profile-root .profile-meta-chip {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--profile-border-soft);
  background: var(--profile-chip-bg);
  color: var(--profile-chip-text);
  min-height: 76px;
}

#profile-root .profile-meta-chip__label {
  color: var(--profile-muted);
  font-size: 0.76rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

#profile-root .profile-meta-chip strong {
  font-size: 0.98rem;
  line-height: 1.35;
  color: var(--profile-chip-text);
}

#profile-root .profile-story,
#profile-root .profile-premium-lock {
  padding: clamp(20px, 2.3vw, 30px);
}

#profile-root .profile-story__title,
#profile-root .profile-premium-lock__title {
  margin: 0;
  font-size: 1.3rem;
}

#profile-root .profile-story__preview-label {
  margin: 8px 0 0;
  color: var(--profile-muted);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

#profile-root .profile-story__text {
  margin: var(--space-sm) 0 0;
  font-size: 1.05rem;
  line-height: 1.75;
  color: rgba(237, 244, 255, 0.9);
}

#profile-root .profile-premium-lock {
  border-color: var(--profile-border-strong);
}

#profile-root .profile-premium-lock__header {
  margin-bottom: var(--space-md);
}

#profile-root .profile-premium-lock__copy {
  margin: 10px 0 0;
  max-width: 680px;
  color: var(--profile-muted);
}

#profile-root .profile-premium-lock__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--profile-border-soft);
  background: rgba(10, 16, 25, 0.5);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  margin-bottom: var(--space-md);
}

#profile-root .profile-premium-lock__label {
  color: var(--profile-muted);
  font-size: 0.88rem;
}

#profile-root .profile-premium-lock__value {
  color: var(--profile-chip-text);
  font-weight: 600;
  letter-spacing: 0.02em;
}

#profile-root .profile-premium-lock__cta[disabled] {
  width: 100%;
  opacity: 0.82;
  cursor: not-allowed;
  filter: saturate(0.82);
}

@media (max-width: 940px) {
  #profile-root .profile-hero {
    grid-template-columns: 1fr;
  }

  #profile-root .profile-hero__media {
    min-height: 300px;
  }

  #profile-root .profile-meta-chips {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  #profile-root .profile-shell {
    gap: var(--space-md);
  }

  #profile-root .profile-story__text {
    font-size: 1rem;
  }

  #profile-root .profile-premium-lock__row {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
}

.profile-detail {
  max-width: 800px;
  margin: 0 auto;
  background: var(--color-bg-card);
  backdrop-filter: blur(var(--blur-strong));
  -webkit-backdrop-filter: blur(var(--blur-strong));
  border-radius: var(--radius-3xl);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.8);
}

.profile-detail__header {
  display: flex;
  gap: var(--space-lg);
  padding: var(--space-lg);
  align-items: flex-start;
  background: rgba(248, 250, 252, 0.5);
  border-bottom: 1px solid var(--color-border-glass);
}

.profile-detail__photo {
  flex-shrink: 0;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--color-bg-card);
  box-shadow: var(--shadow);
  animation: profilePhotoSlideIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.profile-detail__photo img,
#profile-root .bento-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@keyframes profilePhotoSlideIn {
  from {
    opacity: 0;
    transform: translate(-60px, -20px) scale(0.85);
  }

  to {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
}

.profile-detail__video {
  flex: 1;
  min-height: 200px;
  background: rgba(226, 232, 240, 0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  animation: profileVideoFadeIn 0.5s ease 0.2s both;
}

@keyframes profileVideoFadeIn {
  from {
    opacity: 0;
    transform: translateX(20px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.profile-detail__video-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

.profile-detail__video-placeholder svg {
  width: 64px;
  height: 64px;
  opacity: 0.5;
}

.profile-detail__body {
  padding: var(--space-xl);
  text-align: center;
  animation: profileBodySlideUp 0.5s ease 0.25s both;
}

@keyframes profileBodySlideUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.profile-detail__name {
  margin: 0 0 var(--space-xs);
}

.profile-detail__meta {
  font-size: 0.95rem;
  color: var(--color-primary);
  margin-bottom: var(--space-lg);
}

.profile-detail__bio {
  margin-bottom: var(--space-xl);
  text-align: center;
}

.profile-detail__bio p {
  margin-bottom: var(--space-md);
  text-align: center;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

.profile-detail .btn {
  margin-top: var(--space-md);
}

.profile-detail .btn-wrapper {
  display: flex;
  justify-content: center;
}

/* --- Contact page --- */
.contact-section {
  padding: calc(var(--space-3xl) + 20px) 0 var(--space-3xl);
  /* Reduced top padding significantly */
  max-width: 600px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: var(--space-xs);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 16px 20px;
  font-family: var(--font-body);
  font-size: 1.05rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-input-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--color-text);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.03);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  background: var(--color-input-bg-strong);
  box-shadow: 0 0 0 4px var(--color-ring), inset 0 1px 2px rgba(0, 0, 0, 0.01);
  transform: translateY(-2px);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

/* --- Contact modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--color-overlay-strong);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.modal {
  position: relative;
  background: var(--color-bg-card);
  backdrop-filter: saturate(180%) blur(var(--blur-strong));
  -webkit-backdrop-filter: saturate(180%) blur(var(--blur-strong));
  border-radius: var(--radius-2xl);
  padding: var(--space-xl);
  max-width: 480px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-hover);
  border: 1px solid var(--color-border-glass-strong);
  border-top: 1px solid rgba(255, 255, 255, 1);
  border-left: 1px solid rgba(255, 255, 255, 0.9);
}

.modal h2 {
  margin-top: 0;
  margin-bottom: var(--space-lg);
}

.modal-close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

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

.signup-gate-modal__dialog {
  max-width: 540px;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0) 42%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.96), rgba(244, 247, 255, 0.9));
}

.signup-gate-modal__eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.08);
  color: var(--color-primary);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: var(--space-md);
}

.signup-gate-modal__copy {
  color: var(--color-text-muted);
  line-height: 1.7;
  margin: 0 0 var(--space-xl);
}

.signup-gate-modal__actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.signup-gate-modal__dismiss {
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0;
  margin-top: var(--space-lg);
  cursor: pointer;
}

.signup-gate-modal__dismiss:hover {
  color: var(--color-text);
}

/* --- Mentor Matching Chatbot (Flat & Elegant) --- */
.minba-chatbot {
  position: fixed;
  right: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  z-index: 950;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  font-family: var(--font-body);
}

.chatbot-panel-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(3, 8, 20, 0.28);
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.35s ease, backdrop-filter 0.35s ease, -webkit-backdrop-filter 0.35s ease, visibility 0.35s ease;
  z-index: -1;
}

.chatbot-panel-backdrop.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.chatbot-nudge {
  width: min(340px, calc(100vw - 32px));
  padding: 18px 20px;
  border-radius: 12px 12px 2px 12px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
}

.chatbot-nudge[hidden] {
  display: none;
}

.chatbot-nudge__label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-primary);
  line-height: 1.2;
}

.chatbot-nudge__prompt,
.chatbot-chip,
.chatbot-panel__ghost,
.chatbot-form__send,
.chatbot-launcher,
.chatbot-link-action {
  font: inherit;
  border: none;
  cursor: pointer;
  margin: 0;
  outline: none;
}

.chatbot-nudge__prompt {
  width: 100%;
  padding: 14px 18px;
  border-radius: 8px;
  text-align: left;
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--color-text);
  background: #f8fafc;
  border: 1px solid rgba(0, 0, 0, 0.04);
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.chatbot-nudge__prompt:hover,
.chatbot-chip:hover,
.chatbot-panel__ghost:hover,
.chatbot-launcher:hover {
  transform: translateY(-2px);
}

.chatbot-nudge__prompt:hover {
  background: #f1f5f9;
}

/* Launcher */
.chatbot-launcher {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  min-width: unset;
  width: 66px;
  height: 66px;
  padding: 0;
  border-radius: 999px;
  color: #ffffff;
  background:
    radial-gradient(circle at 28% 22%, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 50%),
    linear-gradient(145deg, #0f172a 0%, #12263e 45%, #1f6c81 100%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow:
    0 18px 38px rgba(2, 8, 23, 0.42),
    0 0 0 1px rgba(20, 184, 166, 0.18);
  transition: transform 0.24s ease, box-shadow 0.24s ease, filter 0.24s ease;
  animation: chatbotAIPulse 4s ease-in-out infinite;
}

.chatbot-launcher:hover {
  animation-play-state: paused;
  transform: translateY(-2px) scale(1.04);
  filter: saturate(1.08);
  box-shadow:
    0 22px 44px rgba(2, 8, 23, 0.48),
    0 0 0 1px rgba(45, 212, 191, 0.28),
    0 0 22px rgba(20, 184, 166, 0.2);
}

@keyframes chatbotAIPulse {
  0%, 100% {
    box-shadow:
      0 16px 34px rgba(2, 8, 23, 0.42),
      0 0 0 1px rgba(20, 184, 166, 0.16);
  }
  50% {
    box-shadow:
      0 20px 42px rgba(2, 8, 23, 0.5),
      0 0 0 4px rgba(20, 184, 166, 0.12),
      0 0 18px rgba(20, 184, 166, 0.2);
  }
}

.chatbot-launcher:focus-visible,
.chatbot-nudge__prompt:focus-visible,
.chatbot-chip:focus-visible,
.chatbot-picker__input:focus-visible,
.chatbot-picker-option:focus-visible,
.chatbot-panel__ghost:focus-visible,
.chatbot-form__input:focus-visible,
.chatbot-form__send:focus-visible {
  box-shadow: 0 0 0 3px var(--color-ring);
}

.chatbot-launcher__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: inherit;
  flex-shrink: 0;
}

.chatbot-launcher__core {
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.chatbot-launcher__core svg {
  width: 25px;
  height: 25px;
}

.chatbot-launcher__copy {
  display: none;
}

.chatbot-launcher__eyebrow {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-primary);
  line-height: 1.2;
}

.chatbot-launcher__text {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
}

/* Panel */
.chatbot-panel {
  position: absolute;
  right: 0;
  bottom: calc(100% + 12px);
  width: min(420px, calc(100vw - 32px));
  max-height: min(640px, calc(100vh - 120px));
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px;
  border-radius: 24px;
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.95), rgba(248, 252, 255, 0.9));
  border: 1px solid rgba(15, 23, 42, 0.1);
  box-shadow: 0 24px 68px rgba(2, 8, 23, 0.18);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(18px) scale(0.94);
  filter: blur(3px);
  transform-origin: bottom right;
  transition: opacity 0.34s cubic-bezier(0.16, 1, 0.3, 1), transform 0.34s cubic-bezier(0.16, 1, 0.3, 1), filter 0.34s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.34s ease;
  overflow: hidden;
}

.chatbot-panel.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.chatbot-panel--picker-step .chatbot-messages {
  min-height: 140px;
  max-height: 220px;
}

.chatbot-is-open .chatbot-launcher {
  animation-play-state: paused;
  transform: translateY(2px) scale(0.95);
  box-shadow:
    0 10px 24px rgba(2, 8, 23, 0.36),
    0 0 0 1px rgba(20, 184, 166, 0.12);
}

/* Panel header */
.chatbot-panel__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.chatbot-panel__identity {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.chatbot-panel__badge {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #ffffff;
  font-weight: 700;
  font-size: 1.1rem;
  background: linear-gradient(145deg, #0f172a 0%, #1f6c81 100%);
}

.chatbot-panel__title-wrap {
  min-width: 0;
}

.chatbot-panel__eyebrow {
  display: none;
  align-items: center;
  margin-bottom: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  line-height: 1.2;
}

.chatbot-panel__title {
  margin: 0 0 2px;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text);
}

.chatbot-panel__subtitle {
  display: none;
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--color-text-muted);
}

.chatbot-panel__actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.chatbot-panel__ghost {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  background: transparent;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.chatbot-panel__ghost:hover {
  color: var(--color-text);
  background: #f1f5f9;
}

/* Messages */
.chatbot-messages {
  min-height: 220px;
  max-height: 380px;
  overflow-y: auto;
  padding-right: 8px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  scroll-behavior: smooth;
}

.chatbot-messages::-webkit-scrollbar {
  width: 6px;
}

.chatbot-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chatbot-messages::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 6px;
}

.chatbot-message {
  display: flex;
  flex-direction: column;
  width: 100%;
  animation: chatMsgIn 0.3s ease both;
}

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

.chatbot-message--assistant {
  align-items: flex-start;
}

.chatbot-message--user {
  align-items: flex-end;
}

.chatbot-message__bubble {
  max-width: 88%;
  padding: 14px 18px;
  border-radius: 16px 16px 16px 8px;
  background: #eef4f8;
  color: var(--color-text);
  font-size: 0.95rem;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.chatbot-message--user .chatbot-message__bubble {
  color: #ffffff;
  border-radius: 16px 16px 8px 16px;
  background: linear-gradient(145deg, #0f172a 0%, #1d3a56 100%);
}

.chatbot-message__bubble--typing {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 16px 20px;
}

/* Typewriter cursor */
.chatbot-message__bubble--streaming::after {
  content: '';
  display: inline-block;
  width: 2px;
  height: 1em;
  background: currentColor;
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: chatbotCursor 0.6s ease-in-out infinite;
}

@keyframes chatbotCursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.chatbot-typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-text-muted);
  animation: chatbotTyping 1.4s infinite ease-in-out both;
}

.chatbot-typing-dot:nth-child(1) { animation-delay: -0.32s; }
.chatbot-typing-dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes chatbotTyping {
  0%, 80%, 100% { transform: scale(0); }
  40% { transform: scale(1); }
}

/* Mentor result cards */
.chatbot-mentors-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
  width: 100%;
}

.chatbot-mentor-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: 14px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  text-decoration: none;
  color: var(--color-text);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  animation: chatMsgIn 0.3s ease both;
}

.chatbot-mentor-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 0, 0, 0.15);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.chatbot-mentor-card__avatar {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: #e2e8f0;
}

.chatbot-mentor-card__info {
  flex: 1;
  min-width: 0;
}

.chatbot-mentor-card__name {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--color-text);
  margin: 0;
}

.chatbot-mentor-card__meta {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.4;
  margin-top: 2px;
}

.chatbot-mentor-card__arrow {
  flex-shrink: 0;
  font-size: 1.2rem;
  color: var(--color-text-muted);
  transition: color 0.2s ease;
}

.chatbot-mentor-card:hover .chatbot-mentor-card__arrow {
  color: var(--color-text);
}

.chatbot-mentor-card__content {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

.chatbot-mentor-card--locked {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.chatbot-mentor-card--locked .chatbot-mentor-card__content {
  filter: blur(6px);
  pointer-events: none;
  user-select: none;
}

.chatbot-mentor-card__lock {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.55);
  color: var(--color-text);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  backdrop-filter: saturate(1.1);
}

.chatbot-mentor-card__lock-icon {
  font-size: 1rem;
}

.chatbot-mentor-card--locked:hover .chatbot-mentor-card__lock {
  background: rgba(255, 255, 255, 0.7);
}

body[data-theme="dark"] .chatbot-mentor-card__lock {
  background: rgba(15, 23, 42, 0.55);
  color: #f1f5f9;
}

body[data-theme="dark"] .chatbot-mentor-card--locked:hover .chatbot-mentor-card__lock {
  background: rgba(15, 23, 42, 0.72);
}

/* No results */
.chatbot-no-results {
  padding: 18px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px dashed rgba(0, 0, 0, 0.15);
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* Chips */
.chatbot-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chatbot-chips--picker {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.chatbot-chip {
  padding: 12px 16px;
  border-radius: 999px;
  color: var(--color-text);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.4;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.15);
  transition: all 0.2s ease;
}

.chatbot-chip:hover {
  background: #f8fafc;
  border-color: rgba(0, 0, 0, 0.3);
}

.chatbot-picker {
  display: grid;
  gap: 12px;
  min-height: 0;
}

.chatbot-picker__search {
  position: relative;
}

.chatbot-picker__input {
  width: 100%;
  padding: 14px 16px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--color-text);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 248, 251, 0.98));
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 14px;
  line-height: 1.5;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.chatbot-picker__input:focus {
  outline: none;
  border-color: rgba(15, 23, 42, 0.32);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.chatbot-picker__list {
  display: grid;
  gap: 10px;
  max-height: min(240px, 32vh);
  padding-right: 4px;
  overflow-y: auto;
}

.chatbot-picker__list::-webkit-scrollbar {
  width: 6px;
}

.chatbot-picker__list::-webkit-scrollbar-track {
  background: transparent;
}

.chatbot-picker__list::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, 0.16);
  border-radius: 999px;
}

.chatbot-picker-option {
  width: 100%;
  padding: 14px 16px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-align: left;
  color: var(--color-text);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 248, 251, 0.96));
  border: 1px solid rgba(15, 23, 42, 0.1);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.chatbot-picker-option:hover {
  transform: translateY(-1px);
  border-color: rgba(15, 23, 42, 0.22);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(241, 247, 250, 1));
}

.chatbot-picker-option__text {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.chatbot-picker-option__label {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.35;
}

.chatbot-picker-option__meta {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #0f766e;
}

.chatbot-picker-option__arrow {
  flex-shrink: 0;
  font-size: 1.05rem;
  color: var(--color-text-muted);
  transition: transform 0.2s ease, color 0.2s ease;
}

.chatbot-picker-option:hover .chatbot-picker-option__arrow {
  transform: translateX(2px);
  color: var(--color-text);
}

.chatbot-picker__empty {
  padding: 18px;
  border-radius: 16px;
  text-align: center;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--color-text-muted);
  background: rgba(248, 250, 252, 0.9);
  border: 1px dashed rgba(15, 23, 42, 0.14);
}

/* Input form */
.chatbot-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding-top: 4px;
}

.chatbot-form__input {
  width: 100%;
  padding: 14px 16px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--color-text);
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  line-height: 1.5;
}

.chatbot-form__input:focus {
  outline: none;
  border-color: var(--color-text);
  box-shadow: 0 0 0 1px var(--color-text);
}

.chatbot-form__input:disabled,
.chatbot-form__send:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.chatbot-form__send {
  min-width: 90px;
  padding: 14px 18px;
  border-radius: 12px;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.95rem;
  background: linear-gradient(145deg, #0f172a 0%, #1d3a56 100%);
  transition: background-color 0.2s ease;
}

.chatbot-form__send:hover:not(:disabled) {
  background: #000000;
}

.chatbot-live-region {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Dark mode overrides */
body[data-theme="dark"] .chatbot-nudge {
  background: #1e293b;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

body[data-theme="dark"] .chatbot-nudge__prompt {
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.05);
}

body[data-theme="dark"] .chatbot-nudge__prompt:hover,
body[data-theme="dark"] .chatbot-chip:hover,
body[data-theme="dark"] .chatbot-panel__ghost:hover {
  background: #334155;
  border-color: rgba(255, 255, 255, 0.2);
}

body[data-theme="dark"] .chatbot-launcher {
  background:
    radial-gradient(circle at 26% 20%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 48%),
    linear-gradient(145deg, #0b1325 0%, #0f2740 50%, #165a6b 100%);
  color: #e6f4ff;
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.54),
    0 0 0 1px rgba(45, 212, 191, 0.16);
}

body[data-theme="dark"] .chatbot-panel-backdrop {
  background: rgba(2, 6, 16, 0.44);
}

body[data-theme="dark"] .chatbot-panel {
  background: linear-gradient(165deg, rgba(15, 23, 42, 0.96), rgba(22, 31, 52, 0.94));
  border-color: rgba(148, 163, 184, 0.22);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}

body[data-theme="dark"] .chatbot-panel__badge {
  background: linear-gradient(145deg, #0f2740 0%, #176576 100%);
}

body[data-theme="dark"] .chatbot-panel__header {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

body[data-theme="dark"] .chatbot-message__bubble {
  background: #27364c;
}

body[data-theme="dark"] .chatbot-message--user .chatbot-message__bubble {
  background: linear-gradient(145deg, #0f2740 0%, #176576 100%);
  color: #f8fdff;
}

body[data-theme="dark"] .chatbot-mentor-card {
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.1);
}

body[data-theme="dark"] .chatbot-mentor-card:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: #1e293b;
}

body[data-theme="dark"] .chatbot-mentor-card__avatar {
  background: #334155;
}

body[data-theme="dark"] .chatbot-no-results {
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.1);
}

body[data-theme="dark"] .chatbot-chip {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.15);
}

body[data-theme="dark"] .chatbot-picker__input {
  color: #f8fafc;
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.15);
}

body[data-theme="dark"] .chatbot-picker__input:focus {
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.3);
}

body[data-theme="dark"] .chatbot-picker__list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
}

body[data-theme="dark"] .chatbot-picker-option {
  color: #f8fafc;
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
}

body[data-theme="dark"] .chatbot-picker-option:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: #1e293b;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .chatbot-picker-option__meta {
  color: #5eead4;
}

body[data-theme="dark"] .chatbot-picker__empty {
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.1);
}

body[data-theme="dark"] .chatbot-form__input {
  background: #0f172a;
  border-color: rgba(255, 255, 255, 0.15);
}

body[data-theme="dark"] .chatbot-form__input:focus {
  border-color: #ffffff;
  box-shadow: 0 0 0 1px #ffffff;
}

body[data-theme="dark"] .chatbot-form__send {
  background: linear-gradient(145deg, #0f2740 0%, #176576 100%);
  color: #f8fdff;
}

body[data-theme="dark"] .chatbot-form__send:hover:not(:disabled) {
  background: linear-gradient(145deg, #12314e 0%, #1a7d90 100%);
}

body[data-theme="dark"] .chatbot-messages::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
}

/* --- Contact page (standalone) --- */
.contact-page {
  padding: 120px 0 var(--space-3xl);
}

.contact-page .split-hero {
  justify-content: flex-start;
}

.contact-page .split-hero__container {
  align-items: start;
}

.contact-page h1 {
  text-align: center;
  margin-bottom: var(--space-md);
}

.contact-page .lead {
  text-align: center;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--space-xl);
}

.contact-page .split-hero__left {
  max-width: 640px;
  justify-self: start;
}

.contact-page .page-header {
  max-width: 620px;
  padding: 0 0 var(--space-md);
  text-align: left;
}

.contact-page .page-header h1 {
  text-align: left;
  margin-bottom: var(--space-sm);
}

.contact-page .page-header .lead {
  max-width: 560px;
  margin: 0;
  text-align: left;
  color: var(--color-text-muted);
}

.contact-page .page-header .page-header__badge {
  margin-bottom: var(--space-sm);
}

.contact-page .bento-grid {
  max-width: 560px;
}

/* --- Footer --- */
.site-footer {
  padding: var(--space-xl) 0;
  border-top: 1px solid var(--color-border-glass);
  text-align: center;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-top: var(--space-3xl);
}

/* ============================================
   Scroll-reveal animations
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.reveal--left {
  transform: translateX(-36px);
}

.reveal.reveal--right {
  transform: translateX(36px);
}

.reveal.reveal--scale {
  transform: scale(0.92);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Staggered children */
.reveal-group .reveal:nth-child(1) {
  transition-delay: 0.05s;
}

.reveal-group .reveal:nth-child(2) {
  transition-delay: 0.15s;
}

.reveal-group .reveal:nth-child(3) {
  transition-delay: 0.25s;
}

.reveal-group .reveal:nth-child(4) {
  transition-delay: 0.35s;
}

/* ============================================
   Cursor glow
   ============================================ */
.cursor-glow {
  display: none;
  /* Disable cursor glow */
}

.is-hidden-reserved {
  visibility: hidden;
}

.is-hidden {
  display: none !important;
}

/* ============================================
   Floating particles canvas
   ============================================ */
#particle-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
}

/* Hero typewriter cursor */
.typewriter-cursor {
  display: inline-block;
  width: 3px;
  background: var(--color-primary);
  margin-left: 2px;
  animation: blink 0.9s step-end infinite;
  border-radius: 2px;
  vertical-align: middle;
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

/* --- Responsive --- */
@media (max-width: 990px) {
  .split-hero__container {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
    padding-top: var(--space-lg);
  }

  .split-hero__right {
    order: -1;
    /* Keep text on top for mobile */
    align-items: center;
    text-align: center;
  }

  .hero__badge {
    align-self: center;
  }

  .split-hero__right h1,
  .split-hero__right .lead,
  .split-hero__right .hero__sub {
    text-align: center;
  }

  .split-hero__actions {
    justify-content: center;
  }

  .split-hero__actions .btn {
    align-self: center;
  }
}

@media (max-width: 640px) {
  .minba-chatbot {
    right: 12px;
    left: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    align-items: stretch;
  }

  .chatbot-launcher {
    align-self: flex-end;
  }

  .chatbot-panel {
    width: calc(100vw - 24px);
    max-height: min(70vh, 560px);
    right: 0;
    bottom: calc(100% + 12px);
    transform-origin: bottom center;
  }

  .chatbot-nudge {
    align-self: flex-end;
    width: min(320px, calc(100vw - 24px));
  }

  .chatbot-panel--picker-step .chatbot-messages {
    min-height: 120px;
    max-height: 180px;
  }

  .chatbot-picker__list {
    max-height: min(210px, 28vh);
  }

  .site-header .container {
    align-items: flex-start;
    padding-right: var(--space-lg);
  }

  .header-actions {
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: min(100%, 240px);
  }

  .pill-toggle__button {
    padding: 0.48rem 0.75rem;
    font-size: 0.72rem;
  }

  .hero {
    padding: var(--space-xl) 0 var(--space-lg);
  }

  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
  }

  .stat-card {
    padding: var(--space-lg);
  }

  .stat-card__value {
    font-size: 1.5rem;
  }

  .chart__bars {
    min-height: 140px;
  }

  .chart__bar {
    max-width: 36px;
  }

  .how-it-works__grid {
    grid-template-columns: 1fr;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .profile-detail__header {
    flex-direction: column;
    align-items: center;
  }

  .profile-detail__photo {
    width: 80px;
    height: 80px;
  }

  .profile-detail__video {
    min-height: 160px;
    width: 100%;
  }

  .profile-detail__body,
  .modal {
    padding: var(--space-lg);
  }
}

@media (max-width: 480px) {
  .chatbot-panel__header {
    flex-direction: column;
  }

  .chatbot-panel__actions {
    width: 100%;
    justify-content: flex-start;
  }

  .chatbot-picker-option {
    padding: 13px 14px;
  }

  .chatbot-picker-option__label {
    font-size: 0.9rem;
  }

  .container {
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .header-actions {
    max-width: 210px;
  }
}

/* --- Section titles --- */
.section-title {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.section-title h2 {
  margin-bottom: var(--space-sm);
}

.section-title p {
  margin: 0;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Page header (browse, contact) – community feel --- */
.page-header {
  padding: var(--space-2xl) 0 var(--space-lg);
  text-align: center;
}

.page-header h1 {
  margin-bottom: var(--space-sm);
}

.page-header .lead {
  margin: 0;
  color: var(--color-text-muted);
}

.page-header .page-header__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: 0.8rem;
  color: var(--color-primary);
  margin-bottom: var(--space-md);
  padding: var(--space-xs) var(--space-md);
  background: var(--color-bg-glass);
  backdrop-filter: blur(12px);
  border: 1px solid var(--color-border-glass);
  border-radius: 999px;
}

.page-header__badge svg {
  width: 1rem;
  height: 1rem;
}

/* --- Empty state --- */
.empty-state {
  text-align: center;
  padding: var(--space-3xl) var(--space-lg);
  color: var(--color-text-muted);
}

.empty-state p {
  margin-bottom: var(--space-md);
}

/* --- Illustrations Section --- */
.illustrations-section {
  padding: var(--space-2xl) 0 var(--space-xl);
  position: relative;
  z-index: 2;
}

.illustrations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
  align-items: stretch;
}

.illustration-card {
  background: var(--color-bg-card);
  backdrop-filter: saturate(180%) blur(var(--blur));
  -webkit-backdrop-filter: saturate(180%) blur(var(--blur));
  border-radius: var(--radius-2xl);
  padding: var(--space-lg);
  border: 1px solid var(--color-border-glass-strong);
  border-top: 1px solid rgba(255, 255, 255, 1);
  border-left: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-glass);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.illustration-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(255, 255, 255, 1);
  background: var(--color-bg-glass-strong);
  box-shadow: var(--shadow-hover);
}

.illustration-card img {
  width: 100%;
  max-width: 200px;
  /* Limit image size if it's too big */
  height: auto;
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-md);
  object-fit: contain;
}

.illustration-card h3 {
  font-size: 1.1rem;
  margin: 0;
  color: var(--color-text);
}

body[data-theme="dark"] .hero__badge,
body[data-theme="dark"] .features__eyebrow,
body[data-theme="dark"] .page-header__badge,
body[data-theme="dark"] .page-header .page-header__badge {
  background: rgba(18, 30, 47, 0.82);
  border-color: rgba(148, 163, 184, 0.16);
}

body[data-theme="dark"] .bento-item,
body[data-theme="dark"] .stat-card,
body[data-theme="dark"] .profile-detail,
body[data-theme="dark"] .chart,
body[data-theme="dark"] .how-card,
body[data-theme="dark"] .modal,
body[data-theme="dark"] .illustration-card {
  border-color: rgba(148, 163, 184, 0.18);
  border-top-color: rgba(255, 255, 255, 0.06);
  border-left-color: rgba(255, 255, 255, 0.05);
}

body[data-theme="dark"] .bento-item:hover,
body[data-theme="dark"] .stat-card:hover,
body[data-theme="dark"] .how-card:hover,
body[data-theme="dark"] .illustration-card:hover {
  background: rgba(20, 33, 51, 0.96);
  border-color: rgba(148, 163, 184, 0.22);
}

body[data-theme="dark"] .bento-item__img-wrap,
body[data-theme="dark"] .bento-item__multi-img-wrap,
body[data-theme="dark"] .profile-detail__header,
body[data-theme="dark"] .profile-detail__video {
  background: rgba(13, 22, 35, 0.9);
}

body[data-theme="dark"] .multi-img-item,
body[data-theme="dark"] .bento-item__img-wrap img,
body[data-theme="dark"] .stat-card__icon {
  background: rgba(20, 33, 51, 0.96);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .stat-card__icon {
  color: var(--color-primary);
}

body[data-theme="dark"] .search-input,
body[data-theme="dark"] .browse-select,
body[data-theme="dark"] .form-group input,
body[data-theme="dark"] .form-group textarea {
  border-color: rgba(148, 163, 184, 0.16);
}

body[data-theme="dark"] .browse-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23d8e3f4' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
}

body[data-theme="dark"] .profile-card__avatar {
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
}

body[data-theme="dark"] .chart__bar--active {
  box-shadow: 0 -2px 18px rgba(73, 224, 197, 0.34);
}

body[data-theme="dark"] .site-footer {
  border-top-color: rgba(148, 163, 184, 0.14);
}

body[data-theme="dark"] #particle-canvas {
  opacity: 0.28;
}

/* =============================================
   GLOBE EXPERIENCE – Home Page
   Apple-style scroll-driven 3D globe layout
   Globe at bottom center, rotates on scroll
   ============================================= */

/* --- Force dark cinematic aesthetic on home --- */
body[data-page="home"] {
  background: #050508;
  overflow-x: hidden;
}

body[data-page="home"]::before,
body[data-page="home"]::after {
  display: none;
}

body[data-page="home"] .noise-overlay {
  display: none;
}

body[data-page="home"] .site-footer {
  min-height: auto;
  padding: var(--space-xl) 0;
  background: transparent;
  border: none;
}

body[data-page="home"] .site-footer span {
  color: rgba(255, 255, 255, 0.25);
}

/* --- Globe Canvas Container — fixed, full viewport --- */
.globe-wrap {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

/* Top vignette for text readability above globe */
.globe-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    rgba(5, 5, 8, 0.6) 0%,
    rgba(5, 5, 8, 0.15) 35%,
    transparent 55%,
    transparent 100%
  );
}

/* Red ambient glow behind globe at bottom */
.globe-wrap::after {
  content: '';
  position: absolute;
  bottom: -10%;
  left: 50%;
  transform: translateX(-50%);
  width: 56vmin;
  height: 56vmin;
  background: radial-gradient(
    circle,
    rgba(20, 184, 166, 0.12) 0%,
    rgba(20, 184, 166, 0.06) 28%,
    rgba(20, 184, 166, 0.025) 48%,
    transparent 74%
  );
  pointer-events: none;
  z-index: 0;
  filter: blur(6px);
}

/* --- Slide 4 (IMPACT): globe takes the whole right side --- */
@media (min-width: 991px) {
  body[data-page="home"] #globe-canvas {
    transform-origin: 85% 58%;
    transition: transform 620ms cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
  }

  body[data-page="home"].is-impact #globe-canvas {
    transform: translateX(28vw) scale(1.9);
  }

  body[data-page="home"].is-impact .globe-wrap::before {
    background: linear-gradient(
      to left,
      rgba(5, 5, 8, 0.35) 0%,
      rgba(5, 5, 8, 0.08) 28%,
      transparent 55%,
      transparent 100%
    );
  }

  body[data-page="home"].is-impact .globe-wrap::after {
    left: auto;
    right: -18%;
    transform: none;
    width: 120vmin;
    height: 120vmin;
  }

  body[data-page="home"].is-impact #gs-impact {
    padding-left: 42vw;
    padding-right: clamp(18px, 6vw, 84px);
    justify-content: flex-end;
  }

  body[data-page="home"].is-impact #gs-impact .gs__inner {
    text-align: right;
    margin-left: auto;
    margin-right: 0;
    max-width: 560px;
  }

  body[data-page="home"].is-impact #gs-impact .gs-impact-grid {
    margin-left: auto;
    margin-right: 0;
  }
}

#globe-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* --- Header overrides for dark home bg --- */
body[data-page="home"] .site-header {
  position: fixed;
  transition: background 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

body[data-page="home"] .site-header.is-scrolled {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

body[data-page="home"] .logo {
  color: #ffffff;
}

body[data-page="home"] .logo:hover {
  color: #CC0000;
}

body[data-page="home"] .pill-toggle--theme {
  display: flex;
}

body[data-page="home"] .pill-toggle {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"] .pill-toggle__button {
  color: rgba(255, 255, 255, 0.45);
}

body[data-page="home"] .pill-toggle__button:hover {
  color: rgba(255, 255, 255, 0.8);
}

body[data-page="home"] .pill-toggle__button.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

body[data-page="home"] .menu-toggle {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"] .menu-toggle span {
  background: #ffffff;
}

body[data-page="home"] .menu-toggle.active span {
  background: #CC0000;
}

/* --- Cursor glow on home --- */
body[data-page="home"] .cursor-glow {
  background: radial-gradient(circle, rgba(204, 0, 0, 0.04) 0%, transparent 70%);
}

body[data-page="home"][data-theme="dark"] .logo:hover {
  color: var(--color-primary);
}

body[data-page="home"][data-theme="dark"] .menu-toggle.active span {
  background: var(--color-primary);
}

body[data-page="home"][data-theme="dark"] .cursor-glow {
  background: radial-gradient(circle, rgba(73, 224, 197, 0.08) 0%, transparent 70%);
}

/* ═══════════════════════════════════════════
   GLOBE SECTIONS — each visually distinct
   Text in upper portion, globe at bottom
   ═══════════════════════════════════════════ */

/* --- Section Base --- */
.gs {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 12vh var(--space-lg) 0;
}

.gs__inner {
  max-width: 900px;
  width: 100%;
  text-align: center;
  will-change: transform, opacity;
}

/* --- Light text for all sections --- */
body[data-page="home"] .gs h1,
body[data-page="home"] .gs h2,
body[data-page="home"] .gs h3 {
  color: #ffffff;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6);
}

body[data-page="home"] .gs p {
  color: rgba(255, 255, 255, 0.72);
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.5);
}

/* --- Eyebrow label --- */
.gs__eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: #CC0000;
  margin-bottom: var(--space-lg);
  position: relative;
  padding-left: 28px;
}

.gs__eyebrow::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 1.5px;
  background: #CC0000;
}

body[data-page="home"][data-theme="dark"] .gs__eyebrow {
  color: var(--color-primary);
}

body[data-page="home"][data-theme="dark"] .gs__eyebrow::before {
  background: var(--color-primary);
}

/* ─── HERO ─── */
.gs--hero {
  min-height: 100vh;
  align-items: center;
  padding-top: 4vh;
  position: relative;
}

.gs--hero .gs__inner {
  max-width: 780px;
  padding-bottom: 22vh;
}

.gs--hero h1 {
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: -0.05em;
  margin-bottom: var(--space-xl);
  max-width: 850px;
  margin-left: auto;
  margin-right: auto;
  background: linear-gradient(160deg, #ffffff 20%, rgba(255, 255, 255, 0.4) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 2px 20px rgba(0, 0, 0, 0.5));
}

.gs__lead {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.75;
  max-width: 520px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.35) !important;
  font-family: "DM Sans", "Inter", sans-serif;
}

/* Scroll Hint */
.scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: opacity 0.3s ease;
}

.scroll-hint__line {
  width: 1px;
  height: 52px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.4), transparent);
  animation: scrollLinePulse 2s ease-in-out infinite;
}

@keyframes scrollLinePulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.6); transform-origin: top; }
  50% { opacity: 0.8; transform: scaleY(1); }
}

/* ─── DISCOVER ─── */
.gs--discover {
  align-items: flex-start;
  justify-content: flex-end;
  padding-top: 6vh;
  padding-right: clamp(18px, 6vw, 84px);
}

.gs--discover .gs__inner {
  max-width: 560px;
  text-align: right;
  margin-left: auto;
  margin-right: 0;
}

.gs--discover h2 {
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  margin-bottom: var(--space-3xl);
  line-height: 1.1;
}

.gs-routes {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 420px;
  margin: 0 0 0 auto;
}

.gs-route {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.4s ease;
}

.gs-route:last-child {
  border-bottom: none;
}

.gs-route:hover {
  padding-left: var(--space-md);
}

.gs-route__from {
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  min-width: 80px;
  text-align: right;
}

.gs-route__arrow {
  color: var(--color-primary);
  opacity: 0.5;
  display: flex;
  align-items: center;
}

.gs-route__to {
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff;
  min-width: 100px;
  text-align: left;
}

.gs-route:hover .gs-route__arrow { opacity: 1; }
.gs-route:hover .gs-route__to { color: var(--color-primary); }

body[data-page="home"][data-theme="dark"] .gs-route__arrow,
body[data-page="home"][data-theme="dark"] .gs-route:hover .gs-route__to {
  color: var(--color-primary);
}

/* ─── CONNECT ─── */
.gs--connect {
  align-items: flex-start;
  padding-top: 15vh;
}

.gs-quote {
  margin: 0 auto var(--space-3xl);
  max-width: 680px;
}

.gs-quote p {
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(1.4rem, 3.5vw, 2.4rem);
  font-weight: 400;
  font-style: italic;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.75) !important;
  text-shadow: none !important;
}

.gs-quote cite {
  display: block;
  margin-top: var(--space-lg);
  font-size: 0.85rem;
  font-style: normal;
  font-weight: 600;
  color: var(--color-primary);
  letter-spacing: 0.02em;
}

body[data-page="home"][data-theme="dark"] .gs-quote cite {
  color: var(--color-primary);
}

.gs-connect-stats {
  display: flex;
  justify-content: center;
  gap: var(--space-3xl);
}

.gs-connect-stat {
  text-align: center;
}

.gs-connect-stat__value {
  display: block;
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #ffffff;
}

.gs-connect-stat__label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.3);
  margin-top: var(--space-xs);
}

/* ─── IMPACT ─── */
.gs--impact {
  align-items: flex-start;
  padding-top: 15vh;
}

.gs-impact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  max-width: 560px;
  margin: var(--space-3xl) auto 0;
}

.gs-impact-card {
  padding: var(--space-xl) var(--space-lg);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  text-align: center;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.gs-impact-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(204, 0, 0, 0.2);
  transform: translateY(-4px);
}

.gs-impact-card--wide {
  grid-column: 1 / -1;
  border-color: rgba(204, 0, 0, 0.15);
  background: rgba(204, 0, 0, 0.04);
}

.gs-impact-card__number {
  display: block;
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #ffffff 20%, var(--color-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

body[data-page="home"][data-theme="dark"] .gs-impact-card:hover {
  border-color: rgba(73, 224, 197, 0.22);
}

body[data-page="home"][data-theme="dark"] .gs-impact-card--wide {
  border-color: rgba(73, 224, 197, 0.16);
  background: rgba(73, 224, 197, 0.05);
}

body[data-page="home"][data-theme="dark"] .gs-impact-card__number {
  background: linear-gradient(135deg, #ffffff 20%, #49E0C5 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gs-impact-card__number--large {
  font-size: clamp(3rem, 6vw, 5rem);
}

.gs-impact-card__text {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.35);
  margin-top: var(--space-xs);
}

/* ─── CTA ─── */
.gs--cta {
  min-height: 85vh;
  align-items: flex-start;
  padding-top: 15vh;
}

/* Desktop lift: keep all globe section text higher */
@media (min-width: 991px) {
  .gs {
    padding-top: 7vh;
  }

  .gs--discover {
    justify-content: flex-start;
    padding-top: 11vh;
  }

  .gs--connect,
  .gs--impact,
  .gs--cta {
    padding-top: 9vh;
  }
}

.gs--cta h2 {
  font-family: "DM Sans", "Inter", sans-serif;
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  margin-bottom: var(--space-lg);
  background: linear-gradient(160deg, #ffffff 20%, rgba(255, 255, 255, 0.4) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 2px 16px rgba(0, 0, 0, 0.5));
}

.gs__cta-copy {
  font-size: 1.15rem;
  max-width: 480px;
  margin: 0 auto var(--space-xl);
  color: rgba(255, 255, 255, 0.35) !important;
  line-height: 1.7;
}

.btn--lg {
  padding: 20px 48px;
  font-size: 1.15rem;
}

/* ═══════════════════════════════════════════
   Responsive
   ═══════════════════════════════════════════ */
@media (max-width: 990px) {
  .gs--hero h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
  }
  .gs--cta h2 {
    font-size: clamp(2rem, 5vw, 3rem);
  }
  .gs-impact-grid {
    max-width: 100%;
  }
}

@media (max-width: 640px) {
  .gs {
    padding: 10vh var(--space-md) 0;
  }
  .gs--hero {
    align-items: center;
  }
  .gs--hero .gs__inner {
    padding-bottom: 25vh;
  }
  .gs--hero h1 {
    font-size: clamp(2.2rem, 10vw, 3rem);
  }
  .gs--cta h2 {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
  }
  .gs__lead {
    font-size: 0.92rem;
  }
  .gs-routes {
    max-width: 100%;
  }
  .gs-route {
    gap: var(--space-sm);
  }
  .gs-route__from {
    font-size: 0.75rem;
    min-width: 60px;
  }
  .gs-route__to {
    font-size: 0.85rem;
    min-width: 70px;
  }
  .gs-connect-stats {
    flex-direction: column;
    gap: var(--space-xl);
  }
  .gs-impact-grid {
    grid-template-columns: 1fr;
  }
  .gs-impact-card--wide {
    grid-column: auto;
  }
  .scroll-hint {
    bottom: 20px;
  }
  .btn--lg {
    padding: 16px 32px;
    font-size: 1rem;
  }
}

body[data-page="globe"] .gs--hero h1 {
  font-size: clamp(2.7rem, 6.8vw, 6.1rem);
}

@media (max-width: 990px) {
  body[data-page="globe"] .gs--hero h1 {
    font-size: clamp(2.3rem, 5.6vw, 3.6rem);
  }
}

@media (max-width: 640px) {
  body[data-page="globe"] .gs--hero h1 {
    font-size: clamp(2rem, 8.8vw, 2.7rem);
  }
}

/* ─── Chatbot dark overrides for home page ─── */
body[data-page="home"] .chatbot-nudge {
  background: rgba(12, 18, 30, 0.88);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"] .chatbot-nudge__prompt {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.75);
}

body[data-page="home"] .chatbot-nudge__prompt:hover {
  background: rgba(255, 255, 255, 0.08);
}

body[data-page="home"] .chatbot-launcher {
  background:
    radial-gradient(circle at 26% 20%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 48%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.94) 0%, rgba(18, 39, 64, 0.94) 50%, rgba(20, 102, 119, 0.92) 100%);
  border-color: rgba(148, 163, 184, 0.24);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(45, 212, 191, 0.16);
  color: #ffffff;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"] .chatbot-launcher:hover {
  box-shadow:
    0 24px 52px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(45, 212, 191, 0.28),
    0 0 22px rgba(45, 212, 191, 0.18);
}

body[data-page="home"] .chatbot-panel-backdrop {
  background: rgba(4, 8, 18, 0.42);
}

body[data-page="home"][data-theme="light"] .chatbot-panel-backdrop {
  background: rgba(9, 14, 26, 0.22);
}




/* =============================================
   CINEMATIC DARK THEME – Other pages
   Make browse/profile/contact feel cohesive with home.
   ============================================= */

body[data-theme="dark"][data-page="browse"],
body[data-theme="dark"][data-page="profile"],
body[data-theme="dark"][data-page="contact"] {
  background: #08111d;
  color: #edf4ff;
}

body[data-theme="dark"][data-page="browse"]::before,
body[data-theme="dark"][data-page="browse"]::after,
body[data-theme="dark"][data-page="profile"]::before,
body[data-theme="dark"][data-page="profile"]::after,
body[data-theme="dark"][data-page="contact"]::before,
body[data-theme="dark"][data-page="contact"]::after {
  display: none;
}

body[data-theme="dark"][data-page="browse"] .noise-overlay,
body[data-theme="dark"][data-page="profile"] .noise-overlay,
body[data-theme="dark"][data-page="contact"] .noise-overlay {
  display: none;
}

/* Force the same “dark tokens” used by data-theme="dark" */
body[data-theme="dark"][data-page="browse"],
body[data-theme="dark"][data-page="profile"],
body[data-theme="dark"][data-page="contact"] {
  --color-primary: #49E0C5;
  --color-primary-hover: #72EAD5;
  --color-primary-soft: rgba(73, 224, 197, 0.14);
  --color-primary-glass: rgba(73, 224, 197, 0.22);
  --color-accent: #7EE9D8;
  --color-accent-soft: rgba(126, 233, 216, 0.12);
  --color-accent-glass: rgba(126, 233, 216, 0.16);
  --color-bg: #08111d;
  --color-text: #edf4ff;
  --color-text-muted: #99abc4;
  --color-bg-card: rgba(12, 20, 33, 0.82);
  --color-bg-glass: rgba(14, 24, 39, 0.76);
  --color-bg-glass-strong: rgba(18, 30, 47, 0.92);
  --color-border: rgba(148, 163, 184, 0.16);
  --color-border-glass: rgba(148, 163, 184, 0.18);
  --color-border-glass-strong: rgba(148, 163, 184, 0.24);
  --color-ring: rgba(73, 224, 197, 0.18);
  --color-surface: #182538;
  --color-surface-soft: #111c2c;
  --color-sidebar: rgba(7, 13, 23, 0.94);
  --color-overlay: rgba(3, 7, 14, 0.56);
  --color-overlay-strong: rgba(3, 7, 14, 0.68);
  --color-input-bg: rgba(16, 27, 43, 0.86);
  --color-input-bg-strong: rgba(21, 35, 55, 0.98);
  --color-card-hover: rgba(19, 33, 51, 0.98);
  --color-avatar-border: #0d1726;
  --mesh-primary: rgba(73, 224, 197, 0.14);
  --mesh-accent: rgba(126, 233, 216, 0.12);
  --shadow-sm: 0 10px 26px rgba(0, 0, 0, 0.32);
  --shadow: 0 26px 64px rgba(0, 0, 0, 0.34), inset 0 1px 1px rgba(255, 255, 255, 0.03);
  --shadow-hover: 0 30px 78px rgba(0, 0, 0, 0.42), 0 10px 26px rgba(0, 0, 0, 0.2);
  --shadow-glass: 0 20px 52px rgba(0, 0, 0, 0.34), inset 0 1px 1px rgba(255, 255, 255, 0.03);
  --shadow-glass-hover: 0 28px 62px rgba(0, 0, 0, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.04);
}

/* Header styling consistent with home (fixed + glass) */
body[data-theme="dark"][data-page="browse"] .site-header,
body[data-theme="dark"][data-page="profile"] .site-header,
body[data-theme="dark"][data-page="contact"] .site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

body[data-theme="dark"][data-page="browse"] .logo,
body[data-theme="dark"][data-page="profile"] .logo,
body[data-theme="dark"][data-page="contact"] .logo {
  color: #ffffff;
}

body[data-theme="dark"][data-page="browse"] .logo:hover,
body[data-theme="dark"][data-page="profile"] .logo:hover,
body[data-theme="dark"][data-page="contact"] .logo:hover {
  color: var(--color-primary);
}

body[data-theme="dark"][data-page="browse"] .pill-toggle,
body[data-theme="dark"][data-page="profile"] .pill-toggle,
body[data-theme="dark"][data-page="contact"] .pill-toggle {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-theme="dark"][data-page="browse"] .pill-toggle__button,
body[data-theme="dark"][data-page="profile"] .pill-toggle__button,
body[data-theme="dark"][data-page="contact"] .pill-toggle__button {
  color: rgba(255, 255, 255, 0.45);
}

body[data-theme="dark"][data-page="browse"] .pill-toggle__button:hover,
body[data-theme="dark"][data-page="profile"] .pill-toggle__button:hover,
body[data-theme="dark"][data-page="contact"] .pill-toggle__button:hover {
  color: rgba(255, 255, 255, 0.8);
}

body[data-theme="dark"][data-page="browse"] .pill-toggle__button.is-active,
body[data-theme="dark"][data-page="profile"] .pill-toggle__button.is-active,
body[data-theme="dark"][data-page="contact"] .pill-toggle__button.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

body[data-theme="dark"][data-page="browse"] .menu-toggle,
body[data-theme="dark"][data-page="profile"] .menu-toggle,
body[data-theme="dark"][data-page="contact"] .menu-toggle {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-theme="dark"][data-page="browse"] .menu-toggle span,
body[data-theme="dark"][data-page="profile"] .menu-toggle span,
body[data-theme="dark"][data-page="contact"] .menu-toggle span {
  background: #ffffff;
}

body[data-theme="dark"][data-page="browse"] .menu-toggle.active span,
body[data-theme="dark"][data-page="profile"] .menu-toggle.active span,
body[data-theme="dark"][data-page="contact"] .menu-toggle.active span {
  background: var(--color-primary);
}

/* Footer consistent with home */
body[data-theme="dark"][data-page="browse"] .site-footer,
body[data-theme="dark"][data-page="profile"] .site-footer,
body[data-theme="dark"][data-page="contact"] .site-footer {
  background: transparent;
  border: none;
}

body[data-theme="dark"][data-page="browse"] .site-footer span,
body[data-theme="dark"][data-page="profile"] .site-footer span,
body[data-theme="dark"][data-page="contact"] .site-footer span {
  color: rgba(255, 255, 255, 0.25);
}

/* Make “light-theme” specific UI bits still readable on cinematic pages */
body[data-theme="dark"][data-page="browse"] .page-header__badge,
body[data-theme="dark"][data-page="contact"] .page-header__badge {
  background: rgba(18, 30, 47, 0.82);
  border-color: rgba(148, 163, 184, 0.16);
  color: rgba(255, 255, 255, 0.85);
}

/* ═══════════════════════════════════════════
   HOME PAGE — LIGHT THEME OVERRIDES
   ═══════════════════════════════════════════ */

body[data-page="home"][data-theme="light"] {
  --color-primary: #0B8570;
  --color-primary-hover: #076552;
  --color-primary-soft: rgba(11, 133, 112, 0.12);
  --color-primary-glass: rgba(11, 133, 112, 0.22);
  --color-ring: rgba(11, 133, 112, 0.16);
  background: #ffffff;
}

/* Globe-wrap vignette: soft white top fade instead of dark */
body[data-page="home"][data-theme="light"] .globe-wrap::before {
  background: linear-gradient(
    to bottom,
    rgba(250, 250, 250, 0.85) 0%,
    rgba(250, 250, 250, 0.35) 30%,
    transparent 55%
  );
}

/* Globe ambient glow: sky blue instead of teal */
body[data-page="home"][data-theme="light"] .globe-wrap::after {
  background: radial-gradient(
    circle,
    rgba(59, 130, 246, 0.08) 0%,
    rgba(59, 130, 246, 0.03) 35%,
    transparent 70%
  );
}

/* Impact section globe-wrap light overrides */
body[data-page="home"][data-theme="light"].is-impact .globe-wrap::before {
  background: linear-gradient(
    to left,
    rgba(250, 250, 250, 0.5) 0%,
    rgba(250, 250, 250, 0.1) 28%,
    transparent 55%
  );
}

/* Header */
body[data-page="home"][data-theme="light"] .site-header.is-scrolled {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

body[data-page="home"][data-theme="light"] .logo {
  color: #050505;
}

body[data-page="home"][data-theme="light"] .logo:hover {
  color: #CC0000;
}

/* Pill toggle in light mode on home */
body[data-page="home"][data-theme="light"] .pill-toggle {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"][data-theme="light"] .pill-toggle__button {
  color: rgba(0, 0, 0, 0.5);
}

body[data-page="home"][data-theme="light"] .pill-toggle__button:hover {
  color: rgba(0, 0, 0, 0.8);
}

body[data-page="home"][data-theme="light"] .pill-toggle__button.is-active {
  color: #050505;
  background: rgba(0, 0, 0, 0.08);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
}

/* Menu toggle */
body[data-page="home"][data-theme="light"] .menu-toggle {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

body[data-page="home"][data-theme="light"] .menu-toggle span {
  background: #050505;
}

body[data-page="home"][data-theme="light"] .menu-toggle.active span {
  background: #CC0000;
}

/* Section headings & paragraphs */
body[data-page="home"][data-theme="light"] .gs h1,
body[data-page="home"][data-theme="light"] .gs h2,
body[data-page="home"][data-theme="light"] .gs h3 {
  color: #0f172a;
  text-shadow: none;
}

body[data-page="home"][data-theme="light"] .gs p {
  color: rgba(15, 23, 42, 0.65);
  text-shadow: none;
}

/* Hero h1 gradient: dark on light bg */
body[data-page="home"][data-theme="light"] .gs--hero h1 {
  background: linear-gradient(160deg, #0f172a 20%, rgba(15, 23, 42, 0.45) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: none;
}

/* Lead / subtext */
body[data-page="home"][data-theme="light"] .gs__lead {
  color: rgba(15, 23, 42, 0.45) !important;
}

/* Scroll hint line */
body[data-page="home"][data-theme="light"] .scroll-hint__line {
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.35), transparent);
}

/* Discover section route items */
body[data-page="home"][data-theme="light"] .gs-route {
  border-bottom-color: rgba(0, 0, 0, 0.08);
}

body[data-page="home"][data-theme="light"] .gs-route__from {
  color: rgba(15, 23, 42, 0.4);
}

body[data-page="home"][data-theme="light"] .gs-route__to {
  color: #0f172a;
}

/* Connect section quote */
body[data-page="home"][data-theme="light"] .gs-quote p {
  color: rgba(15, 23, 42, 0.7) !important;
}

body[data-page="home"][data-theme="light"] .gs-connect-stat__value {
  color: #0f172a;
}

body[data-page="home"][data-theme="light"] .gs-connect-stat__label {
  color: rgba(15, 23, 42, 0.4);
}

/* Impact cards */
body[data-page="home"][data-theme="light"] .gs-impact-card {
  border-color: rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.6);
}

body[data-page="home"][data-theme="light"] .gs-impact-card:hover {
  background: rgba(255, 255, 255, 0.85);
  border-color: rgba(204, 0, 0, 0.2);
}

body[data-page="home"][data-theme="light"] .gs-impact-card--wide {
  border-color: rgba(204, 0, 0, 0.12);
  background: rgba(204, 0, 0, 0.03);
}

body[data-page="home"][data-theme="light"] .gs-impact-card__number {
  background: linear-gradient(135deg, #0f172a 20%, #CC0000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

body[data-page="home"][data-theme="light"] .gs-impact-card__text {
  color: rgba(15, 23, 42, 0.4);
}

/* CTA section */
body[data-page="home"][data-theme="light"] .gs--cta h2 {
  background: linear-gradient(160deg, #0f172a 20%, rgba(15, 23, 42, 0.4) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: none;
}

body[data-page="home"][data-theme="light"] .gs__cta-copy {
  color: rgba(15, 23, 42, 0.45) !important;
}

/* Footer */
body[data-page="home"][data-theme="light"] .site-footer span {
  color: rgba(15, 23, 42, 0.35);
}

/* Cursor glow */
body[data-page="home"][data-theme="light"] .cursor-glow {
  background: radial-gradient(circle, rgba(204, 0, 0, 0.025) 0%, transparent 70%);
}

body[data-page="home"][data-theme="light"] .btn--primary {
  box-shadow: 0 10px 28px rgba(11, 133, 112, 0.18), inset 0 1px 1px rgba(255, 255, 255, 0.38);
}

body[data-page="home"][data-theme="light"] .btn--primary:hover {
  box-shadow: 0 16px 36px rgba(11, 133, 112, 0.24), inset 0 1px 1px rgba(255, 255, 255, 0.55);
}

body[data-page="home"][data-theme="light"] .mesh-bg {
  opacity: 0.86;
}

body[data-page="home"][data-theme="light"] .mesh-bg__orb {
  filter: blur(120px);
}

body[data-page="home"][data-theme="light"] .mesh-bg__orb--1 {
  background:
    radial-gradient(circle at 28% 32%, rgba(255, 255, 255, 0.42) 0%, rgba(255, 255, 255, 0) 44%),
    radial-gradient(circle at 58% 46%, rgba(15, 23, 42, 0.09) 0%, rgba(15, 23, 42, 0.035) 32%, transparent 72%);
}

body[data-page="home"][data-theme="light"] .mesh-bg__orb--2 {
  background:
    radial-gradient(circle at 50% 48%, rgba(148, 163, 184, 0.14) 0%, rgba(148, 163, 184, 0.045) 38%, transparent 74%),
    repeating-linear-gradient(135deg, rgba(15, 23, 42, 0.022) 0 2px, transparent 2px 20px);
}

body[data-page="home"][data-theme="light"] .mesh-bg__orb--3 {
  background:
    radial-gradient(circle at 48% 42%, rgba(203, 213, 225, 0.18) 0%, rgba(203, 213, 225, 0.05) 36%, transparent 70%),
    repeating-linear-gradient(45deg, rgba(100, 116, 139, 0.024) 0 1px, transparent 1px 22px);
}

/* ============================================
   Profile Card Redesign (Implemented from Image)
   ============================================ */

.pc-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
  background-color: var(--color-bg);
  min-height: 100vh;
}

.pc-card {
  width: 100%;
  max-width: 400px;
  background: var(--color-surface);
  border-radius: 32px;
  box-shadow: 0 20px 48px rgba(0,0,0,0.06);
  overflow: hidden;
  position: relative;
  font-family: var(--font-body);
  color: var(--color-text);
  margin-top: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

body[data-theme="dark"] .pc-card {
  background: var(--color-surface);
  box-shadow: 0 20px 48px rgba(0,0,0,0.3);
}

.pc-banner {
  height: 160px;
  background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 25%, #a1c4fd 60%, #c2e9fb 100%);
  width: 100%;
  position: relative;
}

body[data-theme="dark"] .pc-banner {
  background: linear-gradient(135deg, #B22222 0%, #8A2BE2 50%, #4682B4 100%);
}

.pc-avatar-wrapper {
  position: relative;
  width: 110px;
  height: 110px;
  margin: -55px auto 0;
  display: flex;
  justify-content: center;
}

.pc-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 6px solid var(--color-surface);
  background-color: #eee;
}

.pc-online-dot {
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 18px;
  height: 18px;
  background-color: #27d381; /* bright green */
  border-radius: 50%;
  border: 4px solid var(--color-surface);
}

.pc-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16px 32px 0;
}

.pc-title-col {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.pc-name {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0;
  color: var(--color-text);
  line-height: 1.2;
}

.pc-role {
  font-size: 1rem;
  font-weight: 500;
  color: var(--color-text-muted);
  margin: 4px 0 0;
}

.pc-bookmark-btn {
  background: none;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-text-muted);
  transition: all 0.2s ease;
}

.pc-bookmark-btn:hover {
  background: var(--color-bg-glass);
  color: var(--color-text);
  transform: scale(1.05);
}

.pc-tags-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 24px 32px 0;
  /* Centering from visual, let's align left like name or center? The image has it left-aligned below name or center? Actually it looks left aligned or perfectly spaced */
  justify-content: flex-start;
}

.pc-tag {
  background: var(--color-bg);
  color: var(--color-text);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--color-border);
}

.pc-stats-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 32px;
  margin: 0;
}

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

.pc-stat-val {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.pc-stat-lbl {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--color-text-muted);
}

.pc-divider {
  width: 1px;
  height: 40px;
  background-color: var(--color-border);
}

.pc-action-btn {
  width: calc(100% - 64px);
  margin: 0 32px 32px;
  padding: 16px;
  background-color: #111;
  color: #fff;
  border: none;
  border-radius: 24px;
  font-size: 1.1rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.pc-action-btn:hover {
  background-color: #000;
  transform: scale(1.02);
}

body[data-theme="dark"] .pc-action-btn {
  background-color: #fff;
  color: #111;
}

body[data-theme="dark"] .pc-action-btn:hover {
  background-color: #f0f0f0;
}

/* ============================================
   Profile Modal
   ============================================ */

.profile-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.profile-modal-overlay.is-open {
  opacity: 1;
  visibility: visible;
}
.profile-modal {
  background: var(--color-surface);
  border-radius: 24px;
  width: 75%;
  max-width: 1000px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 24px 60px rgba(0,0,0,0.15);
  transform: translateY(20px) scale(0.98);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 32px;
}
.profile-modal-overlay.is-open .profile-modal {
  transform: translateY(0) scale(1);
}
.profile-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--color-bg);
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--color-text-muted);
  font-size: 24px;
  line-height: 1;
}
.profile-modal-close:hover {
  color: var(--color-text);
  background: var(--color-border);
}
.profile-modal-header {
  margin-bottom: 24px;
}
.profile-modal-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0 0 4px;
}
.profile-modal-subtitle {
  font-size: 1rem;
  color: var(--color-text-muted);
}
.profile-modal-video {
  width: 100%;
  aspect-ratio: 16/9;
  background: #111;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.1);
}
.profile-modal-video::before {
  content: '▶';
  font-size: 40px;
  color: rgba(255,255,255,0.8);
}
.profile-modal-video::after {
  content: 'video placeholder';
  position: absolute;
  bottom: 16px;
  left: 16px;
  color: rgba(255,255,255,0.5);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.profile-modal-section {
  margin-bottom: 24px;
}
.profile-modal-section h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--color-text);
}
.profile-modal-section p, .profile-modal-section ul {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}
.profile-modal-section ul {
  padding-left: 20px;
}
.profile-modal-section li {
  margin-bottom: 6px;
}
.profile-modal-contact {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}

/* ============================================
   NEW: Header Layout (Brand + Center Nav + Auth)
   ============================================ */
.header-container {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  column-gap: clamp(0.75rem, 1.2vw, 1.35rem);
  max-width: none;
  padding: 0 var(--space-xl);
}

.site-header .header-container {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  column-gap: clamp(0.75rem, 1.2vw, 1.35rem);
}

.header-brand {
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--color-text);
  flex-shrink: 0;
}

.header-brand__logo {
  height: 34px;
  width: auto;
  border-radius: 8px;
}

.header-brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.header-brand__name-twins {
  color: #7c3aed;
}

.header-brand__name-tie {
  color: #16a34a;
}

.header-nav {
  grid-column: 2;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: center;
  width: 100%;
  min-width: 0;
  gap: clamp(0.18rem, 0.35vw, 0.45rem);
  animation: slideDownFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
  opacity: 0;
}

.header-nav__link {
  position: relative;
  width: 100%;
  min-width: 0;
  padding: 0.5rem 0.45rem;
  font-size: 0.85rem;
  font-weight: 500;
  font-family: var(--font-display);
  color: var(--color-text-muted);
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
  border-radius: 999px;
  transition: color 0.25s ease, background 0.25s ease;
}

.header-nav__link:hover {
  color: var(--color-text);
  background: var(--color-primary-soft);
}

.header-nav__link.is-active {
  color: var(--color-primary);
  font-weight: 600;
}

.header-nav__link.is-active::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 2.5px;
  background: var(--color-primary);
  border-radius: 2px;
}

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

.site-header .header-actions {
  grid-column: 3;
  justify-self: end;
  margin-left: 0;
  flex: 0 0 auto;
}

/* Compact pill toggles for new header */
.pill-toggle--compact {
  padding: 3px;
}

.pill-toggle--compact .pill-toggle__button {
  padding: 0.4rem 0.65rem;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pill-toggle--compact .pill-toggle__button svg {
  width: 14px;
  height: 14px;
}

/* Small button variants */
.btn--sm {
  padding: 0.45rem 1rem;
  font-size: 0.8rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all 0.25s ease;
}

.btn--outline {
  background: transparent;
  color: var(--color-text);
  border: 1.5px solid var(--color-border-glass-strong);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.btn--outline:hover {
  background: var(--color-primary-soft);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn--premium-outline {
  background: transparent;
  color: var(--color-primary);
  border: 1.5px solid var(--color-primary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
  transition: all 0.3s ease;
}

.btn--premium-outline:hover {
  background: var(--color-primary-soft);
  color: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.btn--block {
  display: block;
  width: 100%;
  text-align: center;
}

/* User dropdown */
.header-user {
  position: relative;
  display: flex;
  align-items: center;
}

.header-user__trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px 4px 4px;
  background: var(--color-bg-glass-strong);
  border: 1px solid var(--color-border-glass);
  border-radius: 999px;
  cursor: pointer;
  font: inherit;
  color: var(--color-text);
  transition: all 0.25s ease;
}

.header-user__trigger:hover {
  background: var(--color-card-hover);
}

.header-user__avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
}

.header-user__avatar--image {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
  overflow: hidden;
}

.header-user__avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: inherit;
}

.header-user__name {
  font-size: 0.82rem;
  font-weight: 600;
}

.header-user__dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: var(--color-bg-glass-strong);
  border: 1px solid var(--color-border-glass);
  border-radius: var(--radius);
  backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-hover);
  padding: 6px;
  display: none;
  z-index: 200;
}

.header-user__dropdown.is-open {
  display: block;
}

.header-user__dropdown a,
.header-user__dropdown button {
  display: block;
  width: 100%;
  padding: 8px 14px;
  font: inherit;
  font-size: 0.84rem;
  color: var(--color-text);
  text-decoration: none;
  border: none;
  background: transparent;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s ease;
}

.header-user__dropdown a:hover,
.header-user__dropdown button:hover {
  background: var(--color-primary-soft);
}

/* Sidebar updates */
.sidebar__header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--color-border);
}

.sidebar__brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--color-text);
  text-decoration: none;
}

.sidebar__auth {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 24px;
  margin-top: auto;
  border-top: 1px solid var(--color-border);
}

.sidebar-links li.is-active a {
  color: var(--color-primary);
  font-weight: 600;
}

@media (min-width: 991px) and (max-width: 1160px) {
  .header-container,
  .site-header .header-container {
    column-gap: 0.75rem;
    padding-left: var(--space-lg);
    padding-right: var(--space-lg);
  }

  .header-brand {
    gap: 8px;
  }

  .header-brand__name {
    font-size: 1.05rem;
  }

  .header-nav {
    gap: 0.18rem;
  }

  .header-nav__link {
    padding: 0.5rem 0.22rem;
    font-size: 0.74rem;
  }

  .site-header .header-actions {
    gap: 7px;
  }

  .site-header .pill-toggle--compact .pill-toggle__button {
    padding: 0.38rem 0.52rem;
    font-size: 0.68rem;
  }

  .site-header .btn--sm {
    padding: 0.42rem 0.72rem;
    font-size: 0.74rem;
  }
}

/* Hide center nav on mobile */
@media (max-width: 990px) {
  .header-nav {
    display: none;
  }
  .header-auth {
    display: none;
  }
  .pill-toggle--compact {
    display: none;
  }
}

@media (min-width: 991px) {
  .menu-toggle {
    display: none !important;
  }
}

/* ============================================
   NEW: Footer
   ============================================ */
.footer {
  padding: var(--space-3xl) 0 var(--space-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: #050505;
  color: #ffffff;
  margin-top: auto;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--color-text);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: var(--space-md);
}

.footer__logo {
  height: 32px;
  width: auto;
  border-radius: 6px;
}

.footer__tagline {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.88rem;
  line-height: 1.6;
}

.footer__heading {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #ffffff;
  margin-bottom: var(--space-md);
}

.footer__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer__list li {
  margin-bottom: 10px;
}

.footer__col--social {
  text-align: right;
}

.footer__list a {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.2s ease;
}

.footer__list a:hover {
  color: #a78bfa;
}

.footer__contact {
  margin-top: var(--space-lg);
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.78);
}

.footer__contact a {
  color: #ffffff;
  text-decoration: none;
}

.footer__social-icons {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.footer__social-icons a {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 0.76rem;
  font-weight: 700;
}

.footer__social-icons a:hover {
  background: rgba(255, 255, 255, 0.12);
}

.footer__bottom {
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.62);
}

@media (max-width: 768px) {
  .footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
  }
}

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

/* ============================================
   NEW: Page Sections (used across new pages)
   ============================================ */
.page-section {
  padding: clamp(3rem, 8vh, 6rem) 0;
}

main > .page-section:nth-of-type(odd):not(.page-section--hero):not(.page-section--hero-full) {
  background: rgba(124, 58, 237, 0.05);
}

main > .page-section:nth-of-type(even):not(.page-section--hero):not(.page-section--hero-full) {
  background: rgba(22, 163, 74, 0.05);
}

main > .page-section + .page-section {
  border-top: 1px solid rgba(124, 58, 237, 0.12);
}

.page-section--hero {
  min-height: 70vh;
  display: flex;
  align-items: center;
  padding-top: 180px;
}

.page-section--hero-full {
  min-height: 90vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
}

.page-section__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.page-section__badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary);
  background: var(--color-primary-soft);
  padding: 6px 16px;
  border-radius: 999px;
  margin-bottom: var(--space-lg);
}

.page-section__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--color-text);
  margin-bottom: var(--space-lg);
}

.page-section__lead {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--color-text-muted);
  line-height: 1.6;
  max-width: 640px;
}

.page-section__lead--center {
  margin: 0 auto;
  text-align: center;
}

.page-section--center {
  text-align: center;
}

.page-section--center .page-section__lead {
  margin: 0 auto;
}

/* ============================================
   Hero Showcase — pictures flanking hero text
   ============================================ */
.hero-showcase {
  display: grid;
  grid-template-columns: 0.8fr 1.4fr 0.8fr;
  align-items: center;
  gap: var(--space-xl);
}

.hero-showcase__center {
  text-align: center;
  padding-top: clamp(1.75rem, 4vw, 4rem);
}

.hero-showcase__center .page-section__title {
  font-size: clamp(1.6rem, 3.2vw, 2.4rem);
}

.hero-showcase__center .cta-group {
  flex-direction: column;
  align-items: center;
}

.hero-showcase__side {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  margin-top: 8rem;
}

.hero-showcase__side--left {
  padding-right: var(--space-md);
}

.hero-showcase__side--right {
  padding-left: var(--space-md);
}

/* Stagger the cards vertically for visual interest */
.hero-showcase__side--left .hero-card:first-child {
  margin-top: -16px;
}

.hero-showcase__side--left .hero-card:last-child {
  margin-top: 16px;
}

.hero-showcase__side--right .hero-card:first-child {
  margin-top: 12px;
}

.hero-showcase__side--right .hero-card:last-child {
  margin-top: -12px;
}

/* Card container */
.hero-card {
  text-align: center;
  max-width: 200px;
  margin: 0 auto;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-card:hover {
  transform: scale(1.03);
}

/* Shared frame styles */
.hero-card__frame {
  position: relative;
  overflow: hidden;
  border: 3px solid rgba(255, 255, 255, 0.85);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.08),
    0 2px 8px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.4s ease, transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hero-card:hover .hero-card__frame {
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.12),
    0 4px 12px rgba(0, 0, 0, 0.06);
}

.hero-card__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Creative organic shapes — each frame is unique */

/* Frame 1: Rounded pebble / organic stone */
.hero-card__frame--1 {
  border-radius: 62% 38% 46% 54% / 60% 44% 56% 40%;
  aspect-ratio: 4 / 3;
  rotate: -3deg;
}

/* Frame 2: Leaf / teardrop shape */
.hero-card__frame--2 {
  border-radius: 44% 56% 68% 32% / 38% 62% 38% 62%;
  aspect-ratio: 4 / 3;
  rotate: 2deg;
}

/* Frame 3: Cloud / pillow shape */
.hero-card__frame--3 {
  border-radius: 50% 50% 34% 66% / 56% 40% 60% 44%;
  aspect-ratio: 4 / 3;
  rotate: 3deg;
}

/* Frame 4: Shield / gem shape */
.hero-card__frame--4 {
  border-radius: 38% 62% 52% 48% / 42% 58% 42% 58%;
  aspect-ratio: 4 / 3;
  rotate: -2deg;
}

/* Caption under each picture */
.hero-card__label {
  font-family: var(--font-display);
  font-size: clamp(0.85rem, 1.2vw, 1rem);
  font-weight: 600;
  color: var(--color-text);
  margin-top: var(--space-md);
  letter-spacing: -0.01em;
  opacity: 0.88;
}

/* Subtle float animation */
@keyframes heroFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-showcase__side--left .hero-card:first-child .hero-card__frame {
  animation: heroFloat 6s ease-in-out infinite;
}

.hero-showcase__side--left .hero-card:last-child .hero-card__frame {
  animation: heroFloat 7s ease-in-out 1s infinite;
}

.hero-showcase__side--right .hero-card:first-child .hero-card__frame {
  animation: heroFloat 5.5s ease-in-out 0.5s infinite;
}

.hero-showcase__side--right .hero-card:last-child .hero-card__frame {
  animation: heroFloat 6.5s ease-in-out 1.5s infinite;
}

/* Dark mode adjustments */
[data-theme="dark"] .hero-card__frame {
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 2px 8px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.06);
}

[data-theme="dark"] .hero-card:hover .hero-card__frame {
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.4),
    0 4px 12px rgba(0, 0, 0, 0.25);
  border-color: rgba(255, 255, 255, 0.22);
}

/* Tablet: stack to text-on-top, images below in 2x2 */
@media (max-width: 990px) {
  .hero-showcase {
    grid-template-columns: 1fr;
    text-align: center;
    gap: var(--space-2xl);
  }

  .hero-showcase__center {
    order: -1;
    padding-top: 1rem;
  }

  .hero-showcase__side {
    flex-direction: row;
    justify-content: center;
    gap: var(--space-xl);
    padding: 0;
    margin-top: 0;
  }

  .hero-showcase__side--left,
  .hero-showcase__side--right {
    padding: 0;
  }

  .hero-card {
    max-width: 220px;
  }

  .hero-showcase__side--left .hero-card:first-child,
  .hero-showcase__side--left .hero-card:last-child,
  .hero-showcase__side--right .hero-card:first-child,
  .hero-showcase__side--right .hero-card:last-child {
    transform: none;
  }
}

/* Mobile: smaller cards in 2x2 grid */
@media (max-width: 640px) {
  .hero-showcase__side {
    gap: var(--space-md);
  }

  .hero-card {
    max-width: 160px;
  }

  .hero-card__label {
    font-size: 0.8rem;
  }

  .hero-card__frame {
    border-width: 2px;
  }
}

/* CTA Buttons Group */
.cta-group {
  display: flex;
  gap: var(--space-md);
  margin-top: var(--space-xl);
  flex-wrap: wrap;
}

.cta-group--center {
  justify-content: center;
}

/* Card Grid */
.card-grid {
  display: grid;
  gap: var(--space-xl);
  margin-top: var(--space-2xl);
}

.card-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

.card-grid--4 {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 768px) {
  .card-grid--3 {
    grid-template-columns: 1fr;
  }
  .card-grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .card-grid--4 {
    grid-template-columns: 1fr;
  }
}

/* Glass Card */
.glass-card {
  position: relative;
  background: var(--color-bg-glass);
  border: 1px solid var(--color-border-glass);
  border-radius: var(--radius-xl);
  padding: var(--space-2xl);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-glass);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease;
}

body[data-page="home"] .glass-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 243, 255, 0.92));
  border-color: rgba(124, 58, 237, 0.2);
  box-shadow: 0 22px 44px -28px rgba(76, 29, 149, 0.35);
}

body[data-page="contact"] .btn--primary.contact-page__submit {
  background: linear-gradient(120deg, #7c3aed, #16a34a);
}

.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glass-hover);
}

.glass-card__icon {
  position: absolute;
  top: var(--space-lg);
  right: var(--space-lg);
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary-soft);
  color: var(--color-primary);
  border-radius: var(--radius-lg);
  margin: 0;
  font-size: 1.4rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, background 0.35s ease;
}

.glass-card__icon svg {
  width: 26px;
  height: 26px;
  stroke-width: 1.8;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-card:hover .glass-card__icon {
  transform: scale(1.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 4px 16px rgba(0, 0, 0, 0.1);
}

.glass-card:hover .glass-card__icon svg {
  transform: scale(1.05);
}

.glass-card__title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: var(--space-sm);
  color: var(--color-text);
}

.glass-card__text {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* Step number */
.glass-card__step {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--color-primary);
  opacity: 0.2;
  font-family: var(--font-display);
  margin-bottom: var(--space-sm);
}

/* Team Card */
.team-card {
  background: var(--color-bg-glass);
  border: 1px solid var(--color-border-glass);
  border-radius: var(--radius-xl);
  overflow: hidden;
  text-align: center;
  padding: var(--space-2xl) var(--space-lg);
  backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-glass);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease;
}

a.team-card {
  text-decoration: none;
  color: inherit;
  display: block;
}

.team-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glass-hover);
}

.team-card__avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: var(--space-lg);
  border: 3px solid var(--color-primary-soft);
}

.team-card__avatar--placeholder {
  background: var(--color-primary-soft);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0 auto var(--space-lg);
}

.team-card__name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 4px;
}

.team-card__role {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--space-sm);
}

.team-card__bio {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

body[data-page="about"] .page-section--about .page-section__inner {
  max-width: 960px;
}

body[data-page="about"] .page-section--about .page-section__title,
body[data-page="about"] .page-section--about .page-section__lead {
  text-align: left;
}

body[data-page="about"] .page-section--about.page-section--center .page-section__title,
body[data-page="about"] .page-section--about.page-section--center .page-section__lead {
  text-align: center;
}

body[data-page="contact"] .contact-page__header {
  text-align: left;
}

body[data-page="contact"] .contact-page__badge {
  margin-left: 0;
}

body[data-page="contact"] .contact-page__info-grid {
  margin-top: var(--space-xl);
}

body[data-page="contact"] .contact-page__social-block {
  margin-top: var(--space-md);
}

body[data-page="contact"] .contact-page__form-shell {
  padding: var(--space-xl);
  border: 1px solid rgba(124, 58, 237, 0.18);
}

body[data-page="contact"] .contact-page__form {
  max-width: 100%;
}

body[data-page="contact"] .contact-page__submit {
  width: 100%;
}

body[data-page="globe"] .gs h1,
body[data-page="globe"] .gs h2,
body[data-page="globe"] .gs h3 {
  color: #ffffff;
}

body[data-page="globe"] .gs p,
body[data-page="globe"] .gs span,
body[data-page="globe"] .gs cite {
  color: rgba(255, 255, 255, 0.84);
}

body[data-page="globe"] .globe-wrap {
  z-index: 0;
}

body[data-page="globe"] main {
  position: relative;
  z-index: 2;
}

/* ============================================
   NEW: Impact Stats Section
   ============================================ */
.impact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-xl);
  margin-top: var(--space-2xl);
}

.impact-stat {
  text-align: center;
  padding: var(--space-xl) var(--space-lg);
}

.impact-stat__number {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 800;
  color: var(--color-primary);
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: var(--space-sm);
}

.impact-stat__label {
  font-size: 0.88rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

/* ============================================
   NEW: Form Styles (Signup/Login)
   ============================================ */
.form-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px var(--space-xl) var(--space-2xl);
}

body[data-page="signup"] .form-page {
  align-items: flex-start;
  padding-top: clamp(9.5rem, 14vw, 11rem);
}

.form-container {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
}

.form-container--wide {
  max-width: 720px;
}

.form-card {
  background: var(--color-bg-glass);
  border: 1px solid var(--color-border-glass);
  border-radius: var(--radius-2xl);
  padding: var(--space-2xl) var(--space-2xl);
  backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-glass);
}

.form-card__title {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: var(--space-sm);
}

.form-card__subtitle {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: var(--space-2xl);
}

/* Role selection cards */
.role-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  margin-bottom: var(--space-2xl);
}

.role-card {
  background: var(--color-bg-card);
  border: 2px solid var(--color-border-glass);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.role-card:hover {
  border-color: var(--color-primary-glass);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.role-card.is-selected {
  border-color: var(--color-primary);
  background: var(--color-primary-soft);
}

.role-card__icon {
  font-size: 2.2rem;
  margin-bottom: var(--space-md);
}

.role-card__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: var(--space-xs);
}

.role-card__desc {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

/* Form fields */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  font: inherit;
  font-size: 0.92rem;
  color: var(--color-text);
  background: var(--color-input-bg);
  border: 1.5px solid var(--color-border-glass);
  border-radius: var(--radius);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-soft);
}

.form-input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.7;
}

textarea.form-input {
  resize: vertical;
  min-height: 100px;
}

select.form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%2352525B' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.form-input--error {
  border-color: #ef4444;
}

.form-error {
  color: #ef4444;
  font-size: 0.78rem;
  margin-top: 4px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}

@media (max-width: 480px) {
  .form-row {
    grid-template-columns: 1fr;
  }
  .role-selector {
    grid-template-columns: 1fr;
  }
}

/* Password strength */
.pw-requirements {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.pw-req {
  font-size: 0.72rem;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--color-bg-card);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  transition: all 0.2s ease;
}

.pw-req.is-met {
  background: rgba(34, 197, 94, 0.12);
  color: #16a34a;
  border-color: rgba(34, 197, 94, 0.3);
}

/* Toggle switch */
.form-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: var(--space-md);
  cursor: pointer;
}

.form-toggle__track {
  width: 42px;
  height: 24px;
  background: var(--color-border-glass-strong);
  border-radius: 999px;
  position: relative;
  transition: background 0.25s ease;
  flex-shrink: 0;
}

.form-toggle__track::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.25s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.form-toggle input:checked + .form-toggle__track {
  background: var(--color-primary);
}

.form-toggle input:checked + .form-toggle__track::after {
  transform: translateX(18px);
}

.form-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.form-toggle__label {
  font-size: 0.85rem;
  color: var(--color-text);
}

/* Upload area */
.upload-area {
  border: 2px dashed var(--color-border-glass-strong);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.upload-area:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-soft);
}

.upload-area__text {
  font-size: 0.88rem;
  color: var(--color-text-muted);
}

.upload-progress {
  margin-top: var(--space-md);
  height: 6px;
  background: var(--color-bg-card);
  border-radius: 999px;
  overflow: hidden;
}

.upload-progress__bar {
  height: 100%;
  background: var(--color-primary);
  border-radius: 999px;
  width: 0%;
  transition: width 0.3s ease;
}

/* Multi-step progress */
.form-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: var(--space-2xl);
}

.form-step-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-border-glass-strong);
  transition: all 0.3s ease;
}

.form-step-dot.is-active {
  width: 32px;
  border-radius: 999px;
  background: var(--color-primary);
}

.form-step-dot.is-done {
  background: var(--color-primary);
  opacity: 0.5;
}

/* Form actions */
.form-actions {
  display: flex;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}

.form-actions .btn {
  flex: 1;
}

.form-link {
  text-align: center;
  margin-top: var(--space-lg);
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.form-link a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
}

.form-link a:hover {
  text-decoration: underline;
}

/* Alert / Success message */
.form-alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  margin-bottom: var(--space-lg);
}

.form-alert--success {
  background: rgba(34, 197, 94, 0.12);
  color: #16a34a;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.form-alert--error {
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ============================================
   NEW: Admin Dashboard
   ============================================ */
.admin-page {
  padding-top: 100px;
  min-height: 100vh;
}

.admin-tabs {
  display: flex;
  gap: 4px;
  background: var(--color-bg-glass-strong);
  border: 1px solid var(--color-border-glass);
  border-radius: var(--radius);
  padding: 4px;
  margin-bottom: var(--space-2xl);
  width: fit-content;
}

.admin-tab {
  padding: 8px 20px;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text-muted);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.admin-tab.is-active {
  background: var(--color-primary);
  color: #fff;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.admin-table th {
  text-align: left;
  padding: 12px 16px;
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  border-bottom: 2px solid var(--color-border);
}

.admin-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text);
}

.admin-table select {
  padding: 6px 10px;
  font: inherit;
  font-size: 0.82rem;
  border-radius: 8px;
  border: 1px solid var(--color-border-glass);
  background: var(--color-input-bg);
  color: var(--color-text);
}

/* ============================================
   NEW: Legal Pages
   ============================================ */
.legal-page {
  padding-top: 100px;
  min-height: 100vh;
}

.legal-content h2 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--color-text);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content p {
  font-size: 0.92rem;
  line-height: 1.7;
  color: var(--color-text-muted);
  margin-bottom: var(--space-sm);
}

.legal-content ul {
  padding-left: var(--space-lg);
  margin-bottom: var(--space-md);
}

.legal-content li {
  font-size: 0.92rem;
  line-height: 1.7;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.legal-content strong {
  color: var(--color-text);
}

/* ============================================
   NEW: Scroll Reveal Animation
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-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; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ============================================
   NEW: Smooth page-load fade-in
   ============================================ */
body {
  animation: pageEnter 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes pageEnter {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  body {
    animation: none;
  }

  .glass-card,
  .stat-card,
  .team-card {
    transition: none;
  }
}

/* ============================================
   NEW: Mesh Background (for non-globe pages)
   ============================================ */
.mesh-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.mesh-bg__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  animation: meshFloat 20s ease-in-out infinite;
}

.mesh-bg__orb--1 {
  width: 600px;
  height: 600px;
  background: var(--mesh-primary);
  top: -10%;
  right: -10%;
}

.mesh-bg__orb--2 {
  width: 500px;
  height: 500px;
  background: var(--mesh-accent);
  bottom: -10%;
  left: -10%;
  animation-delay: -7s;
}

.mesh-bg__orb--3 {
  width: 400px;
  height: 400px;
  background: var(--color-primary-soft);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: -14s;
}

@keyframes meshFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -30px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* ============================================
   PHASE 9: Mobile Optimization & Polish
   ============================================ */

/* --- Tablet (≤990px) --- */
@media (max-width: 990px) {
  .page-section--hero,
  .page-section--hero-full {
    padding-top: 80px;
    min-height: auto;
  }

  .stats__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .admin-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .admin-tabs {
    width: 100%;
  }

  .browse-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .search-wrap {
    min-width: 100%;
  }

  .browse-filters {
    width: 100%;
  }

  .browse-select {
    flex: 1;
    min-width: 0;
  }
}

/* --- Mobile (≤640px) --- */
@media (max-width: 640px) {
  .page-section--hero,
  .page-section--hero-full {
    padding-top: 72px;
    padding-bottom: var(--space-lg);
  }

  .page-section__title {
    font-size: clamp(1.6rem, 7vw, 2.2rem);
  }

  .page-section__lead {
    font-size: 0.95rem;
  }

  .cta-group {
    flex-direction: column;
    align-items: stretch;
  }

  .cta-group .btn {
    text-align: center;
    justify-content: center;
  }

  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .glass-card {
    padding: var(--space-lg);
  }

  .glass-card__icon {
    width: 40px;
    height: 40px;
  }

  .form-page {
    padding-top: 72px;
  }

  body[data-page="signup"] .form-page {
    padding-top: 8rem;
  }

  .form-card {
    padding: var(--space-lg);
  }

  .role-card {
    padding: var(--space-lg);
  }

  .legal-page {
    padding-top: 80px;
  }

  .legal-content {
    padding: var(--space-lg) !important;
  }

  .legal-content h2 {
    font-size: 1.05rem;
  }

  .admin-page {
    padding-top: 80px;
  }

  .admin-tabs {
    flex-wrap: wrap;
  }

  .admin-tab {
    flex: 1;
    text-align: center;
    padding: 8px 12px;
    font-size: 0.8rem;
  }

  .split-hero {
    padding-top: 72px;
  }

  /* Touch targets minimum 44px */
  .btn,
  .browse-select,
  .form-input,
  select.form-input,
  textarea.form-input,
  .admin-tab,
  .search-input {
    min-height: 44px;
  }

  /* Modal full-width on mobile */
  .modal {
    width: calc(100vw - 32px);
    max-width: 100%;
    margin: 16px;
  }
}

/* --- Small Mobile (≤480px) --- */
@media (max-width: 480px) {
  .page-section {
    padding: clamp(2rem, 6vh, 3.5rem) 0;
  }

  .page-section__title {
    font-size: clamp(1.4rem, 8vw, 1.8rem);
  }

  .stats__grid {
    gap: var(--space-sm);
  }

  .stat-card {
    padding: var(--space-md);
  }

  .stat-card__value {
    font-size: 1.3rem;
  }

  .stat-card__label {
    font-size: 0.72rem;
  }

  .team-card {
    padding: var(--space-lg);
  }

  .browse-header__text h1 {
    font-size: 1.3rem;
  }

  .browse-select {
    font-size: 0.8rem;
    padding: 8px 28px 8px 10px;
  }

  .footer {
    padding: var(--space-2xl) 0 var(--space-lg);
  }

  .footer__brand {
    font-size: 1rem;
  }

  /* Mesh background smaller on mobile to reduce GPU load */
  .mesh-bg__orb--1 {
    width: 300px;
    height: 300px;
  }

  .mesh-bg__orb--2 {
    width: 250px;
    height: 250px;
  }

  .mesh-bg__orb--3 {
    width: 200px;
    height: 200px;
  }
}

/* --- Premium mentor profile studio --- */
.mentor-public,
.mentor-studio {
  display: grid;
  gap: 28px;
  color: #f5f8fc;
}

.mentor-public__frame,
.mentor-studio__cover,
.mentor-studio__panel,
.mentor-public__panel {
  border: 1px solid var(--account-border);
  background:
    radial-gradient(circle at top left, rgba(215, 161, 107, 0.14), transparent 26%),
    linear-gradient(155deg, var(--mentor-surface-strong) 0%, var(--mentor-surface) 100%);
  box-shadow: var(--mentor-shadow);
}

.mentor-public__frame {
  border-radius: 40px;
  overflow: hidden;
}

.mentor-public__cover,
.mentor-studio__cover {
  position: relative;
  min-height: 310px;
  overflow: hidden;
  isolation: isolate;
}

.mentor-public__cover-media,
.mentor-studio__cover-media {
  position: absolute;
  inset: -10px;
  background-size: cover;
  background-position: center;
  filter: blur(4px) brightness(0.9);
  transform: scale(1.03);
}

.mentor-public__cover-media--fallback,
.mentor-studio__cover-media--fallback {
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 205, 142, 0.25), transparent 28%),
    radial-gradient(circle at 80% 18%, rgba(84, 139, 194, 0.2), transparent 26%),
    linear-gradient(135deg, #2e1d14 0%, #102033 40%, #0c1520 100%);
}

.mentor-public__cover-overlay,
.mentor-studio__cover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 11, 19, 0.18) 0%, rgba(7, 11, 19, 0.64) 100%);
}

.mentor-public__topbar,
.mentor-studio__cover-header {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding: 28px;
}

.mentor-cover-flag {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  max-width: min(320px, calc(100vw - 84px));
  min-width: 0;
  padding: 12px 14px 12px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background:
    linear-gradient(135deg, rgba(4, 6, 10, 0.76) 0%, rgba(18, 24, 35, 0.62) 100%),
    rgba(6, 10, 16, 0.54);
  box-shadow:
    0 18px 36px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(18px) saturate(1.1);
  -webkit-backdrop-filter: blur(18px) saturate(1.1);
  overflow: hidden;
}

.mentor-cover-flag::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.14), transparent 42%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.06) 0%, rgba(0, 0, 0, 0.2) 100%);
  pointer-events: none;
}

.mentor-cover-flag__country,
.mentor-cover-flag__emoji {
  position: relative;
  z-index: 1;
}

.mentor-cover-flag__country {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: rgba(248, 251, 255, 0.96);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.mentor-cover-flag__emoji {
  flex: 0 0 auto;
  font-size: 1.5rem;
  line-height: 1;
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.35));
}

.mentor-public__topbar-actions,
.mentor-public__rail-actions,
.mentor-studio__cover-actions,
.mentor-studio__media-actions,
.mentor-studio__url-actions,
.profile-message-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.mentor-public__hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  padding: 0 32px 32px;
  align-items: start;
  position: relative;
  z-index: 2;
}

.mentor-public__identity,
.mentor-studio__cover-meta {
  display: flex;
  gap: 22px;
}

.mentor-public__identity {
  align-items: flex-start;
  gap: 26px;
  margin-top: -84px;
}

.mentor-studio__cover-meta {
  align-items: flex-end;
}

.mentor-public__avatar,
.mentor-studio__avatar {
  width: 168px;
  height: 168px;
  border-radius: 36px;
  overflow: hidden;
  flex-shrink: 0;
  border: 5px solid rgba(9, 15, 24, 0.92);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35);
  background:
    linear-gradient(140deg, rgba(215, 161, 107, 0.24), rgba(78, 126, 177, 0.18)),
    rgba(255, 255, 255, 0.04);
}

.mentor-public__avatar img,
.mentor-studio__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mentor-public__avatar--placeholder,
.mentor-studio__avatar--placeholder {
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 4rem;
}

.mentor-public__identity-body,
.mentor-studio__hero-copy {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.mentor-public__identity-body {
  padding-top: 56px;
}

.mentor-public__eyebrow,
.mentor-studio__eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  color: rgba(245, 248, 252, 0.78);
}

.mentor-public__name,
.mentor-studio__cover-header h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 5vw, 4.9rem);
  line-height: 0.95;
}

.mentor-public__headline,
.mentor-studio__cover-header p {
  margin: 0;
  max-width: 760px;
  color: rgba(244, 248, 253, 0.86);
  font-size: 1.06rem;
  line-height: 1.7;
}

.mentor-public__roleline {
  margin: 0;
  color: var(--account-accent);
  font-weight: 600;
  letter-spacing: 0.01em;
}

.mentor-public__chips,
.mentor-studio__hero-chips,
.mentor-public__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.mentor-public__chip,
.mentor-studio__hero-chip,
.mentor-public__tag {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--account-border);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.9rem;
}

.mentor-public__rail,
.mentor-studio__sidebar {
  display: grid;
  gap: 22px;
  align-content: start;
}

.mentor-public__rail-actions {
  margin-top: 0;
}

.mentor-public__rail-card,
.mentor-studio__panel,
.mentor-public__panel {
  border-radius: 28px;
  padding: 24px;
}

.mentor-public__rail-card,
.mentor-public__panel {
  display: grid;
  gap: 18px;
  align-content: start;
}

.mentor-studio__panel {
  display: grid;
  gap: 18px;
  align-content: start;
}

.mentor-public__rail-card h2,
.mentor-studio__panel h2,
.mentor-public__panel h2 {
  margin: 0 0 10px;
  font-size: 1.2rem;
}

.mentor-public__rail-card p,
.mentor-studio__panel-header p,
.mentor-public__panel p,
.mentor-studio__url-hint,
.mentor-message-card__header p,
.profile-message-modal__subtitle {
  margin: 0;
  color: var(--account-muted);
  line-height: 1.65;
}

.mentor-public__link,
.mentor-studio__url-preview strong {
  color: #f8fbff;
  text-decoration: none;
  word-break: break-word;
}

.mentor-public__cta {
  display: grid;
  gap: 10px;
  margin-top: 0;
}

.mentor-public__owner-note {
  color: var(--account-muted);
  font-size: 0.92rem;
}

.mentor-public__content,
.mentor-studio__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
}

.mentor-public__content {
  align-items: start;
}

.mentor-public__panel--about {
  min-height: 0;
}

.mentor-public__panel--media video,
.mentor-studio__media-card video {
  width: 100%;
  border-radius: 20px;
  border: 1px solid var(--account-border);
  background: rgba(0, 0, 0, 0.3);
}

.mentor-public__details {
  display: grid;
  gap: 14px;
  margin: 0;
}

.mentor-public__details div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  padding: 14px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.mentor-public__details div:first-child {
  border-top: none;
  padding-top: 0;
}

.mentor-public__details dt {
  color: var(--account-muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.mentor-public__details dd {
  margin: 0;
  color: #f5f8fc;
}

.mentor-public__empty,
.mentor-studio__inbox-empty {
  color: var(--account-muted);
}

.mentor-public__chips--locked {
  margin-top: 18px;
}

.mentor-public__chip--redacted {
  min-height: 42px;
  min-width: 110px;
  color: transparent;
  border-color: rgba(255, 255, 255, 0.12);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.08));
}

.mentor-public__chip--redacted-wide {
  min-width: 180px;
}

.mentor-public__content--locked {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mentor-public__panel--locked {
  min-height: 220px;
}

.mentor-public__redacted-lines {
  display: grid;
  gap: 14px;
  padding-top: 8px;
  filter: blur(8px);
  user-select: none;
  pointer-events: none;
}

.mentor-public__redacted-line {
  display: block;
  height: 14px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.32), rgba(255, 255, 255, 0.16));
}

.mentor-public__redacted-line--full {
  width: 100%;
}

.mentor-public__redacted-line--medium {
  width: 74%;
}

.mentor-public__redacted-line--short {
  width: 58%;
}

.mentor-studio .account-form-grid {
  gap: 22px 16px;
}

.mentor-studio .account-field {
  gap: 12px;
}

.mentor-studio__sidebar {
  gap: 22px;
}

.mentor-studio__cover {
  padding-bottom: 28px;
  border-radius: 40px;
  overflow: hidden;
}

.mentor-studio__cover-actions {
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  flex: 0 0 auto;
}

.mentor-studio__cover-header > div:first-child,
.mentor-studio__cover-meta {
  position: relative;
  z-index: 1;
}

.mentor-studio__cover-meta {
  padding: 0 28px;
  margin-top: 8px;
}

.mentor-studio__main {
  display: grid;
  gap: 22px;
}

.mentor-studio__panel-header {
  display: grid;
  gap: 10px;
  margin-bottom: 0;
}

.mentor-studio__media-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--account-border);
  background: rgba(255, 255, 255, 0.03);
}

.mentor-studio__media-card h3,
.mentor-message-card h3 {
  margin: 0;
  font-size: 1rem;
}

.mentor-studio__url-preview {
  display: grid;
  gap: 10px;
  padding: 16px 18px;
  border-radius: 20px;
  border: 1px solid var(--account-border);
  background: rgba(255, 255, 255, 0.03);
  margin-bottom: 0;
}

.mentor-studio__url-preview span,
.mentor-message-card__status,
.mentor-message-card__meta span {
  color: var(--account-muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mentor-studio__inbox {
  display: grid;
  gap: 14px;
}

.mentor-message-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--account-border);
  background: rgba(255, 255, 255, 0.03);
}

.mentor-message-card--unread {
  border-color: rgba(215, 161, 107, 0.4);
  background: rgba(215, 161, 107, 0.08);
}

.mentor-message-card__header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.mentor-message-card__meta {
  text-align: right;
}

.mentor-message-card__body {
  margin: 0;
  white-space: pre-wrap;
  line-height: 1.7;
}

.mentor-message-card__action {
  justify-self: flex-start;
}

.profile-message-modal__dialog {
  width: min(560px, 100%);
}

.profile-message-modal__actions {
  justify-content: flex-end;
  margin-top: 18px;
}

.mentor-public__back {
  backdrop-filter: blur(10px);
}

@media (max-width: 1100px) {
  .mentor-public__hero,
  .mentor-public__content,
  .mentor-studio__layout {
    grid-template-columns: 1fr;
  }

  .mentor-public__rail,
  .mentor-studio__sidebar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .mentor-public__topbar,
  .mentor-studio__cover-header,
  .mentor-public__hero,
  .mentor-public__content,
  .mentor-studio__cover-meta,
  .mentor-studio__layout {
    padding-left: 18px;
    padding-right: 18px;
  }

  .mentor-public__identity,
  .mentor-studio__cover-meta,
  .mentor-message-card__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .mentor-public__identity {
    margin-top: -68px;
  }

  .mentor-public__identity-body {
    padding-top: 0;
  }

  .mentor-public__avatar,
  .mentor-studio__avatar {
    width: 132px;
    height: 132px;
    border-radius: 28px;
  }

  .mentor-public__rail,
  .mentor-studio__sidebar {
    grid-template-columns: 1fr;
  }

  .mentor-public__details div {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .mentor-studio__cover,
  .mentor-public__frame {
    border-radius: 28px;
  }
}

@media (max-width: 640px) {
  .mentor-public__topbar,
  .mentor-studio__cover-header {
    align-items: flex-start;
  }

  .mentor-cover-flag {
    padding: 10px 12px;
    border-radius: 16px;
  }

  .mentor-cover-flag__country {
    display: none;
  }

  .mentor-public__rail-actions,
  .mentor-studio__media-actions,
  .mentor-studio__url-actions,
  .profile-message-modal__actions {
    width: 100%;
  }

  .mentor-public__rail-actions .btn,
  .mentor-studio__media-actions .btn,
  .mentor-studio__url-actions .btn,
  .profile-message-modal__actions .btn {
    width: 100%;
  }

  .mentor-studio__cover-actions {
    width: auto;
  }

  .mentor-studio__cover-actions .btn {
    width: auto;
  }

  .mentor-public__hero,
  .mentor-public__content,
  .mentor-studio__layout,
  .mentor-studio__main {
    gap: 16px;
  }

  .mentor-public__panel,
  .mentor-studio__panel,
  .mentor-public__rail-card {
    padding: 18px;
    border-radius: 22px;
  }
}

/* ============================================
   Profile page — theme-aligned overrides
   Keep the premium layout, but inherit the
   site-wide light and dark theme system.
   ============================================ */

body[data-page="profile"] {
  background: var(--profile-page-bg);
}

body[data-page="profile"]::before {
  background: radial-gradient(circle, var(--profile-panel-glow-primary) 0%, transparent 60%);
}

body[data-page="profile"]::after {
  background: radial-gradient(circle, var(--profile-panel-glow-secondary) 0%, transparent 60%);
}

body[data-page="profile"] .account-empty,
body[data-page="profile"] .account-shell,
body[data-page="profile"] .profile-public,
body[data-page="profile"] .mentor-public,
body[data-page="profile"] .mentor-studio {
  color: var(--color-text);
}

body[data-page="profile"] .uni-marquee-wrapper {
  display: none;
}

body[data-page="profile"] .account-empty,
body[data-page="profile"] .account-hero,
body[data-page="profile"] .profile-public__hero,
body[data-page="profile"] .account-panel,
body[data-page="profile"] .profile-public__panel,
body[data-page="profile"] .mentor-public__frame,
body[data-page="profile"] .mentor-studio__cover,
body[data-page="profile"] .mentor-studio__panel,
body[data-page="profile"] .mentor-public__panel,
body[data-page="profile"] .mentor-public__rail-card {
  border-color: var(--account-border);
  background:
    radial-gradient(circle at top left, var(--profile-panel-glow-primary), transparent 28%),
    radial-gradient(circle at bottom right, var(--profile-panel-glow-secondary), transparent 26%),
    linear-gradient(155deg, var(--account-panel-strong) 0%, var(--account-panel) 100%);
  box-shadow: var(--mentor-shadow);
}

body[data-page="profile"] .mentor-public__frame,
body[data-page="profile"] .mentor-public__panel,
body[data-page="profile"] .mentor-public__rail-card {
  border-color: var(--profile-premium-outline-strong);
}

body[data-page="profile"] .account-panel--danger {
  border-color: rgba(200, 76, 92, 0.28);
  background:
    radial-gradient(circle at top left, rgba(200, 76, 92, 0.16), transparent 30%),
    linear-gradient(160deg, var(--account-panel-strong) 0%, rgba(200, 76, 92, 0.08) 100%);
}

body[data-page="profile"] h1,
body[data-page="profile"] h2,
body[data-page="profile"] h3,
body[data-page="profile"] .mentor-public__link,
body[data-page="profile"] .mentor-studio__url-preview strong,
body[data-page="profile"] .mentor-public__details dd,
body[data-page="profile"] .profile-public__list strong {
  color: var(--color-text);
}

body[data-page="profile"] .account-empty p,
body[data-page="profile"] .account-panel__header p,
body[data-page="profile"] .profile-public__panel p,
body[data-page="profile"] .account-hero__lead,
body[data-page="profile"] .profile-public__lead,
body[data-page="profile"] .account-hero__hint,
body[data-page="profile"] .account-media-card p,
body[data-page="profile"] .mentor-studio__panel-header p,
body[data-page="profile"] .mentor-public__panel p,
body[data-page="profile"] .mentor-studio__url-hint,
body[data-page="profile"] .mentor-message-card__header p,
body[data-page="profile"] .profile-message-modal__subtitle,
body[data-page="profile"] .mentor-public__owner-note,
body[data-page="profile"] .mentor-public__empty,
body[data-page="profile"] .mentor-studio__inbox-empty,
body[data-page="profile"] .mentor-studio__media-card p,
body[data-page="profile"] .mentor-message-card__body {
  color: var(--account-muted);
}

body[data-page="profile"] .account-empty__eyebrow,
body[data-page="profile"] .account-hero__eyebrow,
body[data-page="profile"] .profile-public__eyebrow,
body[data-page="profile"] .account-panel__eyebrow {
  background: var(--profile-card-fill);
  border-color: var(--account-border);
  color: var(--account-muted);
}

body[data-page="profile"] .account-avatar,
body[data-page="profile"] .profile-public__avatar,
body[data-page="profile"] .mentor-public__avatar,
body[data-page="profile"] .mentor-studio__avatar {
  border-color: var(--profile-avatar-border);
  background:
    linear-gradient(140deg, var(--account-accent-soft), var(--color-accent-soft)),
    var(--profile-card-fill);
  box-shadow: var(--profile-avatar-shadow);
}

body[data-page="profile"] .account-avatar--placeholder,
body[data-page="profile"] .profile-public__avatar--placeholder,
body[data-page="profile"] .mentor-public__avatar--placeholder,
body[data-page="profile"] .mentor-studio__avatar--placeholder {
  color: var(--color-text);
}

body[data-page="profile"] .account-hero__chip,
body[data-page="profile"] .profile-public__chip,
body[data-page="profile"] .profile-public__list li,
body[data-page="profile"] .mentor-studio__media-card,
body[data-page="profile"] .mentor-message-card,
body[data-page="profile"] .mentor-studio__url-preview {
  background: var(--profile-card-fill);
  border-color: var(--account-border);
  color: var(--color-text);
}

body[data-page="profile"] .profile-public__list span,
body[data-page="profile"] .account-field span,
body[data-page="profile"] .mentor-studio__url-preview span,
body[data-page="profile"] .mentor-message-card__status,
body[data-page="profile"] .mentor-message-card__meta span,
body[data-page="profile"] .mentor-public__details dt {
  color: var(--account-muted);
}

body[data-page="profile"] .mentor-public__details div {
  border-top-color: var(--profile-premium-outline);
}

body[data-page="profile"] .profile-public__media video,
body[data-page="profile"] .account-media-card video,
body[data-page="profile"] .mentor-public__panel--media video,
body[data-page="profile"] .mentor-studio__media-card video {
  border-color: var(--account-border);
  background: var(--color-surface-soft);
}

body[data-page="profile"] .mentor-public__cover-overlay,
body[data-page="profile"] .mentor-studio__cover-overlay {
  background: var(--profile-cover-overlay);
}

body[data-page="profile"] .mentor-cover-flag {
  border-color: var(--profile-cover-chip-border);
  background: var(--profile-cover-flag-bg);
  box-shadow: var(--shadow-glass);
}

body[data-page="profile"] .mentor-cover-flag__country,
body[data-page="profile"] .mentor-public__name,
body[data-page="profile"] .mentor-studio__cover-header h1,
body[data-page="profile"] .mentor-public__chip,
body[data-page="profile"] .mentor-studio__hero-chip,
body[data-page="profile"] .mentor-public__tag,
body[data-page="profile"] .mentor-public__eyebrow,
body[data-page="profile"] .mentor-studio__eyebrow {
  color: var(--profile-cover-hero-text);
}

body[data-page="profile"] .mentor-public__headline,
body[data-page="profile"] .mentor-studio__cover-header p {
  color: var(--profile-cover-hero-copy);
}

body[data-page="profile"] .mentor-public__eyebrow,
body[data-page="profile"] .mentor-studio__eyebrow,
body[data-page="profile"] .mentor-public__chip,
body[data-page="profile"] .mentor-studio__hero-chip,
body[data-page="profile"] .mentor-public__tag {
  background: var(--profile-cover-chip-bg);
  border-color: var(--profile-cover-chip-border);
}

body[data-page="profile"] .form-input {
  background-color: var(--color-input-bg);
  border-color: var(--profile-input-border);
  color: var(--color-text);
}

body[data-page="profile"] .form-input:focus {
  border-color: var(--profile-input-focus);
  box-shadow: 0 0 0 3px var(--profile-input-ring);
}

body[data-page="profile"] .form-input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.72;
}

body[data-page="profile"] .form-input:disabled,
body[data-page="profile"] .form-input[disabled] {
  background-color: var(--color-surface-soft);
  color: var(--color-text-muted);
  border-color: var(--profile-input-border);
}

body[data-page="profile"] select.form-input {
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 12px 8px;
}

body[data-page="profile"][data-theme="light"] select.form-input {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23586664' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
}

body[data-page="profile"][data-theme="dark"] select.form-input {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%2399abc4' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
}

body[data-page="profile"] select.form-input option {
  background: var(--profile-select-option-bg);
  color: var(--profile-select-option-text);
}

body[data-page="profile"] input[type="range"] {
  accent-color: var(--color-primary);
}

body[data-page="profile"] .form-toggle input:checked + .form-toggle__track {
  background: var(--color-primary);
}

body[data-page="profile"] .modal {
  background: linear-gradient(155deg, var(--color-bg-glass-strong) 0%, var(--color-bg-glass) 100%);
  border: 1px solid var(--account-border);
  box-shadow: var(--shadow-hover);
}

body[data-page="profile"] .modal-close {
  color: var(--account-muted);
}

body[data-page="profile"] .modal-close:hover {
  color: var(--color-text);
}

/* ── Layout refinements ──────────────────── */
/* Center avatar within its left column at desktop */
.account-hero__visual {
  justify-items: center;
}

/* Slightly looser line-height for wrapping names */
.account-hero h1,
.profile-public__body h1 {
  line-height: 1.0;
}

.mentor-public__name,
.mentor-studio__cover-header h1 {
  line-height: 1.02;
}

/* Ensure account-hero media actions are also centred */
.account-hero__media-actions {
  justify-content: center;
}

/* Give the mentor public hero rail a bit more flexibility */
.mentor-public__hero {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 300px);
}

/* Slightly tighter cover min-height for cleaner mobile */
@media (max-width: 820px) {
  .mentor-public__cover,
  .mentor-studio__cover {
    min-height: 260px;
  }
}

/* ── University Marquee ──────────────────── */
.uni-marquee-wrapper {
  width: 100%;
  overflow: hidden;
  background: transparent;
  padding: 12px 0;
  display: flex;
  margin-top: 70px;
}

.uni-marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 120s linear infinite;
}

.uni-marquee-content {
  display: flex;
  gap: 12px;
  padding-right: 12px;
}

.uni-logo-box {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background-color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0, 0, 0, 0.05);
}

.uni-logo-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); } 
}

/* ── Global Layout fixes for Marquee ── */
#site-header {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}

/* ============================================
   Mobile responsive polish
   Shared premium mobile layer across every page.
   ============================================ */

:root {
  --mobile-header-offset: 142px;
  --mobile-gutter: clamp(16px, 4.8vw, 24px);
}

html,
body {
  max-width: 100%;
}

body.sidebar-is-open {
  overflow: hidden;
  touch-action: none;
}

.sidebar__controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0 24px 18px;
}

.sidebar__controls .pill-toggle {
  width: 100%;
  justify-content: center;
  opacity: 1;
  animation: none;
}

.sidebar__controls .pill-toggle__button {
  min-height: 42px;
  flex: 1;
}

.sidebar__user {
  gap: 8px;
  padding: 16px 24px;
  margin-top: auto;
  border-top: 1px solid var(--color-border);
}

.sidebar__user a,
.sidebar__user button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--color-border-glass);
  background: var(--color-bg-glass);
  color: var(--color-text);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 990px) {
  html {
    overflow-x: hidden;
  }

  body {
    overflow-x: hidden;
    letter-spacing: 0;
  }

  h1,
  h2,
  h3,
  p,
  a,
  button,
  input,
  textarea,
  select,
  .page-section__title,
  .mentor-public__name,
  .mentor-studio__cover-header h1 {
    letter-spacing: 0;
    overflow-wrap: anywhere;
  }

  .container,
  .page-section__inner {
    max-width: 100%;
    padding-left: var(--mobile-gutter);
    padding-right: var(--mobile-gutter);
  }

  #site-header {
    z-index: 1000;
  }

  .site-header {
    padding: 9px 0;
    min-height: 64px;
  }

  .header-container,
  .site-header .header-container {
    grid-template-columns: auto auto;
    min-height: 46px;
    padding-left: var(--mobile-gutter);
    padding-right: var(--mobile-gutter);
    column-gap: 12px;
  }

  .header-brand {
    min-width: 0;
  }

  .header-brand__logo {
    height: 32px;
    border-radius: 7px;
  }

  .header-brand__name {
    font-size: 1.05rem;
    white-space: nowrap;
  }

  .header-nav,
  .header-auth,
  .site-header .header-user,
  .site-header .pill-toggle,
  body[data-page="home"] .site-header .pill-toggle--theme {
    display: none !important;
  }

  .site-header .header-actions {
    grid-column: 2;
    justify-self: end;
    max-width: none;
    gap: 0;
  }

  .menu-toggle {
    display: inline-flex;
    width: 46px;
    height: 46px;
    margin-left: 0;
    opacity: 1;
    animation: none;
  }

  .uni-marquee-wrapper {
    margin-top: 64px;
    padding: 8px 0;
  }

  .uni-logo-box {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    padding: 5px;
  }

  .uni-marquee-content {
    gap: 9px;
    padding-right: 9px;
  }

  .sidebar {
    right: 0;
    width: min(360px, 100vw);
    max-width: 100vw;
    padding: calc(72px + env(safe-area-inset-top, 0px)) 0 calc(20px + env(safe-area-inset-bottom, 0px));
    gap: 0;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.34s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .sidebar.active {
    right: 0;
    transform: translateX(0);
  }

  .sidebar__header {
    padding: 0 24px 18px;
  }

  .sidebar__brand {
    font-size: 1.25rem;
  }

  .sidebar-links {
    gap: 6px;
    padding: 8px 16px 16px;
  }

  .sidebar-links a {
    min-height: 48px;
    padding: 12px 14px;
    font-size: 1.08rem;
    border-radius: 14px;
  }

  .sidebar-links a:hover {
    transform: none;
  }

  .sidebar__auth {
    padding: 16px 24px 0;
  }

  .sidebar__auth .btn {
    width: 100%;
    min-height: 46px;
  }

  .page-section {
    padding: clamp(42px, 8vh, 72px) 0;
  }

  .page-section--hero,
  .page-section--hero-full {
    min-height: auto;
    padding-top: var(--mobile-header-offset);
    padding-bottom: clamp(34px, 7vh, 58px);
  }

  .page-section__badge,
  .page-header__badge {
    margin-bottom: 14px;
  }

  .page-section__title {
    font-size: clamp(1.9rem, 8vw, 2.65rem);
    line-height: 1.08;
    margin-bottom: 14px;
  }

  .page-section__lead {
    font-size: 1rem;
    line-height: 1.65;
  }

  .btn,
  .btn--lg {
    min-height: 46px;
    padding: 13px 20px;
    font-size: 1rem;
  }

  .cta-group,
  .form-actions,
  .account-actions {
    gap: 10px;
  }

  .hero-showcase {
    gap: 24px;
  }

  .hero-showcase__center {
    padding-top: 0;
  }

  .hero-showcase__center .page-section__title {
    font-size: clamp(1.95rem, 8.5vw, 2.75rem);
  }

  .hero-showcase__side {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 14px;
  }

  .hero-card {
    width: 100%;
    max-width: 180px;
  }

  .hero-card:hover,
  .glass-card:hover,
  .team-card:hover,
  .profile-card:hover,
  .bento-item:hover {
    transform: none;
  }

  .hero-card__label {
    min-height: 2.6em;
    margin-top: 10px;
  }

  .card-grid,
  .card-grid--3,
  .card-grid--4,
  #card-grid.card-grid,
  .how-it-works__grid,
  .illustrations-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .impact-grid,
  .stats__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .impact-stat,
  .stat-card,
  .glass-card,
  .team-card {
    padding: 18px;
    border-radius: 20px;
  }

  .impact-stat__number,
  .stat-card__value {
    font-size: clamp(1.8rem, 9vw, 2.6rem);
  }

  .footer {
    min-height: 0;
    padding: 44px 0 24px;
  }

  .footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 18px;
    text-align: left;
  }

  .footer__brand {
    justify-content: flex-start;
  }

  .browse-section,
  .contact-page,
  .legal-page,
  .admin-page,
  body[data-page="profile"] .profile-page {
    padding-top: var(--mobile-header-offset);
  }

  body[data-page="signup"] .form-page,
  .form-page {
    align-items: flex-start;
    justify-content: flex-start;
    min-height: auto;
    padding: var(--mobile-header-offset) var(--mobile-gutter) 48px;
  }

  .form-container,
  .form-container--wide {
    max-width: 100%;
  }

  .form-card {
    padding: 22px;
    border-radius: 24px;
  }

  .form-card__title {
    font-size: clamp(1.55rem, 7vw, 2rem);
  }

  .form-row,
  .role-selector,
  .account-form-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .form-input,
  .form-group input,
  .form-group textarea,
  .browse-select,
  .search-input,
  .admin-table select {
    min-height: 46px;
    font-size: 16px;
  }

  .pw-requirements {
    gap: 7px;
  }

  .pw-req {
    font-size: 0.78rem;
    padding: 5px 10px;
  }

  .form-toggle {
    align-items: flex-start;
  }

  .upload-area {
    padding: 22px 16px;
  }

  .browse-header {
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 18px;
  }

  .browse-header__text h1,
  .page-header h1 {
    font-size: clamp(1.7rem, 8vw, 2.35rem);
    line-height: 1.08;
  }

  .browse-toolbar,
  .browse-filters {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    gap: 10px;
  }

  .search-wrap {
    min-width: 0;
    width: 100%;
  }

  .browse-select {
    width: 100%;
    min-width: 0;
  }

  .results-count {
    margin-bottom: 14px;
  }

  .profile-card {
    border-radius: 24px;
    overflow: hidden;
  }

  .profile-card__banner {
    height: 118px;
  }

  .profile-card__body {
    padding: 16px 18px 20px;
  }

  .profile-card__name,
  .chatbot-mentor-card__name {
    overflow-wrap: break-word;
  }

  .profile-card__location,
  .profile-card__email,
  .profile-card__tagline,
  .profile-card__university {
    justify-content: center;
    overflow-wrap: anywhere;
  }

  .profile-card__cta,
  .profile-card__veil {
    width: 100%;
  }

  .split-hero {
    min-height: auto;
    padding-top: 0;
    padding-bottom: 44px;
  }

  .split-hero__container {
    grid-template-columns: 1fr;
    width: 100%;
    gap: 22px;
    padding-top: 0;
  }

  .contact-page .split-hero__left,
  .contact-page .split-hero__right,
  .contact-page .page-header,
  .contact-page .bento-grid {
    max-width: 100%;
  }

  .contact-page .split-hero__right {
    order: 0;
  }

  .contact-page h1,
  .contact-page .page-header h1,
  .contact-page .lead,
  .contact-page .page-header .lead {
    text-align: left;
  }

  .bento-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
    gap: 16px;
  }

  .bento-item,
  .bento-item--large,
  .bento-item--wide,
  .bento-item--tall,
  .bento-item--standard {
    grid-column: auto;
    grid-row: auto;
    flex-direction: column;
  }

  .bento-item__body,
  .bento-item--large .bento-item__body,
  .bento-item--wide .bento-item__body {
    padding: 18px;
  }

  .bento-item__img-wrap,
  .bento-item__multi-img-wrap {
    min-height: 170px;
  }

  .legal-page section {
    width: 100%;
  }

  .legal-content {
    padding: 20px !important;
    border-radius: 22px;
  }

  .legal-content ul {
    padding-left: 18px;
  }

  .admin-tabs {
    width: 100%;
    overflow-x: auto;
    flex-wrap: nowrap;
    justify-content: flex-start;
    padding: 5px;
    -webkit-overflow-scrolling: touch;
  }

  .admin-tab {
    flex: 0 0 auto;
    min-width: max-content;
    min-height: 42px;
    white-space: nowrap;
  }

  .admin-table,
  .admin-table thead,
  .admin-table tbody,
  .admin-table tr,
  .admin-table td {
    display: block;
    width: 100%;
  }

  .admin-table thead {
    display: none;
  }

  .admin-table tr {
    margin-bottom: 14px;
    padding: 14px;
    border: 1px solid var(--color-border-glass);
    border-radius: 18px;
    background: var(--color-bg-glass);
    box-shadow: var(--shadow-sm);
  }

  .admin-table td {
    display: grid;
    grid-template-columns: minmax(96px, 38%) minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--color-border);
    overflow-wrap: anywhere;
  }

  .admin-table td:last-child {
    border-bottom: 0;
  }

  .admin-table td::before {
    content: attr(data-label);
    color: var(--color-text-muted);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
  }

  .request-card .btn,
  .request-card button {
    min-width: 0;
  }

  .profile-public__hero,
  .account-hero {
    grid-template-columns: 1fr;
    padding: 22px;
    border-radius: 26px;
  }

  .profile-public__grid,
  .account-layout,
  .mentor-public__hero,
  .mentor-public__content,
  .mentor-studio__layout {
    grid-template-columns: 1fr;
  }

  .profile-public__avatar,
  .account-avatar {
    width: min(220px, 100%);
    justify-self: center;
  }

  .account-hero__actions,
  .account-hero__media-actions,
  .account-media-card__actions,
  .profile-cropper__actions,
  .profile-cover-cropper__actions,
  .profile-cover-actions-modal__footer,
  .profile-delete-modal__actions,
  .profile-message-modal__actions,
  .mentor-public__rail-actions,
  .mentor-studio__media-actions,
  .mentor-studio__url-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
  }

  .account-hero__actions .btn,
  .account-hero__media-actions .btn,
  .account-media-card__actions .btn,
  .profile-cropper__actions .btn,
  .profile-cover-cropper__actions .btn,
  .profile-cover-actions-modal__footer .btn,
  .profile-delete-modal__actions .btn,
  .profile-message-modal__actions .btn,
  .mentor-public__rail-actions .btn,
  .mentor-studio__media-actions .btn,
  .mentor-studio__url-actions .btn {
    width: 100%;
  }

  .mentor-public__frame,
  .mentor-studio__cover,
  .account-empty,
  .account-panel,
  .profile-public__panel,
  .mentor-public__panel,
  .mentor-public__rail-card,
  .mentor-studio__panel {
    border-radius: 24px;
  }

  .mentor-public__cover,
  .mentor-studio__cover {
    min-height: 240px;
  }

  .mentor-public__topbar,
  .mentor-studio__cover-header,
  .mentor-public__hero,
  .mentor-public__content,
  .mentor-studio__cover-meta,
  .mentor-studio__layout {
    padding-left: 18px;
    padding-right: 18px;
  }

  .mentor-public__identity,
  .mentor-studio__cover-meta,
  .mentor-message-card__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .mentor-public__identity {
    margin-top: -58px;
  }

  .mentor-public__identity-body {
    padding-top: 0;
  }

  .mentor-public__avatar,
  .mentor-studio__avatar {
    width: 124px;
    height: 124px;
    border-radius: 26px;
  }

  .mentor-public__name,
  .mentor-studio__cover-header h1 {
    font-size: clamp(2rem, 11vw, 3rem);
  }

  .mentor-public__chips,
  .mentor-studio__hero-chips,
  .mentor-public__tags,
  .profile-public__chips {
    gap: 8px;
  }

  .mentor-public__chip,
  .mentor-studio__hero-chip,
  .mentor-public__tag,
  .profile-public__chip {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .mentor-public__details div {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .modal,
  .profile-modal,
  .profile-message-modal__dialog,
  .profile-crop-modal,
  .profile-cover-crop-modal,
  .profile-cover-actions-modal {
    width: calc(100vw - 32px);
    max-width: calc(100vw - 32px);
    max-height: calc(100svh - 32px);
    margin: 0;
    padding: 20px;
    border-radius: 22px;
  }

  .profile-cropper,
  .profile-cover-cropper {
    grid-template-columns: 1fr;
  }

  .profile-cropper__viewport {
    width: min(100%, 320px);
    margin: 0 auto;
  }

  .profile-cover-cropper__viewport {
    width: 100%;
  }

  .minba-chatbot {
    right: 12px;
    left: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    align-items: stretch;
  }

  .chatbot-launcher {
    align-self: flex-end;
    width: 58px;
    height: 58px;
  }

  .chatbot-nudge {
    align-self: flex-end;
    width: min(320px, calc(100vw - 24px));
    padding: 14px;
  }

  .chatbot-panel {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: calc(82px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-height: min(72svh, 620px);
    padding: 18px;
    border-radius: 22px;
    transform-origin: bottom center;
  }

  .chatbot-messages {
    min-height: 140px;
    max-height: min(42svh, 330px);
  }

  .chatbot-form {
    grid-template-columns: 1fr;
  }

  .chatbot-form__send {
    min-width: 0;
    width: 100%;
  }

  .chatbot-mentor-card,
  .chatbot-mentor-card__content {
    align-items: flex-start;
  }

  .chatbot-picker__list {
    max-height: min(30svh, 240px);
  }

  body[data-page="globe"] .site-header .pill-toggle {
    display: none !important;
  }

  body[data-page="globe"] .gs {
    min-height: 100svh;
    padding: calc(120px + env(safe-area-inset-top, 0px)) var(--mobile-gutter) 0;
  }

  body[data-page="globe"] .gs--hero {
    align-items: center;
    padding-top: calc(80px + env(safe-area-inset-top, 0px));
  }

  body[data-page="globe"] .gs--hero .gs__inner {
    padding-bottom: 25svh;
  }

  body[data-page="globe"] .gs--discover,
  body[data-page="globe"] .gs--connect,
  body[data-page="globe"] .gs--impact,
  body[data-page="globe"] .gs--cta {
    justify-content: center;
    padding-right: var(--mobile-gutter);
  }

  body[data-page="globe"] .gs__inner,
  body[data-page="globe"] .gs--discover .gs__inner {
    max-width: 100%;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }

  body[data-page="globe"] .gs-routes {
    margin-left: auto;
    margin-right: auto;
  }

  body[data-page="globe"] .gs-route {
    justify-content: center;
  }

  body[data-page="globe"] .gs-connect-stats,
  body[data-page="globe"] .gs-impact-grid {
    gap: 14px;
  }
}

@media (max-width: 640px) {
  :root {
    --mobile-header-offset: 132px;
  }

  .page-section {
    padding: 38px 0;
  }

  .page-section--hero,
  .page-section--hero-full,
  .browse-section,
  .contact-page,
  .legal-page,
  .admin-page,
  body[data-page="profile"] .profile-page,
  body[data-page="signup"] .form-page,
  .form-page {
    padding-top: var(--mobile-header-offset);
  }

  .page-section__title {
    font-size: clamp(1.75rem, 9vw, 2.25rem);
  }

  .page-section__lead {
    font-size: 0.96rem;
  }

  .cta-group,
  .form-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .cta-group .btn,
  .form-actions .btn {
    width: 100%;
  }

  .hero-showcase__side {
    gap: 12px;
  }

  .hero-card {
    max-width: none;
  }

  .hero-card__label {
    font-size: 0.78rem;
  }

  .impact-grid,
  .stats__grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }

  .form-card,
  .role-card,
  .glass-card,
  .team-card,
  .profile-card,
  .legal-content {
    border-radius: 20px;
  }

  .role-card {
    padding: 18px;
  }

  .form-toggle__label {
    line-height: 1.45;
  }

  .admin-table td {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .request-card [style*="display:flex"] {
    flex-wrap: wrap;
  }

  .request-card [style*="display:flex;gap:8px"] {
    display: grid !important;
    grid-template-columns: 1fr;
  }

  .request-card .request-status {
    margin-left: 0 !important;
  }

  .profile-public__hero,
  .account-hero,
  .account-empty {
    padding: 18px;
  }

  .account-empty {
    min-height: auto;
  }

  .account-hero h1,
  .profile-public__body h1 {
    font-size: clamp(2rem, 10vw, 2.7rem);
  }

  .mentor-cover-flag {
    max-width: 100%;
  }

  .mentor-cover-flag__country {
    display: inline;
    white-space: normal;
  }

  .mentor-studio__cover-actions {
    width: 100%;
    align-items: stretch;
  }

  .mentor-studio__cover-actions .btn {
    width: 100%;
  }

  .mentor-message-card__meta {
    text-align: left;
  }

  .profile-cover-actions {
    gap: 10px;
  }

  .profile-cover-option {
    padding: 14px;
  }

  .chatbot-panel__header {
    flex-direction: row;
    align-items: flex-start;
  }

  .chatbot-panel__actions {
    width: auto;
    justify-content: flex-end;
  }

  .chatbot-message__bubble {
    max-width: 94%;
    font-size: 0.92rem;
  }

  .chatbot-chip {
    width: 100%;
    border-radius: 14px;
    text-align: left;
  }

  body[data-page="globe"] .gs-impact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  :root {
    --mobile-gutter: 16px;
  }

  .header-brand__name {
    font-size: 1rem;
  }

  .uni-logo-box {
    width: 34px;
    height: 34px;
  }

  .page-section__title,
  .browse-header__text h1,
  .page-header h1 {
    font-size: clamp(1.58rem, 9.5vw, 2.05rem);
  }

  .btn:not(.menu-toggle),
  .btn--lg {
    width: 100%;
  }

  .profile-card__avatar {
    width: 76px;
    height: 76px;
    margin-top: -38px;
  }

  .impact-grid,
  .stats__grid {
    gap: 10px;
  }

  .impact-stat,
  .stat-card {
    padding: 15px 12px;
  }

  .split-hero__container {
    gap: 18px;
  }

  .contact-page .bento-item[style] {
    padding: 18px !important;
  }

  .modal,
  .profile-modal,
  .profile-message-modal__dialog,
  .profile-crop-modal,
  .profile-cover-crop-modal,
  .profile-cover-actions-modal {
    width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
    padding: 18px;
  }

  .chatbot-panel {
    left: 8px;
    right: 8px;
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    padding: 16px;
  }

  .chatbot-panel__badge {
    width: 40px;
    height: 40px;
  }

  .chatbot-panel__title {
    font-size: 1rem;
  }

  body[data-page="globe"] .gs--hero h1 {
    font-size: clamp(1.85rem, 10vw, 2.45rem);
  }

  body[data-page="globe"] .gs-route {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 8px;
  }
}
