/* Greyhive creator intake. Dark only, brand tokens from the workspace design system. */
:root {
  --bg: #0B0B0D;
  --bg-2: #111115;
  --card: #17171D;
  --card-hover: #1E1E26;
  --surface: #252530;
  --gold: #BBA777;
  --gold-hover: #D4C49A;
  --gold-muted: #8A7C58;
  --blue: #00A3E0;
  --blue-hover: #33B8E8;
  --text: #E8E6E1;
  --text-mid: #A0A0AC;
  --text-dim: #6A6A78;
  --green: #4ADE80;
  --red: #D40000;
  --red-text: #FF6B6B; /* readable red for text on dark; --red is for fills and borders */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --display: 'Bebas Neue', Impact, 'Arial Narrow', sans-serif;
  --body: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Space Mono', ui-monospace, Menlo, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.55 var(--body);
  min-height: 100vh;
}
/* Film grain, about 5% */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .05;
  z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  padding: 48px 16px 96px;
}
@media (min-width: 720px) { .wrap { padding: 88px 28px 120px; } }

/* Header */
.brand {
  display: block;
  width: 180px;
  height: auto;
  margin: 0 0 28px;
}
h1 {
  margin: 0;
  font: 400 clamp(52px, 11vw, 88px)/.92 var(--display);
  letter-spacing: .02em;
  text-transform: uppercase;
}
.lede {
  margin: 16px 0 0;
  max-width: 52ch;
  color: var(--text-mid);
  font-size: 17px;
}
.top { margin-bottom: 40px; animation: rise .8s var(--ease) both; }
#main { animation: rise .8s var(--ease) .08s both; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

/* Sections: separated by rules, not boxed */
.sec {
  padding: 36px 0 12px;
  border-top: 1px solid var(--surface);
}
.sec-last { padding-top: 28px; }
.sec h2 {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 0 0 24px;
  font: 400 32px/1 var(--display);
  letter-spacing: .03em;
  text-transform: uppercase;
}
.num {
  font: 700 12px/1 var(--mono);
  letter-spacing: .1em;
  color: var(--gold);
}

/* Fields */
.field { margin-bottom: 26px; }
label, legend {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  font-size: 15px;
}
.label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}
.opt {
  margin-left: 6px;
  font: 400 11px/1 var(--mono);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--text-dim);
}
input[type=text], input[type=email], input[type=url], input[type=tel], input[type=password], textarea, select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  background: var(--bg-2);
  color: var(--text);
  border: 1px solid var(--surface);
  border-radius: 8px;
  font: 400 16px/1.4 var(--body);
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
textarea { resize: vertical; min-height: 120px; }
select {
  appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23BBA777' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}
input::placeholder, textarea::placeholder { color: var(--text-dim); }
input:hover:not([readonly]), textarea:hover, select:hover { border-color: #33333F; background-color: var(--card); }
input[readonly] { color: var(--text-mid); background: transparent; border-style: dashed; }
input[aria-invalid=true] { border-color: var(--red); }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
input:focus-visible, textarea:focus-visible, select:focus-visible { outline-offset: 0; border-color: var(--gold); }

.hint {
  margin: 8px 0 0;
  max-width: 62ch;
  font-size: 14px;
  color: var(--text-mid);
}
.hint.err { color: var(--red-text); }
.hint code, .status code {
  font: 400 13px var(--mono);
  color: var(--text);
  background: var(--card);
  padding: 1px 5px;
  border-radius: 4px;
}
.note {
  margin: -8px 0 24px;
  color: var(--text-mid);
  max-width: 60ch;
}
#member-note { color: var(--gold-hover); }
.mini-label {
  margin: 0 0 8px;
  font: 700 11px/1 var(--mono);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* Live status under a field */
.status { font-size: 14px; }
.status:not(:empty) { margin-top: 8px; }
.status.ok { color: var(--green); }
.status.err { color: var(--red-text); }
.status.busy { color: var(--text-dim); }
.status p { margin: 0; }
/* Show/hide password: a text button inside the field, so a typo can be seen before submit. */
.pw { position: relative; }
.pw input { padding-right: 76px; }
.pw-toggle {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  min-width: 60px;
  min-height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--gold);
  font: 400 12px var(--mono);
  text-transform: uppercase;
  letter-spacing: .04em;
  cursor: pointer;
  transition: color .2s var(--ease);
}
.pw-toggle:hover { color: var(--gold-hover); }
.suggest {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.pill {
  min-height: 36px;
  padding: 6px 14px;
  border: 1px solid var(--gold-muted);
  border-radius: 100px;
  background: transparent;
  color: var(--gold);
  font: 400 13px var(--mono);
  cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.pill:hover, .pill[aria-pressed="true"] { background: var(--gold); color: var(--bg); }

.btn-link {
  padding: 4px 0;
  margin-bottom: 8px;
  background: none;
  border: 0;
  color: var(--blue);
  font: 500 14px var(--body);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.btn-link:hover { color: var(--blue-hover); }

/* Channel preview */
.preview {
  margin-top: 14px;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--surface);
  border-radius: 10px;
}
.preview-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.preview-avatar {
  width: 56px;
  height: 56px;
  flex: none;
  border-radius: 50%;
  object-fit: cover;
  background: var(--surface);
}
.preview-name { margin: 0; font-weight: 700; font-size: 17px; }
.preview-url {
  margin: 2px 0 0;
  font: 400 12px var(--mono);
  color: var(--text-dim);
  overflow-wrap: anywhere;
}
.titles {
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}
.titles li {
  padding: 8px 0;
  border-top: 1px solid var(--surface);
  color: var(--text-mid);
  font-size: 14px;
}
.confirm { margin: 0; padding: 0; border: 0; }
.confirm legend { margin-bottom: 10px; }
.confirm .choice { display: inline-flex; margin-right: 20px; }

/* Radios, checkbox */
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.choices { display: grid; gap: 10px; margin-bottom: 20px; }
@media (min-width: 560px) { .choices { grid-template-columns: 1fr 1fr; } }
.choice {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  margin: 0;
  font-weight: 400;
  cursor: pointer;
}
.choices .choice {
  padding: 10px 14px;
  border: 1px solid var(--surface);
  border-radius: 8px;
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.choices .choice:hover { background: var(--card); }
.choices .choice:has(input:checked) { border-color: var(--gold); background: var(--card); }
input[type=radio], input[type=checkbox] {
  width: 18px;
  height: 18px;
  margin: 0;
  flex: none;
  accent-color: var(--gold);
}
.check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 32px;
  font-weight: 400;
  cursor: pointer;
}
.check input { margin-top: 3px; }
.hint-inline { display: block; margin-top: 2px; font-size: 14px; color: var(--text-mid); }

/* Images */
.source-images { position: relative; margin-bottom: 24px; padding-bottom: 36px; }
.src-banner {
  display: block;
  width: 100%;
  aspect-ratio: 6 / 1;
  object-fit: cover;
  border-radius: 8px;
  background: var(--card);
}
.src-avatar {
  position: absolute;
  left: 16px;
  bottom: 0;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--bg);
  background: var(--surface);
}
#src-banner-none { margin-left: 100px; }

input[type=file] {
  width: 100%;
  color: var(--text-mid);
  font: 400 14px var(--body);
}
input[type=file]::file-selector-button {
  margin-right: 12px;
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid var(--gold-muted);
  border-radius: 6px;
  background: transparent;
  color: var(--gold);
  font: 500 14px var(--body);
  cursor: pointer;
}
input[type=file]::file-selector-button:hover { border-color: var(--gold); color: var(--gold-hover); }

.crop { margin-top: 14px; }
.crop-canvas {
  display: block;
  width: 100%;
  margin-bottom: 14px;
  border: 1px solid var(--surface);
  border-radius: 8px;
  background: var(--bg-2);
  cursor: grab;
  touch-action: none;
}
.crop-canvas:active { cursor: grabbing; }
.crop-square { max-width: 240px; aspect-ratio: 1; border-radius: 50%; }
.crop-wide { aspect-ratio: 6 / 1; }
input[type=range] { width: 100%; max-width: 320px; accent-color: var(--gold); }

/* Errors summary */
.errors {
  margin: 0 0 32px;
  padding: 18px 20px;
  background: rgba(212, 0, 0, .1);
  border: 1px solid var(--red);
  border-radius: 10px;
}
.errors-title { margin: 0 0 8px; font-weight: 700; }
.errors ul { margin: 0; padding-left: 20px; color: var(--text); }
.errors li + li { margin-top: 4px; }

/* Submit */
.btn {
  width: 100%;
  min-height: 56px;
  padding: 14px 28px;
  background: var(--gold);
  color: var(--bg);
  border: 0;
  border-radius: 6px;
  font: 400 24px/1 var(--display);
  letter-spacing: .05em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color .2s var(--ease), transform .2s var(--ease);
}
@media (min-width: 560px) { .btn { width: auto; min-width: 280px; } }
.btn:hover { background: var(--gold-hover); }
.btn:active { transform: translateY(1px); }
.btn:disabled { background: var(--gold-muted); cursor: progress; }

/* Application page (/apply) */
.wrap.wide { max-width: 1000px; }
.hero { text-align: center; }
.hero .brand { margin: 0 auto 36px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px; margin: 0 0 18px;
  font: 400 12px/1 var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--gold);
}
.eyebrow::before, .eyebrow::after { content: ''; width: 24px; height: 1px; background: var(--gold-muted); }
.hero h1 { font-size: clamp(48px, 9vw, 96px); }
.gold { color: var(--gold); }
.hero .lede { margin: 20px auto 0; text-align: center; }
.cards { display: grid; gap: 16px; margin: 40px 0 0; padding: 0; list-style: none; text-align: center; }
@media (min-width: 720px) { .cards { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.cards li { padding: 24px 20px; background: var(--card); border: 1px solid var(--surface); border-radius: 10px; }
.cards h2 { margin: 0 0 8px; font: 400 22px/1 var(--display); letter-spacing: .04em; color: var(--gold); text-transform: uppercase; }
.cards p { margin: 0; color: var(--text-mid); font-size: 15px; }
.apply-main { max-width: 760px; margin: 0 auto; padding: 32px 20px; background: var(--bg-2); border: 1px solid var(--surface); border-radius: 12px; }
@media (min-width: 720px) { .apply-main { padding: 44px 48px; } }
.form-title { display: flex; flex-direction: column; gap: 10px; margin: 0 0 28px; font: 400 36px/1 var(--display); letter-spacing: .03em; text-transform: uppercase; }
.grid { display: grid; gap: 0 24px; }
@media (min-width: 640px) { .grid { grid-template-columns: 1fr 1fr; } }
.type-row .choices { max-width: 340px; }
@media (min-width: 640px) { .type-row { max-width: calc(50% - 12px); } .type-row .choices { max-width: none; } }
.audience-note { margin: 8px 0 20px; padding-top: 24px; border-top: 1px solid var(--surface); color: var(--text); font-weight: 500; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.apply-main .done { border-top: 0; padding: 8px 0; }
.apply-main .done h2 { margin: 0 0 12px; font: 400 40px/1 var(--display); letter-spacing: .03em; text-transform: uppercase; }
.apply-main .done-msg { max-width: 44ch; font-size: 19px; color: var(--text-mid); }

.lede-sm { margin: 0 0 24px; color: var(--text-mid); }
.lede-sm strong { color: var(--text); }
.code-input { max-width: 220px; font: 700 24px/1 var(--mono) !important; letter-spacing: .3em; }
.code-actions { display: flex; gap: 20px; flex-wrap: wrap; margin: 20px 0 0; }

/* Consent */
.consent .check { margin-bottom: 20px; font-size: 15px; line-height: 1.5; color: var(--text-mid); min-height: 44px; }
.consent .check strong { color: var(--text); }
.consent a { color: var(--blue); text-decoration: underline; text-underline-offset: 2px; }
.consent a:hover { color: var(--blue-hover); }
.consent a:focus-visible, .btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.btn:disabled:not([aria-busy]) { background: var(--surface); color: var(--text-dim); cursor: not-allowed; }
.fine { margin: 16px 0 0; max-width: 60ch; font-size: 13px; line-height: 1.5; color: var(--text-dim); }

/* End states */
.closed, .done { padding: 32px 0; border-top: 1px solid var(--surface); }
.closed h2 {
  margin: 0 0 12px;
  font: 400 36px/1 var(--display);
  letter-spacing: .03em;
  text-transform: uppercase;
}
.closed p { margin: 0; color: var(--text-mid); max-width: 56ch; font-size: 17px; }
.done-msg { margin: 0; font-size: 22px; line-height: 1.4; max-width: 30ch; }
.done:focus { outline: none; }
.warnings { margin: 20px 0 0; padding-left: 20px; color: var(--gold-hover); }
.warnings:empty { display: none; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

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

/* Instagram/Facebook confirm card: the hint sits under the link */
.preview .preview-url + .mini-label { margin-top: 10px; }
