/* ============================================================
   Octopus Player — Quick Setup Page Styles (Vibrant Glassmorphism)
   ============================================================ */

.qs-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--topbar-h) + 60px) 16px 80px;
  background: transparent;
  position: relative;
  min-height: 100vh;
  z-index: 5;
}

.qs-page-head {
  position: relative;
  z-index: 1;
  max-width: 460px;
  width: 100%;
  text-align: center;
  margin-bottom: 32px;
}

.qs-page-head h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #0f172a 20%, #4f46e5 50%, #db2777 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.qs-page-head p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-silver);
}

.qs-page-head strong {
  color: var(--accent);
  font-weight: 700;
}

/* Premium Glassmorphic Card */
.qs-card {
  position: relative;
  z-index: 1;
  max-width: 460px;
  width: 100%;
  margin: 0 auto;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 36px;
  box-shadow: 0 20px 50px -15px rgba(99, 102, 241, 0.12),
              inset 0 1px 0 rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  color: var(--text);
  transition: all 0.3s ease;
}

.qs-method-label {
  margin: 0 0 16px;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Radio-style tabs container */
.qs-tabs--radio {
  display: flex;
  gap: 8px;
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(99, 102, 241, 0.1);
  padding: 4px;
  border-radius: 14px;
  margin-bottom: 24px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.qs-tabs--radio .qs-tab {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 0;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-silver);
  background: transparent;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.qs-tab__dot {
  display: none;
}

.qs-tabs--radio .qs-tab.active {
  color: #6366f1;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.08),
              inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.qs-tabs--radio .qs-tab:hover:not(.active) {
  color: #0f172a;
  background: rgba(255, 255, 255, 0.3);
}

/* Form fields */
.qs-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
  text-align: left;
}

.qs-field label {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
}

.qs-field .opt {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: 4px;
}

.qs-field input {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(99, 102, 241, 0.15);
  color: #0f172a;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 14.5px;
  font-family: inherit;
  outline: none;
  width: 100%;
  transition: all 0.25s ease;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.01);
}

.qs-field input:focus {
  border-color: #6366f1;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.01),
              0 0 0 4px rgba(99, 102, 241, 0.12);
}

.qs-field input::placeholder {
  color: #94a3b8;
}

.qs-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 420px) {
  .qs-row { grid-template-columns: 1fr; gap: 16px; }
}

/* Password toggle */
.qs-pwd {
  position: relative;
}

.qs-pwd input {
  padding-right: 48px;
}

.qs-pwd-btn {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: var(--text-silver);
  cursor: pointer;
  transition: all 0.2s;
}

.qs-pwd-btn:hover {
  color: #6366f1;
  background: rgba(99, 102, 241, 0.05);
}

.qs-pwd-btn svg { width: 18px; height: 18px; }

/* Error message */
.qs-error {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #b91c1c;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 13.5px;
  font-weight: 600;
  margin: 8px 0 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Submit button */
.qs-submit {
  width: 100%;
  min-height: 54px;
  margin-top: 12px;
  background: var(--accent-gradient);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 10px 25px -5px rgba(236, 72, 153, 0.3);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.qs-submit:hover:not(:disabled) {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 15px 30px -5px rgba(236, 72, 153, 0.45);
}

.qs-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.qs-spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.qs-legal {
  margin: 20px 0 0;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.6;
}

.qs-legal strong {
  color: #0f172a;
  font-weight: 700;
}

/* APK download ribbon under form */
.qs-apk {
  position: relative;
  z-index: 1;
  max-width: 460px;
  width: 100%;
  margin: 32px auto 0;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.qs-apk p {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #1e293b;
}

.qs-apk .btn--outline {
  border: 1px solid rgba(99, 102, 241, 0.15);
  background: rgba(255, 255, 255, 0.6);
  color: #4f46e5;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.04);
}

.qs-apk .btn--outline:hover {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.08);
}

/* Activation Code Panel */
.qs-code-panel {
  text-align: center;
}

.qs-code-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #db2777;
  margin: 0 0 20px;
}

.qs-code-number {
  font-size: clamp(3.5rem, 16vw, 4.8rem);
  font-weight: 900;
  letter-spacing: 0.12em;
  color: #4f46e5;
  margin: 0 0 24px;
  font-variant-numeric: tabular-nums;
  user-select: all;
  background: rgba(255, 255, 255, 0.85);
  border: 2px dashed rgba(99, 102, 241, 0.3);
  border-radius: 20px;
  padding: 12px 24px;
  display: inline-block;
  box-shadow: 0 10px 25px -5px rgba(99, 102, 241, 0.06),
              inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

/* Liste PIN kilidi Toggle Switch */
.qs-lock-field {
  margin-bottom: 24px;
}

.qs-toggle-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(99, 102, 241, 0.15);
  border-radius: 14px;
  transition: all 0.3s ease;
}

.qs-toggle-label:hover {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(99, 102, 241, 0.3);
}

.qs-toggle-text {
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
}

.qs-toggle-wrapper {
  position: relative;
  width: 44px;
  height: 24px;
}

.qs-toggle-input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.qs-toggle-bg {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: #cbd5e1;
  border-radius: 24px;
  transition: .4s;
}

.qs-toggle-bg:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  border-radius: 50%;
  transition: .4s;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.qs-toggle-input:checked + .qs-toggle-bg {
  background-color: #6366f1;
}

.qs-toggle-input:focus + .qs-toggle-bg {
  box-shadow: 0 0 1px #6366f1;
}

.qs-toggle-input:checked + .qs-toggle-bg:before {
  transform: translateX(20px);
}

.qs-code-pin-row {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  margin: 0 0 20px;
  padding: 10px 22px;
  border-radius: 16px;
  background: rgba(99, 102, 241, 0.07);
  border: 1px solid rgba(99, 102, 241, 0.22);
}

.qs-code-pin-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #db2777;
}

.qs-code-pin-value {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 0.3em;
  text-indent: 0.3em;
  color: #4f46e5;
  font-variant-numeric: tabular-nums;
  user-select: all;
}

.qs-code-hint {
  font-size: 15px;
  color: var(--text-silver);
  margin: 0 0 24px;
  line-height: 1.6;
}

.qs-code-hint strong {
  color: #0f172a;
}

/* Countdown Timer */
.qs-timer {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #065f46;
  padding: 8px 20px;
  border-radius: 999px;
  border: 1px solid rgba(16, 185, 129, 0.2);
  background: rgba(16, 185, 129, 0.08);
  margin-bottom: 32px;
}

.qs-timer-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  flex-shrink: 0;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.2);
  animation: timerp 1.5s ease-in-out infinite;
}

@keyframes timerp {
  50% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
}

.qs-code-panel.expired .qs-timer-dot {
  background: #64748b;
  animation: none;
  box-shadow: none;
}

.qs-code-panel.expired .qs-code-number {
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.4);
  border-color: rgba(99, 102, 241, 0.1);
  box-shadow: none;
}

.qs-code-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 400px) {
  .qs-code-actions { grid-template-columns: 1fr; }
}

.qs-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 12px;
  font-size: 14.5px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.3s ease;
}

.qs-btn--copy {
  background: rgba(255, 255, 255, 0.6);
  border-color: rgba(99, 102, 241, 0.15);
  color: #4f46e5;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.04);
}

.qs-btn--copy:hover {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(99, 102, 241, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.08);
}

.qs-btn--new {
  background: var(--accent-gradient);
  color: #ffffff;
  box-shadow: 0 10px 25px -5px rgba(236, 72, 153, 0.3);
}

.qs-btn--new:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 15px 30px -5px rgba(236, 72, 153, 0.45);
}

.qs-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 12px;
  color: var(--text-muted);
}

@media (max-width: 480px) {
  .qs-card { padding: 30px 20px; }
  .qs-code-number { font-size: 3.2rem; padding: 10px 16px; }
}
