/* ==========================================================================
   stockmarketdigest.click - shared display layer
   Prefix contract: every class and CSS variable uses "frame8a2e4-"
   Canvas: 320-430px phone-first; wide screens keep a centered 430px canvas
   Palette anchors: #3A3A3A bg / #E0FFFF ink / #999999 mute / #26A69A accent
                   #E0F2F1 soft teal
   Shape language: pill CTAs, square (2-4px) cards, outlined tile game grid
   ========================================================================== */

:root {
  --frame8a2e4-bg: #3a3a3a;
  --frame8a2e4-bg-deep: #2f2f2f;
  --frame8a2e4-bg-outer: #272727;
  --frame8a2e4-panel: #3e3e3e;
  --frame8a2e4-panel-hi: #444444;
  --frame8a2e4-line: #4c4c4c;
  --frame8a2e4-line-soft: rgba(153, 153, 153, 0.22);
  --frame8a2e4-ink: #e0ffff;
  --frame8a2e4-ink-dim: #c6d4d3;
  --frame8a2e4-mute: #999999;
  --frame8a2e4-teal: #26a69a;
  --frame8a2e4-teal-deep: #1d8278;
  --frame8a2e4-teal-glow: rgba(38, 166, 154, 0.38);
  --frame8a2e4-teal-soft: #e0f2f1;
  --frame8a2e4-font-head: "Trebuchet MS", "Segoe UI", Tahoma, Geneva, sans-serif;
  --frame8a2e4-font-body: "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  --frame8a2e4-radius-pill: 999px;
  --frame8a2e4-radius-tile: 4px;
  --frame8a2e4-topbar-h: 60px;
  --frame8a2e4-tabbar-h: 64px;
  --frame8a2e4-canvas: 430px;
  --frame8a2e4-gutter: 12px;
}

/* ---------- base ---------- */

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--frame8a2e4-bg-outer);
  color: var(--frame8a2e4-ink);
  font-family: var(--frame8a2e4-font-body);
  font-size: 14px;
  line-height: 1.62;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--frame8a2e4-font-head);
  color: var(--frame8a2e4-teal-soft);
  line-height: 1.3;
  margin: 0 0 10px;
  letter-spacing: 0.012em;
}

h1 { font-size: 21px; font-weight: 700; }
h2 { font-size: 17px; font-weight: 700; }
h3 { font-size: 14px; font-weight: 700; color: var(--frame8a2e4-ink); }
h4 { font-size: 12.5px; font-weight: 700; color: var(--frame8a2e4-ink-dim); }

p { margin: 0 0 10px; }

ul, ol { margin: 0; padding: 0; list-style: none; }

a {
  color: var(--frame8a2e4-teal);
  text-decoration: none;
}

a:hover { text-decoration: underline; }

img { max-width: 100%; }

button {
  font-family: inherit;
  color: inherit;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--frame8a2e4-teal);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- centered phone canvas ---------- */

.frame8a2e4-shell {
  position: relative;
  max-width: var(--frame8a2e4-canvas);
  margin: 0 auto;
  min-height: 100vh;
  background: var(--frame8a2e4-bg);
  box-shadow: 0 0 36px rgba(0, 0, 0, 0.55);
  /* clear the fixed top bar and the raised bottom tab bar */
  padding: calc(var(--frame8a2e4-topbar-h) + 10px) 0
           calc(var(--frame8a2e4-tabbar-h) + 26px + env(safe-area-inset-bottom, 0px));
}

.frame8a2e4-block {
  padding: 0 var(--frame8a2e4-gutter);
  margin: 0 0 22px;
}

/* ---------- fixed functional header (edge aligned) ---------- */

.frame8a2e4-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 80;
  max-width: var(--frame8a2e4-canvas);
  margin: 0 auto;
  height: var(--frame8a2e4-topbar-h);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  background: rgba(47, 47, 47, 0.97);
  border-bottom: 1px solid var(--frame8a2e4-line);
  backdrop-filter: blur(8px);
}

.frame8a2e4-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: auto;
  min-width: 0;
  text-decoration: none;
}

.frame8a2e4-brand:hover { text-decoration: none; }

.frame8a2e4-brand img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: block;
  border: 1px solid var(--frame8a2e4-teal-glow);
  flex: 0 0 auto;
}

.frame8a2e4-brand span {
  font-family: var(--frame8a2e4-font-head);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--frame8a2e4-teal-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.frame8a2e4-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}

/* pill CTAs - light rounded text buttons */
.frame8a2e4-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: var(--frame8a2e4-radius-pill);
  border: 1px solid var(--frame8a2e4-teal-glow);
  background: transparent;
  color: var(--frame8a2e4-teal-soft);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: background-color 0.18s ease, color 0.18s ease,
              border-color 0.18s ease, transform 0.18s ease;
}

.frame8a2e4-cta--solid {
  background: linear-gradient(160deg, var(--frame8a2e4-teal), var(--frame8a2e4-teal-deep));
  border-color: transparent;
  color: #f2fbfa;
}

.frame8a2e4-cta--solid:hover { background: linear-gradient(160deg, #2db3a6, #219085); }

.frame8a2e4-cta:hover {
  text-decoration: none;
  border-color: var(--frame8a2e4-teal);
}

.frame8a2e4-cta:active { transform: scale(0.97); }

.frame8a2e4-cta--compact {
  min-height: 40px;
  padding: 0 11px;
  font-size: 12px;
}

/* menu trigger - icon morphs from bars to a cross */
.frame8a2e4-menubtn {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: var(--frame8a2e4-radius-pill);
  flex-direction: column;
  gap: 4px;
  transition: border-color 0.18s ease;
}

.frame8a2e4-menubtn i {
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--frame8a2e4-teal-soft);
  transition: transform 0.24s ease, opacity 0.18s ease;
}

.frame8a2e4-menubtn[aria-expanded="true"] { border-color: var(--frame8a2e4-teal); }

.frame8a2e4-menubtn[aria-expanded="true"] i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.frame8a2e4-menubtn[aria-expanded="true"] i:nth-child(2) { opacity: 0; }
.frame8a2e4-menubtn[aria-expanded="true"] i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- layered dropdown menu ---------- */

.frame8a2e4-menu {
  position: fixed;
  top: var(--frame8a2e4-topbar-h);
  left: 0;
  right: 0;
  z-index: 75;
  max-width: var(--frame8a2e4-canvas);
  margin: 0 auto;
  background: #363636;
  border-bottom: 1px solid var(--frame8a2e4-teal-glow);
  max-height: 0;
  overflow: hidden;
  visibility: hidden;
  transition: max-height 0.3s ease, visibility 0.3s;
}

.frame8a2e4-menu.frame8a2e4is-open {
  max-height: 520px;
  visibility: visible;
}

.frame8a2e4-menu__layer {
  padding: 10px var(--frame8a2e4-gutter) 12px;
  border-top: 1px dashed var(--frame8a2e4-line-soft);
}

.frame8a2e4-menu__layer:first-child { border-top: 0; }

.frame8a2e4-menu__tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--frame8a2e4-teal);
  margin: 0 0 7px;
  font-family: var(--frame8a2e4-font-head);
}

.frame8a2e4-menu__row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.frame8a2e4-menu__row a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 13px;
  border: 1px solid var(--frame8a2e4-teal-glow);
  border-radius: var(--frame8a2e4-radius-pill);
  background: var(--frame8a2e4-panel);
  color: var(--frame8a2e4-teal-soft);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.18s ease, border-color 0.18s ease;
}

.frame8a2e4-menu__row a:hover {
  background: var(--frame8a2e4-panel-hi);
  border-color: var(--frame8a2e4-teal);
  text-decoration: none;
}

.frame8a2e4-menu__row a.frame8a2e4is-here {
  background: rgba(38, 166, 154, 0.16);
  border-color: var(--frame8a2e4-teal);
}

/* ---------- lead / hero ---------- */

.frame8a2e4-lead {
  padding: 4px var(--frame8a2e4-gutter) 0;
}

.frame8a2e4-lead__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 14px;
}

.frame8a2e4-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: 3px;
  background: var(--frame8a2e4-panel);
  color: var(--frame8a2e4-ink-dim);
  font-size: 11px;
  white-space: nowrap;
}

.frame8a2e4-chip b { color: var(--frame8a2e4-teal-soft); font-weight: 700; }

.frame8a2e4-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0 0 16px;
}

.frame8a2e4-stats div {
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: var(--frame8a2e4-radius-tile);
  background: var(--frame8a2e4-panel);
  padding: 8px 6px;
  text-align: center;
}

.frame8a2e4-stats b {
  display: block;
  font-family: var(--frame8a2e4-font-head);
  font-size: 17px;
  color: var(--frame8a2e4-teal);
}

.frame8a2e4-stats span { font-size: 10.5px; color: var(--frame8a2e4-mute); }

/* carousel - scroll snap track, JS only syncs dots */
.frame8a2e4-hero { margin: 0 0 20px; }

.frame8a2e4-hero__track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.frame8a2e4-hero__track::-webkit-scrollbar { display: none; }

.frame8a2e4-hero__item {
  flex: 0 0 100%;
  scroll-snap-align: center;
  padding: 0;
  border: 0;
  background: none;
  display: block;
  position: relative;
}

.frame8a2e4-hero__item img {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 1;
  object-fit: cover;
  border-radius: var(--frame8a2e4-radius-tile);
  border: 1px solid var(--frame8a2e4-teal-glow);
}

.frame8a2e4-hero__note {
  position: absolute;
  left: 8px;
  bottom: 8px;
  max-width: calc(100% - 20px);
  background: rgba(31, 31, 31, 0.78);
  border: 1px solid var(--frame8a2e4-teal-glow);
  border-radius: 3px;
  color: var(--frame8a2e4-teal-soft);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
}

.frame8a2e4-hero__dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
}

.frame8a2e4-hero__dot {
  width: 26px;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 3px;
  background: #555555;
  transition: background-color 0.2s ease;
}

.frame8a2e4-hero__dot.frame8a2e4is-on { background: var(--frame8a2e4-teal); }

/* ---------- game shelves ---------- */

.frame8a2e4-shelf { margin: 0 0 24px; }

.frame8a2e4-shelf__head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  padding: 0 var(--frame8a2e4-gutter);
  margin-bottom: 4px;
}

.frame8a2e4-shelf__kicker {
  font-family: var(--frame8a2e4-font-head);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--frame8a2e4-teal);
}

.frame8a2e4-shelf__count {
  font-size: 10.5px;
  color: var(--frame8a2e4-mute);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: 3px;
  padding: 1px 7px;
}

.frame8a2e4-shelf h2 {
  width: 100%;
  margin: 0 0 4px;
}

.frame8a2e4-shelf__intro {
  padding: 0 var(--frame8a2e4-gutter);
  color: var(--frame8a2e4-ink-dim);
  font-size: 12.5px;
  margin: 0 0 10px;
}

/* outlined tile game grid */
.frame8a2e4-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 0 var(--frame8a2e4-gutter);
}

.frame8a2e4-tile {
  width: 100%;
  min-height: 44px;
  padding: 7px 4px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  background: linear-gradient(180deg, var(--frame8a2e4-panel-hi), #3b3b3b);
  border: 1px solid var(--frame8a2e4-teal-glow);
  border-radius: var(--frame8a2e4-radius-tile);
  transition: border-color 0.18s ease, background-color 0.18s ease, transform 0.18s ease;
}

.frame8a2e4-tile:hover {
  border-color: var(--frame8a2e4-teal);
  text-decoration: none;
}

.frame8a2e4-tile:active { transform: scale(0.96); }

.frame8a2e4-tile img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 3px;
  display: block;
}

.frame8a2e4-tile span {
  font-size: 11px;
  line-height: 1.3;
  text-align: center;
  color: var(--frame8a2e4-teal-soft);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
  word-break: break-word;
}

/* wider canvas bump - literal 430 breakpoint */
@media (min-width: 430px) {
  .frame8a2e4-grid { grid-template-columns: repeat(5, 1fr); }
}

@media (max-width: 339px) {
  .frame8a2e4-grid { gap: 6px; }
  .frame8a2e4-tile span { font-size: 10.5px; }
}

/* ---------- editorial modules ---------- */

.frame8a2e4-module {
  padding: 14px var(--frame8a2e4-gutter) 4px;
  margin: 0 0 18px;
  border-top: 1px solid var(--frame8a2e4-line-soft);
}

.frame8a2e4-module__lede {
  color: var(--frame8a2e4-ink-dim);
  font-size: 13px;
}

/* scenario branch rows */
.frame8a2e4-branch {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px;
  margin: 10px 0;
  background: var(--frame8a2e4-panel);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-left: 3px solid var(--frame8a2e4-teal);
  border-radius: var(--frame8a2e4-radius-tile);
}

.frame8a2e4-branch__ico {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--frame8a2e4-teal-glow);
  color: var(--frame8a2e4-teal);
}

.frame8a2e4-branch__ico svg { width: 18px; height: 18px; }

.frame8a2e4-branch h3 { margin: 0 0 3px; }

.frame8a2e4-branch p { margin: 0; font-size: 12.5px; color: var(--frame8a2e4-ink-dim); }

/* compact numbered steps */
.frame8a2e4-steps { counter-reset: frame8a2e4step; margin: 10px 0; }

.frame8a2e4-steps li {
  counter-increment: frame8a2e4step;
  position: relative;
  padding: 8px 10px 8px 40px;
  margin: 6px 0;
  background: var(--frame8a2e4-panel);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: var(--frame8a2e4-radius-tile);
  font-size: 12.5px;
  color: var(--frame8a2e4-ink-dim);
}

.frame8a2e4-steps li::before {
  content: counter(frame8a2e4step);
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(38, 166, 154, 0.16);
  border: 1px solid var(--frame8a2e4-teal-glow);
  color: var(--frame8a2e4-teal);
  font-size: 11px;
  font-weight: 700;
  font-family: var(--frame8a2e4-font-head);
}

/* two column mini summary cards */
.frame8a2e4-duo {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 10px 0;
}

.frame8a2e4-duo article {
  padding: 10px;
  background: var(--frame8a2e4-panel);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: var(--frame8a2e4-radius-tile);
}

.frame8a2e4-duo h3 { margin: 0 0 4px; font-size: 12.5px; }

.frame8a2e4-duo p { margin: 0; font-size: 11.5px; color: var(--frame8a2e4-mute); }

/* milestone list (achievements) */
.frame8a2e4-marks { margin: 10px 0; }

.frame8a2e4-marks li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--frame8a2e4-line-soft);
  font-size: 12.5px;
  color: var(--frame8a2e4-ink-dim);
}

.frame8a2e4-marks li:last-child { border-bottom: 0; }

.frame8a2e4-marks b {
  color: var(--frame8a2e4-teal-soft);
  font-family: var(--frame8a2e4-font-head);
  font-size: 12px;
  flex: 0 0 78px;
}

.frame8a2e4-marks svg {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  color: var(--frame8a2e4-teal);
}

/* inline promo text links */
.frame8a2e4-textlink {
  display: inline;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px dashed var(--frame8a2e4-teal);
  background: none;
  color: var(--frame8a2e4-teal);
  font-size: inherit;
  font-weight: 600;
  text-decoration: none;
}

.frame8a2e4-textlink:hover { color: var(--frame8a2e4-teal-soft); }

/* CTA group */
.frame8a2e4-ctagroup {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 6px;
}

/* FAQ style sub-answers */
.frame8a2e4-qa { margin: 10px 0; }

.frame8a2e4-qa h3 {
  margin: 0;
  padding: 9px 10px;
  background: var(--frame8a2e4-panel);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-bottom: 0;
  border-radius: var(--frame8a2e4-radius-tile) var(--frame8a2e4-radius-tile) 0 0;
  font-size: 12.5px;
}

.frame8a2e4-qa p {
  margin: 0;
  padding: 9px 10px 10px;
  background: rgba(62, 62, 62, 0.5);
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: 0 0 var(--frame8a2e4-radius-tile) var(--frame8a2e4-radius-tile);
  font-size: 12.5px;
  color: var(--frame8a2e4-ink-dim);
}

/* ---------- extended footer (home only) ---------- */

.frame8a2e4-xfoot {
  margin: 22px 0 0;
  padding: 16px var(--frame8a2e4-gutter) 18px;
  background: var(--frame8a2e4-bg-deep);
  border-top: 1px solid var(--frame8a2e4-teal-glow);
}

.frame8a2e4-xfoot__brand {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 8px;
}

.frame8a2e4-xfoot__brand img {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  border: 1px solid var(--frame8a2e4-teal-glow);
}

.frame8a2e4-xfoot__brand b {
  font-family: var(--frame8a2e4-font-head);
  font-size: 14px;
  color: var(--frame8a2e4-teal-soft);
}

.frame8a2e4-xfoot p { font-size: 12px; color: var(--frame8a2e4-mute); }

.frame8a2e4-xfoot__groups {
  display: grid;
  gap: 10px;
  margin: 14px 0;
}

.frame8a2e4-xfoot__group h4 { margin: 0 0 6px; }

.frame8a2e4-xfoot__group ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.frame8a2e4-xfoot__group a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 5px 11px;
  border: 1px solid var(--frame8a2e4-line-soft);
  border-radius: 3px;
  background: var(--frame8a2e4-panel);
  color: var(--frame8a2e4-ink-dim);
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color 0.18s ease, color 0.18s ease;
}

.frame8a2e4-xfoot__group a:hover {
  border-color: var(--frame8a2e4-teal);
  color: var(--frame8a2e4-teal-soft);
  text-decoration: none;
}

/* promotion action tiles: icon plus text label */
.frame8a2e4-promos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 12px 0;
}

.frame8a2e4-promos button {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 8px 10px;
  border: 1px solid var(--frame8a2e4-teal-glow);
  border-radius: var(--frame8a2e4-radius-tile);
  background: linear-gradient(180deg, var(--frame8a2e4-panel-hi), var(--frame8a2e4-panel));
  color: var(--frame8a2e4-teal-soft);
  font-size: 11.5px;
  font-weight: 700;
  text-align: left;
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.frame8a2e4-promos button:hover { border-color: var(--frame8a2e4-teal); }

.frame8a2e4-promos button:active { transform: scale(0.97); }

.frame8a2e4-promos svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  color: var(--frame8a2e4-teal);
}

.frame8a2e4-promos span { display: block; font-weight: 400; color: var(--frame8a2e4-mute); font-size: 10.5px; }

.frame8a2e4-disclaimer {
  padding: 10px 11px;
  border: 1px dashed var(--frame8a2e4-line-soft);
  border-radius: var(--frame8a2e4-radius-tile);
  font-size: 11px;
  color: var(--frame8a2e4-mute);
  margin: 12px 0 0;
}

/* ---------- generic copyright footer ---------- */

.frame8a2e4-copy {
  padding: 12px var(--frame8a2e4-gutter) 14px;
  text-align: center;
  font-size: 11px;
  color: var(--frame8a2e4-mute);
  border-top: 1px solid var(--frame8a2e4-line-soft);
  margin: 0;
}

/* ---------- raised center bottom tab bar ---------- */

.frame8a2e4-tabbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 85;
  max-width: var(--frame8a2e4-canvas);
  margin: 0 auto;
  height: calc(var(--frame8a2e4-tabbar-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: #333333;
  border-top: 1px solid var(--frame8a2e4-line);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  overflow: visible;
}

.frame8a2e4-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: var(--frame8a2e4-tabbar-h);
  color: var(--frame8a2e4-mute);
  font-size: 10px;
  font-weight: 600;
  text-decoration: none;
  background: none;
  border: 0;
  padding: 4px 2px 2px;
}

.frame8a2e4-tab svg {
  width: 21px;
  height: 21px;
  transition: transform 0.2s ease, color 0.2s ease;
}

.frame8a2e4-tab:hover { text-decoration: none; color: var(--frame8a2e4-ink-dim); }

/* active state: top indicator line + icon morph */
.frame8a2e4-tab::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 36px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--frame8a2e4-teal);
  transform: translateX(-50%) scaleX(0);
  transition: transform 0.22s ease;
}

.frame8a2e4-tab.frame8a2e4is-on { color: var(--frame8a2e4-teal-soft); }

.frame8a2e4-tab.frame8a2e4is-on::before { transform: translateX(-50%) scaleX(1); }

.frame8a2e4-tab.frame8a2e4is-on svg {
  transform: translateY(-1px) scale(1.1);
  color: var(--frame8a2e4-teal);
}

/* raised center action */
.frame8a2e4-tab--lift { overflow: visible; }

.frame8a2e4-tab--lift .frame8a2e4-lift {
  width: 52px;
  height: 52px;
  margin-top: -34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(160deg, var(--frame8a2e4-teal), var(--frame8a2e4-teal-deep));
  border: 2px solid rgba(224, 242, 241, 0.55);
  box-shadow: 0 7px 16px rgba(0, 0, 0, 0.45), 0 0 0 5px rgba(38, 166, 154, 0.14);
  color: #f2fbfa;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.frame8a2e4-tab--lift .frame8a2e4-lift svg {
  width: 23px;
  height: 23px;
}

.frame8a2e4-tab--lift .frame8a2e4-lift:active {
  transform: translateY(2px) scale(0.96);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.frame8a2e4-tab--lift span { margin-top: 1px; }

/* ---------- restrained reveal motion ---------- */

.frame8a2e4js .frame8a2e4-reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.frame8a2e4js .frame8a2e4-reveal.frame8a2e4is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  .frame8a2e4js .frame8a2e4-reveal {
    opacity: 1;
    transform: none;
  }
}

/* ---------- small helpers ---------- */

.frame8a2e4-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.frame8a2e4-note {
  font-size: 11.5px;
  color: var(--frame8a2e4-mute);
}

.frame8a2e4-strong { color: var(--frame8a2e4-teal-soft); font-weight: 700; }
