/* ============================================================
   Tiny Byte Studio — concept frame
   Shared chrome for every /concepts/<slug> page in the
   unsolicited-redesign campaign.

   The frame is the ONLY Tiny Byte-branded surface on a concept
   page: a sticky disclosure bar at the top, and a dark outro
   after the concept with the rationale + full disclaimer.
   Everything between them is the redesign, in the subject's own
   visual language — so this file deliberately styles nothing
   global (no body/heading/link resets). Add it AFTER the
   concept's own CSS.
   ============================================================ */

/* Tokens go on the frame elements themselves, not on a wrapper: .tbf-bar is
   `position: sticky`, and a wrapper div only as tall as the bar would give it
   no room to travel — it would scroll straight off the top of the page. */
.tbf,
.tbf-bar,
.tbf-outro {
  /* Tiny Byte tokens, namespaced so a concept's palette can't collide */
  --tbf-ink:       #0c0c0d;
  --tbf-ink-soft:  #141416;
  --tbf-ink-line:  #26262a;
  --tbf-cream:     #f4f1ea;
  --tbf-cream-dim: #9a978f;
  --tbf-ember:     #ff5c35;
  --tbf-display:   'Space Grotesk', ui-sans-serif, system-ui, sans-serif;
  --tbf-body:      'Inter', ui-sans-serif, system-ui, sans-serif;
  --tbf-maxw:      1180px;
  --tbf-gutter:    clamp(1.25rem, 4vw, 3.5rem);
}

.tbf *, .tbf *::before, .tbf *::after,
.tbf-bar *, .tbf-bar *::before, .tbf-bar *::after,
.tbf-outro *, .tbf-outro *::before, .tbf-outro *::after { box-sizing: border-box; }

.tbf-wrap {
  width: 100%;
  max-width: var(--tbf-maxw);
  margin-inline: auto;
  padding-inline: var(--tbf-gutter);
}

/* ---------- Sticky disclosure bar ---------------------------- */

.tbf-bar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--tbf-ink);
  color: var(--tbf-cream);
  border-bottom: 1px solid var(--tbf-ink-line);
  font-family: var(--tbf-body);
  line-height: 1.35;
}

.tbf-bar__inner {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-height: 42px;
  padding-block: 0.4rem;
}

.tbf-bar__tag {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.22rem 0.55rem;
  border-radius: 4px;
  background: var(--tbf-ember);
  color: var(--tbf-ink);
  font-family: var(--tbf-display);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
}

.tbf-bar__text {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 0.8rem;
  color: var(--tbf-cream-dim);
}

.tbf-bar__text b {
  font-weight: 600;
  color: var(--tbf-cream);
}

.tbf-bar__link {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--tbf-cream);
  font-size: 0.78rem;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 92, 53, 0.55);
  padding-bottom: 1px;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.tbf-bar__link:hover {
  color: var(--tbf-ember);
  border-bottom-color: var(--tbf-ember);
}

.tbf-bar__link svg { flex: none; }

@media (max-width: 860px) {
  .tbf-bar__inner { flex-wrap: wrap; gap: 0.45rem 0.7rem; padding-block: 0.55rem; }
  /* Tag left, link right, disclosure text on its own line beneath. */
  .tbf-bar__text { flex: 1 1 100%; order: 3; font-size: 0.74rem; }
  .tbf-bar__link { margin-left: auto; font-size: 0.74rem; }
}

/* ---------- Outro: the rationale + disclaimer ----------------- */

.tbf-outro {
  background: var(--tbf-ink);
  color: var(--tbf-cream);
  font-family: var(--tbf-body);
  line-height: 1.6;
  padding-block: clamp(3.5rem, 8vw, 6.5rem);
  border-top: 1px solid var(--tbf-ink-line);
}

.tbf-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1.1rem;
  font-family: var(--tbf-display);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--tbf-ember);
}

.tbf-eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--tbf-ember);
}

.tbf-outro h2 {
  margin: 0 0 1rem;
  font-family: var(--tbf-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 4.5vw, 3.1rem);
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--tbf-cream);
  max-width: 20ch;
}

.tbf-outro__lede {
  margin: 0;
  max-width: 62ch;
  color: var(--tbf-cream-dim);
  font-size: clamp(1rem, 1.5vw, 1.12rem);
}

/* Numbered rationale list */

.tbf-notes {
  list-style: none;
  margin: clamp(2.5rem, 5vw, 3.75rem) 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1px;
  background: var(--tbf-ink-line);
  border: 1px solid var(--tbf-ink-line);
  border-radius: 16px;
  overflow: hidden;
}

.tbf-notes li {
  background: var(--tbf-ink-soft);
  padding: clamp(1.5rem, 3vw, 2rem);
}

.tbf-notes__n {
  display: block;
  margin-bottom: 0.9rem;
  font-family: var(--tbf-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--tbf-ember);
}

.tbf-notes h3 {
  margin: 0 0 0.5rem;
  font-family: var(--tbf-display);
  font-weight: 700;
  font-size: 1.08rem;
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--tbf-cream);
}

.tbf-notes p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--tbf-cream-dim);
}

.tbf-notes p + p { margin-top: 0.7rem; }

.tbf-notes__fix {
  color: var(--tbf-cream);
}

.tbf-notes__fix b {
  font-family: var(--tbf-display);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tbf-ember);
  display: block;
  margin-bottom: 0.25rem;
}

/* Studio CTA */

.tbf-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem 2rem;
  margin-top: clamp(2.5rem, 5vw, 3.75rem);
  padding: clamp(1.75rem, 4vw, 2.5rem);
  border: 1px solid var(--tbf-ink-line);
  border-radius: 16px;
  background: var(--tbf-ink-soft);
}

.tbf-cta__text { max-width: 46ch; }

.tbf-cta__text strong {
  display: block;
  font-family: var(--tbf-display);
  font-weight: 700;
  font-size: clamp(1.15rem, 2.2vw, 1.5rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--tbf-cream);
  margin-bottom: 0.45rem;
}

.tbf-cta__text span {
  font-size: 0.94rem;
  color: var(--tbf-cream-dim);
}

.tbf-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  border-radius: 100px;
  background: var(--tbf-ember);
  color: var(--tbf-ink);
  font-family: var(--tbf-display);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.tbf-btn:hover {
  background: #ff7a57;
  transform: translateY(-2px);
}

/* Legal disclaimer */

.tbf-legal {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding-top: 1.75rem;
  border-top: 1px solid var(--tbf-ink-line);
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 2.5rem;
  justify-content: space-between;
  align-items: flex-start;
}

.tbf-legal p {
  margin: 0;
  max-width: 78ch;
  font-size: 0.78rem;
  line-height: 1.65;
  color: #6f6c66;
}

.tbf-legal p + p { margin-top: 0.7rem; }

.tbf-legal a {
  color: #8f8c85;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.tbf-legal a:hover { color: var(--tbf-ember); }

.tbf-legal__mark {
  flex: none;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--tbf-display);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--tbf-cream-dim);
  text-decoration: none;
}

.tbf-legal__mark img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: block;
}

.tbf-legal__mark:hover { color: var(--tbf-cream); }

@media (prefers-reduced-motion: reduce) {
  .tbf-btn:hover { transform: none; }
}
