/* ============================================================
   PAGES.CSS – Gedeelde stijlen voor info, settings, install
   ============================================================ */

/* ── Pagina navigatiebalk ────────────────────────────────── */
.page-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: var(--gap-sm) var(--gap-lg);
  display: flex;
  align-items: center;
  gap: var(--gap-md);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.page-nav .btn-back {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 16px;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
  white-space: nowrap;
}
.page-nav .btn-back:hover {
  border-color: var(--role-blue);
  color: var(--role-blue);
  background: rgba(77, 126, 247, 0.08);
}

.page-nav-title {
  flex: 1;
  font-size: var(--font-size-md);
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Pagina inhoud wrapper ───────────────────────────────── */
.page-content {
  max-width: 820px;
  margin: 0 auto;
  padding: var(--gap-lg);
}

/* ── Sectie ──────────────────────────────────────────────── */
.page-section {
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  margin-bottom: var(--gap-lg);
  overflow: hidden;
}

.page-section-header {
  padding: var(--gap-md) var(--gap-lg);
  border-bottom: 1px solid var(--border);
  background: var(--surface-raised);
  display: flex;
  align-items: center;
  gap: var(--gap-sm);
}

.page-section-title {
  font-size: var(--font-size-md);
  font-weight: 700;
  color: var(--text-primary);
}

.page-section-body {
  padding: var(--gap-lg);
}

/* ── Toggle switch ───────────────────────────────────────── */
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--gap-md);
  padding: var(--gap-md) 0;
  border-bottom: 1px solid var(--border);
}
.toggle-row:last-child { border-bottom: none; }

.toggle-label {
  font-size: var(--font-size-md);
  font-weight: 600;
  color: var(--text-primary);
}
.toggle-sublabel {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  margin-top: 2px;
}

.toggle-switch {
  position: relative;
  width: 52px;
  height: 28px;
  flex-shrink: 0;
}
.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--border);
  border-radius: 28px;
  cursor: pointer;
  transition: background 0.2s;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  left: 4px;
  top: 4px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s;
}
.toggle-switch input:checked + .toggle-slider { background: var(--role-blue); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(24px); }

/* ── Cast keuze knoppen ──────────────────────────────────── */
.cast-options {
  display: flex;
  gap: var(--gap-sm);
  flex-wrap: wrap;
}

.cast-option {
  flex: 1;
  min-width: 100px;
  padding: var(--gap-md);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  cursor: pointer;
  text-align: center;
  transition: border-color 0.15s, background 0.15s;
  color: var(--text-muted);
  font-weight: 600;
  font-size: var(--font-size-md);
  font-family: inherit;
}
.cast-option:hover { border-color: var(--role-blue); color: var(--role-blue); }
.cast-option.active {
  border-color: var(--role-blue);
  background: rgba(77, 126, 247, 0.12);
  color: var(--role-blue);
}

/* ── Profiel rij ─────────────────────────────────────────── */
.profile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--gap-sm) 0;
  border-bottom: 1px solid var(--border);
  gap: var(--gap-md);
}
.profile-row:last-child { border-bottom: none; }

.profile-key {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.profile-value {
  font-size: var(--font-size-md);
  font-weight: 700;
  color: var(--text-primary);
  text-align: right;
}

/* ── Info hero ───────────────────────────────────────────── */
.info-hero {
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent-orange);
  padding: var(--gap-xl) var(--gap-lg);
  text-align: center;
  margin-bottom: var(--gap-lg);
}

.info-hero-emoji {
  font-size: 4rem;
  margin-bottom: var(--gap-md);
  display: block;
}

.info-hero-title {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--gap-sm);
  line-height: 1.2;
}

.info-hero-sub {
  font-size: var(--font-size-md);
  color: var(--text-muted);
}

/* ── Video embed ─────────────────────────────────────────── */
.video-wrapper {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #000;
  border: 1px solid var(--border);
  margin-bottom: var(--gap-lg);
}
.video-wrapper iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}
.video-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-muted);
  font-size: var(--font-size-md);
  gap: var(--gap-sm);
  min-height: 200px;
}

/* ── Beschrijving tekst ──────────────────────────────────── */
.info-description {
  font-size: var(--font-size-md);
  color: var(--text-primary);
  line-height: 1.7;
  white-space: pre-line;
}

/* ── Dev credit ──────────────────────────────────────────── */
.dev-credit {
  text-align: center;
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  padding: var(--gap-xl) 0 var(--gap-md);
}
.dev-credit a {
  color: var(--role-blue);
  text-decoration: none;
}
.dev-credit a:hover { text-decoration: underline; }

/* ── Install gids stijlen ────────────────────────────────── */
.install-page {
  min-height: 100vh;
  background: var(--bg-color);
  padding-bottom: 60px;
}

.install-hero {
  background: linear-gradient(135deg, var(--role-blue) 0%, var(--accent-purple) 100%);
  color: #fff;
  padding: var(--gap-xl) var(--gap-lg);
  text-align: center;
}

.install-hero h1 {
  font-size: var(--font-size-xl);
  font-weight: 700;
  margin-bottom: var(--gap-sm);
}
.install-hero p {
  font-size: var(--font-size-md);
  opacity: 0.85;
}

.install-tabs {
  display: flex;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}
.install-tab {
  flex: 1;
  padding: var(--gap-md);
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  font-family: inherit;
  font-size: var(--font-size-md);
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.install-tab.active {
  color: var(--role-blue);
  border-bottom-color: var(--role-blue);
}
.install-tab:hover { color: var(--text-primary); }

.install-panel { display: none; }
.install-panel.active { display: block; }

.install-steps {
  display: flex;
  flex-direction: column;
  gap: var(--gap-md);
  padding: var(--gap-lg);
  max-width: 640px;
  margin: 0 auto;
}

.install-step {
  display: flex;
  gap: var(--gap-md);
  align-items: flex-start;
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  padding: var(--gap-md);
}

.install-step-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--role-blue);
  color: #fff;
  font-weight: 700;
  font-size: var(--font-size-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.install-step-body h3 {
  font-size: var(--font-size-md);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.install-step-body p {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  line-height: 1.5;
}
.install-step-icon {
  font-size: 2rem;
  margin-bottom: var(--gap-sm);
  display: block;
}

.install-tip {
  background: rgba(77, 126, 247, 0.1);
  border: 1px solid rgba(77, 126, 247, 0.3);
  border-radius: var(--radius-md);
  padding: var(--gap-md);
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  margin: 0 var(--gap-lg) var(--gap-md);
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Install banner (op inlogscherm) ─────────────────────── */
.install-banner {
  background: rgba(77, 126, 247, 0.12);
  border: 1px solid rgba(77, 126, 247, 0.3);
  border-radius: var(--radius-md);
  padding: var(--gap-sm) var(--gap-md);
  margin-top: var(--gap-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--gap-sm);
  font-size: var(--font-size-sm);
  color: var(--role-blue);
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s;
}
.install-banner:hover { background: rgba(77, 126, 247, 0.2); }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 500px) {
  .page-content {
    padding: var(--gap-md);
  }
  .info-hero {
    padding: var(--gap-lg) var(--gap-md);
  }
  .install-steps {
    padding: var(--gap-md);
  }
}

@media (min-width: 1024px) {
  .page-content {
    padding: var(--gap-xl);
  }
}
