/* Drop Tabs — a liquid bar: the chosen tab is a drop that sinks, travels as a wave, rises and splashes.
   Every colour comes from the palette variables below (four palettes, chosen with data-palette on <body>). */
[data-palette="pearl"] {
  --bg: #0C0A1F; --glow-a: rgba(124, 92, 255, .38); --glow-b: rgba(255, 110, 196, .26); --top: #221A4F;
  --liq-a: #FFFFFF; --liq-b: #EEE8FF; --on-liq: #2A1E6B; --lift: #7C5CFF; --cut: #FFFFFF; --rim: rgba(255, 255, 255, .9);
  --text: #F6F3FF; --dim: rgba(246, 243, 255, .62); --accent: linear-gradient(90deg, #A68CFF, #FF8FD1); --accent-solid: #B7A2FF;
  --chip-text: #1B1240;
}
[data-palette="cobalt"] {
  --bg: #1C33D9; --glow-a: rgba(120, 150, 255, .45); --glow-b: rgba(79, 109, 255, .40); --top: #2A47F2;
  --liq-a: #FFFFFF; --liq-b: #EEF1FF; --on-liq: #1C33D9; --cut: #FFFFFF; --rim: rgba(255, 255, 255, .95);
  --text: #FFFFFF; --dim: rgba(255, 255, 255, .72); --accent: linear-gradient(90deg, #FFE45C, #FFD23F); --accent-solid: #FFE45C;
  --chip-text: #0E1A7A;
}
:root, [data-palette="mint"] {
  --bg: #04161A; --glow-a: rgba(46, 242, 200, .30); --glow-b: rgba(40, 184, 255, .26); --top: #0B2A31;
  --liq-a: #2EF2C8; --liq-b: #28B8FF; --on-liq: #04262B; --cut: #7EE8E0;
  --text: #EFFFFB; --dim: rgba(239, 255, 251, .6); --accent: linear-gradient(90deg, #2EF2C8, #28B8FF); --accent-solid: #2EF2C8;
  --chip-text: #04262B;
}
[data-palette="gold"] {
  --bg: #0D0B08; --glow-a: rgba(246, 211, 101, .26); --glow-b: rgba(200, 150, 62, .22); --top: #231C10;
  --liq-a: #F9E08B; --liq-b: #C8963E; --on-liq: #2A1E08; --cut: #F2D98A;
  --text: #FFF8E8; --dim: rgba(255, 248, 232, .58); --accent: linear-gradient(90deg, #F9E08B, #C8963E); --accent-solid: #E9C46A;
  --chip-text: #2A1E08;
}
[data-palette="coral"] {
  --bg: #F4EDE3; --glow-a: rgba(255, 94, 91, .22); --glow-b: rgba(255, 170, 110, .22); --top: #FBF7F1;
  --liq-a: #FF5E5B; --liq-b: #FF9A5C; --on-liq: #FFFFFF; --cut: #FF7A5E;
  --text: #2B1714; --dim: rgba(43, 23, 20, .55); --accent: linear-gradient(90deg, #FF5E5B, #FF9A5C); --accent-solid: #FF5E5B;
  --chip-text: #FFFFFF;
}
[data-palette="lime"] {
  --bg: #121314; --glow-a: rgba(198, 255, 61, .20); --glow-b: rgba(124, 255, 107, .16); --top: #1E2021;
  --liq-a: #D4FF4A; --liq-b: #7CFF6B; --on-liq: #16200A; --cut: #B8F45A;
  --text: #F4FFE6; --dim: rgba(244, 255, 230, .56); --accent: linear-gradient(90deg, #D4FF4A, #7CFF6B); --accent-solid: #C6FF3D;
  --chip-text: #16200A;
}
:root { --display: 'Bricolage Grotesque', system-ui, sans-serif; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--display); color: var(--text); background: var(--bg);
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none; user-select: none; overflow: hidden;
}

/* ---- the stage ---- */
.stage {
  position: relative; height: 100dvh; display: grid; place-items: center;
  background:
    radial-gradient(36% 20% at 32% 51%, var(--glow-a), transparent 70%),
    radial-gradient(36% 20% at 70% 54%, var(--glow-b), transparent 70%),
    radial-gradient(90% 55% at 50% 0%, var(--top) 0%, transparent 70%),
    var(--bg);
}
.stage::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .06;
  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 baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}
.frame { position: relative; width: 432px; height: 768px; flex: none; display: grid; place-items: center; transform: scale(var(--k, 1)); }

/* ---- the words ---- */
.title { position: absolute; top: 86px; left: 0; right: 0; text-align: center; }
.series {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin: 0 0 16px; font-size: 11px; font-weight: 700; letter-spacing: .3em; text-transform: uppercase; color: var(--dim);
}
.series b { display: inline-grid; place-items: center; height: 22px; padding: 0 9px; border-radius: 999px; font-size: 11px; letter-spacing: .06em; color: var(--chip-text); background: var(--accent); }
.title h1 { margin: 0; font-size: 76px; font-weight: 800; line-height: .86; letter-spacing: -.055em; }
.title h1 em { display: inline-block; font-style: normal; padding-right: .04em; background: var(--accent); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hint { margin: 18px 0 0; font-size: 15px; font-weight: 500; color: var(--dim); }

/* ---- the bar ---- */
.tabbar { position: relative; width: 344px; height: 150px; margin-top: -40px; touch-action: none; }
.liquid { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 18px 26px rgba(0, 0, 0, .35)); }
.liq-a { stop-color: var(--liq-a); } .liq-b { stop-color: var(--liq-b); }
.drop-shade { pointer-events: none; }
.rim { fill: none; stroke: var(--rim, rgba(255, 255, 255, .55)); stroke-width: 1.4; pointer-events: none; }
.tabs { position: absolute; left: 0; right: 0; bottom: 0; height: 72px; padding: 0 22px; display: grid; grid-template-columns: repeat(5, 1fr); }
.tab { display: grid; place-items: center; padding: 0; border: 0; background: none; cursor: pointer; color: var(--on-liq); position: relative; z-index: 2; }
.tab .icon { will-change: transform; }
.tab .label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tab:focus-visible { outline: 2.5px solid var(--on-liq); outline-offset: -8px; border-radius: 999px; }

.icon { width: 25px; height: 25px; overflow: visible; }
.icon .line { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon .line .dot, .icon .line .sun { fill: currentColor; stroke: none; }
.icon .fill { fill: currentColor; stroke: none; opacity: 0; }
.icon .fill .cut { fill: var(--cut); }

.caption { position: absolute; top: 0; left: 0; margin: 0; transform: translate(-50%, -50%); font-size: 12.5px; font-weight: 800; color: var(--on-liq); white-space: nowrap; pointer-events: none; }
.caption i { display: inline-block; font-style: normal; animation: letter .45s cubic-bezier(.3, 1.5, .5, 1) both; animation-delay: calc(var(--k2) * 30ms); }
@keyframes letter { from { opacity: 0; transform: translateY(8px) scale(.6); } to { opacity: 1; transform: none; } }

/* ---- the frame's footer ---- */
.tutorial {
  position: absolute; left: 50%; bottom: 150px; transform: translateX(-50%); margin: 0;
  display: inline-flex; align-items: center; gap: 9px; white-space: nowrap;
  padding: 10px 18px 10px 11px; border-radius: 999px; font-size: 14px; font-weight: 700; color: var(--text);
  background: color-mix(in srgb, var(--text) 7%, transparent); border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
}
.tutorial svg { width: 24px; height: 24px; padding: 5px; border-radius: 50%; fill: var(--chip-text); background: var(--accent); }
.tutorial span { font-weight: 500; color: var(--dim); }
.credits { position: absolute; left: 28px; right: 24px; bottom: 34px; display: flex; align-items: center; justify-content: space-between; }
.stack { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .24em; text-transform: uppercase; color: var(--dim); }
.stack i { font-style: normal; color: var(--accent-solid); margin: 0 3px; }
.logo { margin: 0; display: flex; align-items: center; gap: 7px; }
.logo .avatar { width: 28px; height: 28px; border-radius: 50%; box-shadow: 0 0 0 1.2px color-mix(in srgb, var(--text) 80%, transparent); }
.logo .lockup { height: 24px; width: auto; }
[data-palette="coral"] .logo .lockup { filter: invert(1); }        /* the white lockup, made dark on the light stage */

/* ---- the touch circle ---- */
.touch {
  position: fixed; top: 0; left: 0; z-index: 10; width: 30px; height: 30px; margin: -15px 0 0 -15px;
  border-radius: 50%; pointer-events: none; opacity: 0;
  border: 1.5px solid var(--text); background: color-mix(in srgb, var(--text) 14%, transparent);
  transition: opacity .12s;
}
.touch.is-on { opacity: 1; }

@media (prefers-reduced-motion: reduce) { .touch { transition: none; } .caption i { animation: none; } }
