/* Global Styles, Resets, and Cinematic Layouts */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background-color: #000000 !important;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  width: 100%;
}
body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  width: 100%;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.08) transparent;
}
html.theme-obsidian,
body.theme-obsidian,
[data-theme="obsidian"] {
  scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
}

body {
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Custom Scrollbar - Ultra Minimalist */
::-webkit-scrollbar {
  width: 3px !important;
  height: 3px !important;
}
::-webkit-scrollbar-track {
  background: transparent !important;
}
::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.08) !important;
  border-radius: 99px !important;
  transition: background 0.3s ease !important;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.25) !important;
}

/* Dark mode scrollbar support */
.theme-obsidian ::-webkit-scrollbar-thumb,
[data-theme="obsidian"] ::-webkit-scrollbar-thumb,
.kino-section-active ::-webkit-scrollbar-thumb,
body.theme-obsidian ::-webkit-scrollbar-thumb,
html.theme-obsidian ::-webkit-scrollbar-thumb,
.theme-obsidian::-webkit-scrollbar-thumb,
body.theme-obsidian::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08) !important;
}
.theme-obsidian ::-webkit-scrollbar-thumb:hover,
[data-theme="obsidian"] ::-webkit-scrollbar-thumb:hover,
.kino-section-active ::-webkit-scrollbar-thumb:hover,
body.theme-obsidian ::-webkit-scrollbar-thumb:hover,
html.theme-obsidian ::-webkit-scrollbar-thumb:hover,
.theme-obsidian::-webkit-scrollbar-thumb:hover,
body.theme-obsidian::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.25) !important;
}

/* Cinematic Background Ambient Glows */
.ambient-glow {
  position: fixed;
  width: 50vw;
  height: 50vw;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(140px);
  opacity: 0.35;
  transition: var(--transition-fluid);
}

.bg-glow-1 {
  top: -10%;
  left: -10%;
  background: radial-gradient(circle, rgba(197, 160, 108, 0.12) 0%, transparent 70%);
}

.bg-glow-2 {
  bottom: -10%;
  right: -10%;
  background: radial-gradient(circle, rgba(197, 160, 108, 0.08) 0%, transparent 70%);
}

/* Minimalist Glass Header (Vogue Germany Style Centered Layout) */
.main-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 15px 40px 10px 40px;
  z-index: 100;
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  background: var(--header-bg);
  border-bottom: 1px solid var(--border-light);
  transition: var(--transition-fluid);
}

.header-top-row {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.header-left, .header-right {
  display: flex;
  align-items: center;
  gap: 20px;
  flex: 1;
}

.header-left {
  justify-content: flex-start;
}

.header-right {
  justify-content: flex-end;
}

.header-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 2;
}

.drawer-toggle-btn-header {
  background: transparent;
  border: none;
  color: #777777; /* Dezent & Edel im Light Mode */
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  outline: none;
  box-shadow: none;
  transition: var(--transition-fluid);
}

.drawer-toggle-btn-header:focus,
.drawer-toggle-btn-header:active {
  outline: none;
  box-shadow: none;
}

.drawer-toggle-btn-header:hover {
  opacity: 0.7;
}

.drawer-toggle-btn-header i {
  width: 24px;
  height: 24px;
}

.logo-text {
  font-family: var(--font-serif);
  font-size: 3.4rem;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  letter-spacing: 8px;
  text-transform: uppercase;
  text-shadow: var(--text-glow);
  transition: var(--transition-fluid);
  line-height: 1;
  outline: none !important;
  border: none !important;
  background: transparent !important;
}

.logo-text:hover, .logo-text:focus, .logo-text:active {
  opacity: 0.7;
  outline: none !important;
  border: none !important;
}

.logo-letter, #light-toggle-trigger, #radio-easter-egg-trigger {
  cursor: default;
  font-family: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
  color: inherit !important;
  letter-spacing: inherit !important;
  margin: 0 !important;
  padding: 0 !important;
  display: inline !important;
  border: none !important;
  outline: none !important;
}

#light-toggle-trigger {
  animation: hidden-pulse 15s infinite;
}

@keyframes hidden-pulse {
  0%   { text-shadow: none; }
  4%   { text-shadow: none; }
  5%   { text-shadow: 0 0 12px currentColor; }
  6%   { text-shadow: none; }
  100% { text-shadow: none; }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 30px;
}

/* Language Selector (Pick) Button Styles */
.language-picker {
  display: flex;
  background: rgba(0, 0, 0, 0.03);
  border: 1px solid var(--border-light);
  padding: 3px;
  border-radius: 20px;
  backdrop-filter: blur(8px);
  transition: var(--transition-fluid);
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 16px;
  cursor: pointer;
  letter-spacing: 1px;
  transition: var(--transition-fluid);
}

.lang-btn:hover {
  color: var(--text-primary);
}

.lang-btn.active {
  background: var(--text-primary);
  color: var(--bg-primary);
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

/* Dashboard Write Trigger Button */
.dashboard-toggle-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: 1px solid var(--text-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 30px;
  cursor: pointer;
  transition: var(--transition-fluid);
}

.dashboard-toggle-btn i {
  width: 16px;
  height: 16px;
}

.dashboard-toggle-btn:hover {
  background: var(--text-primary);
  color: var(--bg-primary);
  transform: translateY(-1px);
}

/* Chapters/Index Quick Drawer */
.chapters-drawer {
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  width: var(--drawer-width);
  background: var(--drawer-bg);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  border-right: 1px solid var(--border-light);
  z-index: 90;
  transform: translateX(calc(-1 * var(--drawer-width)));
  transition: transform var(--transition-slow);
  /* Elegantes Padding — genüg Raum für alle Links ohne Abschneiden */
  padding: 130px 36px 60px 36px;
  box-shadow: 4px 0 40px rgba(0,0,0,0.06);
  /* Scrollbar bei überlangen Listen */
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--border-light) transparent;
}

.chapters-drawer.open {
  transform: translateX(0);
}

.drawer-toggle {
  position: absolute;
  right: -50px;
  top: 92px;
  width: 50px;
  height: 50px;
  background: var(--drawer-toggle-bg);
  border: 1px solid var(--border-light);
  border-left: none;
  border-top-right-radius: 8px;
  border-bottom-right-radius: 8px;
  backdrop-filter: blur(10px);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fluid);
}

.drawer-toggle:hover {
  color: var(--text-primary);
}

.drawer-title {
  font-family: var(--font-serif);
  font-size: 0.65rem;
  letter-spacing: 4px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  text-transform: uppercase;
  opacity: 0.5;
  /* Dezente Trennlinie unter dem Titel */
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-light);
}

.chapters-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: 40px;
}

.chapter-link {
  display: block;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transition: var(--transition-fast);
  cursor: pointer;
  /* Kein Abschneiden mehr */
  white-space: normal;
  overflow: visible;
  word-break: keep-all;
  padding: 2px 0;
}

.chapter-link:hover, .chapter-link.active {
  color: var(--text-primary);
  padding-left: 6px;
}

/* Utility Animations */
.fade-in-text {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1.2s forwards cubic-bezier(0.25, 1, 0.5, 1);
}

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

/* Responsiveness for global frame */
@media (max-width: 768px) {
  :root {
    --header-height: 70px;
    /* Drawer auf Mobile schlankes Maß: 240px */
    --drawer-width: 240px;
  }
  .main-header {
    padding: 10px 20px;
    height: var(--header-height);
    gap: 0;
  }
  .logo-text {
    font-size: 2.6rem;
    letter-spacing: 5px;
  }
  .dashboard-toggle-btn span {
    display: none;
  }
  .language-picker {
    padding: 2px 4px;
    width: fit-content;
    max-width: 150px;
    margin: 40px auto 0 auto !important;
  }
  .lang-btn {
    padding: 2px 6px;
    font-size: 0.65rem;
  }
  .header-left, .header-right {
    gap: 8px;
  }
}

/* Header Brand Logos */
.header-brand-logo-left,
.header-brand-logo-right {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border-pure);
  object-fit: cover;
  transition: var(--transition-fluid);
  filter: grayscale(100%);
  display: block;
}

.header-brand-logo-left:hover,
.header-brand-logo-right:hover {
  filter: grayscale(0%);
  border-color: var(--accent-lux);
  transform: scale(1.05);
}

@media (max-width: 768px) {
  .header-brand-logo-left,
  .header-brand-logo-right {
    width: 28px;
    height: 28px;
  }
}

/* SUPPORT THE JOURNEY FIXED LINK */
.support-journey-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 99;
  display: flex;
  align-items: center;
  gap: 0;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 10px 12px;
  color: var(--text-primary);
  text-decoration: none;
  font-family: var(--font-geometric), sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border-radius: 0; /* Sharp corners to match our aesthetic */
  opacity: 0.25;
  transform: scale(0.98);
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.5s cubic-bezier(0.16, 1, 0.3, 1), 
              transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              gap 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              padding 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              max-width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
  max-width: 40px; /* Initially collapsed, only showing the icon */
  white-space: nowrap;
}

.support-journey-btn .support-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  stroke-width: 1.5px;
}

.support-journey-btn .support-text {
  opacity: 0;
  transform: translateX(10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  margin-left: 0;
}

/* Hover state - expand the button to show text */
.support-journey-btn:hover {
  opacity: 0.95;
  border-color: var(--color-accent) !important;
  transform: scale(1.02);
  max-width: 320px; /* Expand to show full text */
  padding: 10px 20px;
  gap: 12px;
}

.support-journey-btn:hover .support-text {
  opacity: 1;
  transform: translateX(0);
}

/* Dark/Light mode color adaptations */
.theme-obsidian .support-journey-btn,
body.theme-obsidian .support-journey-btn {
  border-color: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

body:not(.theme-obsidian) .support-journey-btn {
  border-color: rgba(0, 0, 0, 0.08);
  color: #000000;
}

/* ==========================================================================
   HYPE KI-WAECHTER WIDGET & CHAT PANEL
   ========================================================================== */
.hype-widget-container {
  position: fixed;
  bottom: 30px;
  left: 30px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  pointer-events: none;
}

.hype-avatar-svg-wrap {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: visible;
  background: transparent;
  border: none;
  box-shadow: none;
  cursor: pointer;
  pointer-events: auto;
  position: relative;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s;
  filter: drop-shadow(0 0 10px rgba(0, 255, 238, 0.65));
  animation: floatIdling 6s ease-in-out infinite;
}

.hype-avatar-svg-wrap:hover {
  transform: scale(1.1);
  filter: drop-shadow(0 0 18px rgba(0, 255, 238, 0.95)) drop-shadow(0 0 28px rgba(0, 136, 255, 0.6));
}

@keyframes floatIdling {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(2deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

.orbit-system {
  width: 100%;
  height: 100%;
  transition: transform 0.1s ease-out; /* Parallax tracking */
}

/* Animations for SVG elements */
@keyframes spin1 {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
@keyframes spin2 {
  0% { transform: rotate(360deg); }
  100% { transform: rotate(0deg); }
}
@keyframes spin3 {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.hype-thinking .orbit-system {
  animation: pulseGlow 1.5s infinite alternate ease-in-out;
}

@keyframes pulseGlow {
  0% { filter: drop-shadow(0 0 5px rgba(0, 210, 255, 0.5)); }
  100% { filter: drop-shadow(0 0 20px rgba(0, 210, 255, 0.95)); }
}

/* Sharp Edged Minimalist Chat Panel */
.hype-chat-panel {
  position: absolute;
  bottom: 95px;
  left: 0;
  width: 320px;
  max-width: calc(100vw - 60px);
  background: rgba(10, 14, 30, 0.92); /* Dark futuristic glass background */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(0, 170, 255, 0.3);
  border-radius: 0; /* Strict sharp-edged design */
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6), inset 0 0 15px rgba(0, 170, 255, 0.05);
  display: flex;
  flex-direction: column;
  max-height: 450px;
  opacity: 0;
  transform: translateY(15px) scale(0.97);
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.hype-chat-panel.active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* Theme adaptation: light mode needs dark text / light bg but HYPE should look high-contrast */
body:not(.theme-obsidian) .hype-chat-panel {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 136, 255, 0.4);
  box-shadow: 0 15px 40px rgba(0, 68, 170, 0.15), inset 0 0 10px rgba(0, 170, 255, 0.03);
}

.hype-chat-header {
  padding: 18px 20px;
  border-bottom: 1px solid rgba(0, 170, 255, 0.18);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

body:not(.theme-obsidian) .hype-chat-header {
  border-bottom-color: rgba(0, 136, 255, 0.15);
}

.hype-header-brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hype-eyebrow {
  font-family: 'Share Tech Mono', 'Courier New', monospace;
  font-size: 0.65rem;
  color: rgba(0, 255, 238, 0.85);
  letter-spacing: 2px;
}

body:not(.theme-obsidian) .hype-eyebrow {
  color: #0066cc;
}

.hype-title {
  font-family: var(--font-geometric), sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 3px;
  color: #ffffff;
}

body:not(.theme-obsidian) .hype-title {
  color: #000000;
}

.hype-subtitle {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 1px;
}

body:not(.theme-obsidian) .hype-subtitle {
  color: #666666;
}

.hype-close-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s ease, transform 0.3s ease;
  width: 28px;
  height: 28px;
}

.hype-close-btn:hover {
  color: #00ffee;
  transform: rotate(90deg);
}

body:not(.theme-obsidian) .hype-close-btn {
  color: #333333;
}

body:not(.theme-obsidian) .hype-close-btn:hover {
  color: #0066cc;
}

.hype-chat-body {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-height: 280px;
}

.hype-chat-msg {
  max-width: 85%;
  padding: 12px 16px;
  font-size: 0.85rem;
  line-height: 1.65;
  letter-spacing: 0.04em;
  word-wrap: break-word;
}

.hype-chat-msg-user {
  align-self: flex-end;
  background: rgba(0, 170, 255, 0.15);
  border: 1px solid rgba(0, 170, 255, 0.3);
  color: #ffffff;
}

body:not(.theme-obsidian) .hype-chat-msg-user {
  background: rgba(0, 119, 255, 0.08);
  border-color: rgba(0, 119, 255, 0.2);
  color: #000000;
}

.hype-chat-msg-model {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.9);
}

body:not(.theme-obsidian) .hype-chat-msg-model {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.06);
  color: #333333;
}

.hype-chat-footer {
  padding: 12px 20px;
  border-top: 1px solid rgba(0, 170, 255, 0.12);
  display: flex;
  gap: 10px;
  align-items: center;
}

body:not(.theme-obsidian) .hype-chat-footer {
  border-top-color: rgba(0, 136, 255, 0.1);
}

#hype-user-input {
  flex: 1;
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid rgba(0, 170, 255, 0.25) !important;
  border-radius: 0 !important;
  color: #ffffff !important;
  padding: 10px 14px;
  font-size: 0.82rem;
  letter-spacing: 1px;
}

body:not(.theme-obsidian) #hype-user-input {
  background: #ffffff !important;
  border: 1px solid rgba(0, 119, 255, 0.25) !important;
  color: #000000 !important;
}

#hype-user-input:focus {
  border-color: #00ffee !important;
  box-shadow: 0 0 8px rgba(0, 255, 238, 0.2);
}

body:not(.theme-obsidian) #hype-user-input:focus {
  border-color: #0077ff !important;
  box-shadow: 0 0 8px rgba(0, 119, 255, 0.15);
}

#hype-send-btn {
  background: rgba(0, 170, 255, 0.2);
  border: 1px solid rgba(0, 170, 255, 0.4);
  color: #00ffee;
  width: 38px;
  height: 38px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

#hype-send-btn:hover {
  background: #00ffee;
  color: #0c1020;
  border-color: #00ffee;
}

body:not(.theme-obsidian) #hype-send-btn {
  background: rgba(0, 119, 255, 0.1);
  border-color: rgba(0, 119, 255, 0.3);
  color: #0066cc;
}

body:not(.theme-obsidian) #hype-send-btn:hover {
  background: #0066cc;
  color: #ffffff;
  border-color: #0066cc;
}

.hype-chat-msg p {
  margin: 0;
  font-family: var(--font-geometric), sans-serif;
}

.typing-stream {
  position: relative;
}

.stream-cursor {
  display: inline-block;
  margin-left: 2px;
  color: #00ffee;
  animation: blinkCursor 0.8s infinite;
}

body:not(.theme-obsidian) .stream-cursor {
  color: #0066cc;
}

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

/* High contrast outlines for HYPE SVG in light mode */
body:not(.theme-obsidian) .orbit-system svg {
  filter: drop-shadow(0 4px 15px rgba(0, 100, 200, 0.15));
}
body:not(.theme-obsidian) .orbit-system svg g path,
body:not(.theme-obsidian) .orbit-system svg rect,
body:not(.theme-obsidian) .orbit-system svg circle,
body:not(.theme-obsidian) .orbit-system svg ellipse {
  stroke-opacity: 0.9 !important;
}


/* ==========================================================================
   MINIMALISTISCHER LUXUS-FOOTER
   ========================================================================== */
.alex-premium-footer {
  width: 100%;
  max-width: var(--max-content-width);
  margin: 120px auto 40px auto;
  padding: 30px 20px 20px 20px;
  border-top: 1px solid rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.theme-obsidian .alex-premium-footer,
body.cinema-dimmed .alex-premium-footer {
  border-top-color: rgba(255, 255, 255, 0.03);
}

.footer-texts {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-text-row {
  font-size: 10px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.18);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin: 0;
  transition: color 0.3s ease;
}

.theme-obsidian .footer-text-row,
body.cinema-dimmed .footer-text-row {
  color: rgba(255, 255, 255, 0.15);
}

.footer-paypal-link {
  color: rgba(0, 0, 0, 0.25);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.theme-obsidian .footer-paypal-link,
body.cinema-dimmed .footer-paypal-link {
  color: rgba(255, 255, 255, 0.25);
}

.footer-paypal-link:hover {
  color: var(--color-accent) !important;
}

.footer-legal-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.legal-link {
  font-size: 9px;
  color: rgba(0, 0, 0, 0.22);
  text-decoration: none;
  letter-spacing: 0.15em;
  transition: color 0.3s ease;
}

.theme-obsidian .legal-link,
body.cinema-dimmed .legal-link {
  color: rgba(255, 255, 255, 0.18);
}

.legal-link:hover {
  color: var(--text-primary) !important;
}


/* ==========================================================================
   MODA SECTION
   ========================================================================== */
.moda-gallery-feed {
  display: flex;
  flex-direction: column;
  gap: 180px; /* Generous breathing room */
  width: 100%;
  max-width: 1100px;
  margin: 60px auto;
  padding: 0 40px 200px 40px;
}

.moda-editorial-card {
  display: flex;
  flex-direction: column;
  width: 65%;
  background: transparent;
  border: none;
  position: relative;
  overflow: visible;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.moda-editorial-card.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Subtler moving monochrome gradient behind the card images */
.moda-editorial-card::before {
  content: "";
  position: absolute;
  top: -40px;
  left: -40px;
  right: -40px;
  bottom: -40px;
  z-index: -1;
  background: radial-gradient(circle at 35% 35%, rgba(0, 0, 0, 0.02) 0%, transparent 70%);
  filter: blur(40px);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0.85;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translate3d(0, var(--scroll-offset, 0px), 0) rotate(var(--scroll-rotate, 0deg));
}

.theme-obsidian .moda-editorial-card::before {
  background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.015) 0%, transparent 70%);
}

.moda-editorial-card:nth-child(odd) {
  align-self: flex-start;
}

.moda-editorial-card:nth-child(even) {
  align-self: flex-end;
}

.moda-editorial-img-wrap {
  width: 100%;
  max-height: 85vh;
  overflow: hidden;
  background: transparent;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid var(--border-pure);
  transition: border-color 0.6s ease, box-shadow 0.6s ease;
}

.moda-editorial-card:hover .moda-editorial-img-wrap {
  border-color: var(--text-primary);
  box-shadow: var(--shadow-premium);
}

.moda-editorial-img {
  width: 100%;
  height: auto;
  max-height: 85vh;
  object-fit: contain;
  filter: grayscale(12%) contrast(102%);
  transition: transform 1.5s cubic-bezier(0.16, 1, 0.3, 1), filter 1s ease;
}

.moda-editorial-card:hover .moda-editorial-img {
  transform: scale(1.025);
  filter: grayscale(0%) contrast(104%);
}

.moda-editorial-details {
  width: 100%;
  padding-top: 35px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.8s var(--transition-fluid);
}

.moda-editorial-card:nth-child(odd) .moda-editorial-details {
  text-align: left;
  align-items: flex-start;
}

.moda-editorial-card:nth-child(even) .moda-editorial-details {
  text-align: right;
  align-items: flex-end;
}

.moda-editorial-serial {
  font-size: 0.65rem;
  color: var(--text-secondary);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 300;
  opacity: 0.85;
}

.moda-editorial-title {
  font-size: 1.45rem;
  font-weight: 300;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin: 0;
}

.moda-editorial-desc {
  font-size: 0.86rem;
  line-height: 1.9;
  color: var(--text-primary);
  font-weight: 300;
  max-width: 580px;
  margin: 0;
  letter-spacing: 0.08em;
  opacity: 0.95;
}

.moda-editorial-divider {
  width: 80px;
  height: 1px;
  background: var(--border-pure);
  opacity: 0.3;
}

.moda-editorial-card:nth-child(odd) .moda-editorial-divider {
  margin: 100px 0 0 0;
}

.moda-editorial-card:nth-child(even) .moda-editorial-divider {
  margin: 100px 0 0 auto;
}

/* Ensure no trailing divider for the last card */
.moda-editorial-card:last-child .moda-editorial-divider {
  display: none;
}

@media (max-width: 992px) {
  .moda-gallery-feed {
    gap: 100px;
    padding: 0 20px 120px 20px;
    margin: 30px auto;
  }
  
  .moda-editorial-card {
    width: 100% !important;
    align-self: stretch !important;
    transform: none !important;
    opacity: 1 !important;
  }

  .moda-editorial-details {
    text-align: center !important;
    align-items: center !important;
  }

  .moda-editorial-desc {
    max-width: 650px;
    margin: 0 auto;
    text-align: center;
  }

  .moda-editorial-divider {
    margin: 80px auto 0 auto !important;
  }
}


/* ==========================================================================
   IDEA/THEATER SUB-TABS & STAGE
   ========================================================================== */
.symphony-sub-nav {
  display: flex;
  gap: 30px;
  margin: 30px auto;
  justify-content: center;
  width: 100%;
  max-width: var(--max-content-width);
  border-bottom: 1px solid var(--border-pure);
  padding-bottom: 12px;
}

.symphony-sub-tab {
  background: transparent;
  border: none;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 8px 0;
  position: relative;
  transition: color 0.3s ease;
  text-transform: uppercase;
}

.symphony-sub-tab:hover {
  color: var(--text-primary);
}

.symphony-sub-tab.active {
  color: var(--text-primary);
}

.symphony-sub-tab.active::after {
  content: "";
  position: absolute;
  bottom: -13px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
}

.symphony-theater-layout {
  width: 100%;
  max-width: var(--max-content-width);
  margin: 40px auto;
}

.theater-stage-clean {
  width: 100%;
  height: 380px;
  background: #08080c;
  border: 1px solid var(--border-pure);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.9);
}

.theater-stage-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 50%, rgba(20, 20, 35, 0.8) 0%, rgba(4, 4, 8, 1) 100%);
  z-index: 1;
}

/* ── Story Sync Button ─────────────────────────────────────── */
.story-sync-btn {
  position: absolute;
  top: 18px;
  right: 20px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.35);
  font-family: 'Courier Prime', monospace;
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  padding: 5px 12px;
  border-radius: 20px;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
  z-index: 10;
}
.story-sync-btn:hover {
  color: rgba(255, 255, 255, 0.7);
  border-color: rgba(255, 255, 255, 0.3);
}
.story-sync-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

/* ensure container is relative for absolute positioning of sync btn */
.story-stream-container {
  position: relative;
}
.theater-stage-spotlight {
  position: absolute;
  top: -50px;
  left: calc(50% - 100px);
  width: 200px;
  height: 430px;
  background: conic-gradient(from 165deg at 50% 0%, rgba(0, 170, 255, 0.12) 0deg, rgba(0, 170, 255, 0) 30deg);
  filter: blur(15px);
  z-index: 2;
  pointer-events: none;
  transform-origin: top center;
  animation: swayLight 10s infinite alternate ease-in-out;
}

@keyframes swayLight {
  0% { transform: rotate(-5deg); }
  100% { transform: rotate(5deg); }
}

.theater-stage-label {
  z-index: 5;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 30px;
}

.theater-stage-tag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  color: #00ffee;
  letter-spacing: 3px;
}

.theater-stage-title {
  font-size: 1.4rem;
  font-weight: 500;
  color: #ffffff;
  letter-spacing: 4px;
  margin: 0;
}

.theater-stage-desc {
  font-size: 0.8rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.5);
  max-width: 420px;
  margin: 0 auto;
  letter-spacing: normal;
}

/* Screenplay (Script Format) Styling for FAN FICTION */
.theater-script-wrapper {
  background: #FFFFFF;
  color: #0D0D0D;
  font-family: 'Courier Prime', 'Courier New', Courier, monospace;
  padding: 80px 100px;
  border: 1px solid var(--border-pure);
  box-shadow: var(--shadow-premium);
  max-width: 800px;
  margin: 40px auto;
  line-height: 1.85;
  text-align: left;
  transition: var(--transition-fluid);
}

/* HYPE h3 title — needs generous breathing room */
#theater-script-hype h3 {
  margin-top: 0;
  margin-bottom: 2.8rem;
  font-size: 1.4rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* H4 chapter headers in HYPE */
#theater-script-hype h4 {
  margin-top: 2.8rem;
  margin-bottom: 0.8rem;
  font-size: 1rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.theme-obsidian .theater-script-wrapper,
body.theme-obsidian .theater-script-wrapper {
  background: #0A0A0A;
  color: #F5F5F7;
  border-color: #222222;
}

.script-header {
  text-align: center;
  margin-bottom: 60px;
  border-bottom: 1px solid var(--border-pure);
  padding-bottom: 40px;
}

.script-title {
  font-size: 2.4rem;
  letter-spacing: 0.18em;
  font-weight: 700;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.script-subtitle {
  font-size: 1.15rem;
  letter-spacing: 0.08em;
  font-weight: 400;
  margin-bottom: 10px;
  color: var(--text-secondary);
}

.script-author {
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
  font-style: italic;
}

.script-version {
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 25px;
}

.script-genre {
  font-size: 0.9rem;
  letter-spacing: 0.22em;
  font-weight: bold;
  color: var(--text-primary);
  text-transform: uppercase;
}

.script-meta-section {
  margin-bottom: 40px;
  border-bottom: 1px solid var(--border-pure);
  padding-bottom: 30px;
}

.script-section-title {
  font-size: 1.05rem;
  letter-spacing: 0.15em;
  font-weight: bold;
  text-transform: uppercase;
  margin-bottom: 15px;
  color: var(--text-primary);
}

.script-meta-text {
  font-size: 0.95rem;
  margin-bottom: 15px;
  color: var(--text-primary);
  text-align: justify;
  line-height: 1.6;
}

.script-characters-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.script-characters-list li {
  margin-bottom: 12px;
  font-size: 0.95rem;
  line-height: 1.6;
}

.script-act {
  font-size: 1.3rem;
  font-weight: bold;
  text-align: center;
  margin-top: 60px;
  margin-bottom: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-primary);
}

.script-scene {
  font-size: 1rem;
  font-weight: bold;
  text-align: center;
  margin-bottom: 35px;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.script-stage-direction {
  font-style: italic;
  margin: 25px auto;
  max-width: 90%;
  color: var(--text-secondary);
  text-align: left; /* Stage directions inside parenthesis can be block left or centered */
  line-height: 1.6;
}

.script-dialogue-block {
  margin: 30px auto;
  max-width: 80%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.script-character-name {
  font-weight: bold;
  letter-spacing: 0.18em;
  margin-bottom: 6px;
  text-align: center;
  text-transform: uppercase;
  color: var(--text-primary);
}

.script-dialogue-text {
  text-align: center;
  line-height: 1.7;
  margin: 0;
  width: 100%;
}

.script-divider {
  width: 100%;
  height: 1px;
  background: var(--border-pure);
  margin: 50px 0;
}

@media (max-width: 768px) {
  .theater-script-wrapper {
    padding: 40px 20px;
    margin: 20px 0;
  }
  .script-dialogue-block {
    max-width: 100%;
  }
  .script-stage-direction {
    max-width: 100%;
  }
  .script-title {
    font-size: 1.8rem;
  }
  #theater-script-hype h3 {
    font-size: 1.2rem;
  }
}

/* LYRICS placeholder view */
.lyrics-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40vh;
  width: 100%;
}

.lyrics-coming-soon {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  letter-spacing: 0.3em;
  color: var(--text-muted);
  text-transform: uppercase;
  font-style: italic;
  opacity: 0.6;
  animation: subtlePulse 3s ease-in-out infinite;
}

@keyframes subtlePulse {
  0%, 100% { opacity: 0.4; }
  50%       { opacity: 0.75; }
}

/* ==========================================================================
   GAMES SECTION
   ========================================================================== */
.games-dashboard {
  max-width: 800px;
  margin: 60px auto;
  padding: 0 40px 100px 40px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.games-selector {
  display: flex;
  justify-content: center;
  gap: 20px;
  border-bottom: 1px solid var(--border-pure);
  padding-bottom: 20px;
}

.game-select-btn {
  background: transparent;
  border: 1px solid var(--border-pure);
  color: var(--text-secondary);
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  padding: 10px 24px;
  cursor: pointer;
  transition: all 0.4s var(--transition-fluid);
  border-radius: 20px;
  font-weight: 300;
}

.game-select-btn:hover,
.game-select-btn.active {
  color: var(--text-primary);
  border-color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.theme-obsidian .game-select-btn:hover,
.theme-obsidian .game-select-btn.active {
  background: rgba(255, 255, 255, 0.02);
}

.game-active-container {
  min-height: 480px;
  position: relative;
}

.game-view {
  display: none;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.game-view.active {
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 1;
  transform: translateY(0);
}

.game-instructions {
  width: 100%;
  margin-bottom: 30px;
  text-align: center;
}

.game-instruction-tag {
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 300;
  display: block;
  margin-bottom: 10px;
}

.game-instruction-desc {
  font-size: 0.85rem;
  line-height: 1.8;
  color: var(--text-primary);
  font-weight: 300;
  max-width: 600px;
  margin: 0 auto;
  opacity: 0.85;
}

.game-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 500px;
  margin-bottom: 40px;
  gap: 20px;
}

.control-group {
  display: flex;
  align-items: center;
  gap: 15px;
}

.control-label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.size-buttons {
  display: flex;
  gap: 8px;
}

.size-btn {
  background: transparent;
  border: 1px solid var(--border-pure);
  color: var(--text-secondary);
  font-size: 0.75rem;
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.size-btn:hover,
.size-btn.active {
  color: var(--text-primary);
  border-color: var(--text-primary);
}

.game-btn-action {
  background: transparent;
  border: 1px solid var(--text-primary);
  color: var(--text-primary);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  padding: 8px 20px;
  cursor: pointer;
  border-radius: 4px;
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.game-btn-action:hover {
  background: var(--text-primary);
  color: var(--bg-primary);
}

/* CYPHER BOARD STYLING */
.cypher-board-wrapper {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-pure);
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow-premium);
  backdrop-filter: blur(20px);
  margin-bottom: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 480px;
  aspect-ratio: 1 / 1;
}

.cypher-board {
  display: grid;
  gap: 12px;
  width: 100%;
  height: 100%;
}

.cypher-board-3x3 {
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
}

.cypher-board-4x4 {
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
}

.cypher-board-5x5 {
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 1fr);
}

.cypher-tile {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border-pure);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.4s var(--transition-fluid);
  aspect-ratio: 1 / 1;
  color: var(--text-secondary);
  opacity: 0.7;
}

.cypher-tile:hover {
  border-color: var(--text-primary);
  opacity: 1;
  background: rgba(255, 255, 255, 0.04);
}

.cypher-tile.active {
  border-color: rgba(0, 255, 238, 0.4);
  color: #00ffee;
  opacity: 1;
  box-shadow: 0 0 15px rgba(0, 255, 238, 0.15);
  background: rgba(0, 255, 238, 0.02);
}

.theme-obsidian .cypher-tile.active {
  border-color: rgba(0, 255, 238, 0.5);
  box-shadow: 0 0 20px rgba(0, 255, 238, 0.2);
}

.cypher-tile.source-tile,
.cypher-tile.target-tile {
  cursor: default;
  background: rgba(255, 255, 255, 0.05);
}

.cypher-tile.source-tile.active,
.cypher-tile.target-tile.active {
  color: #00ffee;
  background: rgba(0, 255, 238, 0.04);
}

.tile-line {
  stroke: currentColor;
  fill: none;
  stroke-linecap: round;
  transition: stroke 0.4s ease;
}

.tile-node {
  fill: currentColor;
  transition: fill 0.4s ease;
}

.tile-line.source-line,
.tile-line.target-line {
  stroke-dasharray: 4, 4;
}

/* SYNAPSE MATCH BOARD STYLING */
.synapse-game-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 40px;
  width: 100%;
}

.synapse-wheel-wrapper {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-pure);
  border-radius: 50%;
  padding: 30px;
  box-shadow: var(--shadow-premium);
  backdrop-filter: blur(20px);
  width: 320px;
  height: 320px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.synapse-wheel {
  width: 100%;
  height: 100%;
  position: relative;
  border-radius: 50%;
}

.synapse-pad {
  position: absolute;
  width: 42%;
  height: 42%;
  border-radius: 50%;
  border: 1px solid var(--border-pure);
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(0, 0, 0, 0.3);
  opacity: 0.6;
}

.synapse-pad.pad-0 { top: 4%; left: 29%; border-color: rgba(255, 100, 100, 0.3); } /* Top - Red */
.synapse-pad.pad-1 { top: 29%; right: 4%; border-color: rgba(100, 255, 100, 0.3); } /* Right - Green */
.synapse-pad.pad-2 { bottom: 4%; left: 29%; border-color: rgba(100, 100, 255, 0.3); } /* Bottom - Blue */
.synapse-pad.pad-3 { top: 29%; left: 4%; border-color: rgba(255, 255, 100, 0.3); } /* Left - Yellow */

.synapse-pad.pad-0.active { background: rgba(255, 100, 100, 0.4); border-color: #ff6464; box-shadow: 0 0 20px #ff6464; opacity: 1; }
.synapse-pad.pad-1.active { background: rgba(100, 255, 100, 0.4); border-color: #64ff64; box-shadow: 0 0 20px #64ff64; opacity: 1; }
.synapse-pad.pad-2.active { background: rgba(100, 100, 255, 0.4); border-color: #6464ff; box-shadow: 0 0 20px #6464ff; opacity: 1; }
.synapse-pad.pad-3.active { background: rgba(255, 255, 100, 0.4); border-color: #ffff64; box-shadow: 0 0 20px #ffff64; opacity: 1; }

.synapse-pad:hover {
  opacity: 0.9;
  border-color: var(--text-primary);
}

.synapse-center-btn {
  position: absolute;
  top: 35%;
  left: 35%;
  width: 30%;
  height: 30%;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 1px solid var(--border-pure);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: var(--shadow-premium);
  transition: all 0.3s ease;
  z-index: 5;
}

.synapse-center-btn:hover {
  border-color: var(--text-primary);
  transform: scale(1.05);
}

#synapse-btn-text {
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  font-weight: bold;
  color: var(--text-primary);
  text-transform: uppercase;
}

/* GAME STATUS BAR */
.game-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 800px;
  padding: 15px 20px;
  border: 1px solid var(--border-pure);
  background: rgba(255, 255, 255, 0.01);
  border-radius: 8px;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 10px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #555;
  transition: all 0.3s ease;
}

.status-dot.unstable {
  background: #ff5555;
  box-shadow: 0 0 8px #ff5555;
}

.status-dot.connected {
  background: #00ffee;
  box-shadow: 0 0 8px #00ffee;
}

.status-dot.scan {
  background: #ffff55;
  box-shadow: 0 0 8px #ffff55;
  animation: pulse 1s infinite alternate;
}

#cypher-status-text,
#synapse-status-text {
  font-size: 0.75rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

.game-stats {
  font-size: 0.75rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

#cypher-moves-count,
#synapse-score-count {
  color: var(--text-primary);
  font-weight: bold;
}

@keyframes pulse {
  0% { opacity: 0.4; }
  100% { opacity: 1; }
}

@media (max-width: 580px) {
  .game-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 15px;
  }
  
  .control-group {
    justify-content: space-between;
  }

  .cypher-board-wrapper {
    aspect-ratio: 1 / 1;
    width: 100%;
  }

  .synapse-wheel-wrapper {
    width: 270px;
    height: 270px;
  }
}

/* ==========================================================================
   ARCADE PLATFORMER STYLING
   ========================================================================== */
.arcade-game-container {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin-bottom: 30px;
}

.arcade-canvas-wrapper {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-pure);
  border-radius: 12px;
  box-shadow: var(--shadow-premium);
  background: #000;
  max-width: 800px;
  width: 100%;
  aspect-ratio: 800 / 450;
}

#arcade-canvas {
  width: 100%;
  height: auto;
  display: block;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

/* Touch Control Overlay */
.arcade-touch-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 24px;
  box-sizing: border-box;
}

/* Show touch controls by default on smaller viewports, or can be clicked on desktop too */
.arcade-dpad {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  opacity: 0.65;
  transition: opacity 0.3s;
  pointer-events: auto;
}

.arcade-dpad:hover {
  opacity: 0.95;
}

.dpad-row {
  display: flex;
  gap: 36px;
}

.dpad-btn {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 1.1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  user-select: none;
  outline: none;
  transition: all 0.15s ease;
}

.dpad-btn:active {
  background: rgba(255, 255, 255, 0.2);
  border-color: #00ffee;
  color: #00ffee;
  transform: scale(0.95);
}

.arcade-action-btns {
  display: flex;
  gap: 16px;
  opacity: 0.65;
  transition: opacity 0.3s;
  pointer-events: auto;
}

.arcade-action-btns:hover {
  opacity: 0.95;
}

.action-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 0.7rem;
  font-family: 'Outfit', 'Inter', monospace;
  font-weight: bold;
  letter-spacing: 0.05em;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  user-select: none;
  outline: none;
  transition: all 0.15s ease;
}

.action-btn.btn-jump {
  border-color: rgba(0, 255, 238, 0.4);
  text-shadow: 0 0 5px rgba(0, 255, 238, 0.5);
}

.action-btn.btn-shoot {
  border-color: rgba(255, 34, 102, 0.4);
  text-shadow: 0 0 5px rgba(255, 34, 102, 0.5);
}

.action-btn:active {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(0.92);
}

.action-btn.btn-jump:active {
  border-color: #00ffee;
  color: #00ffee;
}

.action-btn.btn-shoot:active {
  border-color: #ff2266;
  color: #ff2266;
}

/* Responsive adjust for smaller screens */
@media (max-width: 768px) {
  .arcade-touch-overlay {
    padding: 12px;
  }
  .dpad-btn {
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
  }
  .dpad-row {
    gap: 28px;
  }
  .action-btn {
    width: 50px;
    height: 50px;
    font-size: 0.65rem;
  }
}

/* ─────────────────────────────────────────────────────────────
   ART GALLERY — Horizontaler Kunstfluss
   ───────────────────────────────────────────────────────────── */

/* ─────────────────────────────────────────────────────────────
   ART GALLERY — Horizontaler Kunstfluss (Fixed Architecture)
   ───────────────────────────────────────────────────────────── */

/*
 * Die Section selbst wird ein Block-Container ohne Padding.
 * display:block überschreibt das flex der Base-Class, damit
 * der Strip die volle Breite bekommen kann.
 */
.app-section--art {
  display: block !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  height: 100vh !important;
  min-height: unset !important;
  width: 100% !important;
}

/*
 * Der Strip ist der echte Scroll-Container.
 * width: 100%  → füllt die Section vollständig (KEIN 100vw)
 * overflow-x: scroll → Browser registriert Scroll-Grenzen
 */
.art-gallery-strip {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 15px;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0;
  margin: 0;
  background: #000;
  touch-action: pan-x;
  cursor: grab;
  /* Scrollbar verstecken — alle Browser */
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
}
.art-gallery-strip::-webkit-scrollbar {
  display: none;
}
.art-gallery-strip.dragging,
.art-gallery-strip.dragging * {
  cursor: grabbing !important;
  user-select: none !important;
}

/* ══════════════════════════════════════════════════════════════
   HYPE — Holy Temple Section
   Overrides .app-section base (padding:275px/130px, min-height:100vh)
══════════════════════════════════════════════════════════════ */

/* Hide ambient player widget everywhere */
#ambient-player { display: none !important; }

#hype {
  background: radial-gradient(ellipse at 50% 44%,
    #ebebeb 0%, #e2e2e6 50%, #d8d8de 100%) !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  /* Override the 275px / 130px section padding */
  padding: 90px 24px 36px !important;
  gap: 0 !important;
}

/* ── Stage (orb + aura container) ── */
.holy-stage {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  /* No flex:1 — let the stage be exactly as tall as the orb */
  margin-bottom: 20px;
}

/* ── Plasma Aura (behind orb) ── */
.holy-aura {
  position: absolute;
  z-index: 0;
  width:  clamp(220px, 38vmin, 380px);
  height: clamp(220px, 38vmin, 380px);
  border-radius: 50%;
  /* Nur reines Weiß — kein Farbenspiel */
  background: radial-gradient(circle, rgba(255,255,255,0.55) 0%, transparent 70%);
  filter: blur(28px);
  opacity: 0;
  transform: scale(0.88);
  transition:
    opacity  1.6s cubic-bezier(0.25, 1, 0.5, 1),
    transform 1.6s cubic-bezier(0.25, 1, 0.5, 1);
}
.holy-aura.streaming {
  opacity: 0.28;
  transform: scale(1.04);
  /* Kein Rotieren, kein Regenbogen — nur ein ruhiges Aufleuchten */
}

/* ── The Holy Orb ── */
.holy-orb {
  position: relative;
  z-index: 1;
  /* vmin = smaller of vw/vh → orb scales with the shorter dimension */
  width:  clamp(160px, 32vmin, 280px);
  height: clamp(160px, 32vmin, 280px);
  border-radius: 50%;
  /* Layered radial gradient: pure white core → warm ivory edge */
  background: radial-gradient(circle at 50% 42%,
    #ffffff 0%,
    #ffffff 28%,
    #fdfdfd 55%,
    #f5f5f8 80%,
    #eeeeF2 100%);
  /* Minimaler, sehr dezenter weißer Glow */
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.35),
    0 0 12px 4px  rgba(255,255,255,0.55),
    0 0 30px 12px rgba(255,255,255,0.2),
    0 0 60px 25px rgba(255,255,255,0.08);
  display: flex;
  justify-content: center;
  align-items: center;
  /* Sanftes Atmen + Schweben */
  animation: orb-breath 7s ease-in-out infinite,
             orb-drift  9s ease-in-out infinite;
  transition: box-shadow 1.6s ease;
}

/* Concentric glass rings (texture) */
.holy-orb::before {
  content: '';
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  background: repeating-radial-gradient(circle,
    transparent 0px, transparent 4px,
    rgba(0,0,0,0.025) 5px, transparent 6px);
  pointer-events: none;
}

/* ── Inner Sun-Core dot ── */
.orb-core {
  position: absolute;
  top: 40%;
  width: 8px;
  height: 8px;
  background: rgba(255,255,255,0.9);
  border-radius: 50%;
  /* Sehr dezenter Kern — fast unsichtbar im Ruhezustand */
  box-shadow:
    0 0 6px 2px rgba(255,255,255,0.5),
    0 0 14px 5px rgba(255,255,255,0.2);
  z-index: 2;
}
/* During streaming: core pulses */
.holy-stage.streaming .orb-core {
  animation: core-pulse 1.8s ease-in-out infinite;
}

/* ── Starburst cross-rays ── */
.starburst {
  position: absolute;
  top: 40%;
  width: 12px;
  height: 12px;
  z-index: 2;
  pointer-events: none;
}
.starburst::before,
.starburst::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  background: radial-gradient(ellipse, rgba(255,255,255,0.9) 0%, transparent 65%);
  border-radius: 50%;
}
/* Horizontal ray */
.starburst::before {
  width: 80px; height: 3px;
  transform: translate(-50%,-50%) rotate(12deg);
}
/* Diagonal ray */
.starburst::after {
  width: 55px; height: 3px;
  transform: translate(-50%,-50%) rotate(-42deg);
}

/* ══ Keyframes ══ */
/* Minimales Atmen — Glow wächst nur leicht */
@keyframes orb-breath {
  0%, 100% {
    box-shadow:
      0 0 0 1px rgba(255,255,255,0.35),
      0 0 12px 4px  rgba(255,255,255,0.55),
      0 0 30px 12px rgba(255,255,255,0.2),
      0 0 60px 25px rgba(255,255,255,0.08);
  }
  50% {
    box-shadow:
      0 0 0 1px rgba(255,255,255,0.5),
      0 0 18px 7px  rgba(255,255,255,0.7),
      0 0 42px 18px rgba(255,255,255,0.3),
      0 0 80px 35px rgba(255,255,255,0.12);
  }
}
/* Sanftes Schweben — unverändert */
@keyframes orb-drift {
  0%   { transform: translateY(0px)   scale(1); }
  33%  { transform: translateY(-5px)  scale(1.008); }
  66%  { transform: translateY(-2px)  scale(1.004); }
  100% { transform: translateY(0px)   scale(1); }
}
/* Kern-Puls beim Antworten — dezentes weißes Aufleuchten */
@keyframes core-pulse {
  0%, 100% { transform: scale(1);   opacity: 0.6;
              box-shadow: 0 0 6px 2px rgba(255,255,255,0.5), 0 0 14px 5px rgba(255,255,255,0.2); }
  50%       { transform: scale(1.15); opacity: 1;
              box-shadow: 0 0 12px 4px rgba(255,255,255,0.9), 0 0 28px 10px rgba(255,255,255,0.4); }
}
/* Antwort-Puls: rein weißes, sanftes Aufleuchten — kein Blau, kein Grün */
@keyframes orb-think {
  0%, 100% {
    box-shadow:
      0 0 0 1px rgba(255,255,255,0.4),
      0 0 15px 5px  rgba(255,255,255,0.6),
      0 0 35px 14px rgba(255,255,255,0.22),
      0 0 65px 28px rgba(255,255,255,0.08);
  }
  50% {
    box-shadow:
      0 0 0 1px rgba(255,255,255,0.7),
      0 0 22px 9px  rgba(255,255,255,0.88),
      0 0 50px 22px rgba(255,255,255,0.35),
      0 0 90px 40px rgba(255,255,255,0.15);
  }
}
/* Beim Antworten: sanfter weißer Puls, Kugel schwebt weiter ruhig */
.holy-orb.hype-thinking {
  animation:
    orb-think 2.4s ease-in-out infinite,
    orb-drift 9s ease-in-out infinite;
}


/* ── Blinking caret ── */
.holy-caret {
  display: inline-block;
  width: 2px;
  height: 1.1em;
  background: #111;
  margin-left: 4px;
  vertical-align: middle;
  animation: caret-blink 0.8s infinite;
}
@keyframes caret-blink { 50% { opacity: 0; } }

/* ── Answer sermon text ── */
.hype-sermon {
  width: 100%;
  max-width: 420px;
  /* No min-height: collapses to 0 when empty → input stays near orb */
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 20px;
  margin-bottom: 14px;
}
.hype-sermon-text {
  font-family: Georgia, var(--font-serif, serif);
  font-size: clamp(0.95rem, 1.8vw, 1.1rem);
  line-height: 1.7;
  letter-spacing: 0.02em;
  color: #111;
  margin: 0;
}

/* ══ HYPE INPUT — RADIKALER BROWSER-RESET ══ */
.hype-input-zone {
  width: 100% !important;
  max-width: 500px !important;
  pointer-events: auto !important;
}

.hype-input-row {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  background: transparent !important;
  border: none !important;
}

/* ID-Selektor = höchste Spezifität → schlägt alle Browser-Defaults */
#hype-input {
  background: transparent !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  -webkit-box-shadow: none !important;
  color: #111 !important;
  font-family: inherit !important;
  font-size: 1.1rem !important;
  font-style: italic !important;
  text-align: center !important;
  width: 100% !important;
  padding: 6px 30px !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  pointer-events: auto !important;
  cursor: text !important;
  -webkit-user-select: text !important;
  user-select: text !important;
  flex: 1 !important;
}

/* Blaues Leuchten beim Fokus komplett töten */
#hype-input:focus,
#hype-input:focus-visible,
#hype-input:active {
  outline: none !important;
  outline-offset: 0 !important;
  box-shadow: none !important;
  -webkit-box-shadow: none !important;
  border: none !important;
  background: transparent !important;
}

#hype-input::placeholder {
  color: rgba(0,0,0,0.28) !important;
  font-style: italic !important;
}

/* Weißer 8px Kreis-Button */
#hype-send-btn {
  position: absolute !important;
  right: 8px !important;
  width: 8px !important;
  height: 8px !important;
  background: rgba(255,255,255,0.7) !important;
  border: none !important;
  border-radius: 50% !important;
  cursor: pointer !important;
  padding: 0 !important;
  opacity: 0.5 !important;
  box-shadow: none !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  transition: opacity 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease !important;
  pointer-events: auto !important;
  flex-shrink: 0 !important;
}
/* Hover: weißes Leuchten, kein übertriebenes Scale */
#hype-send-btn:hover {
  opacity: 1 !important;
  transform: scale(1.2) !important;
  box-shadow: 0 0 8px #ffffff, 0 0 15px rgba(255,255,255,0.7) !important;
}
#hype-send-btn:active {
  transform: scale(0.88) !important;
}
#hype-send-btn:focus,
#hype-send-btn:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

@media (max-width: 768px) {
  #hype { padding: 80px 16px 28px !important; }
  .hype-sermon { max-width: 90vw; }
  .hype-input-zone { max-width: 90vw !important; }
}






/* Einzelnes Bild */
.art-gallery-img {
  height: 100%;
  width: auto;
  flex-shrink: 0;
  object-fit: cover;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  transition: filter 0.35s ease;
  filter: grayscale(18%);
  scroll-snap-align: center;
}
.art-gallery-img:hover {
  filter: grayscale(0%);
}

/* ── BOOKS SECTION ─────────────────────────────────────────── */
.app-section--books {
  padding: 260px 60px 100px !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
}

.books-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 40px;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
}

.book-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.book-cover-wrap {
  width: 100%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.07);
}

.book-cover {
  width: 100%;
  max-width: 300px;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  transition: transform 0.4s ease;
}
.book-card:hover .book-cover {
  transform: scale(1.03);
}

/* Platzhalter */
.book-cover-wrap--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.02);
  border: 1px dashed rgba(255,255,255,0.1);
}
.book-placeholder-label {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: rgba(255,255,255,0.2);
  text-transform: uppercase;
}

.book-title {
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 600;
  color: #111;
  margin: 0;
}
.book-title--muted { color: rgba(255,255,255,0.2); }

.book-desc {
  font-size: 0.78rem;
  line-height: 1.75;
  color: #333;
  margin: 0;
}
.book-desc--muted { color: rgba(255,255,255,0.15); }

/* Mobile: 1 Spalte */
@media (max-width: 768px) {
  .app-section--books {
    padding: 120px 24px 80px !important;
  }
  .books-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .book-cover-wrap {
    max-width: 280px;
  }
}

/* ==========================================================================
   GRACEFUL DEGRADATION: VISUELLE FALLBACKS & SPINNER
   Architektur-Kommentar: Diese Fallbacks greifen, wenn APIs (HYPE) oder 
   Audio-Puffer verzögern, um ein Einfrieren (Freeze) der UI zu verhindern.
   Sie erhalten den State der "Antenne" aufrecht.
   ========================================================================== */

.alex-spinner {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-top-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  animation: alexSpin 0.8s linear infinite;
  display: inline-block;
}

body:not(.theme-obsidian) .alex-spinner {
  border-color: rgba(0, 0, 0, 0.1);
  border-top-color: rgba(0, 0, 0, 0.8);
}

@keyframes alexSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.fallback-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  text-align: center;
  animation: fadeInUp 0.5s ease;
}

.fallback-text {
  font-family: var(--font-geometric), sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  text-transform: uppercase;
}
