/* Examples page only. Shared chrome lives in site.css.
   x-  = page layout on the dark site
   m-  = inside an example site (light, laid out by container width, not screen width)
   c-  = small one-off demos in the component cards */

/* Intro */
.x-hero { padding: 4.8rem 0 1rem; }
.x-hero .lede { max-width: 56ch; margin: 0 0 2.2rem; }
.x-figure { margin: 0; }
.x-figure img { display: block; width: 100%; height: auto; border-radius: 8px; border: 1px solid #2a364c; box-shadow: var(--shadow); }
.x-figure figcaption { margin-top: .75rem; font-family: var(--mono); font-size: .8rem; color: var(--muted); }
.x-tight { padding-top: 3.2rem; }

/* Plan tags */
.x-tag {
  display: inline-flex;
  align-items: center;
  padding: .16rem .45rem;
  border: 1px solid currentColor;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .1em;
  line-height: 1.3;
  text-transform: uppercase;
  white-space: nowrap;
}
.x-tag.oversight { color: var(--ice); }
.x-tag.signal { color: var(--live); }
.x-tag.local { color: var(--star); }
.x-tag.custom { color: var(--muted); border-style: dashed; }

.x-legend { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 0; padding: 0; list-style: none; }
.x-legend li { padding: 1.05rem 1.1rem; background: linear-gradient(180deg, var(--panel-2), var(--panel)); border: 1px solid var(--line); border-radius: var(--radius); }
.x-legend p { margin: .6rem 0 0; color: var(--muted); font-size: .9rem; }
@media (max-width: 900px) { .x-legend { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .x-legend { grid-template-columns: 1fr; } }

/* Full examples */
.x-tools { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0 0 .9rem; }
.x-status { margin: 0 0 8px; font-family: var(--mono); font-size: .7rem; color: var(--muted); }
.x-status b { color: var(--live); }
/* No scrolling inside the frame on any screen (it trapped the page scroll on desktop).
   Show the top of the example with a fade, then a button opens the rest. */
.x-stage { position: relative; background: #05070c; border-radius: 5px; }
.x-view {
  container: site / inline-size;
  width: 100%;
  max-width: 100%;
  max-height: 680px;
  margin-inline: auto;
  overflow: hidden;
  border-radius: 5px;
  background: #fff;
  transition: width .25s ease;
}
.x-stage::after { content: ""; position: absolute; inset: auto 0 0; height: 140px; border-radius: 0 0 5px 5px; background: linear-gradient(rgb(5 7 12 / 0), rgb(5 7 12 / .92)); pointer-events: none; }
.x-expand { display: inline-flex; margin-top: .9rem; }
.is-expanded .x-view { max-height: none; }
.is-expanded .x-stage::after { display: none; }
.x-features-title { margin: 1.8rem 0 .3rem; font-family: var(--mono); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--star); }
.x-features { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 0 1.6rem; margin: 0; padding: 0; list-style: none; }
.x-features li { display: flex; justify-content: space-between; align-items: center; gap: .8rem; padding: .6rem 0; border-bottom: 1px solid var(--line); font-size: .92rem; }
@media (max-width: 700px) {
  .x-width { display: none; }
  .x-hero { padding: 3.4rem 0 .5rem; }
  .x-view { max-height: 820px; }
}

/* Component cards */
.x-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
@media (max-width: 980px) { .x-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .x-grid { grid-template-columns: 1fr; } }
.x-card { display: flex; flex-direction: column; padding: 1rem 1rem 1.2rem; background: linear-gradient(180deg, var(--panel-2), var(--panel)); border: 1px solid var(--line); border-radius: var(--radius); }
.x-card > p { margin: .45rem 0 0; color: var(--muted); font-size: .9rem; }
.x-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: .6rem; margin-top: 1.1rem; }
.x-card-head h3 { margin: 0; font-family: var(--serif); font-size: 1.35rem; font-weight: 400; line-height: 1.15; }
.x-screen { container: site / inline-size; min-height: 236px; overflow: hidden; border-radius: 5px; background: #fff; }
.x-screen > .m-site { min-height: 236px; }
.x-center { display: grid; place-items: center; padding: .9rem; background: #e9ebef; }
.x-center > .m-site { min-height: 0; background: transparent; }
.x-close-actions { display: flex; flex-wrap: wrap; gap: .6rem; }

/* ---------- Inside an example site ---------- */

/* ---------- Component card demos ---------- */

.c-sk { height: 8px; margin: .55rem .7rem 0; border-radius: 4px; background: var(--m-line); }
.c-sk.w40 { width: 40%; } .c-sk.w50 { width: 50%; } .c-sk.w60 { width: 60%; } .c-sk.w70 { width: 70%; } .c-sk.w80 { width: 80%; }

.c-phone { position: relative; width: 170px; height: 252px; overflow: hidden; border: 7px solid #1a1f29; border-radius: 24px; background: var(--m-bg, #f6f2eb); }
.c-phone .m-site { height: 100%; padding-top: .5rem; }
.c-phone .m-bar { position: absolute; left: 0; right: 0; bottom: 0; }
.c-phone .m-bar span { font-size: .56rem; padding: .4rem 0 .5rem; }
.c-phone .m-bar svg { width: 15px; height: 15px; }
.c-ph { min-height: 0; margin: .6rem .7rem 0; aspect-ratio: 16 / 10; }
.c-ph::before { width: 18px; height: 18px; }

.c-gallery { grid-template-columns: repeat(3, 1fr); }
.c-gallery .m-ph::before { width: 18px; height: 18px; }

.m-site .c-label { display: flex; justify-content: space-between; gap: .5rem; margin-bottom: .5rem; font-size: .78rem; font-weight: 700; }
.c-label em { color: var(--m-soft); font-size: .64rem; font-style: normal; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.c-bars { display: grid; grid-template-columns: repeat(7, 1fr); align-items: end; gap: 6px; height: 78px; }
.c-bars i { display: block; height: var(--h); border-radius: 3px 3px 0 0; background: linear-gradient(180deg, #3e7bd6, #2b5ea8); }
.c-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin: .25rem 0 .8rem; color: var(--m-soft); font-size: .66rem; text-align: center; }
.c-top { display: grid; gap: .35rem; margin: 0; padding: 0; list-style: none; }
.c-top li { display: grid; grid-template-columns: 4.2rem 1fr; align-items: center; gap: .5rem; font-size: .76rem; }
.c-top i { display: block; width: var(--w); height: 8px; border-radius: 4px; background: #e3a33b; }

.c-page { position: relative; overflow: hidden; padding: .5rem 0 .8rem; border: 1px solid var(--m-line); border-radius: 6px; background: #fff; }
.c-btns { display: flex; gap: .5rem; margin: .7rem .7rem 0; }
.c-btns span { flex: 1; padding: .45rem; border-radius: 4px; background: var(--m-dark); color: #fff; font-size: .72rem; font-weight: 600; text-align: center; }
.c-btns span + span { background: transparent; color: var(--m-ink); border: 1px solid var(--m-line); }
.c-blob { position: absolute; left: var(--x); top: var(--y); width: var(--s); height: var(--s); border-radius: 50%; background: radial-gradient(circle, rgb(230 50 30 / .75), rgb(255 160 0 / .45) 45%, rgb(255 220 0 / .15) 65%, transparent 72%); transform: translate(-50%, -50%); mix-blend-mode: multiply; pointer-events: none; }

.c-listing { display: grid; }
.c-listing-ph { min-height: 76px; aspect-ratio: auto; border-radius: 0; }
.c-listing-body { display: grid; gap: .3rem; padding: .75rem .85rem .9rem; font-size: .82rem; }
.m-site .c-listing-name { font-size: 1.05rem; font-weight: 700; }
.c-inline { padding: 0; border: 0; background: none; font-size: .8rem; }
.c-actions { display: flex; gap: .4rem; margin-top: .35rem; }
.c-actions span { flex: 1; padding: .4rem 0; border: 1px solid var(--m-line); border-radius: 999px; color: #2b5ea8; font-size: .7rem; font-weight: 700; text-align: center; }

.c-links { display: grid; justify-items: center; gap: .6rem; text-align: center; }
.c-links .m-soft { max-width: 24ch; font-size: .8rem; }
