/* RustCraft — Launcher 2.2 "Forge", while it's coming soon: the first-look tour on Home, the news
   post's links, and the Store's bundles and coming-soon items. Loaded after css/panel.css. */

/* the "coming soon" chip: ion cyan, so it never reads as a price, a rank or a sale */
.soon-chip { display: inline-flex; align-items: center; margin-right: 0.5rem; padding: 0.26rem 0.5rem 0.24rem; border-radius: 999px;
  font: 800 0.6rem/1 var(--f-display); letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap; color: #03181d;
  background: linear-gradient(180deg, #8ff6ff, #2bc9e3); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 0 16px rgba(62, 230, 255, 0.4); }

/* ── Home: the tour ── */
.forge { margin-top: clamp(3.2rem, 7vw, 5rem); }
.forge .sec-head .eyebrow { display: inline-flex; align-items: center; flex-wrap: wrap; row-gap: 0.4rem; }
.forge-tour { position: relative; padding: clamp(0.8rem, 2vw, 1.3rem); border-radius: 1.3rem;
  background: radial-gradient(120% 90% at 0% 0%, rgba(139, 92, 246, 0.16), transparent 55%), radial-gradient(90% 80% at 100% 100%, rgba(255, 107, 26, 0.12), transparent 60%), linear-gradient(180deg, rgba(20, 15, 36, 0.94), rgba(10, 8, 20, 0.94));
  border: 1px solid rgba(170, 150, 255, 0.2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 4px 0 rgba(30, 24, 52, 0.9), 0 5px 0 rgba(6, 5, 12, 0.95), 0 40px 80px -40px rgba(0, 0, 0, 0.95); }
.forge-tabs { display: flex; width: max-content; max-width: 100%; margin: 0 auto 1.2rem; }
.forge-tabs button { display: inline-flex; align-items: center; gap: 0.42rem; min-height: 2.5rem; padding: 0.55rem 0.8rem; font-size: 0.8rem; }
.forge-tabs button svg { flex: none; width: 1rem; height: 1rem; }
.forge-tabs button.on { color: #1a0b02; background: linear-gradient(180deg, #ffb062, var(--rust) 45%, #d9500b); }
.forge-tabs button:focus-visible { outline: 2px solid #3ee6ff; outline-offset: 2px; }
.forge-panel { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: clamp(1rem, 2.6vw, 2.2rem); align-items: center; }
.forge-panel[hidden] { display: none; }
.forge-panel:not([hidden]) { animation: forgeIn 0.5s var(--glide) both; }
@keyframes forgeIn { from { opacity: 0; transform: translateY(8px); } }
.forge-panel:focus-visible { outline: 2px solid rgba(62, 230, 255, 0.6); outline-offset: 6px; border-radius: 1rem; }
.forge-shot { margin: 0; padding: 0.5rem; border-radius: 0.9rem; background: linear-gradient(180deg, #2c2f35, #15171b); border: 1px solid #000;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 0 60px -20px rgba(139, 92, 246, 0.45);
  transform: perspective(1600px) rotateY(5deg) rotateX(1.5deg); transition: transform 0.6s var(--glide); }
.forge-panel:hover .forge-shot { transform: perspective(1600px) rotateY(2deg) rotateX(0.5deg) translateY(-3px); }
.forge-shot.rivets::before, .forge-shot.rivets::after { top: 0.1rem; width: 0.3rem; height: 0.3rem; }
.forge-shot img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; border-radius: 0.45rem; background: #0b0910; }
.forge-copy { display: grid; gap: 0.6rem; align-content: center; min-width: 0; }
.forge-k { font: 700 0.72rem/1 var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--ember); }
.forge-copy h3 { margin: 0; font: 800 clamp(1.5rem, 2.6vw, 2.1rem)/1.05 var(--f-display); text-transform: uppercase; color: #fff; }
.forge-copy p { margin: 0; color: var(--steel); font-size: 0.98rem; line-height: 1.55; }
.forge-pts { list-style: none; margin: 0.2rem 0 0; padding: 0; display: grid; gap: 0.45rem; }
.forge-pts li { position: relative; padding-left: 1.4rem; color: var(--steel-2); font-size: 0.9rem; line-height: 1.45; }
.forge-pts li::before { content: ""; position: absolute; left: 0.12rem; top: 0.42em; width: 0.5rem; height: 0.5rem; border-radius: 2px; transform: rotate(45deg);
  background: linear-gradient(135deg, var(--ember), var(--rust)); box-shadow: 0 0 10px rgba(255, 140, 60, 0.6); }
.forge-cta { margin-top: 0.4rem; }
.forge-more { list-style: none; margin: 1.1rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.55rem; justify-content: center; }
.forge-more li { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 0.85rem; border-radius: 999px; font-size: 0.84rem; color: var(--steel);
  background: rgba(22, 17, 40, 0.7); border: 1px solid var(--line-2); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05); }
.forge-more svg { flex: none; width: 0.95rem; height: 0.95rem; color: var(--ember); }
/* tablets and small laptops: the eight tabs wrap onto two rows instead of hiding off the edge */
@media (min-width: 561px) and (max-width: 939px) {
  .forge-tabs { flex-wrap: wrap; justify-content: center; width: auto; border-radius: 0.9rem; }
}
@media (max-width: 900px) {
  .forge-panel { grid-template-columns: 1fr; }
  .forge-shot, .forge-panel:hover .forge-shot { transform: none; }
  .forge-tabs { margin-left: 0; }
}
@media (max-width: 560px) {
  .forge-tabs button { padding: 0.5rem 0.65rem; font-size: 0.76rem; }
  .forge-more { justify-content: flex-start; }
}

/* ── Home: news ── */
@media (min-width: 901px) {   /* the lead post fills its column: its picture grows to the height of the side posts */
  .news > .post.lead { align-self: stretch; grid-template-rows: minmax(0, 1fr) auto; }
  .news > .post.lead > img { height: 100%; min-height: 0; aspect-ratio: auto; object-position: top left; }
}
.post small b.soon { color: #6ef0ff; }
.post-links { display: flex; flex-wrap: wrap; gap: 0.35rem 1.1rem; }
.post-links a { color: var(--ember); font-weight: 700; text-decoration: none; border-bottom: 1px solid rgba(255, 181, 71, 0.35); transition: color 0.2s, border-color 0.2s; }
.post-links a:hover { color: #fff; border-color: #fff; }
.news-side > .post.wide { grid-column: 1 / -1; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); }
.news-side > .post.wide > img { height: 100%; min-height: 12rem; aspect-ratio: auto;
  -webkit-mask: linear-gradient(90deg, #000 72%, rgba(0, 0, 0, 0.5)); mask: linear-gradient(90deg, #000 72%, rgba(0, 0, 0, 0.5)); }
@media (max-width: 560px) {
  .news-side > .post.wide { grid-template-columns: 1fr; }
  .news-side > .post.wide > img { height: auto; min-height: 0; aspect-ratio: 16 / 9;
    -webkit-mask: linear-gradient(180deg, #000 70%, rgba(0, 0, 0, 0.55)); mask: linear-gradient(180deg, #000 70%, rgba(0, 0, 0, 0.55)); }
}

/* ── Store: coming soon (the pill has its own row under the hero) ── */
.store-hero .soon-pill { justify-self: start; margin-top: 0.9rem; }
@media (min-width: 980px) { .store-hero .soon-pill { grid-column: 1 / -1; justify-self: end; margin-top: 0.7rem; } }
.soon-pill { display: inline-flex; align-items: center; padding: 0.42rem 0.9rem 0.42rem 0.42rem; border-radius: 999px; font: 700 0.82rem/1.25 var(--f-body); text-align: left; color: #dff9ff; cursor: pointer;
  background: rgba(8, 30, 38, 0.72); border: 1px solid rgba(62, 230, 255, 0.4); box-shadow: 0 0 22px -6px rgba(62, 230, 255, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 0.4s var(--spring), box-shadow 0.3s, border-color 0.3s; }
.soon-pill:hover { transform: translateY(-2px); border-color: rgba(62, 230, 255, 0.8); box-shadow: 0 0 30px -4px rgba(62, 230, 255, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.1); }
.soon-pill:focus-visible { outline: 2px solid #3ee6ff; outline-offset: 2px; }
.sbadge.soon { background: rgba(62, 230, 255, 0.12); color: #7ff0ff; border-color: rgba(62, 230, 255, 0.38); }
.scard-flag.soon { color: #03181d; background: linear-gradient(180deg, #8ff6ff, #2bc9e3); }
.soon-note { align-items: center; }
.soon-note .soon-chip { margin-right: 0; }
.fi-soon { display: inline-flex; align-items: center; justify-content: center; cursor: default; color: #bff6ff; background: rgba(8, 30, 38, 0.72);
  border-color: rgba(62, 230, 255, 0.35); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.fi-soon:hover { transform: none; color: #bff6ff; }

/* ── Store: bundles. A run of bundle cards gets its own wider grid inside the catalog ── */
.b-run { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19.5rem), 1fr)); gap: inherit; }
.scard.bundle .scard-art { aspect-ratio: 2 / 0.86;
  background: radial-gradient(60% 75% at 32% 64%, color-mix(in srgb, var(--a) 40%, transparent), transparent 70%),
    radial-gradient(55% 70% at 72% 38%, color-mix(in srgb, var(--a2) 32%, transparent), transparent 72%), linear-gradient(180deg, #120c18, #08060c); }
.scard.bundle .scard-art::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.85;
  background-image: radial-gradient(1px 1px at 12% 30%, rgba(255, 255, 255, 0.7), transparent), radial-gradient(1px 1px at 78% 18%, rgba(255, 255, 255, 0.55), transparent),
    radial-gradient(1.4px 1.4px at 88% 70%, rgba(255, 255, 255, 0.5), transparent), radial-gradient(1px 1px at 30% 84%, rgba(255, 255, 255, 0.45), transparent),
    radial-gradient(1px 1px at 58% 12%, rgba(255, 255, 255, 0.5), transparent), radial-gradient(1.2px 1.2px at 6% 72%, rgba(255, 255, 255, 0.4), transparent); }
.scard.bundle .scard-art::after { content: ""; position: absolute; left: 50%; bottom: 7%; width: 42%; height: 12%; transform: translateX(-50%); border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--a) 55%, transparent), transparent); filter: blur(2px); }
.scard.bundle .scard-art > canvas { z-index: 1; }
.scard.bundle .scard-desc { -webkit-line-clamp: 2; }
.b-items { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.2rem; }
.b-it { position: relative; display: grid; place-items: center; width: 2.35rem; height: 2.35rem; border-radius: 0.5rem; overflow: hidden; color: var(--a);
  background: radial-gradient(70% 70% at 50% 60%, color-mix(in srgb, var(--a) 26%, transparent), transparent 75%), rgba(10, 8, 18, 0.85);
  border: 1px solid color-mix(in srgb, var(--a) 30%, var(--line)); }
.b-it > svg { width: 52%; height: 52%; opacity: 0.75; }
.b-it > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.b-it.painted > svg { display: none; }
.b-it.b-more { font: 800 0.72rem/1 var(--f-display); color: var(--steel-2); }
.b-it.b-emo { color: var(--ember); }
.scard.bundle .b-cape .art-cape, .scard.bundle:hover .b-cape .art-cape, .scard.bundle.is-preview .b-cape .art-cape { width: 44%; transform: none; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6); }
.b-what { font: 600 0.7rem/1.2 var(--f-body); color: var(--steel-2); letter-spacing: 0.02em; }
.scard.bundle .scard-cta { white-space: nowrap; }
@media (max-width: 560px) {
  .scard.bundle .scard-desc { display: -webkit-box; }
  .b-it { width: 2.1rem; height: 2.1rem; }
}

/* the info box: a bundle's pieces, each a button that swaps it in */
.fi-set { list-style: none; margin: 0.1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(10.5rem, 1fr)); gap: 0.35rem; }
.fi-piece { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 0.5rem; align-items: center; width: 100%; min-height: 2.6rem;
  padding: 0.38rem 0.55rem; border-radius: 0.55rem; text-align: left; font: inherit; color: var(--steel); cursor: pointer;
  background: rgba(12, 9, 22, 0.7); border: 1px solid color-mix(in srgb, var(--a) 26%, var(--line)); transition: border-color 0.2s, background 0.2s, transform 0.3s var(--spring); }
.fi-piece:hover { border-color: color-mix(in srgb, var(--a) 60%, transparent); transform: translateY(-1px); }
.fi-piece:focus-visible { outline: 2px solid var(--a); outline-offset: 2px; }
.fi-piece svg { grid-row: 1 / 3; width: 1.15rem; height: 1.15rem; color: var(--a); }
.fi-piece span { font: 700 0.8rem/1.2 var(--f-body); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fi-piece small { font-size: 0.68rem; color: var(--steel-2); letter-spacing: 0.02em; }
.fi-piece.on { background: color-mix(in srgb, var(--ok) 10%, rgba(12, 9, 22, 0.7)); border-color: color-mix(in srgb, var(--ok) 55%, transparent); }
.fi-piece small b { font-weight: inherit; color: var(--ok); }
/* desktop: the fitting room is a sticky column of fixed height, so a long info box scrolls inside it
   (the set's buttons and Your look stay on screen) */
@media (min-width: 980px) {
  .fit-info { flex: 0 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
  .fit-info .fi-acts { position: sticky; bottom: 0; z-index: 1; padding-top: 0.6rem; background: linear-gradient(180deg, transparent, var(--plate) 0.6rem); }
  .fit-info .fi-piece { scroll-margin-bottom: 8rem; }   /* (a focused piece scrolls clear of the buttons and the box's padding) */
}
/* a short screen leaves the box little more than the buttons' height: they scroll with the list instead */
@media (min-width: 980px) and (max-height: 720px) { .fit-info .fi-acts { position: static; } .fit-info .fi-piece { scroll-margin-bottom: 0; } }
@media (min-width: 980px) and (max-height: 820px) { .fi-set { grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); } .fi-piece { min-height: 2.2rem; padding: 0.3rem 0.5rem; } }

@media (prefers-reduced-motion: reduce) {
  .forge-panel:not([hidden]) { animation: none; }
  .forge-shot, .soon-pill, .fi-piece { transition: none; }
}
/* phones and tablets: a piece reached with Shift+Tab scrolls clear of the sticky top bar */
@media (max-width: 979px) { .fit-info .fi-piece { scroll-margin-top: calc(4.6rem + env(safe-area-inset-top, 0px)); } }
/* (keyboard focus going back up the catalog stops below the sticky store bar; on phones, focus in the
   fitting room stops above the small floating preview) */
#storeGrid .scard { scroll-margin-top: calc(14.75rem + env(safe-area-inset-top, 0px)); }
@media (max-width: 979px) { #fit button, #fit input, #fit a { scroll-margin-bottom: calc(12rem + 24px + env(safe-area-inset-bottom, 0px)); } }
