/* Page-Specific Styles */

/* ========================================
   HERO/LANDING PAGE
   ======================================== */

.hero-container {
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 40px 20px;
  box-sizing: border-box;
  overflow: auto;
}

.hero-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin: 0 0 var(--spacing-2xl) 0;
  letter-spacing: -0.03em;
  animation: fadeInUp 700ms ease;
}

.logo-mark {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--spacing-xl);
  color: var(--btn);
  animation: fadeInScale 600ms ease;
}

/* ========================================
   CONTENT PAGES (lobby, download, etc.)
   ======================================== */

.page-container {
  text-align: center;
  max-width: 400px;
  padding: var(--spacing-lg);
  animation: fadeInUp 600ms ease;
}

.page-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto var(--spacing-lg);
  animation: fadeInScale 500ms ease;
}

.page-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin: 0 0 var(--spacing-lg) 0;
  letter-spacing: -0.02em;
  color: var(--text);
}

.page-message {
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0 0 40px 0;
  font-size: 0.95rem;
}

/* ========================================
   DOWNLOAD PAGE SPECIFIC
   ======================================== */

.download-icon {
  color: var(--btn-text);
}

.login-prompt {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.login-prompt a {
  color: var(--btn);
  text-decoration: none;
  font-weight: 500;
  transition: opacity var(--transition-fast);
}

.login-prompt a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

/* ========================================
   LOBBY PAGE SPECIFIC
   ======================================== */

.status-icon {
  color: var(--orange);
}

.contact {
  font-size: 0.85rem;
  color: var(--text-tertiary);
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--border);
  animation: fadeIn 800ms ease;
}

.contact a {
  color: var(--btn);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}

.contact a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

/* ========================================
   AUTH CALLBACK PAGE SPECIFIC
   ======================================== */

.success-icon {
  color: var(--green);
}

.helper-text {
  margin-top: var(--spacing-2xl);
  font-size: var(--font-size-sm);
  color: var(--text-tertiary);
  opacity: 0;
  animation: fadeIn 400ms ease 2s forwards;
}

.arrow-icon {
  width: 18px;
  height: 18px;
  transition: transform var(--transition-fast);
}

.btn:hover .arrow-icon {
  transform: translate(2px, -2px);
}

/* ========================================
   WELCOME PAGE SPECIFIC
   ======================================== */

/* Override base.css to ensure scrolling works on welcome page */
html.welcome-page,
html.welcome-page body {
  height: auto !important;
  min-height: 100vh;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}

body.welcome-page.page-centered {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  height: auto !important;
  padding-top: 60px;
}

/* Setup instructions container - wider than default but still compact */
.setup-container {
  max-width: 650px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

/* Warning banners */
.warning-banner {
  display: none;
  padding: 1rem;
  margin: 1rem auto;
  border-radius: 8px;
  background: #FEF3C7;
  border: 1px solid var(--orange);
  color: #92400e;
  align-items: center;
  gap: 0.75rem;
  max-width: 400px;
}

.warning-banner.show {
  display: flex;
}

.warning-banner a {
  color: var(--orange);
  text-decoration: underline;
}

.warning-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--orange);
}

/* Setup sections */
.setup-section {
  margin-bottom: 3rem;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
}

.section-icon {
  width: 24px;
  height: 24px;
  color: var(--btn);
}

/* Setup steps */
.setup-steps {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.setup-step {
  display: flex;
  gap: 1rem;
  padding: 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: all 0.2s ease;
}

.setup-step:hover {
  box-shadow: var(--shadow-sm);
}

.step-number {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--btn);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
}

.step-content {
  flex: 1;
}

.step-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 0.25rem 0;
}

.step-description {
  color: var(--text-secondary);
  line-height: 1.5;
  font-size: 0.875rem;
  margin: 0;
}

/* Code snippets */
.code-snippet {
  background: var(--bg-secondary);
  color: var(--text);
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.85em;
}

/* Download buttons in setup steps */
.setup-step .download-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 10px 20px;
  background: var(--btn);
  color: white !important;
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-md);
}

.setup-step .download-button:hover {
  background: var(--btn-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}

.download-icon {
  width: 18px;
  height: 18px;
}

/* Steps with screenshots */
.step-with-image .step-content {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

.step-text {
  flex: 1;
  min-width: 240px;
}

.step-screenshot {
  flex-shrink: 0;
  width: 240px;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.step-screenshot img {
  width: 100%;
  height: auto;
  display: block;
}

/* Completion section */
.completion-section {
  text-align: center;
  padding: 2rem;
  margin-top: 3rem;
}

.completion-icon {
  width: 32px;
  height: 32px;
  margin: 0 auto 0.75rem;
  color: var(--green);
}

.completion-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 0.75rem 0;
}

.shortcut-hint {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin: 0;
}

.keyboard-shortcut {
  background: var(--bg-secondary);
  padding: 4px 8px;
  border-radius: 4px;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 0.95rem;
  color: var(--text);
  display: inline-block;
  font-weight: 500;
  margin: 0 0.25rem;
  border: 1px solid var(--border);
}

.success-message {
  background-color: #d1fae5;
  border: 1px solid #10b981;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 24px;
  color: #065f46;
}

.download-actions {
  display: flex;
  gap: 16px;
  margin: 40px 0;
  justify-content: center;
  flex-wrap: wrap;
}

.download-card {
  display: block;
  padding: 20px;
  border-radius: 14px;
  text-decoration: none;
  transition: all var(--transition-fast);
  cursor: pointer;
  min-width: 200px;
  flex: 1;
  max-width: 280px;
}

.download-card--primary {
  background: var(--btn);
  color: white;
  box-shadow: var(--shadow-lg);
}

.download-card--primary:hover {
  background: var(--btn-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
  text-decoration: none;
  color: white;
}

.download-card--secondary {
  background: var(--bg);
  color: var(--text);
  border: 2px solid var(--btn);
  box-shadow: var(--shadow-md);
}

.download-card--secondary:hover {
  background: var(--btn);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  text-decoration: none;
}

.download-card--disabled,
.download-card--coming-soon {
  background: var(--bg-secondary);
  color: var(--text-tertiary);
  border: 1px solid var(--border);
  cursor: not-allowed;
  opacity: 0.7;
}

.download-card-content {
  text-align: center;
}

.download-card-icon {
  margin-bottom: 12px;
}

.download-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.download-card-subtitle {
  font-size: 0.9rem;
  opacity: 0.8;
}

.download-icon-inline {
  margin-right: 8px;
}

/* ========================================
   COLLAPSIBLE SETUP INSTRUCTIONS
   ======================================== */

.setup-toggle {
  text-align: center;
  margin-top: 2rem;
}

.setup-toggle-button {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  cursor: pointer;
  padding: 8px 16px;
  border-radius: 6px;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.setup-toggle-button:hover {
  background: var(--bg-secondary);
  color: var(--text);
}

.setup-toggle-icon {
  width: 16px;
  height: 16px;
  transition: transform var(--transition-fast);
}

.setup-toggle-button[aria-expanded="true"] .setup-toggle-icon {
  transform: rotate(180deg);
}

.setup-instructions {
  display: none;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  animation: slideDown 0.3s ease;
}

.setup-instructions.show {
  display: block;
}

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

/* Compact styles for collapsible version */
.setup-instructions .setup-section {
  margin-bottom: 2.5rem;
  text-align: left;
}

.setup-instructions .section-header {
  font-size: 1.125rem;
}

.setup-instructions .section-icon {
  width: 20px;
  height: 20px;
}

.setup-instructions .setup-steps {
  gap: 0.75rem;
}

.setup-instructions .setup-step {
  padding: 0.75rem;
  background: var(--bg-secondary);
  border-radius: 6px;
  font-size: 0.875rem;
  border: none;
}

.setup-instructions .step-number {
  width: 24px;
  height: 24px;
  font-size: 0.75rem;
}

.setup-instructions .step-title {
  font-size: 0.875rem;
}

.setup-instructions .step-description {
  font-size: 0.8125rem;
}

.setup-instructions .code-snippet {
  background: var(--bg);
  border: 1px solid var(--border);
}

.inline-download {
  color: var(--btn);
  text-decoration: none;
  font-weight: 500;
}

.inline-download:hover {
  text-decoration: underline;
}

/* ========================================
   WELCOME PAGE RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
  .setup-container {
    max-width: 100%;
  }

  .step-with-image .step-content {
    flex-direction: column;
  }

  .step-text {
    min-width: auto;
  }

  .step-screenshot {
    width: 100%;
    max-width: 320px;
    margin-top: 0.75rem;
  }

  .shortcut-hint {
    font-size: 1rem;
  }

  .keyboard-shortcut {
    font-size: 1rem;
    display: block;
    margin: 0.75rem auto;
    width: fit-content;
  }
}

