/*
  Tab 09 — Spatial Mobile Dock Tabs — standalone HTML/CSS/JS implementation.
  No build step, no framework, no external dependency: copy index.html,
  this file, and script.js into any project as-is. This is primary
  navigation, not a same-page panel-switcher, so it deliberately does not
  use the ARIA tabs pattern — a `<nav>` with `aria-current="page"` on the
  active item instead.
*/

:root {
  --card-accent: #39ff14;
  --card-fg: oklch(0.145 0 0);
  --card-muted: oklch(0.5 0 0);
  --card-border: oklch(0.9 0 0);
}

.bottom-nav {
  display: flex;
  align-items: center;
  justify-content: space-around;
  border-top: 1px solid var(--card-border);
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(4px);
  padding: 0.5rem 0.5rem calc(0.5rem + env(safe-area-inset-bottom, 0px));
  font-family:
    Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji",
    "Segoe UI Emoji";
}

.bottom-nav__item {
  display: flex;
  min-width: 2.75rem;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  font-family: inherit;
  padding: 0;
  cursor: pointer;
  outline: none;
}

.bottom-nav__item:focus-visible {
  outline: 2px solid var(--card-accent);
  outline-offset: 2px;
}

.bottom-nav__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 9999px;
  padding: 0.5rem 0.5rem;
  transition:
    padding 260ms ease-out,
    background-color 260ms ease-out;
}

.bottom-nav__pill--active {
  background-color: var(--card-fg);
  padding: 0.5rem 0.875rem 0.5rem 0.5rem;
}

.bottom-nav__icon {
  display: flex;
  height: 1.25rem;
  width: 1.25rem;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  color: var(--card-muted);
  transition: color 200ms ease-out;
}

.bottom-nav__icon svg {
  height: 1.125rem;
  width: 1.125rem;
}

.bottom-nav__icon--active {
  color: #ffffff;
}

.bottom-nav__label {
  overflow: hidden;
  max-width: 0;
  font-size: 0.75rem;
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
  opacity: 0;
  transition:
    max-width 260ms ease-out,
    opacity 260ms ease-out;
}

.bottom-nav__label--active {
  max-width: 6rem;
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .bottom-nav__pill,
  .bottom-nav__icon,
  .bottom-nav__label {
    transition: none;
  }
}

/*
  Page layout — the canvas this resource is presented on. Adjust or drop it
  when placing the resource inside your own layout.
*/

*,
*::before,
*::after {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-family:
    Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: linear-gradient(to bottom, #f0f0f1, #e4e4e7b3);
}
.tab09-layout {
  display: flex;
  min-height: 24rem;
  align-items: center;
  justify-content: center;
  padding: 2rem 2.5rem;
}
.tab09-layout__frame {
  display: flex;
  height: 20rem;
  width: 16rem;
  flex-direction: column;
  overflow: hidden;
  border-radius: 2rem;
  border: 4px solid oklch(0.205 0 0);
  background-color: oklch(0.985 0 0);
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.3);
}
.tab09-layout__title {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
  font-weight: 600;
  color: oklch(0.145 0 0);
}
