/* StarrTrax — sandbox redesign
   One stylesheet for index.html and jobs.html. No frameworks. */

:root {
	--bg: #050b14;
	--panel: rgba(14, 26, 42, 0.62);
	--panel-solid: #0c1726;
	--line: rgba(255, 255, 255, 0.14);
	--line-strong: rgba(255, 255, 255, 0.32);
	--text: #e9eff6;
	--muted: #9db0c4;
	--accent: #4cc3e6;      /* between the brand teal #6acbd5 and blue #2eb2e4 */
	--accent-deep: #0e5581;
	--warm: #f79031;
	--radius: 10px;
	--wrap: 1120px;
	--font: "Source Sans 3", "Source Sans Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
	margin: 0;
	background: radial-gradient(ellipse at 50% 0%, #0d2238 0%, var(--bg) 60%) fixed, var(--bg);
	color: var(--text);
	font: 300 1.0625rem/1.65 var(--font);
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { font-weight: 600; line-height: 1.2; margin: 0 0 .6em; }
p { margin: 0 0 1em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Animated fiber-optic background (assets/fiber.js) */
#fiber { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }

.wrap { width: min(var(--wrap), 100% - 2.5rem); margin-inline: auto; }

/* ---------- Eyebrow / headings ---------- */
.eyebrow {
	display: block;
	font-size: .78rem;
	font-weight: 600;
	letter-spacing: .28em;
	text-transform: uppercase;
	color: var(--accent);
	margin-bottom: .8rem;
}
.section-title {
	font-size: clamp(1.6rem, 3.2vw, 2.3rem);
	font-weight: 300;
	letter-spacing: .04em;
}

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: .5em;
	padding: .8em 1.6em;
	border: 1px solid var(--line-strong);
	border-radius: 999px;
	background: transparent;
	color: var(--text);
	font: 600 .8rem/1 var(--font);
	letter-spacing: .2em;
	text-transform: uppercase;
	cursor: pointer;
	transition: background .2s, border-color .2s, color .2s;
}
.btn:hover { background: rgba(255, 255, 255, .08); border-color: var(--text); text-decoration: none; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #04121c; }
.btn-primary:hover { background: #7ad5ef; border-color: #7ad5ef; }
.btn[disabled] { opacity: .5; cursor: progress; }

/* ---------- Top bar (appears after the hero) ---------- */
.topbar {
	position: fixed; inset: 0 0 auto 0; z-index: 50;
	background: rgba(5, 11, 20, .78);
	backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
	border-bottom: 1px solid var(--line);
	transform: translateY(-100%);
	transition: transform .35s ease;
}
.topbar.show, .topbar.always { transform: none; }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 1rem; }
.topbar .brand img { height: 32px; width: auto; }
.topbar nav { display: flex; align-items: center; gap: 1.6rem; }
.topbar nav a {
	color: var(--text); font-size: .78rem; font-weight: 600;
	letter-spacing: .2em; text-transform: uppercase; opacity: .75;
}
.topbar nav a:hover, .topbar nav a.active { opacity: 1; text-decoration: none; color: var(--accent); }
.topbar nav .btn { padding: .6em 1.2em; opacity: 1; }
.menu-toggle { display: none; background: none; border: 0; color: var(--text); padding: .4rem; cursor: pointer; }
.menu-toggle svg { width: 26px; height: 26px; }

@media (max-width: 760px) {
	.menu-toggle { display: block; }
	.topbar nav {
		position: absolute; top: 60px; left: 0; right: 0;
		flex-direction: column; gap: 0; align-items: stretch;
		background: rgba(5, 11, 20, .96);
		border-bottom: 1px solid var(--line);
		display: none;
	}
	.topbar.open nav { display: flex; }
	.topbar nav a { padding: 1rem 1.25rem; border-top: 1px solid var(--line); }
	.topbar nav .btn { margin: 1rem 1.25rem; }
}

/* ---------- Hero (the Dimension-style centered intro) ---------- */
.hero {
	min-height: 100vh; min-height: 100svh;
	display: flex; flex-direction: column; align-items: center; justify-content: center;
	text-align: center; padding: 3rem 1.25rem;
	position: relative;
	isolation: isolate;
}
/* Borderless frosted area behind the intro and footer: the blur fades out
   toward the edges, so the fibers stay crisp at the margins and calm behind the text. */
.hero::before, footer.site::before {
	content: "";
	position: absolute; inset: 6% 0;
	z-index: -1;
	-webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
	-webkit-mask-image: radial-gradient(ellipse closest-side, #000 55%, transparent 100%);
	mask-image: radial-gradient(ellipse closest-side, #000 55%, transparent 100%);
	pointer-events: none;
}
.hero .logo { width: min(440px, 80vw); height: auto; margin-bottom: 1.8rem; filter: drop-shadow(0 6px 30px rgba(76, 195, 230, .25)); }
.hero h1 {
	font-size: clamp(1.05rem, 2.6vw, 1.5rem); font-weight: 400;
	letter-spacing: .3em; text-transform: uppercase; margin: 0;
}
.hero p.lede { color: var(--muted); max-width: 40rem; margin: .9rem auto 0; font-size: clamp(1rem, 1.8vw, 1.15rem); }

/* the bordered nav strip from cloud91 */
.hero-nav {
	display: flex; margin-top: 2.4rem;
	border: 1px solid var(--line-strong); border-radius: var(--radius);
	overflow: hidden;
}
.hero-nav a {
	padding: 1rem 1.6rem; color: var(--text);
	font-size: .8rem; font-weight: 600; letter-spacing: .24em; text-transform: uppercase;
	border-left: 1px solid var(--line-strong);
	transition: background .2s;
}
.hero-nav a:first-child { border-left: 0; }
.hero-nav a:hover { background: rgba(255, 255, 255, .08); text-decoration: none; }
.hero-nav a.hot { color: var(--accent); }
@media (max-width: 560px) {
	.hero-nav { flex-wrap: wrap; width: 100%; max-width: 22rem; }
	.hero-nav a { flex: 1 1 50%; border-left: 0; border-top: 1px solid var(--line-strong); padding: .95rem .5rem; }
	.hero-nav a:nth-child(-n+2) { border-top: 0; }
	.hero-nav a:nth-child(even) { border-left: 1px solid var(--line-strong); }
}
.scroll-cue {
	position: absolute; bottom: 1.6rem; left: 50%; transform: translateX(-50%);
	color: var(--muted); opacity: .7; animation: bob 2.4s ease-in-out infinite;
}
.scroll-cue svg { width: 22px; height: 22px; }
@keyframes bob { 50% { transform: translate(-50%, 6px); } }

/* ---------- Sections ---------- */
section.block { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.panel {
	background: var(--panel);
	backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: clamp(1.5rem, 4vw, 3rem);
}
.intro { max-width: 52rem; font-size: clamp(1.1rem, 2vw, 1.3rem); color: var(--text); }

/* Fade-and-lift reveal (echoes the Dimension article transition) */
.reveal { opacity: 0; transform: translateY(24px) scale(.985); filter: blur(4px); transition: opacity .8s ease, transform .8s ease, filter .8s ease; }
.reveal.in { opacity: 1; transform: none; filter: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; filter: none; transition: none; } }

.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 700px) { .grid-2 { grid-template-columns: 1fr; } }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }

.feature { border-top: 1px solid var(--line-strong); padding-top: 1.2rem; }
.feature h3 { font-size: 1.15rem; font-weight: 600; letter-spacing: .02em; display: flex; gap: .6rem; align-items: center; }
.feature h3 svg { width: 22px; height: 22px; color: var(--accent); flex: none; }
.feature p { color: var(--muted); margin: 0; }

/* "Who we place" chips */
.placements { margin-top: 2.5rem; }
.placements h4 { font-size: .78rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: .8rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: 0; }
.chips li { border: 1px solid var(--line); border-radius: 999px; padding: .3em .9em; font-size: .92rem; color: var(--text); }

/* ---------- Job cards (home + jobs page) ---------- */
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.section-head .section-title { margin: 0; }

.job-card {
	display: flex; flex-direction: column; gap: .35rem;
	padding: 1.2rem 1.3rem;
	background: rgba(14, 26, 42, .5);
	-webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
	border: 1px solid var(--line); border-radius: var(--radius);
	color: var(--text);
	transition: border-color .2s, background .2s, transform .2s;
}
.job-card:hover { border-color: var(--accent); background: rgba(18, 40, 62, .62); text-decoration: none; transform: translateY(-2px); }
.job-card .title { font-size: 1.12rem; font-weight: 600; }
.job-card .meta { display: flex; flex-wrap: wrap; gap: .3rem 1rem; font-size: .9rem; color: var(--muted); }
.job-card .meta span { display: inline-flex; align-items: center; gap: .35rem; }
.job-card .meta svg { width: 15px; height: 15px; opacity: .8; }
.job-card .pay { color: var(--accent); font-weight: 600; }
.job-card .date { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); opacity: .8; }

.status { color: var(--muted); padding: 1rem 0; }

/* ---------- Team ---------- */
/* Leadership row (4) over a centred row (3). Desktop: 4 across.
   Phones: 2 across, so rows split 2+2 and 2+1 (centred), never 3+1. */
.team { display: flex; flex-direction: column; gap: 2.5rem; }
.team-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 2rem 1.25rem; }
.person { text-align: center; width: min(210px, (100% - 3 * 1.25rem) / 4); }
@media (max-width: 760px) {
	.team { gap: 2rem; }
	.person { width: calc((100% - 1.25rem) / 2); }
}
.person img {
	width: min(132px, 100%); height: auto; aspect-ratio: 1; object-fit: cover; margin: 0 auto 1rem;
	border-radius: 50%; border: 1px solid var(--line-strong);
	filter: grayscale(.25);
	transition: filter .3s, border-color .3s;
}
.person:hover img { filter: none; border-color: var(--accent); }
.person h3 { font-size: 1.05rem; margin: 0; font-weight: 600; }
.person .role { display: block; color: var(--muted); font-size: .9rem; }
.person .links { display: flex; justify-content: center; gap: .5rem; margin-top: .6rem; }
.icon-link {
	display: inline-grid; place-items: center; width: 34px; height: 34px;
	border: 1px solid var(--line); border-radius: 50%; color: var(--muted);
	transition: color .2s, border-color .2s;
}
.icon-link:hover { color: var(--accent); border-color: var(--accent); }
.icon-link svg { width: 16px; height: 16px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.contact-item { display: flex; gap: 1rem; align-items: flex-start; }
.contact-item svg { width: 26px; height: 26px; color: var(--accent); flex: none; margin-top: .2rem; }
.contact-item h3 { font-size: .78rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin-bottom: .3rem; }
.contact-item p { margin: 0; font-size: 1.1rem; }
.contact-item a { color: var(--text); }

/* ---------- Footer ---------- */
footer.site {
	padding: 2.5rem 0 3rem; text-align: center; color: var(--muted); font-size: .88rem;
	position: relative;
	isolation: isolate;
}
footer.site::before { inset: 0; }
footer.site .social { display: flex; justify-content: center; gap: .6rem; margin-bottom: 1rem; }

/* ======================================================================
   Jobs page
   ====================================================================== */
.jobs-page { padding-top: 60px; }
.jobs-hero { padding: clamp(2.5rem, 6vw, 4rem) 0 1.5rem; }
.jobs-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 300; letter-spacing: .04em; margin: 0; }
.jobs-hero p { color: var(--muted); margin: .4rem 0 0; }

.filters {
	display: grid; gap: .75rem;
	grid-template-columns: 2fr 1fr 1fr;
	position: sticky; top: 60px; z-index: 10;
	padding: 1rem 0;
	background: linear-gradient(var(--bg) 70%, transparent);
}
@media (max-width: 760px) { .filters { grid-template-columns: 1fr 1fr; } .filters .search { grid-column: 1 / -1; } }

.field, .filters input, .filters select {
	width: 100%;
	padding: .8rem 1rem;
	background: rgba(255, 255, 255, .05);
	border: 1px solid var(--line);
	border-radius: 8px;
	color: var(--text);
	font: 400 1rem var(--font);
	appearance: none; -webkit-appearance: none;
}
.filters select {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%239db0c4' stroke-width='1.6'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.4rem;
}
.filters select option { background: var(--panel-solid); color: var(--text); }
.field:focus, .filters input:focus, .filters select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(76, 195, 230, .2); }

.job-list { display: grid; gap: .75rem; padding-bottom: 4rem; }
.result-count { color: var(--muted); font-size: .9rem; margin: .25rem 0 1rem; }
.clear-link { background: none; border: 0; color: var(--accent); cursor: pointer; font: inherit; padding: 0; margin-left: .5rem; }

/* Job detail: a Dimension-style "article" that fades in over the page */
.overlay {
	position: fixed; inset: 0; z-index: 100;
	background: rgba(3, 7, 13, .72);
	backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
	display: flex; justify-content: center; align-items: flex-start;
	overflow-y: auto; padding: 4vh 1rem;
	opacity: 0; visibility: hidden;
	transition: opacity .3s ease, visibility 0s linear .3s;
}
.overlay.open { opacity: 1; visibility: visible; transition: opacity .3s ease; }
.article {
	position: relative; width: min(820px, 100%);
	background: var(--panel-solid);
	border: 1px solid var(--line); border-radius: var(--radius);
	padding: clamp(1.5rem, 4vw, 3rem);
	transform: translateY(20px) scale(.98); opacity: 0;
	transition: transform .4s ease .05s, opacity .4s ease .05s;
}
.overlay.open .article { transform: none; opacity: 1; }
@media (max-width: 600px) {
	.overlay { padding: 0; }
	.article { border-radius: 0; min-height: 100%; border: 0; }
}
.close {
	position: absolute; top: .8rem; right: .8rem;
	width: 42px; height: 42px; border-radius: 50%;
	background: none; border: 1px solid transparent; color: var(--muted); cursor: pointer;
	display: grid; place-items: center;
}
.close:hover { border-color: var(--line-strong); color: var(--text); }
.close svg { width: 20px; height: 20px; }
.article h2 { font-size: clamp(1.5rem, 3.5vw, 2rem); font-weight: 400; padding-right: 2.5rem; }
.article .meta { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1.4rem; }
.article .meta span { border: 1px solid var(--line); border-radius: 999px; padding: .25em .85em; font-size: .9rem; color: var(--muted); }
.article .meta .pay { color: var(--accent); border-color: rgba(76, 195, 230, .5); }
.article .actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-bottom: 2rem; }

.description { color: #cdd8e4; border-top: 1px solid var(--line); padding-top: 1.6rem; }
.description h4 { color: var(--text); font-size: 1.05rem; margin-top: 1.4em; }
.description ul, .description ol { padding-left: 1.3rem; }
.description li { margin-bottom: .35em; }
.description strong, .description b { color: var(--text); font-weight: 600; }
.description table { border-collapse: collapse; width: 100%; }
.description td, .description th { border: 1px solid var(--line); padding: .4em .6em; }

/* Apply form */
.apply { margin-top: 2.5rem; border-top: 1px solid var(--line); padding-top: 1.8rem; }
.apply h3 { font-weight: 400; font-size: 1.4rem; }
.form-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }
.form-grid label { display: block; font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: .4rem; font-weight: 600; }
.file-drop {
	display: flex; align-items: center; gap: 1rem;
	border: 1px dashed var(--line-strong); border-radius: 8px; padding: 1rem;
	cursor: pointer; color: var(--muted);
}
.file-drop:hover, .file-drop.drag { border-color: var(--accent); color: var(--text); }
.file-drop svg { width: 26px; height: 26px; color: var(--accent); flex: none; }
.file-drop input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.form-note { font-size: .85rem; color: var(--muted); }
.form-msg { margin-top: 1rem; padding: .9rem 1rem; border-radius: 8px; display: none; }
.form-msg.error { display: block; background: rgba(229, 72, 86, .12); border: 1px solid rgba(229, 72, 86, .5); color: #ffb4bb; }
.form-msg.ok { display: block; background: rgba(149, 189, 61, .12); border: 1px solid rgba(149, 189, 61, .5); color: #d4f0a0; }

body.locked { overflow: hidden; }
