/* CSS DESIGN SYSTEM - GUNG WISNU PORTFOLIO (SELINE ANALYTICS THEME) */

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

/* --- CUSTOM VARIABLES --- */
:root {
  /* Colors */
  --color-stone-canvas: #fafaf9;
  --color-pure-white: #ffffff;
  --color-stone-border: #e8e6e5;
  --color-stone-muted: #d6d3d1;
  --color-ash-gray: #a8a29e;
  --color-warm-gray: #78716c;
  --color-ink-black: #0c0a09;
  --color-soot: #1c1917;
  --color-sky-wash: #c1e1f7;
  --color-cyan-signal: #3ba6f1;
  --color-cyan-edge: #3398e1;

  /* Typography — Font Families */
  --font-roobert: 'Inter', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-inter: 'Inter', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Typography — Scale */
  --text-caption: 10px;
  --leading-caption: 2.3;
  --text-body-lg: 16px;
  --leading-body-lg: 1.69;
  --tracking-body-lg: 0.048px;
  --text-subheading: 20px;
  --leading-subheading: 1.2;
  --tracking-subheading: -0.1px;
  --text-heading-sm: 32px;
  --leading-heading-sm: 1.25;
  --tracking-heading-sm: -0.8px;
  --text-display: 52px;
  --leading-display: 1.12;
  --tracking-display: -1.092px;

  /* Typography — Weights */
  --font-weight-regular: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;

  /* Spacing */
  --spacing-unit: 4px;
  --spacing-4: 4px;
  --spacing-8: 8px;
  --spacing-12: 12px;
  --spacing-16: 16px;
  --spacing-24: 24px;
  --spacing-32: 32px;
  --spacing-40: 40px;
  --spacing-48: 48px;
  --spacing-64: 64px;
  --spacing-80: 80px;
  --spacing-96: 96px;
  --spacing-160: 160px;

  /* Layout */
  --page-max-width: 1200px;
  --section-gap: 96px;
  --card-padding: 24px;
  --element-gap: 8px;

  /* Border Radius */
  --radius-md: 4px;
  --radius-lg: 10px;
  --radius-2xl: 16px;
  --radius-full: 9999px;

  /* Named Radii */
  --radius-tags: 9999px;
  --radius-cards: 10px;
  --radius-icons: 4px;
  --radius-inputs: 6px;
  --radius-buttons: 12px;
  --radius-feature-card: 16px;

  /* Shadows */
  --shadow-md: rgba(0, 0, 0, 0.05) 0px 4px 16px 0px;
  --shadow-sm: rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.1) 0px 2px 4px -2px;
  --shadow-subtle: rgba(0, 0, 0, 0.05) 0px 1px 2px 0px;
  --shadow-xl: rgba(17, 12, 46, 0.12) 0px 12px 45px 0px;

  /* Surfaces */
  --surface-canvas: #fafaf9;
  --surface-card: #ffffff;
  --surface-floating-preview: #ffffff;
  --surface-inverted-section: #1c1917;
}

/* --- DARK MODE OVERRIDES (SELINE DARK VARIANT) --- */
html.dark {
  --color-stone-canvas: #0c0a09;
  --color-pure-white: #1c1917;
  --color-stone-border: #2e2a27;
  --color-stone-muted: #44403c;
  --color-ash-gray: #78716c;
  --color-warm-gray: #a8a29e;
  --color-ink-black: #fafaf9;
  --color-soot: #fafaf9;
  --color-sky-wash: rgba(59, 166, 241, 0.15);
  --color-cyan-signal: #3ba6f1;
  --color-cyan-edge: #58b6f5;
  --shadow-md: rgba(0, 0, 0, 0.3) 0px 4px 16px 0px;
  --shadow-xl: rgba(0, 0, 0, 0.5) 0px 12px 45px 0px;
}

/* --- GENERAL RESET & BASE --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--color-stone-canvas);
  color: var(--color-warm-gray);
  font-family: var(--font-inter);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.64;
  letter-spacing: 0.004em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Typography Headings */
h1, h2, h3, h4, h5, h6 {
  color: var(--color-ink-black);
  font-family: var(--font-roobert);
  font-weight: 400;
}

h1 {
  font-size: var(--text-display);
  line-height: var(--leading-display);
  letter-spacing: var(--tracking-display);
}

h2 {
  font-size: var(--text-heading-sm);
  line-height: var(--leading-heading-sm);
  letter-spacing: var(--tracking-heading-sm);
}

h3 {
  font-size: var(--text-subheading);
  line-height: var(--leading-subheading);
  letter-spacing: var(--tracking-subheading);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--color-stone-canvas);
}
::-webkit-scrollbar-thumb {
  background: var(--color-stone-border);
  border-radius: 99px;
  border: 2px solid var(--color-stone-canvas);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-stone-muted);
}

/* --- HIDE FORBIDDEN DECORATIONS --- */
.hero-glow-blob, .glow-blur-back {
  display: none !important;
}

/* --- TYPOGRAPHIC HIGHLIGHT SPAN PATTERN --- */
.highlight-span {
  display: inline-block !important;
  color: var(--color-cyan-edge) !important;
  background-color: var(--color-sky-wash) !important;
  padding: 2px 8px !important;
  border-radius: 4px !important;
  font-weight: 400 !important;
  line-height: 1.15;
}

.gradient-text-indigo {
  display: inline !important;
  background: none !important;
  background-clip: initial !important;
  -webkit-background-clip: initial !important;
  -webkit-text-fill-color: initial !important;
  color: var(--color-cyan-edge) !important;
  padding: 0 !important;
  border-radius: 0 !important;
  font-weight: inherit !important;
}
/* --- NAVIGATION BAR --- */
header.glass-panel {
  background-color: var(--color-pure-white) !important;
  border-bottom: 1px solid var(--color-stone-border) !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  box-shadow: var(--shadow-subtle) !important;
  border-radius: 0 !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 1000 !important;
  transform: none !important;
  padding: 0 !important;
}

header.glass-panel:hover {
  transform: none !important;
  box-shadow: var(--shadow-subtle) !important;
  border-color: var(--color-stone-border) !important;
}

header a.brand-logo-text {
  font-family: var(--font-inter) !important;
  color: var(--color-ink-black) !important;
  transition: color 0.4s ease !important;
}

header a.brand-logo-text:hover {
  color: var(--color-cyan-edge) !important;
}


header nav a {
  font-family: var(--font-inter) !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  color: var(--color-warm-gray) !important;
  padding: 0 12px;
  height: 64px;
  display: inline-flex;
  align-items: center;
  transition: color 0.2s ease;
  text-transform: none !important; /* Undo uppercase */
  letter-spacing: normal !important;
}

header nav a:hover {
  color: var(--color-ink-black) !important;
}

/* Navigation Social Proof Avatar Link */
.avatar-stack {
  display: flex;
  align-items: center;
  padding-left: 8px;
  padding-right: 8px;
}

.avatar-stack img {
  width: 24px;
  height: 24px;
  border-radius: 9999px;
  border: 2px solid var(--color-pure-white);
  margin-left: -8px;
  object-fit: cover;
  flex-shrink: 0;
}

.avatar-stack img:first-child {
  margin-left: 0;
}

/* --- BUTTONS --- */
/* Primary CTA: Cyan Filled */
.btn-gradient, button#send-btn, .primary-cta {
  background: var(--color-cyan-signal) !important;
  border: 1px solid var(--color-cyan-edge) !important;
  color: var(--color-pure-white) !important;
  font-family: var(--font-inter) !important;
  font-weight: 500 !important;
  font-size: 14px !important;
  border-radius: var(--radius-buttons) !important;
  box-shadow: var(--shadow-subtle) !important;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-transform: none !important;
  letter-spacing: normal !important;
}

.btn-gradient:hover:not(:disabled), button#send-btn:hover:not(:disabled), .primary-cta:hover {
  background-color: var(--color-cyan-edge) !important;
  transform: translateY(-1px);
}

.btn-gradient:active, button#send-btn:active {
  transform: translateY(0);
}

/* Secondary Action: Ghost Button */
.ghost-btn, .secondary-ghost {
  background: transparent !important;
  border: 1px solid var(--color-stone-border) !important;
  color: var(--color-ink-black) !important;
  font-family: var(--font-inter) !important;
  font-weight: 400 !important;
  font-size: 14px !important;
  border-radius: var(--radius-buttons) !important;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.ghost-btn:hover, .secondary-ghost:hover {
  background-color: var(--color-stone-canvas) !important;
  border-color: var(--color-stone-muted) !important;
}

/* --- MASCOT STICKER STYLE --- */
.mascot-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 16px;
  pointer-events: none;
}

.mascot-sticker {
  width: 72px;
  height: 72px;
  color: var(--color-warm-gray);
  filter: drop-shadow(rgba(0,0,0,0.1) 0px 3px 4px);
  opacity: 0.75;
  transition: transform 0.4s ease, opacity 0.3s ease;
  pointer-events: auto;
}

.mascot-sticker:hover {
  transform: rotate(-6deg) scale(1.08);
  opacity: 0.95;
  color: var(--color-ink-black);
}

/* --- HERO SECTION 3D PHOTO FRAME --- */
.scene3d {
  perspective: 1000px;
  width: 100%;
  max-width: 380px;
  position: relative;
  z-index: 10;
}

.card3d {
  width: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  border-radius: var(--radius-lg);
  background: var(--color-pure-white);
  border: 1px solid var(--color-stone-border);
  padding: 8px;
  box-shadow: var(--shadow-xl);
}

.card3d-bg {
  display: block !important;
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(59, 166, 241, 0.05), transparent);
  z-index: 1;
  pointer-events: none;
  border: 1px dashed rgba(53, 152, 225, 0.2);
}

.card3d-img-container {
  width: 100% !important;
  height: 380px !important;
  border-radius: 8px !important;
  overflow: hidden !important;
  position: relative;
  z-index: 2;
  background-color: var(--color-stone-canvas);
}

.card3d-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none !important;
  transition: filter 0.5s ease, transform 0.5s ease;
}

.card3d:hover .card3d-img-container img {
  filter: none !important;
  transform: scale(1.02);
}

.glow-blur-back {
  display: none !important; /* Glow blob disabled per design guide */
}

/* Grayscale Logos Row */
.partner-logos-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
  margin-top: 32px;
  border-top: 1px solid var(--color-stone-border);
  padding-top: 24px;
}

.partner-logo {
  height: 24px;
  filter: grayscale(1) opacity(0.4) contrast(0.8);
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.partner-logo:hover {
  filter: grayscale(0.5) opacity(0.8) contrast(1.0);
}

/* Trust Line */
.trust-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--color-warm-gray);
  font-family: var(--font-inter);
}

.star-rating {
  color: var(--color-ink-black);
  letter-spacing: 2px;
}

/* Typewriter subtitle styling */
.typing-cursor {
  color: var(--color-cyan-edge) !important;
  font-weight: 400;
}

/* --- FLAT CONTENT CARD (Quest, Path, Abilities, Missions, Contact) --- */
.glass-panel {
  background: var(--color-pure-white) !important;
  border: 1px solid var(--color-stone-border) !important;
  border-radius: var(--radius-cards) !important; /* 10px */
  box-shadow: var(--shadow-md) !important; /* 16px blur shadow */
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  padding: var(--card-padding) !important; /* 24px */
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease !important;
}

.glass-panel:hover {
  border-color: var(--color-stone-muted) !important;
  box-shadow: var(--shadow-md) !important;
  transform: translateY(-2px);
}

/* Sections margin & spacing */
section {
  padding-top: 80px;
  padding-bottom: 80px;
  scroll-margin-top: 64px;
}

.max-w-7xl {
  max-width: var(--page-max-width) !important;
}

/* --- TIMELINE QUEST LOG --- */
.timeline-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--color-stone-border);
  padding-bottom: 12px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 400;
  background: transparent;
  border: 1px solid var(--color-stone-border);
  color: var(--color-ink-black);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-inter);
}

.filter-btn:hover {
  background-color: var(--color-stone-canvas);
  border-color: var(--color-stone-muted);
}

.filter-btn.active {
  background: var(--color-soot) !important;
  border-color: var(--color-soot) !important;
  color: var(--color-pure-white) !important;
}

/* Timeline container layout */
.timeline-container {
  position: relative;
  padding-left: 2rem !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 3rem !important;
}

.timeline-container::before {
  content: "" !important;
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 0;
  width: 1px;
  background-color: var(--color-stone-border) !important;
  display: block !important;
}

.timeline-item {
  margin-bottom: 0 !important;
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
  position: relative;
  transition: transform 0.2s ease;
}

.timeline-item:hover {
  transform: translateX(4px);
}

.timeline-dot {
  display: block !important;
  position: absolute;
  left: calc(-2rem - 6px) !important; /* Centered on the vertical line */
  top: 8px !important;
  width: 12px !important;
  height: 12px !important;
  border-radius: 9999px !important;
  background-color: var(--color-stone-muted) !important;
  border: none !important;
  z-index: 10;
}

.active-quest .timeline-dot {
  background-color: var(--color-cyan-edge) !important;
  box-shadow: 0 0 0 4px var(--color-sky-wash) !important;
}

.quest-status-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: normal;
  margin-bottom: 12px;
  border: 1px solid var(--color-stone-border) !important;
  background: var(--color-stone-canvas) !important;
  color: var(--color-warm-gray) !important;
  text-transform: none !important;
}

.active-quest .quest-status-badge {
  background: var(--color-sky-wash) !important;
  color: var(--color-cyan-edge) !important;
  border-color: var(--color-sky-wash) !important;
}

/* Style leadership items to match members font but highlight with Seline cyan color */
.role-leadership {
  background: none !important;
  -webkit-background-clip: initial !important;
  -webkit-text-fill-color: initial !important;
  color: var(--color-cyan-edge) !important;
  animation: none !important;
  font-weight: inherit !important; /* matches member bold weight */
}

/* Quest images - product preview style */
.doc-journey-grid {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.doc-img-wrapper {
  width: 100%;
  max-width: 180px;
  aspect-ratio: 16/9 !important;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--color-stone-border);
  cursor: pointer;
  box-shadow: var(--shadow-subtle);
  background-color: var(--color-stone-canvas);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.doc-img-wrapper:hover {
  transform: scale(1.02);
  border-color: var(--color-stone-muted);
}

.doc-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none !important;
  transition: filter 0.3s ease, transform 0.3s ease;
}

.doc-img-wrapper:hover img {
  filter: none !important;
  transform: scale(1.03);
}

.doc-img-wrapper::after {
  display: none !important; /* Remove the "View" black filter overlay */
}

/* --- SKILLS & BADGES --- */
.skill-card {
  overflow: visible !important;
}

.skill-card::before {
  display: none !important; /* Remove colored glow overlays */
}

.skill-badge {
  background: var(--color-stone-canvas) !important;
  color: var(--color-warm-gray) !important;
  border: 1px solid var(--color-stone-border) !important;
  border-radius: var(--radius-full) !important;
  padding: 4px 12px !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  transition: all 0.2s ease !important;
}

.skill-card:hover .skill-badge {
  background: var(--color-stone-canvas) !important;
  border-color: var(--color-stone-border) !important;
  color: var(--color-warm-gray) !important;
  transform: none !important;
}

.skill-badge:hover {
  background: var(--color-sky-wash) !important;
  border-color: var(--color-sky-wash) !important;
  color: var(--color-cyan-edge) !important;
  transform: translateY(-1px) !important;
}

/* --- MISSIONS (Projects Card) --- */
/* Custom styling for Project Cards to behave like Feature Cards (16px radius) */
#projects .glass-panel {
  border-radius: var(--radius-feature-card) !important; /* 16px */
  overflow: hidden;
  padding: 0 !important; /* We pad internally */
}

#projects .glass-panel img {
  filter: none !important;
  transition: filter 0.4s ease, transform 0.4s ease;
}

#projects .glass-panel:hover img {
  filter: none !important;
}

/* Active Preview Banner Overlay styles */
#projects .glass-panel a div {
  background: rgba(12, 10, 9, 0.4) !important; /* monochrome soot-overlay */
}

#projects .glass-panel a span {
  background: var(--color-soot) !important;
  border: 1px solid var(--color-stone-border);
  border-radius: var(--radius-full);
}

/* Internally pad the body of the project card */
#projects .glass-panel > div:last-child {
  padding: 24px !important;
}

/* --- CONTACT FORM --- */
.contact-input {
  background-color: var(--color-pure-white) !important;
  color: var(--color-ink-black) !important;
  border: 1px solid var(--color-stone-muted) !important;
  border-radius: var(--radius-inputs) !important; /* 6px */
  padding: 8px 12px !important;
  font-family: var(--font-inter) !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.contact-input:focus {
  border-color: var(--color-cyan-signal) !important;
  box-shadow: 0 0 0 2px var(--color-sky-wash) !important;
  background-color: var(--color-pure-white) !important;
}

.contact-input::placeholder {
  color: var(--color-ash-gray) !important;
}

/* --- FOOTER --- */
footer {
  background-color: var(--color-pure-white) !important;
  border-top: 1px solid var(--color-stone-border) !important;
  padding-top: 32px !important;
  padding-bottom: 32px !important;
}

footer p {
  color: var(--color-warm-gray) !important;
}

footer a {
  color: var(--color-warm-gray) !important;
}

footer a:hover {
  color: var(--color-ink-black) !important;
}

/* --- LIGHTBOX MODAL DIALOG (MONOCHROME REDESIGN) --- */
.lightbox-modal {
  position: fixed !important;
  inset: 0 !important;
  z-index: 10000 !important;
  display: none !important;
  align-items: center !important;
  justify-content: center !important;
  background: rgba(250, 250, 249, 0.98) !important; /* warm-stone backdrop */
}

html.dark .lightbox-modal {
  background: rgba(12, 10, 9, 0.98) !important; /* Seline dark backdrop */
}

.lightbox-modal.open {
  display: flex !important;
}

.lightbox-close-btn {
  position: absolute !important;
  top: 24px !important;
  right: 24px !important;
  font-size: 36px !important;
  font-weight: 300 !important;
  color: var(--color-ink-black) !important;
  background: transparent !important;
  border: none !important;
  cursor: pointer !important;
  line-height: 1 !important;
  transition: transform 0.2s ease !important;
}

.lightbox-close-btn:hover {
  transform: scale(1.15) !important;
}

.lightbox-content {
  max-width: 90vw !important;
  max-height: 85vh !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 16px !important;
}

.lightbox-image {
  max-width: 100% !important;
  max-height: 75vh !important;
  border-radius: var(--radius-cards) !important;
  border: 1px solid var(--color-stone-border) !important;
  box-shadow: var(--shadow-xl) !important;
  object-fit: contain !important;
}

.lightbox-caption {
  font-family: var(--font-inter) !important;
  color: var(--color-warm-gray) !important;
  font-size: 14px !important;
  text-align: center !important;
}

/* --- SCROLL REVEAL (Clean fade) --- */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform, opacity;
}

.reveal-on-scroll.active {
  opacity: 1;
  transform: translateY(0);
}

/* Mobile responsive fixes */
@media (max-width: 768px) {
  h1 {
    font-size: 38px !important;
    line-height: 1.15 !important;
  }
  
  h2 {
    font-size: 26px !important;
  }
  
  .timeline-container {
    padding-left: 1.5rem !important;
    gap: 2rem !important;
  }
  
  .timeline-dot {
    left: calc(-1.5rem - 6px) !important;
  }
}

/* Skill card indicator dots override */
.skill-card h3 span.rounded-full {
  background-color: var(--color-sky-wash) !important;
  border: 1px solid var(--color-cyan-edge) !important;
  width: 8px !important;
  height: 8px !important;
  display: inline-block !important;
}

/* --- EDUCATION PATH LOGO SIZING --- */
.edu-logo-container {
  width: 56px !important;
  height: 56px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  overflow: hidden !important;
}

/* --- PROJECTS/MISSIONS SEAMLESS GRADIENT BLENDING --- */
#projects .glass-panel a div.bg-gradient-to-t {
  background-image: linear-gradient(to top, var(--color-pure-white) 15%, rgba(255, 255, 255, 0.2) 65%, transparent) !important;
}

html.dark #projects .glass-panel a div.bg-gradient-to-t {
  background-image: linear-gradient(to top, var(--color-pure-white) 15%, rgba(28, 25, 23, 0.2) 65%, transparent) !important;
}

/* Projects tag badges color overrides */
.glass-panel .flex.flex-wrap.gap-2 span {
  background: var(--color-stone-canvas) !important;
  color: var(--color-warm-gray) !important;
  border: 1px solid var(--color-stone-border) !important;
}

html.dark .glass-panel .flex.flex-wrap.gap-2 span {
  background: rgba(255, 255, 255, 0.05) !important;
  color: rgba(255, 255, 255, 0.8) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.glass-panel a.text-indigo-400 {
  color: var(--color-cyan-edge) !important;
}

.glass-panel a.text-indigo-400:hover {
  color: var(--color-cyan-signal) !important;
}

/* --- GLOBAL DAY/NIGHT SWITCH TRANSITION ANIMATIONS --- */
body, header, .glass-panel, .timeline-item, .timeline-dot, h1, h2, h3, h4, h5, h6, p, a, button, input, textarea {
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease, box-shadow 0.4s ease, transform 0.2s ease !important;
}

.theme-toggle-btn svg {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.theme-toggle-btn:active svg {
  transform: rotate(360deg) scale(1.2) !important;
}

/* --- QUEST TIMELINE HEIGHT & TOGGLE CONTROL --- */
/* Show only the top 5 newest items initially */
.timeline-container.show-highlights-only .timeline-item:nth-child(n+6) {
  display: none !important;
}

/* Force identical font size and bold weights for all timeline quest titles */
.timeline-item h3 {
  font-family: var(--font-inter) !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  line-height: var(--leading-subheading) !important;
  letter-spacing: var(--tracking-subheading) !important;
}

@media (min-width: 640px) {
  .timeline-item h3 {
    font-size: 24px !important;
  }
}

/* --- THEME TOGGLE ICON VISIBILITY --- */
.theme-toggle-btn .sun-icon {
  display: none !important;
}
.theme-toggle-btn .moon-icon {
  display: block !important;
}
html.dark .theme-toggle-btn .sun-icon {
  display: block !important;
}
html.dark .theme-toggle-btn .moon-icon {
  display: none !important;
}

/* --- NAVIGATION SCROLLSPY HIGHLIGHTS --- */
header nav a.active {
  color: var(--color-cyan-edge) !important;
  border-bottom: 2px solid var(--color-cyan-edge) !important;
  font-weight: 600 !important;
}

.mobile-menu-panel nav a.active {
  color: var(--color-cyan-edge) !important;
  padding-left: 18px !important;
  border-left: none !important;
  border-bottom: none !important;
}

/* --- MOBILE NAVIGATION PANEL & HAMBURGER BUTTON --- */
.mobile-menu-panel {
  display: none;
  background: var(--color-pure-white) !important;
  border-top: 1px solid var(--color-stone-border);
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 999;
  box-shadow: var(--shadow-lg);
}

.mobile-menu-panel.open {
  display: block !important;
}

html.dark .mobile-menu-panel {
  background: var(--color-soot) !important;
  border-top-color: var(--color-stone-border);
}

.mobile-menu-btn {
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  width: 20px;
  height: 12px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
  position: relative;
}

.burger-line {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--color-ink-black);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

html.dark .burger-line {
  background-color: var(--color-pure-white);
}

/* Burger transform to X when open */
.mobile-menu-btn.open .burger-line:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

.mobile-menu-btn.open .burger-line:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.open .burger-line:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}