/* Atomik Rack pages (hub + download). Builds on release.css (.ac-rel variables, buttons, video facades). Scoped under .ac-rack.
 * Same dark / neon-pink look as the home page, with a cyan "tech" secondary accent. */

.ac-rack {
	--rk-cyan: #31e0d0;
	--rk-cyan-dim: rgba(61, 230, 214, .16);
	--rk-pad: 16px;
	display: block;
	background: var(--ac-bg);
	overflow-x: clip;
	padding-bottom: 24px;
}
body.ac-rack-page, body.ac-rack-page .site-content { background: #0b0a10; }
.ac-rack .rk-wrap { max-width: 1120px; margin: 0 auto; padding: 0 var(--rk-pad); }
@media (min-width: 922px) { .ac-rack { --rk-pad: 32px; } }
.ac-rack .rk-i { width: 24px; height: 24px; flex: none; display: block; }
.ac-rack a:focus-visible, .ac-rack summary:focus-visible { outline: 2px solid var(--rk-cyan); outline-offset: 3px; border-radius: 6px; }

/* ---------- Hero ---------- */
.rk-hero {
	position: relative; isolation: isolate; overflow: hidden;
	padding: 112px var(--rk-pad) 48px;
	background:
		radial-gradient(900px 520px at 88% 12%, rgba(61, 230, 214, .20), transparent 60%),
		radial-gradient(800px 520px at 6% 92%, rgba(251, 95, 171, .20), transparent 60%),
		radial-gradient(600px 400px at 50% 40%, rgba(142, 92, 255, .14), transparent 70%),
		#0b0a10;
}
.rk-hero__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.rk-hero__bg::after { /* floor grid, cyan lines this time */
	content: ""; position: absolute; left: -10%; right: -10%; bottom: 0; height: 38%;
	background:
		linear-gradient(to top, #0b0a10 0%, transparent 70%),
		repeating-linear-gradient(90deg, rgba(61, 230, 214, .20) 0 1px, transparent 1px 64px),
		repeating-linear-gradient(0deg, rgba(61, 230, 214, .20) 0 1px, transparent 1px 40px);
	transform: perspective(500px) rotateX(58deg); transform-origin: bottom; opacity: .5;
}
.rk-hero__inner { max-width: 1120px; margin: 0 auto; display: grid; gap: 32px; align-items: center; position: relative; }
.rk-hero__text { text-align: center; min-width: 0; }
.rk-eyebrow { display: inline-flex; align-items: center; gap: 12px; color: var(--ac-muted); font-size: .8125rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.rk-eyebrow img { width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .16), 0 0 24px rgba(61, 230, 214, .35); }
.ac-rack .rk-hero__title { font-size: clamp(2.125rem, 8.5vw, 3.75rem); font-weight: 800; line-height: 1.06; letter-spacing: -.01em; margin: 14px 0 14px; text-wrap: balance; overflow-wrap: anywhere; }
.rk-hero__tag { color: var(--ac-muted); font-size: 1.0625rem; max-width: 36em; margin: 0 auto; }
.rk-hero__cta { display: flex; flex-direction: column; gap: 12px; margin-top: 26px; align-items: stretch; }
.ac-rack .rk-btn-lg { min-height: 56px; font-size: 1.0625rem; padding: 0 28px; }
.ac-rack .ac-rel__btn--ghost:hover { border-color: var(--rk-cyan); }
.rk-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 20px !important; }
.rk-badges li {
	margin: 0; padding: 4px 12px; border-radius: 999px; border: 1px solid rgba(61, 230, 214, .45); background: var(--rk-cyan-dim);
	color: var(--rk-cyan); font-size: .8125rem; font-weight: 700; letter-spacing: .04em;
}
.rk-hero__video { min-width: 0; }
.rk-hero__video .ac-rel__embed { box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 0 60px rgba(61, 230, 214, .22), 0 30px 80px rgba(0, 0, 0, .6); border-radius: 18px; }
.rk-hero__cap { margin-top: 10px; color: var(--ac-muted); font-size: .875rem; text-align: center; }
.rk-hero--slim { padding-bottom: 40px; }
.rk-crumbs { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 8px; margin-bottom: 14px; font-size: .875rem; color: var(--ac-muted); }
.rk-crumbs a { color: var(--ac-muted); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.rk-crumbs a:hover { color: #fff; text-decoration: underline; }
.rk-crumbs span { display: inline-flex; align-items: center; }
@media (min-width: 600px) { .rk-hero__cta { flex-direction: row; justify-content: center; } }
@media (min-width: 922px) {
	.rk-hero { padding: 150px var(--rk-pad) 88px; }
	.rk-hero--slim { padding-bottom: 64px; }
	.rk-hero__inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; width: 100%; }
	.rk-hero__inner--one { grid-template-columns: minmax(0, 1fr); }
	.rk-hero__text { text-align: left; }
	.rk-hero__tag { margin: 0; font-size: 1.1875rem; }
	.rk-hero__cta, .rk-badges, .rk-crumbs { justify-content: flex-start; }
	.rk-hero__cap { text-align: left; }
}

/* ---------- Sections ---------- */
.rk-sec { margin-top: 64px; }
.rk-sec__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.ac-rack .rk-h { font-size: clamp(1.5rem, 4.5vw, 2rem); font-weight: 800; line-height: 1.15; margin: 0 0 14px; text-wrap: balance; }
.rk-sec__head .rk-h { margin: 0; }
.rk-lead { color: var(--ac-muted); max-width: 60ch; margin: -4px 0 22px !important; }
.rk-small { color: var(--ac-muted); font-size: .875rem; margin-top: 16px !important; max-width: 70ch; }
.rk-links a { display: inline-flex; align-items: center; min-height: 44px; }
.rk-more { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 700; text-decoration: none; }
.rk-more:hover { text-decoration: underline; }
.rk-note { margin-top: 14px !important; padding: 12px 16px; border: 1px solid var(--ac-border); border-radius: 12px; background: var(--ac-surface); color: var(--ac-muted); font-size: .9375rem; }

/* ---------- Download ---------- */
.rk-dl {
	display: grid; gap: 28px; padding: 24px; border: 1px solid rgba(61, 230, 214, .3); border-radius: calc(var(--ac-radius) + 4px);
	background: linear-gradient(145deg, rgba(61, 230, 214, .10), rgba(142, 92, 255, .10) 55%, rgba(251, 95, 171, .08));
	scroll-margin-top: 90px;
}
.rk-dl__ver { color: var(--ac-muted); font-size: 1rem; margin: 0 0 12px !important; }
.rk-dl__ver strong { color: var(--rk-cyan); font-weight: 800; }
.rk-hero .rk-dl__ver { margin-top: 18px !important; }
.rk-dl__txt { color: var(--ac-muted); max-width: 46ch; }
.rk-dl__cta { display: flex; flex-direction: column; gap: 12px; margin-top: 20px; }
.rk-dl__small { margin-top: 14px !important; font-size: .9375rem; display: flex; flex-wrap: wrap; gap: 0 10px; align-items: center; color: var(--ac-muted); }
.rk-dl__small a { display: inline-flex; align-items: center; min-height: 44px; }
@media (min-width: 600px) { .rk-dl__cta { flex-direction: row; } }
@media (min-width: 922px) { .rk-dl { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 40px; padding: 40px; align-items: center; } }

/* OS cards */
.rk-os { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
.rk-os__card { margin: 0; padding: 18px; border: 1px solid var(--ac-border); border-radius: var(--ac-radius); background: rgba(22, 20, 31, .92); display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.rk-os__head { display: flex; align-items: center; gap: 12px; }
.rk-os__head .rk-i { width: 28px; height: 28px; color: var(--rk-cyan); }
.ac-rack .rk-os__head h3 { font-size: 1.125rem; font-weight: 800; line-height: 1.2; }
.rk-os__arch { color: var(--ac-muted); font-size: .8125rem; }
.rk-os__rec { margin-left: auto; padding: 2px 10px; border-radius: 999px; background: var(--rk-cyan); color: #04211e; font-size: .75rem; font-weight: 800; white-space: nowrap; }
.rk-os__note { color: var(--ac-muted); font-size: .875rem; }
.rk-os__none { font-size: .9375rem; }
.rk-files { display: grid; gap: 8px; }
.rk-files li { margin: 0; }
.ac-rack a.rk-file {
	display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 8px 16px; border-radius: 12px;
	border: 1px solid var(--ac-border); background: var(--ac-surface-2); color: var(--ac-text); text-decoration: none; font-weight: 700; font-size: .9375rem;
	transition: border-color .15s ease, background-color .15s ease, transform .15s ease;
}
.ac-rack a.rk-file:hover { border-color: var(--rk-cyan); background: #26233a; color: #fff; transform: translateY(-1px); }
.ac-rack a.rk-file--main { border-color: rgba(61, 230, 214, .55); }
.rk-file__s { color: var(--ac-muted); font-weight: 600; font-size: .8125rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* The visitor's system floats to the top (set by rack.js on [data-os]). */
.ac-rack[data-os="windows"] .rk-os--windows, .ac-rack[data-os="linux"] .rk-os--linux, .ac-rack[data-os="macos"] .rk-os--macos { order: -1; border-color: var(--rk-cyan); box-shadow: 0 0 0 1px var(--rk-cyan), 0 0 30px rgba(61, 230, 214, .2); }
@media (min-width: 700px) and (max-width: 921px) { .rk-os { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 922px) { .rk-download .rk-os { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } .rk-download .rk-os__card { padding: 22px; } }

/* ---------- Features ---------- */
.rk-feat { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
.rk-feat__item { margin: 0; padding: 22px; border: 1px solid var(--ac-border); border-radius: var(--ac-radius); background: linear-gradient(160deg, rgba(31, 28, 43, .9), rgba(22, 20, 31, .9)); transition: border-color .15s ease, transform .15s ease; }
.rk-feat__item:hover { border-color: rgba(61, 230, 214, .5); transform: translateY(-2px); }
.rk-feat__ic { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--rk-cyan-dim); color: var(--rk-cyan); margin-bottom: 14px; }
.ac-rack .rk-feat__item h3 { font-size: 1.0625rem; font-weight: 800; line-height: 1.25; margin-bottom: 8px; }
.rk-feat__item p { color: var(--ac-muted); font-size: .9375rem; }
@media (min-width: 640px) { .rk-feat { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 992px) { .rk-feat { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }

/* ---------- Tutorials ---------- */
.rk-tuts { display: grid; gap: 20px 16px; grid-template-columns: minmax(0, 1fr); }
.rk-tuts li { margin: 0; }
.ac-rack a.rk-tut { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--ac-text); height: 100%; }
.rk-tut__img { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: var(--ac-radius); overflow: hidden; background: var(--ac-surface); box-shadow: 0 14px 40px rgba(0, 0, 0, .45); }
.rk-tut__img img { width: 100%; height: 100%; object-fit: cover; opacity: .9; transition: opacity .2s ease, transform .3s ease; }
.rk-tut:hover .rk-tut__img img { opacity: 1; transform: scale(1.03); }
.rk-tut__play { position: absolute; top: 50%; left: 50%; width: 56px; height: 56px; margin: -28px 0 0 -28px; border-radius: 50%; display: grid; place-items: center; background: var(--ac-accent); color: var(--ac-accent-ink); box-shadow: 0 6px 24px rgba(0, 0, 0, .5); }
.rk-tut__play .rk-i { width: 26px; height: 26px; margin-left: 3px; }
.rk-tut__t { margin-top: 6px; font-weight: 800; font-size: 1.0625rem; line-height: 1.3; }
.rk-tut:hover .rk-tut__t { text-decoration: underline; }
.rk-tut__b { color: var(--ac-muted); font-size: .9375rem; }
.ac-rack a.rk-tut:focus-visible { outline-offset: 6px; }
@media (min-width: 700px) { .rk-tuts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- Open source ---------- */
.rk-oss { display: grid; gap: 28px; padding: 24px; border: 1px solid var(--ac-border); border-radius: calc(var(--ac-radius) + 4px); background: linear-gradient(145deg, rgba(31, 28, 43, .9), rgba(22, 20, 31, .9)); }
.rk-oss__main > p { color: var(--ac-muted); max-width: 52ch; }
.rk-oss__links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px !important; }
.rk-oss__links li { margin: 0; }
.rk-oss__links .ac-rel__btn { width: 100%; }
.rk-oss__links .rk-i { width: 20px; height: 20px; }
.rk-oss__links li { flex: 1 1 100%; }
.ac-rack .rk-oss__road h3 { font-size: .8125rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--rk-cyan); margin-bottom: 12px; }
.rk-checks { display: grid; gap: 10px; }
.rk-checks li { margin: 0; padding-left: 28px; position: relative; color: var(--ac-text); font-size: .9375rem; }
.rk-checks li::before { content: ""; position: absolute; left: 4px; top: .45em; width: 8px; height: 8px; border-radius: 2px; background: var(--rk-cyan); box-shadow: 0 0 10px rgba(61, 230, 214, .7); }
@media (min-width: 560px) { .rk-oss__links li { flex: 1 1 calc(50% - 10px); } }
@media (min-width: 922px) { .rk-oss { grid-template-columns: 1.2fr 1fr; gap: 48px; padding: 40px; } }

/* ---------- FAQ ---------- */
.rk-faq { display: grid; gap: 10px; max-width: 860px; }
.rk-faq__item { border: 1px solid var(--ac-border); border-radius: 12px; background: var(--ac-surface); }
.rk-faq__item[open] { border-color: rgba(61, 230, 214, .4); }
.rk-faq__item summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; padding: 12px 20px; cursor: pointer; font-weight: 700; list-style: none; }
.rk-faq__item summary::-webkit-details-marker { display: none; }
.rk-faq__item summary::after { content: "+"; color: var(--rk-cyan); font-size: 1.5rem; line-height: 1; flex: none; }
.rk-faq__item[open] summary::after { content: "\2212"; }
.rk-faq__item p { padding: 0 20px 18px; color: var(--ac-muted); max-width: 70ch; }
.rk-faq__item p a { text-decoration: underline; }

/* ---------- Music cross-link / next steps / nightly ---------- */
.rk-music, .rk-nightly {
	display: grid; gap: 20px; padding: 24px; border: 1px solid var(--ac-border); border-radius: calc(var(--ac-radius) + 4px);
	background: linear-gradient(135deg, rgba(251, 95, 171, .18), rgba(142, 92, 255, .14));
}
.rk-nightly { background: var(--ac-surface); align-items: center; }
.rk-music p, .rk-nightly p { color: var(--ac-muted); max-width: 56ch; }
.rk-music .rk-h, .rk-nightly .rk-h { margin-bottom: 8px; }
.rk-music__cta { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.rk-nightly .ac-rel__btn { justify-self: start; }
@media (min-width: 700px) { .rk-music__cta { flex-direction: row; flex-wrap: wrap; } }
@media (min-width: 922px) { .rk-music, .rk-nightly { grid-template-columns: 1.3fr 1fr; gap: 40px; padding: 36px 40px; align-items: center; } .rk-music__cta { justify-content: flex-end; } .rk-nightly .ac-rel__btn { justify-self: end; } }

/* ---------- Install steps ---------- */
.rk-steps { display: grid; gap: 14px; counter-reset: rk; }
.rk-steps li { margin: 0; padding: 22px; border: 1px solid var(--ac-border); border-radius: var(--ac-radius); background: var(--ac-surface); counter-increment: rk; }
.rk-steps li::before { content: counter(rk); display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--rk-cyan-dim); border: 1px solid rgba(61, 230, 214, .5); color: var(--rk-cyan); font-weight: 800; margin-bottom: 12px; }
.ac-rack .rk-steps h3 { font-size: 1.125rem; font-weight: 800; margin-bottom: 8px; }
.rk-steps p { color: var(--ac-muted); font-size: .9375rem; }
@media (min-width: 800px) { .rk-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

@media (prefers-reduced-motion: reduce) {
	.ac-rack *, .ac-rack *::before, .ac-rack *::after { transition: none !important; }
}

/* Compact OS cards inside the hub's download block: head + main file only (all files are on the download page). */
.rk-dl .rk-os__note, .rk-dl .rk-files li:not(:first-child) { display: none; }
.rk-dl .rk-os__card { padding: 14px 16px; gap: 10px; }
.ac-rack .rk-btn-lg { white-space: nowrap; }
.rk-dl__cta, .rk-hero__cta { flex-wrap: wrap; }

/* ---------- Screenshots (hero, feature rows, gallery, zoom dialog) ---------- */
.rk-shot { margin: 0; border-radius: 16px; overflow: hidden; background: #0d0c14; line-height: 0;
	box-shadow: 0 0 0 1px rgba(61, 230, 214, .38), 0 0 44px rgba(61, 230, 214, .16), 0 24px 60px rgba(0, 0, 0, .55); }
.rk-shot img, .rk-shot__img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.rk-shot--hero { box-shadow: 0 0 0 1px rgba(61, 230, 214, .5), 0 0 70px rgba(61, 230, 214, .24), 0 30px 80px rgba(0, 0, 0, .6); border-radius: 18px; }
.rk-hero__shot { min-width: 0; }

/* Watch the tour */
.rk-tour { display: grid; gap: 22px; align-items: center; }
.rk-tour__text p { color: var(--ac-muted); max-width: 46ch; margin-bottom: 8px; }
.rk-tour__video { min-width: 0; }
.rk-tour__video .ac-rel__embed { box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 0 50px rgba(61, 230, 214, .18), 0 24px 60px rgba(0, 0, 0, .55); border-radius: 16px; }
@media (min-width: 800px) { .rk-tour { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 40px; } }

/* Feature rows: screenshot beside the text, alternating */
.rk-show { display: grid; gap: 40px; margin-bottom: 8px; }
.rk-show__row { margin: 0; display: grid; gap: 18px; align-items: center; }
.rk-show__text { min-width: 0; }
.ac-rack .rk-show__text h3 { font-size: clamp(1.25rem, 3.5vw, 1.5rem); font-weight: 800; line-height: 1.2; margin-bottom: 10px; }
.rk-show__text p { color: var(--ac-muted); font-size: 1rem; max-width: 46ch; }
.ac-rack .rk-subh { font-size: 1.25rem; font-weight: 800; margin: 44px 0 16px; }
@media (min-width: 800px) {
	.rk-show { gap: 56px; }
	.rk-show__row { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 40px; }
	.rk-show__row:nth-child(even) { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); }
	.rk-show__row:nth-child(even) .rk-shot { order: 2; }
}

/* Gallery strip: horizontal scroll with snap on phones, a grid on desktop */
.rk-gal { position: relative; display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 14px; margin: 0; list-style: none; -webkit-overflow-scrolling: touch; scrollbar-color: rgba(61, 230, 214, .5) transparent; }
.rk-gal li { margin: 0; flex: 0 0 72%; scroll-snap-align: start; min-width: 0; }
.ac-rack a.rk-gal__a { position: relative; display: block; color: var(--ac-text); text-decoration: none; }
.rk-gal__img { display: block; border-radius: 12px; overflow: hidden; line-height: 0; background: #0d0c14; box-shadow: 0 0 0 1px rgba(61, 230, 214, .28), 0 12px 30px rgba(0, 0, 0, .45); transition: box-shadow .15s ease, transform .15s ease; }
.rk-gal__a:hover .rk-gal__img { box-shadow: 0 0 0 1px var(--rk-cyan), 0 0 28px rgba(61, 230, 214, .3), 0 12px 30px rgba(0, 0, 0, .45); transform: translateY(-2px); }
.rk-gal__cap { display: block; margin-top: 8px; font-size: .875rem; font-weight: 700; color: var(--ac-muted); line-height: 1.3; }
.rk-gal__a:hover .rk-gal__cap { color: #fff; }
.ac-rack a.rk-gal__a:focus-visible { outline-offset: 5px; }
@media (min-width: 700px) {
	.rk-gal { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: visible; gap: 18px; padding-bottom: 0; }
	.rk-gal li { flex: none; }
}
.rk-gal__hint { margin: 0 !important; }

dialog.rk-zoom { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 96vh; width: auto; overflow: visible; color: #fff; }
dialog.rk-zoom::backdrop { background: rgba(5, 4, 9, .88); }
.rk-zoom__fig { margin: 0; display: grid; gap: 10px; justify-items: center; }
.rk-zoom__fig img { display: block; max-width: 96vw; max-height: calc(96vh - 90px); width: auto; height: auto; border-radius: 12px; box-shadow: 0 0 0 1px rgba(61, 230, 214, .5), 0 0 60px rgba(61, 230, 214, .22); }
.rk-zoom__cap { font-size: .9375rem; color: #cfcbe0; text-align: center; max-width: 80ch; }
.rk-zoom__close { position: absolute; top: -8px; right: -8px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .4); background: #14121d; color: #fff; font-size: 24px; line-height: 1; cursor: pointer; display: grid; place-items: center; z-index: 2; }
.rk-zoom__close:hover { border-color: #31e0d0; color: #31e0d0; }
.rk-zoom__close:focus-visible { outline: 2px solid #31e0d0; outline-offset: 3px; }
@media (max-width: 600px) { .rk-zoom__close { top: 4px; right: 4px; } }
