/* ── Reset ── */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ── Body ── */
body {
  min-height: 100vh;
  overflow-x: hidden;
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
  color: #f0f0f0;
  font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
  font-size: 16px;
  line-height: 1.7;
  padding: 80px 40px 100px;
  transition: background-color 0.3s ease, background-image 0.3s ease, color 0.3s ease;
}

/* ── Intro Reveal ── */
.reveal-target {
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition: opacity 0.45s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-target.revealed {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

/* ── Background Themes (IDE-inspired) ── */
body.bg-0 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.bg-1 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.bg-2 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.bg-3 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.bg-4 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.bg-5 {
  background-color: #1a1a1a;
  background-image: radial-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* ── Container ── */
.container {
  max-width: 720px;
  margin: 0 auto;
  transition: max-width 0.4s ease, margin-left 0.4s ease, margin-right 0.4s ease, opacity 0.3s ease;
  position: relative;
  z-index: 1;
}

/* ── Header ── */
h1 {
  font-size: 2.2em;
  font-weight: 700;
  margin-bottom: 8px;
  color: #f0f0f0;
}

.prompt {
  color: #9bc3ff;
  margin-right: 12px;
  font-size: 0.64em;
  vertical-align: middle;
  opacity: 0.95;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  padding: 2px 8px;
  border: 1px solid #3a4b60;
  border-radius: 999px;
  background: rgba(88, 166, 255, 0.08);
  letter-spacing: 0.03em;
}

/* ── Name Styles ── */
.name-clickable {
  cursor: pointer;
  display: inline;
  position: relative;
  transition: color 0.15s ease, text-shadow 0.15s ease, letter-spacing 0.15s ease;
  user-select: none;
  -webkit-user-select: none;
}

.name-clickable * {
  user-select: none;
  -webkit-user-select: none;
}

/* 0: Bold (default) */
.name-style-0 {
  font-weight: 700;
  color: #f0f0f0;
  font-family: inherit;
  font-style: normal;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  -webkit-text-fill-color: unset;
  text-shadow: none;
  letter-spacing: normal;
  -webkit-text-stroke: 0;
}

/* 1: Claude Blocks (mattoncini) */
.name-style-1 {
  font-weight: 600;
  font-family: 'SF Pro Rounded', 'Nunito', system-ui, sans-serif;
}

.name-style-1 .name-letter {
  display: inline-block;
  padding: 2px 5px;
  margin: 1px;
  border-radius: 6px;
  color: #2a2a2a;
  font-weight: 700;
  line-height: 1.2;
}

.name-space {
  display: inline-block;
  width: 12px;
}

/* 2: Terminal */
.name-style-2 {
  font-weight: 400;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #00ff41;
  text-shadow: 0 0 8px rgba(0, 255, 65, 0.3);
}

.name-style-2::after {
  content: '_';
  animation: blink 1s step-end infinite;
  color: #00ff41;
}

@keyframes blink {
  50% { opacity: 0; }
}

/* 3: Claude Code */
.name-style-3 {
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #e07a5f;
  text-shadow: 0 0 8px rgba(224, 122, 95, 0.3);
  letter-spacing: 0.5px;
}

/* 4: Orbital Rings */
.name-style-4 {
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #9ac8ff;
  text-shadow: 0 0 10px rgba(120, 186, 255, 0.35);
  letter-spacing: 0.04em;
}

.name-style-4 .orbital-letter {
  position: relative;
  display: inline-block;
  padding: 0 2px;
}

.name-style-4 .orbital-letter::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 16px;
  border: 1px solid rgba(154, 200, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%) rotate(var(--orbit, 0deg));
  pointer-events: none;
}

.name-style-4 .orbital-letter::after {
  content: '';
  position: absolute;
  top: calc(50% - 8px);
  left: calc(50% + 8px);
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #d7ecff;
  box-shadow: 0 0 8px rgba(215, 236, 255, 0.7);
  animation: orbitalPulse 1.8s ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  pointer-events: none;
}

/* 5: CAD Blueprint */
.name-style-5 {
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #8ec5ff;
  letter-spacing: 0.08em;
}

.name-style-5 .blueprint-letter {
  position: relative;
  display: inline-block;
  margin: 0 1px;
  padding: 2px 5px;
  border: 1px solid rgba(142, 197, 255, 0.38);
  background-image:
    linear-gradient(rgba(142, 197, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(142, 197, 255, 0.08) 1px, transparent 1px);
  background-size: 6px 6px;
  border-radius: 4px;
}

.name-style-5 .blueprint-letter::after {
  content: '';
  position: absolute;
  left: 2px;
  right: 2px;
  bottom: 2px;
  border-bottom: 1px dotted rgba(142, 197, 255, 0.4);
}

/* 6: Telemetry HUD */
.name-style-6 {
  font-weight: 500;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #7ce0c1;
  text-shadow: 0 0 8px rgba(124, 224, 193, 0.3);
  letter-spacing: 0.06em;
}

.name-style-6 .telemetry-letter {
  position: relative;
  display: inline-block;
  padding: 1px 3px;
}

.name-style-6 .telemetry-letter::before {
  content: attr(data-bit);
  position: absolute;
  left: 50%;
  bottom: calc(100% - 2px);
  transform: translateX(-50%);
  font-size: 8px;
  color: rgba(124, 224, 193, 0.6);
  letter-spacing: 0;
}

.name-style-6 .telemetry-letter::after {
  content: '';
  position: absolute;
  left: 2px;
  right: 2px;
  top: 50%;
  border-top: 1px solid rgba(124, 224, 193, 0.22);
}

/* 7: Mission Stamp */
.name-style-7 {
  font-weight: 700;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #ffd8b6;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.name-style-7 .mission-letter {
  display: inline-block;
  margin: 0 1px;
  padding: 1px 4px;
  border: 1px solid rgba(255, 216, 182, 0.48);
  border-radius: 3px;
  background: rgba(255, 216, 182, 0.06);
  transform: rotate(var(--tilt, 0deg));
  box-shadow: inset 0 0 0 1px rgba(255, 216, 182, 0.08);
}

/* 8: Claude Grid (inspired) */
.name-style-8 {
  font-weight: 700;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #e38a66;
  letter-spacing: 0.03em;
}

.name-style-8 .claude-grid-letter {
  position: relative;
  display: inline-block;
  margin: 1px;
  padding: 2px 6px;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(227, 138, 102, 0.16) 0 8px,
      rgba(227, 138, 102, 0.24) 8px 9px
    );
  border: 1px solid rgba(227, 138, 102, 0.8);
  box-shadow:
    inset 0 0 0 1px rgba(25, 20, 18, 0.55),
    2px 2px 0 rgba(227, 138, 102, 0.55),
    -2px -2px 0 rgba(227, 138, 102, 0.16);
}

.name-style-8 .claude-grid-letter::before {
  content: '';
  position: absolute;
  inset: -4px;
  border: 1px solid rgba(227, 138, 102, 0.6);
  pointer-events: none;
}

/* 9: Braille Matrix */
.name-style-9 {
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #9ad0ff;
  letter-spacing: 0.04em;
}

.name-style-9 .braille-letter {
  position: relative;
  display: inline-block;
  margin: 0 2px;
  padding: 2px 4px 2px 3px;
}

.name-style-9 .braille-letter::after {
  content: attr(data-braille);
  position: absolute;
  left: 50%;
  top: calc(100% + 1px);
  transform: translateX(-50%);
  font-size: 10px;
  color: rgba(154, 208, 255, 0.82);
  letter-spacing: 0.02em;
}

/* 12: Hebrew Signature */
.name-style-12 {
  font-weight: 700;
  font-family: 'Noto Sans Hebrew', 'Rubik', 'SF Mono', 'Fira Code', monospace;
  color: #f0c7a7;
  letter-spacing: 0.02em;
}

.name-style-12 .hebrew-word {
  direction: rtl;
  unicode-bidi: isolate;
  display: inline-block;
  margin: 0 4px;
}

@keyframes orbitalPulse {
  0%, 100% { transform: scale(0.85); opacity: 0.65; }
  50% { transform: scale(1.2); opacity: 1; }
}

/* ── Profile Photo ── */
.profile-photo-container {
  display: flex;
  justify-content: center;
  margin-bottom: 28px;
}

.profile-photo-wrapper {
  position: relative;
  width: 130px;
  height: 130px;
  cursor: pointer;
}

.profile-photo {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #444444;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  display: block;
}

.profile-photo-wrapper:hover .profile-photo {
  border-color: #58a6ff;
  box-shadow: 0 0 24px rgba(88, 166, 255, 0.35);
  transform: scale(1.06);
}

.profile-photo-tooltip {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: rgba(0, 0, 0, 0.65);
  color: #f0f0f0;
  font-size: 13px;
  font-weight: 600;
  padding: 8px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.profile-photo-wrapper:hover .profile-photo-tooltip {
  opacity: 1;
}

/* ── Role ── */
.role {
  color: #aaaaaa;
  font-size: 1em;
  margin-bottom: 30px;
}

.role span {
  display: block;
}

/* ── Bio ── */
.bio {
  margin-bottom: 40px;
  padding: 16px 20px;
  border-left: 3px solid #444444;
  color: #aaaaaa;
  font-style: italic;
}

/* ── Sections ── */
details {
  margin-bottom: 12px;
}

summary {
  font-size: 1.1em;
  font-weight: 600;
  cursor: pointer;
  padding: 8px 0;
  list-style: none;
  color: #f0f0f0;
}

summary::-webkit-details-marker {
  display: none;
}

summary::before {
  content: '\25B6 ';
  font-size: 0.8em;
}

details[open] summary::before {
  content: '\25BC ';
}

summary:hover {
  color: #58a6ff;
}

.section-content {
  padding: 12px 0 12px 24px;
  color: #f0f0f0;
  animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Lists ── */
ul {
  list-style: disc;
  padding-left: 20px;
}

li {
  margin-bottom: 12px;
  color: #f0f0f0;
}

/* ── Links ── */
a {
  color: #58a6ff;
  text-decoration: underline;
}

a:hover {
  opacity: 0.8;
}

/* ── Focus Styles ── */
.top-bar-btn:focus-visible,
.social-link:focus-visible,
.status-song-link:focus-visible,
.dropdown-option:focus-visible,
.side-panel-close:focus-visible,
.lightbox-close:focus-visible,
.lightbox-nav:focus-visible,
.ignition-btn:focus-visible,
summary:focus-visible {
  outline: 2px solid #58a6ff;
  outline-offset: 2px;
}

.command-input:focus-visible {
  outline: 2px solid #58a6ff;
  outline-offset: 0;
}

/* ── Social Links ── */
.social-links {
  display: flex;
  gap: 12px;
  margin-top: 40px;
}

.social-link {
  padding: 8px 16px;
  border: 1px solid #444444;
  color: #f0f0f0;
  text-decoration: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.social-link:hover {
  background: #333333;
  border-color: #58a6ff;
  color: #58a6ff;
}

.social-icon {
  width: 24px;
  height: 24px;
  border: 1px solid currentColor;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: lowercase;
}

.social-label {
  font-size: 12px;
  letter-spacing: 0.01em;
}

/* ── Status Bar ── */
.status-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px max(20px, env(safe-area-inset-left)) max(10px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-right));
  background: #252525;
  border-top: 1px solid #444444;
  font-size: 12px;
  color: #888888;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  z-index: 100;
}

.status-bar span {
  transition: opacity 0.3s ease;
}

#statusMessage {
  min-width: 180px;
  text-align: center;
  cursor: pointer;
  user-select: none;
  transition: opacity 0.3s ease, color 0.15s;
}

#statusMessage:hover {
  color: #bbb;
}

.ignition-btn {
  background: none;
  border: 1px solid #444444;
  color: #888888;
  padding: 3px 12px;
  font-family: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.2s ease;
  display: flex;
  align-items: center;
  gap: 6px;
  border-radius: 4px;
}

.ignition-btn:hover {
  border-color: #ff6b35;
  color: #ff6b35;
}

#radarBtn:hover {
  border-color: #7cc9ff;
  color: #7cc9ff;
}

.ignition-btn .rocket-icon {
  width: 12px;
  height: 16px;
}

.status-song-link {
  border: 1px solid #444444;
  color: #888888;
  text-decoration: none;
  text-transform: lowercase;
  letter-spacing: 0.04em;
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 4px;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.2s ease;
}

.status-song-link:hover {
  border-color: #58a6ff;
  color: #58a6ff;
  background: rgba(88, 166, 255, 0.08);
}

.radar-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 550;
  overflow: hidden;
}

.radar-dot,
.radar-link {
  position: absolute;
  opacity: 0;
}

.radar-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #8cc0ff;
  box-shadow: 0 0 8px rgba(140, 192, 255, 0.65);
  animation: radarDotPop 1.5s ease-out forwards;
}

.radar-link {
  height: 1px;
  background: linear-gradient(90deg, rgba(115, 170, 235, 0), rgba(115, 170, 235, 0.75), rgba(115, 170, 235, 0));
  transform-origin: 0 50%;
  animation: radarLinkFlash 1.5s ease-out forwards;
}

@keyframes radarDotPop {
  0% { opacity: 0; transform: scale(0.2); }
  35% { opacity: 1; transform: scale(1.1); }
  100% { opacity: 0; transform: scale(0.9); }
}

@keyframes radarLinkFlash {
  0% { opacity: 0; }
  30% { opacity: 1; }
  100% { opacity: 0; }
}

/* ── Top Bar ── */
.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 10px max(20px, env(safe-area-inset-left)) 10px max(20px, env(safe-area-inset-right));
  background: #252525;
  border-bottom: 1px solid #444444;
  display: flex;
  justify-content: center;
  gap: 24px;
  z-index: 600;
}

.top-bar-btn {
  background: none;
  border: 1px solid #444444;
  color: #888888;
  padding: 6px 14px;
  font-family: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.2s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.top-bar-btn:hover {
  background: #333333;
  border-color: #58a6ff;
  color: #58a6ff;
}

.top-bar-btn.active {
  background: #333333;
  border-color: #58a6ff;
  color: #58a6ff;
}

/* ── Dropdowns (shared: lang + mail) ── */
.dropdown-wrapper {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #2a2a2a;
  border: 1px solid #665e5a;
  border-radius: 8px;
  overflow: hidden;
  min-width: 140px;
  z-index: 700;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

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

.dropdown-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  cursor: pointer;
  color: #ccc;
  font-family: inherit;
  font-size: 12px;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  transition: background 0.1s;
  text-decoration: none;
}

.dropdown-option:hover {
  background: #3a3632;
  color: #f0f0f0;
}

.dropdown-option.active {
  color: #f0f0f0;
  background: #3a3632;
}

.dropdown-option .dropdown-icon {
  font-size: 16px;
  line-height: 1;
}

/* Mail dropdown specific */
.mail-dropdown {
  min-width: 240px;
}

.mail-label {
  font-size: 10px;
  color: #666;
  margin-left: auto;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ── Command Palette ── */
.command-palette-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  justify-content: center;
  padding-top: 15vh;
}

.command-palette-overlay.active {
  display: flex;
}

.command-palette {
  width: 100%;
  max-width: 500px;
  background: #252525;
  border: 1px solid #444444;
  border-radius: 8px;
  overflow: hidden;
  height: fit-content;
}

.command-input-wrapper {
  padding: 16px;
  border-bottom: 1px solid #444444;
  display: flex;
  align-items: center;
  gap: 10px;
}

.prompt-symbol {
  color: #58a6ff;
  font-weight: bold;
}

.command-input {
  flex: 1;
  background: none;
  border: none;
  color: #f0f0f0;
  font-family: inherit;
  font-size: 16px;
  outline: none;
}

.command-input::placeholder {
  color: #888888;
}

.command-list {
  max-height: 300px;
  overflow-y: auto;
}

.command-item {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  color: #f0f0f0;
}

.command-item:hover,
.command-item.selected {
  background: #333333;
}

.command-item .shortcut {
  color: #888888;
  font-size: 0.85em;
  margin-left: auto;
}

/* ── Side Panel ── */
body.panel-open .container {
  opacity: 1;
}

.side-panel {
  position: fixed;
  top: 84px;
  left: 50%;
  width: min(640px, calc(100vw - 40px));
  max-height: min(74vh, 760px);
  background: rgba(27, 27, 29, 0.95);
  border: 1px solid #3f434b;
  border-radius: 14px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5),
              0 0 0 1px rgba(120, 164, 214, 0.08);
  padding: 28px 24px;
  overflow-y: auto;
  transform: translate3d(-50%, 8px, 0) scale(0.985);
  transform-origin: center top;
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.24s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  z-index: 750;
  opacity: 0;
  will-change: transform, opacity;
  pointer-events: none;
}

.side-panel.open {
  transform: translate3d(-50%, 0, 0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.side-panel.panel-polish {
  border-color: #5f7693;
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.62),
              0 0 0 1px rgba(108, 169, 232, 0.18);
}

.side-panel-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #444444;
  border-radius: 50%;
  color: #aaa;
  font-size: 18px;
  width: 32px;
  height: 32px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.2s ease;
}

.side-panel-close:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #58a6ff;
  color: #58a6ff;
}

.side-panel-title {
  font-size: 1.15em;
  font-weight: 700;
  margin-bottom: 18px;
  color: #f0f0f0;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.side-panel-text {
  color: #aaaaaa;
  line-height: 1.7;
  margin-bottom: 12px;
  font-size: 0.95em;
}

.side-panel-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.side-panel-tag {
  padding: 3px 10px;
  background: #2f3138;
  border: 1px solid #424753;
  font-size: 0.78em;
  color: #98a0ad;
  position: relative;
  cursor: default;
  border-radius: 999px;
}

.side-panel-tag::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 10px;
  background: #1a1a1a;
  border: 1px solid #58a6ff;
  color: #58a6ff;
  font-size: 11px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  margin-bottom: 6px;
}

.side-panel-tag:hover::after {
  opacity: 1;
}

.clickable-item {
  cursor: pointer;
  transition: color 0.15s;
}

.clickable-item:hover {
  color: #58a6ff;
}

/* ── Photo Gallery ── */
.photo-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 18px;
}

.gallery-thumb {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid #444444;
  border-radius: 6px;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.3s ease,
              border-color 0.3s ease,
              filter 0.3s ease;
  filter: grayscale(20%) brightness(0.95);
  position: relative;
}

.gallery-thumb:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 24px rgba(88, 166, 255, 0.28);
  border-color: #58a6ff;
  filter: grayscale(0%) brightness(1.05);
  z-index: 10;
}

/* ── Lightbox ── */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(8px);
}

.lightbox.open {
  display: flex;
}

.lightbox-img {
  max-width: 85%;
  max-height: 85%;
  object-fit: contain;
  border: 2px solid #444444;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: 1px solid #888888;
  color: #ffffff;
  font-size: 28px;
  width: 44px;
  height: 44px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.2s ease;
}

.lightbox-close:hover {
  border-color: #58a6ff;
  color: #58a6ff;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: 1px solid #888888;
  color: #ffffff;
  font-size: 28px;
  width: 50px;
  height: 60px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.2s ease;
}

/* ── Micro interactions ── */
.magnetic-item {
  will-change: transform;
}

.lightbox-nav:hover {
  border-color: #58a6ff;
  color: #58a6ff;
  background: rgba(88, 166, 255, 0.1);
}

.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

.lightbox-counter {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  color: #888888;
  font-size: 14px;
}

/* ── Rocket Animation ── */
.rocket-container {
  position: fixed;
  right: 40px;
  bottom: 60px;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  will-change: transform, opacity;
}

.rocket-container.launching {
  opacity: 1;
  animation: rocketLaunchVertical 2.2s ease-in forwards;
}

.rocket-svg {
  width: 24px;
  height: 48px;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.rocket-fire {
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 20px;
  background: linear-gradient(to bottom, #ff6b35, #ffcc00, transparent);
  border-radius: 0 0 50% 50%;
  opacity: 0;
}

.rocket-container.launching .rocket-fire {
  opacity: 1;
  animation: fireFlicker 0.08s infinite alternate;
}

@keyframes rocketLaunchVertical {
  0% { transform: translateY(0) rotate(0deg); opacity: 1; }
  3% { transform: translateY(2px) rotate(-0.5deg); }
  6% { transform: translateY(-1px) rotate(0.5deg); }
  9% { transform: translateY(1px) rotate(-0.3deg); }
  12% { transform: translateY(0) rotate(0deg); }
  100% { transform: translateY(-120vh) rotate(2deg); opacity: 0; }
}

@keyframes fireFlicker {
  0% { height: 16px; opacity: 0.8; width: 8px; }
  100% { height: 24px; opacity: 1; width: 12px; }
}

.particle {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  will-change: transform, opacity;
}

.particle.animate {
  animation: particleFall 0.8s ease-out forwards;
}

@keyframes particleFall {
  0% { opacity: 0.9; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(100px) scale(0); }
}

/* ── Minimal Scrollbar ── */
::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #444;
  border-radius: 2px;
}

::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* ── Scroll Progress Bar ── */
.scroll-progress {
  position: fixed;
  top: 0;
  right: 0;
  width: 4px;
  height: 0%;
  background: linear-gradient(to bottom, #a8c8e8, #c8a8d8);
  border-radius: 4px;
  z-index: 500;
  transition: height 0.15s ease-out;
  box-shadow: 0 0 6px rgba(168, 200, 232, 0.4);
}

/* ── Copy Toast ── */
.copy-toast {
  position: fixed;
  bottom: 60px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #333;
  color: #f0f0f0;
  padding: 8px 20px;
  border-radius: 6px;
  font-size: 13px;
  font-family: inherit;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 5000;
  pointer-events: none;
  border: 1px solid #555;
}

.copy-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ══════════════════════════════════════════
   LIGHT MODE
   ══════════════════════════════════════════ */

body.light-mode {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  color: #2f2927;
}

body.light-mode.bg-1 {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.light-mode.bg-2 {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.light-mode.bg-3 {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.light-mode.bg-4 {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.light-mode.bg-5 {
  background-color: #f8efea;
  background-image: radial-gradient(rgba(69, 51, 46, 0.08) 1px, transparent 1px);
  background-size: 24px 24px;
}

body.light-mode h1,
body.light-mode summary,
body.light-mode .section-content,
body.light-mode li,
body.light-mode .social-link,
body.light-mode .command-input,
body.light-mode .command-item {
  color: #2f2927;
}

body.light-mode .role,
body.light-mode .bio {
  color: #70615d;
}

body.light-mode .prompt {
  color: #6f95bf;
}

body.light-mode .social-link {
  border-color: #d4c2b9;
}

body.light-mode .social-link:hover {
  background: #fff7f3;
}

body.light-mode .status-bar {
  background: #fff8f5;
  border-color: #d8c8bf;
  color: #8d7a73;
}

body.light-mode .command-palette {
  background: #fff8f4;
  border-color: #d8c8bf;
}

body.light-mode .command-item:hover,
body.light-mode .command-item.selected {
  background: #f5e8e1;
}

body.light-mode .top-bar {
  background: #fff8f5;
  border-color: #d8c8bf;
}

body.light-mode .top-bar-btn {
  border-color: #d4c2b9;
  color: #7c6961;
}

body.light-mode .top-bar-btn:hover,
body.light-mode .top-bar-btn.active {
  background: #f4e8e1;
  border-color: #bfa79c;
  color: #5f4e47;
}

body.light-mode .dropdown-menu {
  background: #fff8f5;
  border-color: #dccbc2;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

body.light-mode .dropdown-option {
  color: #72625d;
}

body.light-mode .dropdown-option:hover,
body.light-mode .dropdown-option.active {
  background: #f4e8e1;
  color: #2f2927;
}

body.light-mode .side-panel {
  background: #fff8f4;
  border-color: #d8c5bc;
  box-shadow: 0 16px 44px rgba(106, 84, 76, 0.16),
              0 0 0 1px rgba(125, 93, 81, 0.08);
}

body.light-mode .side-panel.panel-polish {
  border-color: #c6ada2;
  box-shadow: 0 18px 48px rgba(106, 84, 76, 0.22),
              0 0 0 1px rgba(151, 119, 106, 0.16);
}

body.light-mode .side-panel-close {
  background: rgba(0, 0, 0, 0.03);
  border-color: #d2c1b9;
  color: #8d7a73;
}

body.light-mode .side-panel-title {
  color: #2f2927;
}

body.light-mode .side-panel-text {
  color: #70615d;
}

body.light-mode .side-panel-tag {
  background: #f5e9e2;
  border-color: #d7c5bc;
  color: #7d6b66;
}

body.light-mode .side-panel-tag::after {
  background: #fff8f4;
  border-color: #b99f92;
  color: #8a6f62;
}

body.light-mode .gallery-thumb {
  border-color: #d8c6bd;
}

body.light-mode ::-webkit-scrollbar-thumb {
  background: #ccb8af;
}

body.light-mode ::-webkit-scrollbar-thumb:hover {
  background: #bea89f;
}

body.light-mode .ignition-btn {
  border-color: #d4c2b9;
  color: #8d7a73;
}

body.light-mode .ignition-btn:hover {
  border-color: #ff6b35;
  color: #ff6b35;
  background: #fff3ee;
}

body.light-mode #radarBtn:hover {
  border-color: #6f95bf;
  color: #6f95bf;
  background: #f3ece8;
}

body.light-mode .status-song-link {
  border-color: #d4c2b9;
  color: #8d7a73;
}

body.light-mode .status-song-link:hover {
  border-color: #b79d91;
  color: #5f4e47;
  background: #f4e8e1;
}

body.light-mode .radar-dot {
  background: #8a9fc9;
  box-shadow: 0 0 8px rgba(138, 159, 201, 0.6);
}

body.light-mode .radar-link {
  background: linear-gradient(90deg, rgba(138, 159, 201, 0), rgba(138, 159, 201, 0.75), rgba(138, 159, 201, 0));
}

/* Light mode name styles */
body.light-mode .name-style-0 {
  color: #2f2927;
}

body.light-mode .name-style-2 {
  color: #2f8f51;
  text-shadow: none;
}

body.light-mode .name-style-2::after {
  color: #2f8f51;
}

body.light-mode .name-style-3 {
  color: #b85b41;
  text-shadow: none;
}

body.light-mode .name-style-4 {
  color: #567fab;
  text-shadow: none;
}

body.light-mode .name-style-4 .orbital-letter::before {
  border-color: rgba(86, 127, 171, 0.35);
}

body.light-mode .name-style-4 .orbital-letter::after {
  background: #6d95c1;
  box-shadow: 0 0 8px rgba(109, 149, 193, 0.55);
}

body.light-mode .name-style-5 {
  color: #4f79a4;
}

body.light-mode .name-style-5 .blueprint-letter {
  border-color: rgba(79, 121, 164, 0.35);
  background-image:
    linear-gradient(rgba(79, 121, 164, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79, 121, 164, 0.08) 1px, transparent 1px);
}

body.light-mode .name-style-6 {
  color: #3e9a82;
  text-shadow: none;
}

body.light-mode .name-style-6 .telemetry-letter::before {
  color: rgba(62, 154, 130, 0.62);
}

body.light-mode .name-style-6 .telemetry-letter::after {
  border-color: rgba(62, 154, 130, 0.2);
}

body.light-mode .name-style-7 {
  color: #98614d;
}

body.light-mode .name-style-7 .mission-letter {
  border-color: rgba(152, 97, 77, 0.45);
  background: rgba(152, 97, 77, 0.08);
  box-shadow: inset 0 0 0 1px rgba(152, 97, 77, 0.1);
}

body.light-mode .name-style-8 {
  color: #a75f46;
}

body.light-mode .name-style-8 .claude-grid-letter {
  border-color: rgba(167, 95, 70, 0.82);
  background:
    repeating-linear-gradient(
      90deg,
      rgba(167, 95, 70, 0.12) 0 8px,
      rgba(167, 95, 70, 0.2) 8px 9px
    );
  box-shadow:
    inset 0 0 0 1px rgba(255, 245, 240, 0.6),
    2px 2px 0 rgba(167, 95, 70, 0.35),
    -2px -2px 0 rgba(167, 95, 70, 0.14);
}

body.light-mode .name-style-8 .claude-grid-letter::before {
  border-color: rgba(167, 95, 70, 0.54);
}

body.light-mode .name-style-9 {
  color: #587ea9;
}

body.light-mode .name-style-9 .braille-letter::after {
  color: rgba(88, 126, 169, 0.8);
}

body.light-mode .name-style-12 {
  color: #9a694f;
}

/* Light mode profile photo */
body.light-mode .profile-photo {
  border-color: #d6c7bf;
}

body.light-mode .profile-photo-wrapper:hover .profile-photo {
  border-color: #58a6ff;
}

body.light-mode .profile-photo-tooltip {
  background: rgba(255, 255, 255, 0.75);
  color: #2a2a2a;
}

/* Light mode scroll progress */
body.light-mode .scroll-progress {
  background: linear-gradient(to bottom, #b98f86, #9d8eb8);
  box-shadow: 0 0 6px rgba(162, 128, 121, 0.3);
}

/* Light mode copy toast */
body.light-mode .copy-toast {
  background: #fff9f6;
  color: #2f2927;
  border-color: #d8c5bd;
}

/* ══════════════════════════════════════════
   REDUCED MOTION
   ══════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ══════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════ */

/* ── Tablet Landscape (≤ 1024px) ── */
@media (max-width: 1024px) {
  body {
    padding: 70px 30px 90px;
  }

  .top-bar {
    gap: 16px;
    padding: 10px 16px;
  }
}

/* ── Side Panel Tablet (≤ 900px) ── */
@media (max-width: 900px) {
  .side-panel {
    width: min(640px, calc(100vw - 28px));
    top: 72px;
    max-height: min(74vh, 700px);
  }

  body.panel-open .container {
    opacity: 1;
  }
}

/* ── Tablet Portrait / iPad (≤ 768px) ── */
@media (max-width: 768px) {
  body {
    padding: 65px 24px 80px;
  }

  .profile-photo-wrapper {
    width: 110px;
    height: 110px;
  }

  .profile-photo-tooltip {
    font-size: 12px;
  }

  .container {
    max-width: 100%;
  }

  h1 {
    font-size: 1.8em;
  }

  .top-bar {
    gap: 10px;
    padding: 8px 12px;
    flex-wrap: wrap;
  }

  .top-bar-btn {
    font-size: 11px;
    padding: 5px 10px;
    min-height: 36px;
  }

  .status-bar {
    gap: 16px;
    padding: 8px 12px;
  }

  #statusMessage {
    min-width: 120px;
    font-size: 11px;
  }

  .side-panel {
    width: calc(100vw - 24px);
    top: 60px;
    left: 50%;
    padding: 24px 18px;
    border-radius: 12px;
    max-height: min(76vh, 680px);
  }

  .lightbox {
    backdrop-filter: none;
  }

  .gallery-thumb {
    filter: none;
  }

  .social-link {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .dropdown-option {
    min-height: 44px;
  }
}

/* ── Mobile (≤ 600px) ── */
@media (max-width: 600px) {
  body {
    padding: 60px 20px 80px;
    font-size: 15px;
  }

  .profile-photo-wrapper {
    width: 90px;
    height: 90px;
  }

  .profile-photo-tooltip {
    font-size: 11px;
  }

  h1 {
    font-size: 1.5em;
  }

  .social-links {
    flex-direction: column;
  }

  .social-link {
    text-align: center;
    justify-content: center;
  }

  .top-bar {
    gap: 6px;
    padding: 6px 8px;
  }

  .top-bar-btn {
    font-size: 10px;
    padding: 4px 8px;
  }

  .status-bar {
    gap: 8px;
    padding: 6px 10px;
    flex-wrap: wrap;
  }

  #statusMessage {
    min-width: 0;
  }

  .ignition-btn {
    font-size: 11px;
    padding: 2px 8px;
  }

  .dropdown-menu {
    left: auto;
    right: 0;
    transform: none;
    min-width: 0;
    max-width: calc(100vw - 20px);
  }

  .mail-dropdown {
    min-width: 0;
  }

  .dropdown-option {
    font-size: 11px;
    padding: 8px 12px;
  }

  .photo-gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .side-panel {
    width: calc(100% - 16px);
    left: 50%;
    top: 55px;
    max-height: calc(100vh - 55px - 55px);
    border-radius: 12px;
    padding: 20px 14px;
  }

  body.panel-open .container {
    display: block;
  }

  body.panel-open .status-bar {
    width: 100%;
  }

  .lightbox-img {
    max-width: 95%;
    max-height: 80%;
  }

  .lightbox-nav {
    width: 36px;
    height: 44px;
    font-size: 22px;
  }

  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }

  .lightbox-close {
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    font-size: 22px;
  }

  .command-palette-overlay {
    padding-top: 10vh;
    padding-left: 10px;
    padding-right: 10px;
  }

  .command-palette {
    max-width: 100%;
  }

  .status-song-link {
    font-size: 10px;
    padding: 3px 8px;
  }

  .social-label {
    font-size: 11px;
  }

}

/* ── Small Phones (≤ 400px) ── */
@media (max-width: 400px) {
  body {
    padding: 55px 14px 75px;
  }

  .profile-photo-wrapper {
    width: 75px;
    height: 75px;
  }

  .profile-photo-tooltip {
    font-size: 10px;
  }

  h1 {
    font-size: 1.3em;
  }

  .name-style-1 .name-letter {
    padding: 1px 3px;
    margin: 0.5px;
    font-size: 0.95em;
  }

  .name-style-8 .claude-grid-letter {
    padding: 1px 3px;
    margin: 0.5px;
  }

  .name-style-9 .braille-letter::after {
    font-size: 9px;
  }

  .top-bar {
    gap: 4px;
    padding: 5px 6px;
  }

  .top-bar-btn {
    font-size: 10px;
    padding: 3px 6px;
  }

  .social-link {
    padding: 6px 12px;
    font-size: 13px;
  }

  .social-icon {
    width: 22px;
    height: 22px;
    font-size: 10px;
  }

  .social-label {
    font-size: 10px;
  }

  .side-panel {
    width: calc(100% - 12px);
    left: 50%;
    padding: 18px 12px;
  }

  .photo-gallery {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .rocket-container {
    right: 20px;
  }
}

/* ══════════════════════════════════════════
   V2 OVERRIDES: 2-step theme/palette system
   ══════════════════════════════════════════ */

body {
  --bg-base: #f8efea;
  --bg-dot: rgba(69, 51, 46, 0.08);
  --surface-1: #fff8f5;
  --surface-2: #f4e8e1;
  --panel-bg: rgba(255, 248, 244, 0.95);
  --text-primary: #2f2927;
  --text-muted: #70615d;
  --border-color: #d8c8bf;
  --accent: #b85b41;
  --accent-soft: rgba(184, 91, 65, 0.12);
  --accent-glow: rgba(184, 91, 65, 0.28);
  --dot-grid-size: 24px;
  background-color: var(--bg-base);
  background-image: radial-gradient(var(--bg-dot) 1px, transparent 1px);
  background-size: var(--dot-grid-size) var(--dot-grid-size);
  color: var(--text-primary);
}

body.theme-light.palette-cream {
  --bg-base: #f8efea;
  --bg-dot: rgba(83, 64, 56, 0.08);
  --surface-1: #fff8f5;
  --surface-2: #f4e8e1;
  --panel-bg: rgba(255, 248, 244, 0.95);
  --text-primary: #2f2927;
  --text-muted: #70615d;
  --border-color: #d8c8bf;
  --accent: #b85b41;
  --accent-soft: rgba(184, 91, 65, 0.12);
  --accent-glow: rgba(184, 91, 65, 0.28);
}

body.theme-light.palette-rose {
  --bg-base: #f7ecee;
  --bg-dot: rgba(103, 70, 82, 0.08);
  --surface-1: #fff6f8;
  --surface-2: #f6e7eb;
  --panel-bg: rgba(255, 246, 248, 0.95);
  --text-primary: #3a2b31;
  --text-muted: #7b626b;
  --border-color: #dec7cf;
  --accent: #b85e74;
  --accent-soft: rgba(184, 94, 116, 0.12);
  --accent-glow: rgba(184, 94, 116, 0.24);
}

body.theme-light.palette-sky {
  --bg-base: #edf3f8;
  --bg-dot: rgba(64, 83, 101, 0.08);
  --surface-1: #f8fcff;
  --surface-2: #e7f0f6;
  --panel-bg: rgba(248, 252, 255, 0.95);
  --text-primary: #2a3642;
  --text-muted: #607182;
  --border-color: #c8d7e3;
  --accent: #5e86b8;
  --accent-soft: rgba(94, 134, 184, 0.12);
  --accent-glow: rgba(94, 134, 184, 0.24);
}

body.theme-light.palette-sage {
  --bg-base: #eef3ec;
  --bg-dot: rgba(63, 78, 67, 0.08);
  --surface-1: #f8fcf6;
  --surface-2: #e8f0e4;
  --panel-bg: rgba(248, 252, 246, 0.95);
  --text-primary: #2e3a31;
  --text-muted: #667567;
  --border-color: #ced9cc;
  --accent: #5d8767;
  --accent-soft: rgba(93, 135, 103, 0.12);
  --accent-glow: rgba(93, 135, 103, 0.22);
}

body.theme-light.palette-peach {
  --bg-base: #faeee5;
  --bg-dot: rgba(94, 69, 57, 0.08);
  --surface-1: #fff8f2;
  --surface-2: #f7e8dc;
  --panel-bg: rgba(255, 248, 242, 0.95);
  --text-primary: #3c2d27;
  --text-muted: #7f665b;
  --border-color: #e2cbbc;
  --accent: #c0704c;
  --accent-soft: rgba(192, 112, 76, 0.12);
  --accent-glow: rgba(192, 112, 76, 0.24);
}

body.theme-light.palette-lavender {
  --bg-base: #f2eff8;
  --bg-dot: rgba(79, 70, 101, 0.08);
  --surface-1: #fbf9ff;
  --surface-2: #ece8f6;
  --panel-bg: rgba(251, 249, 255, 0.95);
  --text-primary: #312d3f;
  --text-muted: #6f6784;
  --border-color: #d7cde8;
  --accent: #7d6ab2;
  --accent-soft: rgba(125, 106, 178, 0.12);
  --accent-glow: rgba(125, 106, 178, 0.24);
}

body.theme-dark.palette-charcoal {
  --bg-base: #17181b;
  --bg-dot: rgba(236, 239, 245, 0.06);
  --surface-1: #202228;
  --surface-2: #2a2d35;
  --panel-bg: rgba(30, 33, 40, 0.95);
  --text-primary: #eceff4;
  --text-muted: #b7bec9;
  --border-color: #3a3f4a;
  --accent: #89b4ff;
  --accent-soft: rgba(137, 180, 255, 0.14);
  --accent-glow: rgba(137, 180, 255, 0.3);
}

body.theme-dark.palette-warm-ink {
  --bg-base: #1d1a19;
  --bg-dot: rgba(250, 234, 224, 0.06);
  --surface-1: #262220;
  --surface-2: #2f2927;
  --panel-bg: rgba(39, 34, 32, 0.95);
  --text-primary: #f1e7de;
  --text-muted: #c8b8ab;
  --border-color: #4a3f39;
  --accent: #df9f79;
  --accent-soft: rgba(223, 159, 121, 0.14);
  --accent-glow: rgba(223, 159, 121, 0.32);
}

h1,
summary,
.section-content,
li,
.social-link,
.command-input,
.command-item {
  color: var(--text-primary);
}

.role,
.bio,
.side-panel-text {
  color: var(--text-muted);
}

.prompt {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border-color));
  background: var(--accent-soft);
}

.top-bar,
.status-bar,
.command-palette {
  background: var(--surface-1);
  border-color: var(--border-color);
}

.top-bar-btn,
.social-link,
.ignition-btn,
.status-song-link,
.dropdown-menu,
.command-palette,
.command-input-wrapper,
.side-panel,
.gallery-thumb,
.copy-toast {
  border-color: var(--border-color);
}

.top-bar-btn,
.ignition-btn,
.status-song-link,
#statusMessage {
  color: var(--text-muted);
}

.top-bar-btn:hover,
.top-bar-btn.active,
.social-link:hover,
.ignition-btn:hover,
.status-song-link:hover,
.command-item:hover,
.command-item.selected {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}

.side-panel {
  background: var(--panel-bg);
  box-shadow: 0 16px 48px color-mix(in srgb, var(--bg-base) 65%, #000),
              0 0 0 1px color-mix(in srgb, var(--accent) 20%, transparent);
}

.side-panel.panel-polish {
  border-color: var(--accent);
  box-shadow: 0 22px 52px color-mix(in srgb, var(--bg-base) 62%, #000),
              0 0 0 1px color-mix(in srgb, var(--accent) 40%, transparent);
}

.dropdown-menu,
.copy-toast {
  background: var(--surface-1);
}

.dropdown-option {
  color: var(--text-muted);
}

.dropdown-option:hover,
.dropdown-option.active {
  color: var(--text-primary);
  background: var(--surface-2);
}

.side-panel-tag {
  background: var(--surface-2);
  border-color: var(--border-color);
  color: var(--text-muted);
}

.side-panel-tag::after {
  background: var(--surface-1);
  border-color: var(--accent);
  color: var(--accent);
}

.scroll-progress {
  background: linear-gradient(to bottom, var(--accent), color-mix(in srgb, var(--accent) 52%, #ffffff));
  box-shadow: 0 0 6px var(--accent-glow);
}

.social-icon-svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
}

.social-link {
  min-height: 40px;
}

/* Name style 4: planet glyph + constellation */
.name-style-4 {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: color-mix(in srgb, var(--text-primary) 88%, var(--accent));
  text-shadow: 0 0 6px color-mix(in srgb, var(--accent) 22%, transparent);
  padding: 2px 12px 3px;
  letter-spacing: 0.02em;
}

.name-style-4 .planet-constellation-core {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: baseline;
}

.name-style-4 .constellation-letter {
  position: relative;
  display: inline-block;
}

.name-style-4 .planet-glyph {
  position: relative;
  display: inline-block;
  margin: 0 1px;
  padding: 0 1px;
}

.name-style-4 .planet-glyph::before {
  content: '';
  position: absolute;
  inset: -2px -4px;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  border-radius: 999px;
  transform: rotate(-12deg);
  opacity: 0.8;
}

.name-style-4 .constellation-track {
  position: absolute;
  left: 4px;
  right: 4px;
  height: 1px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--accent) 42%, transparent), transparent);
  pointer-events: none;
}

.name-style-4 .constellation-track-1 {
  top: -2px;
}

.name-style-4 .constellation-track-2 {
  bottom: -3px;
  opacity: 0.65;
}

.name-style-4 .constellation-node {
  position: absolute;
  width: 4px;
  height: 4px;
  margin-top: -2px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 65%, #ffffff);
  box-shadow: 0 0 6px color-mix(in srgb, var(--accent) 46%, transparent);
  animation: orbitNodePulse 2.4s ease-in-out infinite;
  pointer-events: none;
}

.name-style-4 .constellation-node-1 {
  top: -2px;
  left: 16%;
}

.name-style-4 .constellation-node-2 {
  top: 100%;
  left: 54%;
  animation-delay: 0.4s;
}

.name-style-4 .constellation-node-3 {
  top: -4px;
  right: 14%;
  animation-delay: 0.9s;
}

.name-style-4.name-click-burst .planet-glyph::before {
  transform: rotate(-22deg) scale(1.07);
}

.name-style-4.name-click-burst .constellation-node {
  transform: scale(1.25);
}

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

/* Braille only style */
.name-style-9 {
  color: color-mix(in srgb, var(--accent) 78%, var(--text-primary));
}

.name-style-9.braille-only {
  font-family: 'SF Mono', 'Fira Code', monospace;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.name-style-9 .braille-label {
  color: var(--text-muted);
  margin-right: 6px;
  font-size: 0.62em;
  text-transform: lowercase;
}

.name-style-9 .braille-text {
  font-size: 0.9em;
}

/* New Elegant Geek styles */
.name-style-13 {
  color: color-mix(in srgb, var(--text-primary) 90%, var(--accent));
  letter-spacing: 0.03em;
}

.name-style-13 .monoline-letter {
  display: inline-block;
  padding: 0 1px;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 44%, transparent);
}

.name-style-14 {
  color: color-mix(in srgb, var(--accent) 90%, #a5f5f1);
  text-shadow: 0 0 10px color-mix(in srgb, var(--accent) 52%, #7cf5ea);
}

.name-style-14 .neon-wire-letter {
  display: inline-block;
  padding: 0 1px;
  transform: skewX(-5deg);
}

.name-style-15 {
  color: var(--text-primary);
  letter-spacing: 0.08em;
}

.name-style-15 .dot-matrix-letter {
  position: relative;
  display: inline-block;
  margin: 0 1px;
}

.name-style-15 .dot-matrix-letter::after {
  content: '';
  position: absolute;
  left: 50%;
  top: calc(100% + 3px);
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 76%, #ffffff);
  transform: translateX(-50%);
  box-shadow:
    -6px 0 0 color-mix(in srgb, var(--accent) 44%, transparent),
    6px 0 0 color-mix(in srgb, var(--accent) 44%, transparent);
}

.name-style-16 {
  color: color-mix(in srgb, var(--text-primary) 84%, var(--accent));
}

.name-style-16 .aero-serif-letter {
  display: inline-block;
  margin-right: 1px;
  font-family: 'Iowan Old Style', 'Palatino Linotype', serif;
  letter-spacing: 0.01em;
}

/* V2 typography tuning */
body {
  --fs-base: clamp(15px, 0.32vw + 14px, 17px);
  --fs-h1: clamp(1.9rem, 1.55vw + 1.5rem, 2.9rem);
  --fs-role: clamp(0.98rem, 0.36vw + 0.9rem, 1.17rem);
  --fs-body: clamp(0.97rem, 0.16vw + 0.93rem, 1.05rem);
  --fs-summary: clamp(1rem, 0.28vw + 0.92rem, 1.2rem);
  --fs-ui: clamp(0.74rem, 0.16vw + 0.7rem, 0.84rem);
  font-size: var(--fs-base);
  line-height: 1.7;
}

h1 {
  font-size: var(--fs-h1);
  line-height: 1.12;
  letter-spacing: -0.012em;
  margin-bottom: 10px;
}

.prompt {
  font-size: clamp(0.5em, 0.58em, 0.64em);
}

.role {
  font-size: var(--fs-role);
  line-height: 1.46;
  margin-bottom: 30px;
}

.bio {
  font-size: var(--fs-body);
  line-height: 1.72;
  padding: 16px 20px;
  margin-bottom: 34px;
}

summary {
  font-size: var(--fs-summary);
  line-height: 1.28;
  letter-spacing: 0.01em;
}

.section-content,
li {
  font-size: var(--fs-body);
  line-height: 1.68;
}

.section-content {
  padding: 12px 0 14px 24px;
}

.top-bar-btn,
.ignition-btn,
.status-song-link,
.social-label {
  font-size: var(--fs-ui);
}

#statusMessage {
  font-size: clamp(0.72rem, 0.15vw + 0.7rem, 0.84rem);
}

.social-link {
  padding: 9px 16px;
  gap: 9px;
}

/* Profile photo polish */
.profile-photo {
  border: 2px solid rgba(255, 255, 255, 0.92);
  box-shadow: 0 3px 14px rgba(0, 0, 0, 0.22);
}

.profile-photo-wrapper:hover .profile-photo {
  transform: scale(1.09);
  border-color: #ffffff;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--accent) 24%, rgba(0, 0, 0, 0.2));
}

body.theme-light .profile-photo {
  border-color: #ffffff;
  box-shadow: 0 3px 14px rgba(114, 86, 72, 0.18);
}

body.theme-light .profile-photo-wrapper:hover .profile-photo {
  border-color: #ffffff;
  box-shadow: 0 10px 26px rgba(135, 102, 86, 0.22);
}

/* Name style color tuning */
.name-style-2 {
  color: #76b28b;
  text-shadow: 0 0 6px rgba(118, 178, 139, 0.2);
}

.name-style-2::after {
  color: #76b28b;
}

.name-style-3 {
  color: #e08968;
  border: 1px solid rgba(170, 90, 56, 0.72);
  border-radius: 6px;
  padding: 1px 8px 2px;
  background: rgba(57, 45, 40, 0.34);
}

.theme-dark .name-style-3 {
  color: #d8c9be;
  border-color: rgba(160, 93, 57, 0.85);
  background: rgba(37, 34, 32, 0.78);
  box-shadow: inset 0 0 0 1px rgba(255, 174, 120, 0.1);
}

.name-style-6 {
  color: #7ea8b8;
  text-shadow: 0 0 8px rgba(126, 168, 184, 0.2);
}

.name-style-6 .telemetry-letter::before {
  color: rgba(126, 168, 184, 0.68);
}

.name-style-6 .telemetry-letter::after {
  border-color: rgba(126, 168, 184, 0.28);
}

.name-style-7 {
  font-size: 0.91em;
}

.name-style-7 .mission-letter {
  padding: 0 3px;
}

.theme-dark .name-style-13,
.theme-dark .name-style-14,
.theme-dark .name-style-15,
.theme-dark .name-style-16 {
  color: var(--text-primary);
  text-shadow: none;
}

/* Signal feature */
.signal-ping,
.signal-ring,
.signal-rl-step {
  position: absolute;
  pointer-events: none;
}

.signal-ping {
  width: 8px;
  height: 8px;
  margin: -4px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 72%, #ffffff);
  box-shadow: 0 0 10px var(--accent-glow);
  animation: signalPingFade 1.1s ease-out forwards;
}

.signal-ring {
  width: 18px;
  height: 18px;
  margin: -9px;
  border: 1px solid color-mix(in srgb, var(--accent) 58%, transparent);
  border-radius: 50%;
  animation: signalRingExpand 0.78s ease-out forwards;
}

.signal-rl-step {
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid color-mix(in srgb, var(--accent) 44%, transparent);
  background: color-mix(in srgb, var(--surface-1) 90%, transparent);
  color: var(--text-primary);
  font-size: 11px;
  letter-spacing: 0.03em;
  white-space: nowrap;
  opacity: 0;
  animation: signalRLPop 0.62s ease-out forwards;
}

@keyframes signalPingFade {
  0% { transform: scale(0.7); opacity: 1; }
  100% { transform: scale(1.15); opacity: 0; }
}

@keyframes signalRingExpand {
  0% { transform: scale(0.4); opacity: 0.95; }
  100% { transform: scale(5.8); opacity: 0; }
}

@keyframes signalRLPop {
  0% { transform: translateY(6px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .name-style-4 .constellation-node {
    animation: none !important;
  }
}
