/* Self Inspection — Start Journey Styles */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #3b82f6;
  --success: #16a34a;
  --danger: #dc2626;
  --bg: #0f172a;
  --bg-card: #1e293b;
  --bg-input: #0f172a;
  --border: #334155;
  --text: #f8fafc;
  --muted: #94a3b8;
  --app-height: 100vh;
}
@supports (height: 100dvh) {
  :root { --app-height: 100dvh; }
}

html, body {
  height: var(--app-height);
  overflow: hidden;
  overscroll-behavior: none;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}

#app {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  overflow: hidden;
}

.screen {
  display: none;
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.screen.active { display: block; }

.container {
  max-width: 480px;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
}

/* Logo */
.logo {
  width: 64px; height: 64px; border-radius: 16px;
  background: var(--primary);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
  color: white;
}

h1 {
  font-size: 1.75rem;
  text-align: center;
  margin-bottom: 0.25rem;
}

.subtitle {
  text-align: center;
  color: var(--muted);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

/* Instructions */
.instructions {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.instructions h2 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--primary-light);
}

.step-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.step-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.step-num {
  flex-shrink: 0;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  margin-top: 2px;
}

.step-item strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 2px;
}

.step-item p {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.4;
}

.prereqs {
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}

.prereqs h3 {
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  color: var(--muted);
}

.prereqs ul {
  list-style: none;
  padding: 0;
}

.prereqs li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.4;
}

.prereqs li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--success);
  font-weight: 700;
}

/* Buttons */
.btn-primary {
  display: block;
  width: 100%;
  background: var(--primary);
  color: white;
  border: none;
  padding: 16px 32px;
  border-radius: 14px;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary:hover { background: var(--primary-dark); }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-full { width: 100%; }

.btn-back {
  background: none;
  border: 1px solid var(--border);
  color: var(--muted);
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  margin-bottom: 1.25rem;
  -webkit-tap-highlight-color: transparent;
}
.btn-back:hover { border-color: var(--text); color: var(--text); }

/* Form */
form { display: flex; flex-direction: column; gap: 1rem; }

.form-group { display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }

.form-row { display: flex; gap: 0.75rem; }

label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
}

.req { color: var(--danger); }

input, select {
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s;
  -webkit-appearance: none;
}

input:focus, select:focus {
  outline: none;
  border-color: var(--primary);
}

input::placeholder { color: #475569; }

select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394a3b8' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
}

select option { background: var(--bg-card); color: var(--text); }

.form-error {
  background: rgba(220, 38, 38, 0.15);
  border: 1px solid var(--danger);
  color: #fca5a5;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.85rem;
  line-height: 1.4;
}

.hidden { display: none !important; }

/* Loader spinner */
.loader {
  width: 20px; height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  vertical-align: middle;
}

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

/* Responsive tweaks */
@media (max-width: 380px) {
  .container { padding: 1.5rem 1rem 2rem; }
  h1 { font-size: 1.5rem; }
  .form-row { flex-direction: column; gap: 1rem; }
}
