/* Layan.ai — onboarding: phone-style slides, the wisp travels with you */
.ob-body { min-height: 100vh; display: grid; place-items: center; background: radial-gradient(ellipse 70% 60% at 50% 0%, rgba(37, 78, 193, 0.35), transparent 70%), var(--abyss); padding: 0; }
.ob-shell {
  --h: 214; width: min(430px, 100vw); height: min(880px, 100dvh); display: grid; grid-template-rows: auto auto 1fr auto;
  background: var(--abyss); color: var(--paper); position: relative; overflow: hidden;
  transition: background var(--t-slow) var(--ease-out), color var(--t-slow) var(--ease-out);
}
@media (min-width: 480px) { .ob-shell { border-radius: 36px; border: 1px solid var(--line-strong); box-shadow: 0 60px 120px -40px rgba(0, 0, 0, 0.9), 0 0 160px -60px hsl(var(--h) 90% 60% / 0.7); margin: 24px 0; } }
.ob-shell[data-theme="light"] { background: #EEF4FF; color: #0B1B3F; }
.ob-shell[data-theme="light"] .ob-step, .ob-shell[data-theme="light"] .ob-skip, .ob-shell[data-theme="light"] .ob-slide > p, .ob-shell[data-theme="light"] .ob-note, .ob-shell[data-theme="light"] .ob-label { color: #4A5E86; }
.ob-shell[data-theme="light"] .brand { color: #0B1B3F; }
.ob-top { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 6px; font-size: var(--fs-sm); }
.ob-step { font-family: var(--font-mono); font-size: 0.7rem; color: var(--muted); }
.ob-skip { color: var(--muted); }
.ob-stage { position: relative; height: 230px; display: grid; place-items: center; }
.ob-wisp { width: auto; height: 100%; max-width: 100%; display: block; }
.ob-tags { position: absolute; inset: 0; pointer-events: none; }
.ob-tag {
  position: absolute; font-size: var(--fs-xs); font-weight: 500; padding: 4px 9px; border-radius: var(--r-pill);
  border: 1px solid hsl(var(--h) 80% 65% / 0.45); color: hsl(var(--h) 90% 80%); background: rgba(7, 20, 51, 0.55); backdrop-filter: blur(6px);
  opacity: 0; transform: translateY(6px); transition: opacity var(--t-slow) var(--ease-out), transform var(--t-slow) var(--ease-out);
}
.ob-shell[data-theme="light"] .ob-tag { background: rgba(255, 255, 255, 0.7); color: hsl(var(--h) 70% 35%); }
.ob-tag.is-in { opacity: 1; transform: none; }
.ob-viewport { overflow: hidden; min-height: 0; }
.ob-track { display: flex; height: 100%; transition: transform 520ms var(--ease-out); will-change: transform; }
.ob-slide { flex: 0 0 100%; overflow-y: auto; padding: 4px 24px 24px; display: flex; flex-direction: column; gap: 12px; scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; overscroll-behavior: contain; }
.ob-slide::-webkit-scrollbar { width: 6px; }
.ob-slide::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 3px; }
.ob-slide > *:last-child { margin-bottom: 8px; }
.ob-slide h1 { font-size: 2.1rem; font-weight: 500; letter-spacing: -0.03em; text-align: center; }
.ob-slide h2 { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; }
.ob-slide > p { font-size: var(--fs-sm); color: var(--paper-2); }
.ob-slide:first-child > p { text-align: center; }
.ob-facts { display: flex; justify-content: center; gap: 18px; margin-top: 8px; font-size: var(--fs-xs); color: var(--muted); }
.ob-facts b { display: block; font-size: 1.4rem; font-weight: 300; color: var(--signal); }
.ob-label { font-size: var(--fs-xs); color: var(--muted); margin-top: 4px; }
.ob-input { width: 100%; font: inherit; font-size: var(--fs-sm); color: inherit; background: rgba(2, 9, 31, 0.55); border: 1px solid var(--line-strong); border-radius: var(--r-md); padding: 10px 12px; outline: none; transition: border-color var(--t-fast); }
.ob-shell[data-theme="light"] .ob-input { background: #fff; border-color: rgba(37, 78, 193, 0.2); }
.ob-input:focus { border-color: var(--signal); }
.ob-note { font-size: var(--fs-xs); color: var(--muted); }
.ob-code { font-family: var(--font-mono); font-size: 0.72rem; line-height: 1.5; resize: vertical; }
.ob-chips-small button { padding: 5px 10px; }
.ob-testrow { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ob-testrow[hidden] { display: none; }
.ob-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ob-chips button { font-size: var(--fs-xs); font-weight: 500; padding: 7px 12px; border-radius: var(--r-pill); border: 1px solid var(--line-strong); color: var(--frost); background: rgba(170, 206, 253, 0.06); transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast); }
.ob-shell[data-theme="light"] .ob-chips button { color: #23407A; background: rgba(37, 78, 193, 0.06); border-color: rgba(37, 78, 193, 0.18); }
.ob-chips button.is-on { background: var(--cobalt); color: #fff; border-color: var(--cobalt); }
.ob-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ob-stat { padding: 10px 12px; border-radius: var(--r-md); border: 1px solid var(--line); background: rgba(7, 20, 51, 0.5); display: grid; gap: 4px; font-size: var(--fs-xs); color: var(--paper-2); }
.ob-stat b { font-size: 1.2rem; font-weight: 300; color: var(--paper); }
.ob-stat .ev { justify-self: start; }
.ob-workers { display: grid; gap: 8px; }
.ob-dept { padding: 10px 12px; border-radius: var(--r-md); border: 1px solid var(--line); background: rgba(7, 20, 51, 0.5); display: grid; gap: 6px; }
.ob-shell[data-theme="light"] .ob-dept, .ob-shell[data-theme="light"] .ob-stat, .ob-shell[data-theme="light"] .ob-result, .ob-shell[data-theme="light"] .ob-assets li { background: #fff; border-color: rgba(37, 78, 193, 0.14); color: #4A5E86; }
.ob-dept b { font-size: var(--fs-sm); font-weight: 600; display: flex; align-items: center; gap: 8px; }
.ob-dept .pa-orb { width: 12px; height: 12px; }
.ob-dept label { display: flex; align-items: center; gap: 8px; font-size: var(--fs-xs); }
.ob-dept input { accent-color: var(--cobalt); }
.hues { display: flex; flex-wrap: wrap; gap: 6px; }
.hue { width: 24px; height: 24px; border-radius: 50%; border: 2px solid transparent; background: hsl(var(--h) 90% 60%); box-shadow: 0 0 10px hsl(var(--h) 90% 60% / 0.6); transition: transform var(--t-fast), border-color var(--t-fast); }
.hue.is-on { border-color: currentColor; transform: scale(1.14); }
.pa-orb { --h: 214; width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0; position: relative; background: radial-gradient(circle at 40% 35%, #fff 0, hsl(var(--h) 95% 78%) 18%, hsl(var(--h) 90% 55%) 45%, hsl(var(--h) 80% 30% / 0.2) 70%, transparent 72%); box-shadow: 0 0 22px hsl(var(--h) 95% 65% / 0.7); }
.ob-drop { display: grid; place-items: center; text-align: center; padding: 20px; border-radius: var(--r-lg); border: 1px dashed var(--line-strong); font-size: var(--fs-sm); color: var(--paper-2); cursor: pointer; position: relative; }
.ob-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.ob-drop.is-over { border-color: var(--signal); background: rgba(96, 157, 252, 0.08); }
.ob-assets { display: grid; gap: 6px; }
.ob-assets li { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; font-size: var(--fs-xs); padding: 8px 10px; border-radius: var(--r-sm); background: rgba(170, 206, 253, 0.06); border: 1px solid var(--line); }
.ob-assets li b { display: block; font-size: var(--fs-sm); font-weight: 500; color: var(--paper); }
.ob-assets li button { color: var(--muted); }
.ob-assets .kp { grid-column: 1 / -1; color: var(--muted); font-size: var(--fs-xs); }
.ob-results { display: grid; gap: 8px; }
.ob-result { padding: 10px 12px; border-radius: var(--r-md); border: 1px solid var(--line); background: rgba(7, 20, 51, 0.5); display: grid; gap: 6px; font-size: var(--fs-xs); color: var(--paper-2); }
.ob-result b { font-size: var(--fs-sm); font-weight: 600; color: var(--paper); }
.ob-shell[data-theme="light"] .ob-result b, .ob-shell[data-theme="light"] .ob-stat b, .ob-shell[data-theme="light"] .ob-dept b, .ob-shell[data-theme="light"] .ob-assets li b { color: #0B1B3F; }
.ob-result .ev { vertical-align: 1px; }
.meter-row { display: grid; grid-template-columns: 92px 1fr auto; gap: 8px; align-items: center; font-size: var(--fs-xs); }
.meter-row .meter { height: 6px; border-radius: 3px; background: rgba(170, 206, 253, 0.12); overflow: hidden; }
.meter-row .meter span { display: block; height: 100%; width: var(--p); border-radius: 3px; background: var(--signal); }
.meter-row[data-level="3"] .meter span { background: var(--warn); }
.ob-plan { display: flex; justify-content: space-between; align-items: baseline; }
.ob-plan strong { font-size: 1.4rem; font-weight: 300; color: var(--paper); }
.ob-shell[data-theme="light"] .ob-plan strong { color: #0B1B3F; }
.ob-actions { display: grid; gap: 8px; margin-top: 4px; }
.ob-form { display: grid; gap: 8px; }
.ob-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 20px 22px; }
.ob-dots { display: flex; gap: 6px; }
.ob-dots span { width: 6px; height: 6px; border-radius: 50%; background: var(--line-strong); transition: background var(--t-fast), transform var(--t-fast); }
.ob-dots span.is-on { background: var(--signal); transform: scale(1.3); }
.ob-shell[data-theme="light"] .btn-primary { background: var(--cobalt); color: #fff; }
.ob-shell[data-theme="light"] .btn-quiet { color: #4A5E86; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; padding: 10px 16px; border-radius: var(--r-pill); background: var(--paper); color: var(--abyss); font-size: var(--fs-sm); font-weight: 500; box-shadow: 0 20px 50px -20px rgba(0,0,0,0.8); transition: opacity var(--t-ui) var(--ease-out), transform var(--t-ui) var(--ease-out); pointer-events: none; z-index: 100; max-width: calc(100% - 32px); text-align: center; }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { .ob-track { transition: none; } }

/* small phones and short viewports: give the content the room */
@media (max-width: 479px), (max-height: 760px) {
  .ob-shell { height: 100dvh; }
  .ob-top { padding: 12px 16px 0; }
  .ob-stage { height: 150px; }
  .ob-slide { padding: 0 16px 20px; gap: 10px; }
  .ob-slide h1 { font-size: 1.75rem; }
  .ob-slide h2 { font-size: 1.3rem; }
  .ob-tag:nth-child(n+3) { display: none; }
  .ob-stats { grid-template-columns: 1fr; }
  .ob-foot { padding: 10px 16px 16px; }
  .ob-foot .btn { height: 40px; padding: 0 14px; }
  .meter-row { grid-template-columns: 80px 1fr auto; }
  .ob-result, .ob-stat, .ob-dept { padding: 10px; }
}
@media (max-height: 640px) { .ob-stage { height: 110px; } .ob-tags { display: none; } }
