/* ════════════════════════════════════════════════════════════════════
   VIDEOS — shared stylesheet for /videos, the video index.

   Self-contained page chrome: tokens, navbar, footer, and the card grid.
   Same design language as guides.css (DM Serif + DM Sans, dark UI,
   purple/pink accent) so the hub reads as part of the site.

   This is a hub, not an article. It indexes the videos and points each
   one at the article it belongs to — it never restates the article's
   content, so it competes with nothing.
   ════════════════════════════════════════════════════════════════════ */

:root {
	--bg:            #080810;
	--bg-card:       #0f0f1a;
	--bg-surface:    #13131f;
	--purple:        #7c3aed;
	--purple-mid:    #9d5ff5;
	--purple-light:  #c4a8ff;
	--pink:          #e879f9;
	--text:          #e8e4f0;
	--text-muted:    #8b82a7;
	--border:        rgba(124, 58, 237, .18);
	--border-strong: rgba(124, 58, 237, .32);
	--serif:         'DM Serif Display', Georgia, serif;
	--sans:          'DM Sans', system-ui, -apple-system, sans-serif;
	--gradient:      linear-gradient(135deg, #7c3aed 0%, #e879f9 100%);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
	background: var(--bg);
	color: var(--text);
	font-family: var(--sans);
	font-size: 16px;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

a { color: var(--purple-light); }
img { max-width: 100%; display: block; }

.skip-link {
	position: absolute; left: -9999px; top: 0; z-index: 100;
	background: var(--purple); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ── Navbar ───────────────────────────────────────────────────────── */
.navbar {
	position: sticky; top: 0; z-index: 50;
	background: rgba(8, 8, 16, .82);
	backdrop-filter: blur(14px);
	border-bottom: 1px solid var(--border);
}
.nav-container {
	max-width: 1200px; margin: 0 auto; padding: 14px 24px;
	display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
/* Width cap, not just height: the logo asset is 198px wide and was the
   single largest cause of horizontal overflow on small screens. */
.nav-logo img { height: 34px; width: auto; max-width: 150px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-link { color: var(--text-muted); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav-link:hover { color: var(--text); }
.nav-cta-pink {
	background: var(--gradient); color: #fff; text-decoration: none;
	padding: 10px 18px; border-radius: 999px; font-size: 14px; font-weight: 700;
	white-space: nowrap;
}
/* This nav carries one more item than blog.html's, which is enough to push it
   past a 390px viewport: measured 501px of content in a 390px window, and a
   document wider than the viewport is what stops a sticky header spanning it.
   Below 560px the two links that exist elsewhere on the page (Home is the
   logo, Blog is in the footer) drop out; Demo and the CTA stay, because those
   are the two the nav is actually for. */
@media (max-width: 560px) {
	.nav-container { padding: 12px 16px; gap: 10px; }
	.nav-logo img { max-width: 112px; height: 30px; }
	.nav-links { gap: 12px; }
	.nav-hide-mobile { display: none; }
	.nav-hide-small { display: none; }
	.nav-link { font-size: 14px; }
	.nav-cta-pink { padding: 9px 13px; font-size: 12.5px; }
}

/* ── Hero ─────────────────────────────────────────────────────────── */
.vh-hero { max-width: 900px; margin: 0 auto; padding: 64px 24px 40px; text-align: center; }
.vh-badge {
	display: inline-flex; align-items: center; gap: 8px;
	border: 1px solid var(--border-strong); border-radius: 999px;
	padding: 6px 14px; font-size: 12px; font-weight: 600;
	letter-spacing: .08em; text-transform: uppercase; color: var(--purple-light);
	margin-bottom: 20px;
}
.vh-badge::before {
	content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--pink);
}
.vh-hero h1 {
	font-family: var(--serif); font-weight: 400;
	font-size: clamp(34px, 6vw, 56px); line-height: 1.12; letter-spacing: -.02em;
	color: #fff; margin-bottom: 18px;
}
.vh-hero h1 em { font-style: normal; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.vh-lede { font-size: 18px; color: var(--text-muted); max-width: 680px; margin: 0 auto; }

/* ── Grid ─────────────────────────────────────────────────────────── */
.vh-grid {
	max-width: 1200px; margin: 0 auto; padding: 24px 24px 80px;
	display: grid; gap: 28px;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
}
/* minmax(320px,1fr) with an explicit min-width:0 on the item — a grid item
   defaults to min-width:auto, which lets a long unbroken string widen the
   whole document and stop a sticky header spanning it. */
.vh-card {
	min-width: 0;
	background: var(--bg-card);
	border: 1px solid var(--border);
	border-radius: 14px;
	overflow: hidden;
	display: flex; flex-direction: column;
	transition: border-color .2s ease, transform .2s ease;
}
.vh-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.vh-thumb { position: relative; aspect-ratio: 16 / 9; background: #000; }
.vh-thumb img { width: 100%; height: 100%; object-fit: cover; }
.vh-dur {
	position: absolute; right: 8px; bottom: 8px;
	background: rgba(0, 0, 0, .82); color: #fff;
	font-size: 12px; font-weight: 600; padding: 2px 7px; border-radius: 4px;
	font-variant-numeric: tabular-nums;
}
.vh-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.vh-card h2 {
	font-family: var(--serif); font-weight: 400; font-size: 20px;
	line-height: 1.3; color: #fff; margin: 0;
}
.vh-card h2 a { color: inherit; text-decoration: none; }
.vh-card h2 a:hover { color: var(--purple-light); }
.vh-desc { font-size: 14.5px; color: var(--text-muted); margin: 0; }
.vh-links {
	display: flex; flex-wrap: wrap; gap: 10px 18px;
	margin-top: auto; padding-top: 6px; font-size: 14px; font-weight: 600;
}
.vh-links a { text-decoration: none; }
.vh-links a:hover { text-decoration: underline; }
.vh-meta { font-size: 13px; color: var(--text-muted); }

/* ── Footer ───────────────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--border); padding: 40px 24px; }
.footer-container { max-width: 1200px; margin: 0 auto; text-align: center; display: grid; gap: 16px; justify-items: center; }
.footer-logo { height: 30px; width: auto; max-width: 150px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; justify-content: center; }
.footer-link { color: var(--text-muted); text-decoration: none; font-size: 14px; }
.footer-link:hover { color: var(--text); }
.footer-copyright { font-size: 13px; color: var(--text-muted); }
