/* Werkbank — base: tokens, layout, chrome */
:root {
  --bg: #060605;
  --ink: #EDEAE3;
  --ink-dim: #9B968A;
  --ink-faint: #6B675D;
  --amber: #E89B4B;
  --amber-hot: #F5B36B;
  --amber-deep: #B36A24;
  --line: rgba(255, 255, 255, 0.08);
  --line-soft: rgba(255, 255, 255, 0.05);
  --glass: rgba(255, 255, 255, 0.04);
  --glass-2: rgba(255, 255, 255, 0.02);
  --danger: #E86A5C;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --r-xl: 2rem;
  --r-inner: calc(2rem - 0.5rem);
  --sat: env(safe-area-inset-top, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { color-scheme: dark; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Plus Jakarta Sans", -apple-system, "SF Pro Text", system-ui, sans-serif;
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

/* ---- Atmosphere ---- */
.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
}
.orb-a {
  width: 60vw; height: 60vw; max-width: 480px; max-height: 480px;
  top: -12vh; right: -20vw;
  background: radial-gradient(circle, rgba(232, 155, 75, 0.22), transparent 70%);
}
.orb-b {
  width: 70vw; height: 70vw; max-width: 560px; max-height: 560px;
  bottom: -25vh; left: -25vw;
  background: radial-gradient(circle, rgba(120, 90, 50, 0.14), transparent 70%);
}
.grain {
  position: fixed; inset: 0;
  z-index: 40;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---- Top bar ---- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(var(--sat) + 14px) 22px 12px;
  background: rgba(6, 6, 5, 0.6);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line-soft);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--amber); }
.brand-mark { width: 26px; height: 26px; }
.brand-name {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--ink);
}
.brand-tag {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-faint);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 12px;
}

/* ---- Main / panels ---- */
main {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin: 0 auto;
  padding: 28px 20px calc(140px + var(--sab));
}
.panel { display: none; }
.panel.active { display: block; animation: panelIn 0.65s var(--ease) both; }
@keyframes panelIn {
  from { opacity: 0; transform: translateY(18px); filter: blur(6px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

.eyebrow {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  color: var(--amber);
  border: 1px solid rgba(232, 155, 75, 0.25);
  background: rgba(232, 155, 75, 0.07);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 18px;
}
.panel-title {
  font-size: clamp(30px, 8.5vw, 42px);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 30px;
}
.panel-title strong { font-weight: 700; }
.sub-title {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-dim);
}

/* ---- Double-bezel shells ---- */
.shell {
  background: var(--glass-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-xl);
  padding: 8px;
  margin-bottom: 22px;
}
.core {
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--r-inner);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.06);
  padding: 22px 18px;
}

/* ---- Reveal ---- */
.reveal { opacity: 0; transform: translateY(24px); filter: blur(6px); }
.reveal.in {
  opacity: 1; transform: translateY(0); filter: blur(0);
  transition: all 0.8s var(--ease);
}

/* ---- Tab bar ---- */
.tabbar {
  position: fixed;
  bottom: calc(var(--sab) + 16px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  gap: 4px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(14, 13, 11, 0.72);
  -webkit-backdrop-filter: blur(28px);
  backdrop-filter: blur(28px);
  border: 1px solid var(--line);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55), inset 0 1px 1px rgba(255, 255, 255, 0.07);
}
.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  min-width: 68px;
  padding: 9px 12px 8px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-faint);
  font-family: inherit;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.5s var(--ease);
}
.tab svg { width: 21px; height: 21px; }
.tab.active {
  background: rgba(232, 155, 75, 0.12);
  color: var(--amber-hot);
}
.tab:active { transform: scale(0.94); }
