/* SameTune "Vinyl night": a record club after dark. Always dark, pink → orange glow.
   Fonts are self-hosted (SIL Open Font License, see public/fonts/), so no requests go to Google. */
@font-face {
  font-family: 'Unbounded'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/fonts/unbounded-latin-ext-wght-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
@font-face {
  font-family: 'Unbounded'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/fonts/unbounded-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: 'Outfit'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/fonts/outfit-latin-ext-wght-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(/fonts/outfit-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
:root {
  --bg: #16061a;          /* deep plum-black */
  --surface: #220a27;     /* cards */
  --surface-2: #2d0f33;   /* raised bits inside cards */
  --text: #f7d9ea;        /* soft pink body text */
  --heading: #ffe4f2;     /* near-white pink for headings */
  --muted: #c99ab6;       /* dusty pink for secondary text */
  --line: #3d1840;
  --accent: #ff2e93;      /* hot pink for buttons and links */
  --accent-2: #ff7a3d;    /* tangerine, the end of the glow */
  --accent-text: #16061a;
  --accent-soft: #3a1238;
  --link: #ff6fb5;        /* lighter pink: easier to read as small text */
  --ok: #ffb38a;          /* warm peach */
  --ok-strong: var(--accent-2);
  --fade: linear-gradient(90deg, var(--accent), var(--accent-2));  /* pink → orange */
  --danger: #ff6b6b;
  --radius: 16px;
  --display: 'Unbounded', 'Arial Black', system-ui, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.55 'Outfit', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* a soft pink glow in the top corner, like stage lights */
  background-image: radial-gradient(60rem 40rem at 85% -10%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
  background-repeat: no-repeat;
}
a { color: var(--link); }
code { background: var(--accent-soft); padding: 0 .3em; border-radius: 4px; }
main { max-width: 960px; margin: 0 auto; padding: 24px 16px 48px; }
h1, h2, h3, legend, .logo { font-family: var(--display); letter-spacing: -.02em; }
h1 { font-size: clamp(1.6rem, 4.5vw, 2.3rem); font-weight: 800; line-height: 1.1; margin: 0 0 .5em; color: var(--heading); }
h2, h3, legend { color: var(--heading); font-weight: 600; }
h2 { font-size: 1.15rem; margin: 0 0 .25em; }
h3 { font-size: 1rem; }
.muted { color: var(--muted); }

.top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  max-width: 960px; margin: 0 auto; padding: 16px;
}
.logo { font-weight: 800; font-size: 1.2rem; color: var(--heading); text-decoration: none; }
nav { display: flex; gap: 18px; align-items: center; }
nav a { color: var(--text); text-decoration: none; font-weight: 500; }
nav form { margin: 0; }
.badge {
  display: inline-block; min-width: 1.4em; padding: 0 .4em; border-radius: 99px;
  background: var(--accent); color: var(--accent-text); font-size: .8em; text-align: center;
}
footer { text-align: center; color: var(--muted); font-size: .85rem; padding: 24px 16px 40px; }
footer a { color: var(--muted); }

.btn {
  display: inline-block; border: 0; border-radius: 10px; cursor: pointer;
  background: var(--fade); color: var(--accent-text);
  padding: .65em 1.3em; font: inherit; font-weight: 600; text-decoration: none;
}
.btn:hover { filter: brightness(1.08); }
.btn.big { padding: .85em 1.8em; font-size: 1.05rem; }
.btn.ghost { background: transparent; color: var(--link); box-shadow: inset 0 0 0 2px var(--accent); }
.btn.danger { background: var(--danger); color: #1a0812; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); cursor: pointer; text-decoration: underline; }
nav .link { color: var(--text); text-decoration: none; font-weight: 500; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

.notice { background: var(--accent-soft); padding: 12px 16px; border-radius: var(--radius); display: inline-block; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 20px; }
.narrow { max-width: 520px; margin-left: auto; margin-right: auto; }
.center { text-align: center; }
.center .row { justify-content: center; }
.profile-chip { display: inline-flex; gap: 14px; align-items: center; text-align: left; padding: 12px 18px; border: 1px solid var(--line); border-radius: var(--radius); margin: 8px 0; }
.profile-chip img, .avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.avatar { display: grid; place-items: center; background: var(--accent-soft); font-size: 2rem; }

.form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; margin-top: 16px; }
.form .full { grid-column: 1 / -1; }
@media (max-width: 600px) { .form { grid-template-columns: 1fr; } }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; }
label small, fieldset small { font-weight: 400; color: var(--muted); }
label.check { flex-direction: row; align-items: center; font-weight: 400; margin-top: 8px; }
label.inline { font-weight: 400; margin-top: 12px; }
input, select, textarea {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: .6em .7em; width: 100%;
}
textarea { resize: vertical; min-height: 8em; }
.feedback-form .btn { margin-top: 10px; }
input[type=checkbox] { width: auto; }
input:focus, select:focus, textarea:focus, .btn:focus-visible, .link:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 0; display: flex; flex-direction: column; gap: 8px; }
legend { font-weight: 700; padding: 0 6px; }
.results { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.results button { font: inherit; border: 1px solid var(--line); background: var(--accent-soft); color: var(--text); border-radius: 8px; padding: .3em .9em; cursor: pointer; }
.errors { background: color-mix(in srgb, var(--danger) 12%, transparent); border-left: 4px solid var(--danger); padding: 8px 16px; border-radius: 8px; margin: 12px 0; }
.danger-zone h2 { color: var(--danger); }

.matches { display: flex; flex-direction: column; gap: 16px; }
.match { display: flex; gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.match.new { border-color: var(--accent); }
.match .body { flex: 1; min-width: 0; }
.score {
  flex: none; width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center;
  /* score ring fills with the pink → orange glow */
  background: conic-gradient(var(--accent) 0%, var(--ok-strong) calc(var(--p) * 1%), var(--accent-soft) 0);
}
.score span { display: grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; background: var(--surface); font-family: var(--display); font-weight: 700; font-size: 1rem; color: var(--heading); }
.match h2 a { font-weight: 500; font-size: .95rem; }
.reasons { margin: .6em 0 1em; padding-left: 1.2em; }
.pill { display: inline-block; background: var(--fade); color: var(--accent-text); font-size: .75rem; font-weight: 700; border-radius: 99px; padding: 0 .6em; margin-bottom: 4px; }
.status { font-weight: 600; color: var(--muted); }
.status.ok { color: var(--heading); }
@media (max-width: 520px) { .match { flex-direction: column; gap: 12px; } }

/* Profile page: two profile blocks */
.profile-block { margin: 20px 0; padding: 16px 18px 20px; }
.profile-block legend { font-size: 1.05rem; }
.profile-block legend .muted { font-weight: 400; font-size: .9rem; }
.profile-block .form { margin-top: 4px; }
.soulmate { border-color: var(--accent); background: color-mix(in srgb, var(--accent-soft) 45%, transparent); }
.fixed { font-weight: 400; padding: .6em .7em; border-radius: 10px; background: var(--accent-soft); }
.range { display: flex; align-items: center; gap: 8px; font-weight: 400; }
.label { display: block; font-weight: 600; margin-bottom: 6px; }
.artist-picker { display: flex; flex-direction: column; gap: 6px; }

/* Matches page */
.filter {
  display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; margin: 0 0 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; width: fit-content; max-width: 100%;
}
.filter a { padding: .45em 1em; border-radius: 8px; color: var(--text); text-decoration: none; font-weight: 600; font-size: .95rem; }
.filter a span { color: var(--muted); font-weight: 500; margin-left: 2px; }
.filter a.active { background: var(--fade); color: var(--accent-text); }
.filter a.active span { color: inherit; opacity: .8; }
@media (max-width: 520px) { .filter { border-radius: var(--radius); width: 100%; } .filter a { flex: 1; text-align: center; } }
.pills { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; }
.both-scores { font-size: .9rem; color: var(--muted); margin: .2em 0 0; }
.match.closest { border-width: 2px; border-color: var(--accent); box-shadow: 0 6px 24px color-mix(in srgb, var(--accent) 18%, transparent); }
.closest-pill { background: var(--fade); color: var(--accent-text); }
.pill.soft { background: var(--accent-soft); color: var(--link); }
.pill + .pill { margin-left: 4px; }
.small { font-size: .9rem; margin-top: -.4em; }

.agree { margin: 4px 0 16px; align-items: flex-start; gap: 8px; }
.agree input { margin-top: .3em; }
.safety { margin-top: 12px; font-size: .9rem; }
.safety summary { cursor: pointer; color: var(--muted); width: fit-content; }
.safety form { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.safety label { font-weight: 500; }
.small-btn { padding: .45em 1em; font-size: .9rem; }
.notice { margin-bottom: 16px; }
.flash { display: block; border-left: 4px solid var(--accent); }
.email-status { margin: 0; font-size: .9rem; color: var(--muted); }
.email-status.ok { color: var(--heading); }

.dev-users { list-style: none; padding: 0; margin-top: 16px; }
.dev-users li { display: flex; gap: 12px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid var(--line); }
.dev-users form { margin: 0; }

/* Legal pages */
.legal h2 { margin-top: 1.4em; }
.legal li { margin-bottom: .4em; }
.missing { background: color-mix(in srgb, var(--danger) 20%, transparent); color: var(--danger); padding: 0 .3em; border-radius: 4px; font-size: .9em; }

/* Mutual match: share step */
.mutual { display: flex; flex-direction: column; gap: 10px; padding: 14px; margin-top: 4px; border: 1px solid var(--accent); border-radius: 12px; background: color-mix(in srgb, var(--accent-soft) 60%, transparent); }
.mutual .status { margin: 0; }
.share-line { margin: 0; color: var(--muted); }
.share-line.ok { color: var(--heading); }
.share-form { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0; }
.share-form small { flex-basis: 100%; color: var(--muted); }

/* Sign-up with a playlist */
.verify-steps { padding-left: 1.3em; display: flex; flex-direction: column; gap: 18px; margin: 16px 0; }
.verify-steps li { display: flex; flex-direction: column; gap: 6px; }
.verify-steps small { color: var(--muted); }
.code-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.code { font-size: 1.25rem; font-weight: 700; letter-spacing: .04em; padding: .35em .7em; user-select: all; }
.paste-form { display: flex; gap: 10px; flex-wrap: wrap; }
.paste-form input { flex: 1 1 220px; }
p.small { font-size: .9rem; }

/* "Artists you listen to most" */
.my-artists { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 12px; }
.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.chips li { display: inline-flex; align-items: center; gap: 4px; background: var(--accent-soft); border-radius: 99px; padding: .25em .4em .25em .9em; }
.chip-x { border: 0; background: none; color: var(--muted); font-size: 1.1rem; line-height: 1; cursor: pointer; padding: 0 .3em; border-radius: 50%; }
.chip-x:hover, .chip-x:focus-visible { color: var(--danger); }
.genre-picker { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 12px; }
.genre-picker select { max-width: 320px; }

/* Welcome page: text beside a spinning record, "How it works" as a tracklist */
.home-hero { display: grid; gap: 8px 32px; align-items: center; padding: 16px 0 8px; }
@media (min-width: 760px) { .home-hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); } }
.home-hero h1 { font-size: clamp(2.2rem, 6.5vw, 3.6rem); line-height: 1.02; max-width: 11ch; margin-bottom: .35em; }
.home-text p { max-width: 50ch; }
.home-text .row { margin-top: 20px; }
.lead-left { font-size: 1.25rem; color: var(--heading); margin-top: 0; font-weight: 500; }
.record { width: 100%; max-width: 440px; justify-self: center; }
.record svg { display: block; width: 100%; height: auto; }
.record text { font-family: var(--display); font-weight: 800; font-size: 13px; fill: #16061a; }
.spin { transform-origin: 185px 168px; animation: spin 7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation: none; } }
@media (max-width: 759px) { .record { max-width: 280px; margin: 8px auto 0; } }
.liner { color: var(--muted); max-width: 62ch; margin: 8px 0 0; padding-left: 14px; border-left: 3px solid var(--accent); }
#how { margin-top: 40px; }
.tracklist { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); column-gap: 32px; border-top: 1px solid var(--line); }
.tracklist li { display: flex; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.tracklist span { flex: none; width: 2.2em; font-family: var(--display); font-weight: 500; font-size: .9rem; color: var(--accent); padding-top: 2px; }
.tracklist h3 { margin: 0 0 .2em; }
.tracklist p { margin: 0; color: var(--muted); }
nav .btn.small-btn { color: var(--accent-text); }
/* Connect Spotify: the "why" box */
.why { background: var(--accent-soft); border-radius: var(--radius); padding: 12px 16px; margin: 12px 0 8px; }
.why summary { cursor: pointer; font-weight: 600; color: var(--heading); }
.why p { margin: .4em 0; }
.fixed-line { margin: 4px 0; }
/* The small text under a form (e.g. on the sign-up page) needs room above it */
form + p.small, form + p.muted.small { margin-top: 14px; }
/* FAQ */
details.faq { border-bottom: 1px solid var(--line); padding: 10px 0; }
details.faq summary { cursor: pointer; font-weight: 600; color: var(--heading); }
details.faq div { padding: 4px 0 0; }
/* "Fill this in from Spotify Wrapped" on the profile page */
.wrapped-fill { margin: 16px 0 8px; padding: 16px 18px; border-radius: var(--radius); border: 1px dashed var(--accent); background: color-mix(in srgb, var(--accent-soft) 55%, transparent); }
.wrapped-fill h2 { margin-bottom: .3em; }
.wrapped-fill p { margin: .4em 0; }
.shot { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; font-weight: 400; margin: 10px 0 4px; cursor: pointer; }
.shot input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.shot:focus-within .btn { outline: 3px solid var(--accent); outline-offset: 2px; }
.wrapped-status:empty { display: none; }
.wrapped-status { color: var(--heading); font-weight: 500; }
.wrapped-fill.busy .wrapped-status::before { content: ""; display: inline-block; width: .8em; height: .8em; margin-right: .5em; border-radius: 50%; border: 2px solid var(--accent); border-right-color: transparent; vertical-align: -.05em; animation: spin 0.8s linear infinite; }

/* Verified or not (matches page) */
.pill.verified { background: transparent; color: var(--ok); box-shadow: inset 0 0 0 1px var(--ok); }
.pill.unverified { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--line); }
.verify-nudge { border-color: var(--accent); }
.verify-nudge p { margin: .4em 0 1em; max-width: 62ch; }

/* The * after fields needed for matching: hover over or tap it for a short explanation */
.req { position: relative; color: var(--accent); font-weight: 700; cursor: help; padding: 0 2px; border-radius: 4px; }
.req:focus-visible { outline: 2px solid var(--accent); }
.req:hover::after, .req:focus::after {
  content: attr(data-tip); position: absolute; left: 0; top: 1.7em; z-index: 20; width: max-content; max-width: min(260px, 70vw);
  padding: 8px 10px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line);
  color: var(--text); font: 400 .85rem/1.4 system-ui, sans-serif; white-space: normal; box-shadow: 0 6px 20px rgb(0 0 0 / .4);
}
.req-note { margin: 0 0 8px; }
