/* ========================================
LOCAL FONTS - OPTIMIZED SUBSETS
======================================== */
/* Cardo for content (lyrics, translations) - Optimized subset */
@font-face {
  font-family: 'Cardo';
  src: url('fonts/optimized/Cardo-Regular-subset.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}
@font-face {
  font-family: 'Cardo';
  src: url('fonts/optimized/Cardo-Bold-subset.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}
@font-face {
  font-family: 'Cardo';
  src: url('fonts/optimized/Cardo-Regular-subset.ttf') format('truetype');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
  font-preload: true;
}

/* Source Sans 3 for UI elements (titles, controls) - Optimized subset */
@font-face {
  font-family: 'Source Sans 3';
  src: url('fonts/optimized/SourceSans3-Regular-subset.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}
@font-face {
  font-family: 'Source Sans 3';
  src: url('fonts/optimized/SourceSans3-Medium-subset.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}
@font-face {
  font-family: 'Source Sans 3';
  src: url('fonts/optimized/SourceSans3-Semibold-subset.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}
@font-face {
  font-family: 'Source Sans 3';
  src: url('fonts/optimized/SourceSans3-Bold-subset.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  font-preload: true;
}

/* ========================================
CSS VARIABLES
======================================== */
:root {
  --olive-green: #7e6c2a;
  --gold-yellow: #f2673a;
  --warm-white: #f9f7f1;
  --deep-olive: #23241f;
  --gray-olive: #4a4538;
  --gray-olive-light: #5a5445;
  --gray-olive-dark: #3d382f;
  --gray-olive-neutral: #4f4a3d;
  --text-dark: #3a3a3a;
  --text-light: #f9f7f1;
  --white: #ffffff;
}

.dark-mode .dark-mode-text::before {
  content: "LIGHT MODE";
}

.dark-mode-text::before {
  content: "DARK MODE";
}

/* ========================================
BASE STYLES
======================================== */
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
  scroll-behavior: smooth;
}

.container {
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Light mode base */
body {
  background: var(--warm-white);
  color: var(--gray-olive);
}

/* Base body font */
body {
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

  /* Content fonts - serif for readability */
.lyrics, .translation {
  font-family: 'Cardo', Georgia, 'Times New Roman', serif;
  font-feature-settings: 'liga' 1, 'kern' 1, 'calt' 1;
  font-weight: 400;
  font-synthesis: none;
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.2); }
}

/* ========================================
LAYOUT
======================================== */

.view {
  position: absolute;
  top: 0;
  bottom: 84px;
  left: 0;
  right: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}

.control-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 84px;
  box-sizing: border-box;
  z-index: 1000;
}


/* ========================================
HOME VIEW
======================================== */
.home {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 40px;
  padding-bottom: 60px;
}

.home .home-header .home-title {
  font-size: 3em;
  font-weight: 700;
  color: var(--gray-olive-dark);
  text-align: center;
  margin-bottom: 10px;
} 

.home .home-header .home-subtitle {
  font-family: 'Cardo', Georgia, 'Times New Roman', serif;
  font-size: 1.1em;
  font-weight: 400;
  text-align: center;
  margin-bottom: 40px;
}

.home .home-buttons-container {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 15px;
  margin-bottom: 40px;
}

.home .home-buttons-container .home-live-button {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--olive-green);
  border-radius: 30px;
  padding: 8px 12px;
  border: 1px solid var(--olive-green);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
  color: var(--warm-white);
}

.home .home-buttons-container .home-live-button:hover {
  scale: 1.05;
}

.home .home-buttons-container .home-live-button:active {
  scale: 0.95;
}

.home .home-buttons-container .home-live-button .live-text {
  font-size: 1em;
  font-weight: 400;
}

.home .home-buttons-container .home-live-button .live-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--warm-white);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  animation: pulse 1s infinite;
}

.home .home-buttons-container .home-live-button.presenter {
  background: var(--gold-yellow);
  color: var(--white);
  border: 1px solid var(--gold-yellow);
}

.home .home-buttons-container .home-live-button.presenter .live-indicator {
  background: var(--white);
  animation: pulse 1s infinite;
  box-shadow: 0 2px 8px rgba(242, 103, 58, 0.3);
}

.home .home-buttons-container .home-live-button.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

.home .home-buttons-container .home-live-button.disabled .live-indicator {
  animation: none;
}

.home .home-buttons-container .home-dark-mode-button {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--gray-olive);
  border-radius: 30px;
  padding: 8px 12px;
  border: 1px solid var(--gray-olive);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
  color: var(--warm-white);
}

.home .home-buttons-container .home-dark-mode-button:hover {
  scale: 1.05;
}

.home .home-buttons-container .home-dark-mode-button:active {
  scale: 0.95;
}

.home .home-buttons-container .home-dark-mode-button .dark-mode-button-icon {
  height: 20px;
  width: 20px;
  fill: #b4b4b4;
}

.home .home-buttons-container .home-dark-mode-button .dark-mode-text {
  font-size: 1em;
  font-weight: 400;
}

.home .search-container {
  position: relative;
  width: 450px;
  margin-bottom: 20px;
}

.home .search-container .search-input {
  width: 100%;
  padding: 12px 45px 12px 45px;
  font-size: 1.1em;
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  border: 2px solid rgba(0, 0, 0, 0.2);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--gray-olive-dark);
  box-sizing: border-box;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  outline: none;
}

.home .search-container .search-input:focus {
  border-color: var(--olive-green);
  background: rgba(255, 255, 255, 0.8);
}

.home .search-container .search-input::placeholder {
  color: rgba(0, 0, 0, 0.4);
}

.home .search-container .search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  fill: var(--gray-olive);
  pointer-events: none;
}

.home .search-container .clear-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  fill: var(--gray-olive);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.home .search-container .clear-icon:hover {
  fill: var(--gold-yellow);
  scale: 1.1;
}

.home .search-container .clear-icon:active {
  scale: 0.9;
}

.home .deck-list {
  display: flex;
  flex-direction: column;
  width: 450px;
  gap: 10px;
  font-size: 1.1em;
}

.home .deck-list .deck-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.3);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.home .deck-list .deck-item:hover {
  border-bottom: 1px solid var(--olive-green);
  scale: 1.05;
}

.home .deck-list .deck-item:active {
  border-bottom: 1px solid var(--olive-green);
  scale: 0.95;
}

.home .deck-list .deck-item .deck-content {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
}

.home .deck-list .deck-item .deck-content .deck-chevron svg {
  fill: var(--gray-olive);
  width: 20px;
  height: 20px;
}

/* Search Results */
.home .search-results {
  display: flex;
  flex-direction: column;
  width: 450px;
  gap: 20px;
}

.home .search-results-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.home .search-results-label {
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.85em;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: rgba(0, 0, 0, 0.5);
  padding-left: 10px;
  margin-bottom: -5px;
}

.home .search-results-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.home .search-result-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.3);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.home .search-result-item:hover {
  border-bottom: 1px solid var(--olive-green);
  scale: 1.05;
}

.home .search-result-item:active {
  border-bottom: 1px solid var(--olive-green);
  scale: 0.95;
}

.home .search-result-item .search-result-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
  position: relative;
}

.home .search-result-item .search-result-title {
  font-size: 1.05em;
  font-weight: 500;
  color: var(--gray-olive-dark);
}

.home .search-result-item .search-result-subtitle {
  font-size: 0.85em;
  color: rgba(0, 0, 0, 0.5);
  font-style: italic;
}

.home .search-result-item .search-result-preview {
  font-size: 0.9em;
  color: rgba(0, 0, 0, 0.6);
  line-height: 1.4;
  margin-top: 2px;
}

.home .search-result-item .search-result-chevron {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
}

.home .search-result-item .search-result-chevron svg {
  fill: var(--gray-olive);
  width: 20px;
  height: 20px;
}

.home .search-result-item-hidden {
  display: none;
}

.home .search-results-toggle {
  display: flex;
  justify-content: center;
  padding: 10px;
}

.home .search-results-toggle-btn {
  background: transparent;
  border: 1px solid rgba(0, 0, 0, 0.3);
  color: var(--gray-olive-dark);
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 0.9em;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.home .search-results-toggle-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  border-color: var(--olive-green);
  color: var(--olive-green);
}

.home .search-results-toggle-btn:active {
  transform: scale(0.95);
}


/* ========================================
PRESENTATION VIEW
======================================== */
.presentation .view {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.slides {
  height: 100%;
  display: grid;
}

.slides section {
  margin: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 20px;
  padding-bottom: 20px;
  padding-left: 20px;
  padding-right: 20px;
  box-sizing: border-box;
}

.slides section .slide-deck-title {
  font-size: 3em;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--gold-yellow);
  text-align: center;
  text-transform: uppercase;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  position: relative;
  align-self: center;
}

.slides section .slide-deck-subtitle {
  font-size: 1.2em;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--gray-olive);
  text-align: center;
  text-transform: uppercase;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  position: relative;
  align-self: center;
}

.slide-deck-subtitle::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
  width: 100px;
  height: 3px;
  background: linear-gradient(90deg, var(--gold-yellow), var(--olive-green));
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(242, 103, 58, 0.3);
}

.slides section .slide-title {
  font-size: 1.9em;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--olive-green);
  text-align: center;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.slides section .lyrics {
  font-size: 2.6em;
  margin-bottom: 20px;
  text-align: center;
  color: var(--gray-olive-dark);
}

.slides section .translation {
  font-size: 2.4em;
  color: var(--gray-olive-neutral);
}

/* ========================================
CONTROL BAR
======================================== */
.control-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  box-sizing: border-box;
  border-top: 2px solid var(--gold-yellow);
  border-radius: 0;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.control-bar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.control-bar-item {
  flex: 1;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.1);
  border: 2px solid rgba(0, 0, 0, 0.3);
  min-height: 56px;
  min-width: 56px;
  max-height: 56px;
  max-width: 56px;
  box-sizing: border-box;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.control-bar-item:hover {
  border: 2px solid var(--olive-green);
  scale: 1.05;
}

.control-bar-item:active {
  border: 2px solid var(--olive-green);
  scale: 0.95;
}

.control-bar-item.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.control-bar-item svg {
  fill: var(--gray-olive);
  height: 100px;
  width: 100px;
}

.control-bar .return-button-icon {
  stroke: var(--gray-olive);
  stroke-width: 2;
  fill: none !important;
}

.live-button .live-button-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 600;
  color: var(--gray-olive);
}

.live-button .live-button-content .live-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: pulse 1s infinite;
  background: #13a613;
  box-shadow: 0 2px 8px rgba(242, 103, 58, 0.3);
}

.live-button.presenter .live-button-content .live-indicator {
  background: var(--gold-yellow);
  animation: pulse 1s infinite;
  box-shadow: 0 2px 8px rgba(242, 103, 58, 0.3);
}

.live-button.not-synced .live-button-content .live-indicator {
  background: var(--gray-olive-light);
  animation: pulse 1s infinite;
  box-shadow: 0 2px 8px rgba(135, 137, 131, 0.2);
}

.live-button.disabled .live-button-content .live-indicator {
  background: var(--gray-olive-light);
  animation: none;
  box-shadow: 0 2px 8px rgba(135, 137, 131, 0.2);
}

/* ========================================
FLOATING LIVE BUTTON
======================================== */
.floating-live {
  position: fixed;
  top: 15px;
  left: 15px;
  height: 40px;
  width: 70px;
  border-radius: 20px;
  background: var(--gold-yellow);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  z-index: 10000;
}

.floating-live .live-floating-button-content {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.floating-live .live-text {
  font-size: 1.1em;
  font-weight: 600;
}

.floating-live .live-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--white);
  animation: pulse 1s infinite;
  box-shadow: 0 2px 8px rgba(242, 103, 58, 0.3);
}

/* ========================================
ROTATION OVERLAY
======================================== */
.rotation-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: overlayFadeIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: rgba(255, 255, 255, 0.95);
  text-align: center;
  padding: 40px 20px;
  box-sizing: border-box;
}

.rotation-overlay.hidden {
  display: none;
}

.rotation-overlay.fade-out {
  animation: overlayFadeOut 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.rotation-overlay .rotation-icon {
  margin-bottom: 2.5rem;
  filter: drop-shadow(0 4px 20px rgba(0, 0, 0, 0.3));
}

.rotation-overlay .phone-svg {
  width: 120px;
  height: 120px;
  animation: phoneRotate 3s ease-in-out infinite;
  transform-origin: center;
}

.rotation-overlay .rotation-text {
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
  font-weight: 500;
  max-width: 320px;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: -0.01em;
  margin-bottom: 1rem;
}

.rotation-overlay .rotation-dismiss {
  font-size: 1.3rem;
  opacity: 0.6;
  animation: subtlePulse 3s ease-in-out infinite;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 400;
}

/* ========================================
Sync Invitation Overlay
======================================== */
.sync-invitation-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: overlayFadeIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

.sync-invitation-overlay.hidden {
  display: none;
}

.sync-invitation-overlay.fade-out {
  animation: overlayFadeOut 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.sync-invitation-content {
  background: rgba(200, 200, 200, 0.6);
  border: 2px solid var(--gray-olive);
  border-radius: 20px;
  padding: 20px;
  width: 500px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(126, 108, 42, 0.15);
  transform: translateY(0);
  transition: all 0.3s ease;
}

.sync-invitation-icon svg {
  width: 48px;
  height: 48px;
  margin-bottom: 10px;
  fill: var(--olive-green);
}

.sync-invitation-message {
  font-size: 1.5em;
  color: var(--text-dark);
  opacity: 0.95;
  margin-bottom: 20px;
  line-height: 1.5;
}

.sync-invitation-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
}

.sync-invitation-button {
  padding: 16px;
  box-sizing: border-box;
  border: none;
  border-radius: 12px;
  font-size: 1.3em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  width: 215px;
}

.sync-invitation-button.sync-yes {
  background: var(--gray-olive-dark);
  color: var(--warm-white);
}

.sync-invitation-button.sync-yes:hover {
  background: var(--gray-olive);
  transform: translateY(-1px);
}

.sync-invitation-button.sync-no {
  background: var(--warm-white);
  color: var(--gray-olive);
}

.sync-invitation-button.sync-no:hover {
  background: #f9f7f1;
  transform: translateY(-1px);
}

/* Animations */
@keyframes overlayFadeIn {
  from { 
    opacity: 0; 
    transform: scale(0.95);
  }
  to { 
    opacity: 1; 
    transform: scale(1);
  }
}

@keyframes overlayFadeOut {
  from { 
    opacity: 1; 
    transform: scale(1);
  }
  to { 
    opacity: 0; 
    transform: scale(0.95);
  }
}

@keyframes phoneRotate {
  0% { 
    transform: rotate(0deg) scale(1);
  }
  25% { 
    transform: rotate(0deg) scale(1.05);
  }
  50% { 
    transform: rotate(90deg) scale(1.1);
  }
  75% { 
    transform: rotate(90deg) scale(1.05);
  }
  100% { 
    transform: rotate(0deg) scale(1);
  }
}

@keyframes subtlePulse {
  0%, 100% { 
    opacity: 0.6; 
    transform: translateY(0px);
  }
  50% { 
    opacity: 0.8; 
    transform: translateY(-2px);
  }
}

/* ========================================
SLIDE NAVIGATION
======================================== */
.lyrics-translation-nav {
  margin-top: 15px;
  margin-bottom: 15px;
  text-align: center;
  font-size: 0.9em;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}

.lyrics-translation-nav .to-lyrics-nav-link, .lyrics-translation-nav .to-translation-nav-link {
  padding: 8px 16px;
  background: var(--olive-green);
  color: var(--warm-white);
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  margin: 0 4px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 6px rgba(126, 108, 42, 0.3);
}

.lyrics-translation-nav .to-lyrics-nav-link:hover, .lyrics-translation-nav .to-translation-nav-link:hover {
  background: var(--gold-yellow);
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(242, 103, 58, 0.4);
}

.lyrics-translation-nav .to-lyrics-nav-link:active, .lyrics-translation-nav .to-translation-nav-link:active {
  transform: translateY(0);
}

/* Hide navigation for non-presenters by default */
.lyrics-translation-nav.hidden {
  display: none;
}

/* ========================================
RESPONSIVE STYLES
======================================== */

@media (max-width: 600px) {
  .slides section .slide-deck-title {
    font-size: 2.5em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 1.5em;
  }

  .slides section .slide-title {
    font-size: 1.5em;
  }

  .slides section .lyrics {
    font-size: 1.7em;
  }

  .slides section .translation {
    font-size: 1.6em;
  }

  .sync-invitation-content {
    width: 290px;
  }
  
  .sync-invitation-message {
    font-size: 1em;
  }
  
  .sync-invitation-button {
    font-size: 1em;
    width: auto;
    min-width: 100px;
  }

  .home .deck-list {
    width: 310px;
  }

  .home .search-results {
    width: 310px;
  }

  .home .search-container {
    width: 310px;
  }

  .home .search-container .search-input {
    font-size: 1em;
  }
}

@media (min-width: 601px) and (max-width: 900px) {
  .slides section .slide-deck-title {
    font-size: 3em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 1.5em;
  }

  .slides section .slide-title {
    font-size: 1.6em;
  }

  .slides section .lyrics {
    font-size: 2.1em;
  }

  .slides section .translation {
    font-size: 1.95em;
  }
}

@media (min-width: 901px) and (max-width: 1199px) {
  .slides section .slide-deck-title {
    font-size: 4em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 2em;
  }

  .slides section .slide-title {
    font-size: 2em;
  }

  .slides section .lyrics {
    font-size: 2.25em;
  }

  .slides section .translation {
    font-size: 2.15em;
  }
}

@media (min-width: 1200px) {
  .slides section .slide-deck-title {
    font-size: 4em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 2em;
  }

  .slides section .slide-title {
    font-size: 2em;
  }

  .slides section .lyrics {
    font-size: 2.7em;
  }

  .slides section .translation {
    font-size: 2.5em;
  }
}

@media (min-width: 1600px) {
  .slides section .slide-deck-title {
    font-size: 5em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 2.5em;
  }

  .slides section .slide-title {
    font-size: 2.2em;
  }

  .slides section .lyrics {
    font-size: 3em;
  }

  .slides section .translation {
    font-size: 2.8em;
  }
}

@media (max-width: 1024px) and (max-height: 500px) and (orientation: landscape) {
  .slides section .slide-deck-title {
    font-size: 2.5em;
  }

  .slides section .slide-deck-subtitle {
    font-size: 1.7em;
  }

  .slides section .slide-title {
    font-size: 1.25em;
  }

  .slides section .lyrics {
    font-size: 1.65em;
  }

  .slides section .translation {
    font-size: 1.55em;
  }

  .view {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 84px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }
  
  .control-bar {
    top: 0;
    bottom: 0;
    left: auto;
    right: 0;
    width: 84px;
    height: 100%;
    border-top: none;
    border-left: 2px solid var(--gold-yellow);
    border-radius: 0;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
  }

  .control-bar-nav {
    flex-direction: column;
  }
}

/* ========================================
DARK MODE
======================================== */

/* General dark mode styles */
.dark-mode {
  background: var(--deep-olive);
  color: var(--warm-white);
}

/* Slides dark mode styles */
.dark-mode .slides section .slide-deck-title {
  color: var(--gold-yellow);
}

.dark-mode .slides section .slide-deck-subtitle {
  color: var(--warm-white);
}

.dark-mode .slides section .slide-title {
  color: var(--gold-yellow);
}

.dark-mode .slides section .lyrics {
  color: var(--warm-white);
}

.dark-mode .slides section .translation {
  color: var(--warm-white);
}

/* Control bar dark mode styles */
.dark-mode .control-bar {
  border-color: var(--olive-green);
}

.dark-mode .control-bar-item {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
}

.dark-mode .control-bar-item:hover {
  border-color: var(--gold-yellow);
}

.dark-mode .control-bar-item:active {
  border-color: var(--gold-yellow);
}

.dark-mode .control-bar-item svg {
  fill: rgba(255, 255, 255, 0.75);
}

.dark-mode .control-bar .return-button-icon {
  stroke: rgba(255, 255, 255, 0.75);
}

.dark-mode .control-bar .live-button .live-button-content {
  color: rgba(255, 255, 255, 0.75);
}

.dark-mode .control-bar .live-button.not-synced .live-button-content .live-indicator {
  background: var(--warm-white);
  animation: pulse 1s infinite;
  box-shadow: 0 2px 8px rgba(214, 162, 128, 0.48);
}

/* Home view dark mode styles */
.dark-mode .home .home-header .home-title {
  color: var(--gold-yellow);
}

.dark-mode .home .home-buttons-container .home-live-button {
  background: var(--gold-yellow);
  border-color: var(--gold-yellow);
}

.dark-mode .home .home-buttons-container .home-live-button.disabled {
  opacity: 0.6;
}

.dark-mode .home .deck-list .deck-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.dark-mode .home .deck-list .deck-item:hover {
  border-bottom: 1px solid var(--gold-yellow);
}

.dark-mode .home .deck-list .deck-item:active {
  border-bottom: 1px solid var(--gold-yellow);
}

.dark-mode .home .deck-list .deck-item .deck-content .deck-chevron svg {
  fill: rgba(255, 255, 255, 0.75);
}

/* Search bar dark mode styles */
.dark-mode .home .search-container .search-input {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--warm-white);
}

.dark-mode .home .search-container .search-input:focus {
  border-color: var(--gold-yellow);
  background: rgba(255, 255, 255, 0.15);
}

.dark-mode .home .search-container .search-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.dark-mode .home .search-container .search-icon {
  fill: rgba(255, 255, 255, 0.6);
}

.dark-mode .home .search-container .clear-icon {
  fill: rgba(255, 255, 255, 0.6);
}

.dark-mode .home .search-container .clear-icon:hover {
  fill: var(--gold-yellow);
}

/* Search results dark mode styles */
.dark-mode .home .search-results-label {
  color: rgba(255, 255, 255, 0.5);
}

.dark-mode .home .search-result-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.dark-mode .home .search-result-item:hover {
  border-bottom: 1px solid var(--gold-yellow);
}

.dark-mode .home .search-result-item:active {
  border-bottom: 1px solid var(--gold-yellow);
}

.dark-mode .home .search-result-item .search-result-title {
  color: var(--warm-white);
}

.dark-mode .home .search-result-item .search-result-subtitle {
  color: rgba(255, 255, 255, 0.5);
}

.dark-mode .home .search-result-item .search-result-preview {
  color: rgba(255, 255, 255, 0.6);
}

.dark-mode .home .search-result-item .search-result-chevron svg {
  fill: rgba(255, 255, 255, 0.75);
}

.dark-mode .home .search-results-toggle-btn {
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--warm-white);
}

.dark-mode .home .search-results-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--gold-yellow);
  color: var(--gold-yellow);
}

/* Sync invitation dark mode styles */
.dark-mode .sync-invitation-content {
  background: rgba(0, 0, 0, 0.5);
  border-color: var(--gray-olive-dark);
}

.dark-mode .sync-invitation-icon svg {
  fill: var(--gold-yellow);
}

.dark-mode .sync-invitation-message {
  color: var(--warm-white);
}

.dark-mode .sync-invitation-button.sync-yes {
  background: var(--gold-yellow);
}

.dark-mode .sync-invitation-button.sync-yes:hover {
  background: #b34520;
}

.dark-mode .sync-invitation-button.sync-no {
  background: var(--gray-olive-dark);
  color: var(--warm-white);
}

.dark-mode .sync-invitation-button.sync-no:hover {
  background: var(--gray-olive-neutral);
}

/* Lyrics translation nav dark mode styles */
.dark-mode .lyrics-translation-nav .to-lyrics-nav-link, .dark-mode .lyrics-translation-nav .to-translation-nav-link {
  background: var(--gold-yellow);
  color: var(--deep-olive);
}

.dark-mode .lyrics-translation-nav .to-lyrics-nav-link:hover, .dark-mode .lyrics-translation-nav .to-translation-nav-link:hover {
  background: #b34520;
  color: var(--warm-white);
}

/* ========================================
HIDDEN
======================================== */
.hidden {
  display: none !important;
}

.view.hidden {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}