/* thatnerdygirlliz.site: whimsy goth, witchy, nerdy, fairy, sparkly. Corn mode (html.corn, corn.js) swaps
   the colors and turns the sky, sparkle and fonts off. Fonts come from Google Fonts (linked in layout.html). */
:root {
  --bg: #100a1c; --panel: #1b1230; --panel-2: #251843; --line: #3a2a5e;
  --text: #f3ecff; --muted: #bcadd8;
  --accent: #d9a6ff; --accent-deep: #9b5de5; --on-accent: #1a0d2e;
  --accent-2: #8ff0d0; --on-accent-2: #0b2a20;
  --rose: #ff9ccf; --gold: #f6d67a;
  --shimmer: linear-gradient(100deg, #e9c8ff, #ff9ccf 45%, #8ff0d0 75%, #e9c8ff);
  --frame: linear-gradient(135deg, #9b5de5, #ff9ccf 50%, #8ff0d0);
  --display: "Uncial Antiqua", "Palatino Linotype", Georgia, serif;
  --body: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Space Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --radius: 18px;
  color-scheme: dark;
}
html.corn {
  --bg: #17200f; --panel: #222e16; --panel-2: #2b3a1c; --line: #3b5025;
  --text: #fff8e3; --muted: #cfc7a3;
  --accent: #ffd23f; --accent-deep: #e8a800; --on-accent: #1d1600;
  --accent-2: #8cc34f; --on-accent-2: #102006;
  --shimmer: linear-gradient(#ffd23f, #ffd23f);
  --frame: linear-gradient(#3b5025, #3b5025);
  --display: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--text); min-height: 100vh; display: flex; flex-direction: column;
  font: 17px/1.6 var(--body);
  background: radial-gradient(ellipse 120% 70% at 85% -10%, #2b1650 0%, transparent 60%),
              radial-gradient(ellipse 90% 60% at -10% 110%, #1f1036 0%, transparent 60%), var(--bg);
  background-attachment: fixed;
}
/* The night sky: two layers of stars, the second twinkling. */
body::before, body::after { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0; }
body::before {
  background:
    radial-gradient(1px 1px at 12% 18%, #fff 99%, transparent), radial-gradient(1px 1px at 72% 9%, #f6d67a 99%, transparent),
    radial-gradient(1.5px 1.5px at 33% 62%, #e9c8ff 99%, transparent), radial-gradient(1px 1px at 88% 44%, #fff 99%, transparent),
    radial-gradient(1px 1px at 56% 82%, #8ff0d0 99%, transparent), radial-gradient(1px 1px at 6% 91%, #fff 99%, transparent),
    radial-gradient(1.5px 1.5px at 94% 76%, #ff9ccf 99%, transparent), radial-gradient(1px 1px at 46% 31%, #fff 99%, transparent);
  background-size: 320px 320px; opacity: .55;
}
body::after {
  background:
    radial-gradient(1.5px 1.5px at 22% 40%, #f6d67a 99%, transparent), radial-gradient(1px 1px at 64% 24%, #fff 99%, transparent),
    radial-gradient(2px 2px at 81% 63%, #e9c8ff 99%, transparent), radial-gradient(1px 1px at 9% 70%, #8ff0d0 99%, transparent),
    radial-gradient(1.5px 1.5px at 50% 95%, #fff 99%, transparent);
  background-size: 460px 460px; animation: twinkle 4.5s ease-in-out infinite alternate;
}
@keyframes twinkle { from { opacity: .15; } to { opacity: .9; } }
html.corn body { background: var(--bg); }
html.corn body::before, html.corn body::after, html.corn .dust, html.corn .moon, html.corn .ornament { display: none; }
html.corn body {
  background-image:
    radial-gradient(ellipse 5px 6px at 50% 50%, rgb(255 210 63 / .07) 98%, transparent),
    radial-gradient(ellipse 5px 6px at 50% 50%, rgb(255 210 63 / .07) 98%, transparent);
  background-size: 28px 30px; background-position: 0 0, 14px 15px;
}
.corn-only { display: none !important; }
html.corn .corn-only { display: inline-block !important; }
html.corn .not-corn { display: none !important; }
/* The corn mode switch: one small, faded corn in the footer corner. */
.cornmode { position: absolute; right: 10px; bottom: 8px; width: 22px; height: 30px; padding: 0; border: 0; background: none;
  opacity: .22; cursor: pointer; rotate: -20deg; transition: opacity .3s, rotate .3s; }
.cornmode img { width: 100%; height: 100%; display: block; }
.cornmode:hover, .cornmode:focus-visible { opacity: .6; }
html.corn .cornmode { opacity: 1; rotate: 15deg; z-index: 7; }

/* Fairy dust and tap sparkles (sparkle.js) */
.dust { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.dust i { position: absolute; left: var(--x); bottom: -10px; width: var(--s); height: var(--s); border-radius: 50%;
  background: var(--c); box-shadow: 0 0 8px 2px var(--c); opacity: 0; animation: rise var(--dur) linear var(--delay) infinite; }
@keyframes rise { 10% { opacity: .9; } 50% { translate: var(--drift) -55vh; } 90% { opacity: .6; } to { translate: 0 -110vh; opacity: 0; } }
.spark { position: fixed; z-index: 9; pointer-events: none; color: var(--c); text-shadow: 0 0 6px var(--c); translate: -50% -50%;
  animation: spark .7s ease-out forwards; font-family: var(--body); }
@keyframes spark { to { transform: translate(var(--dx), var(--dy)) rotate(90deg) scale(.3); opacity: 0; } }

a { color: var(--accent); }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; max-width: 960px; width: 100%; margin: 0 auto; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 9px; font-family: var(--body); font-weight: 900; font-size: 19px; color: var(--text); text-decoration: none; letter-spacing: .01em; }
html.corn .brand { font-size: 17px; font-weight: 800; }
.brand img { width: 28px; height: 28px; }
html.corn .brand .not-corn { display: none !important; }
nav { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
nav a { color: var(--muted); text-decoration: none; padding: 6px 14px; border-radius: 99px; font-weight: 700; }
nav a:hover, nav a[aria-current] { color: var(--on-accent); background: var(--shimmer); }
main { flex: 1; max-width: 960px; width: 100%; margin: 0 auto; padding: 20px 16px 48px; }
h1, h2 { font-family: var(--display); font-weight: 400; }
h1 { font-size: clamp(40px, 10.5vw, 72px); line-height: 1.05; margin: 0 0 16px; letter-spacing: .005em;
  background: var(--shimmer); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shimmer 8s ease-in-out infinite alternate; }
@keyframes shimmer { to { background-position: 100% 0; } }
h1 .sparkle { color: var(--gold); -webkit-text-fill-color: var(--gold); font-family: var(--body); font-size: .45em; vertical-align: .9em; margin-left: .15em; display: inline-block; animation: tw 2.2s ease-in-out infinite; }
@keyframes tw { 50% { opacity: .35; scale: .75; rotate: 20deg; } }
html.corn h1 { font-size: clamp(36px, 9vw, 64px); letter-spacing: -.025em; animation: none; color: var(--text); background: none; }
html.corn h1 .sparkle { display: none; }
h2 { font-size: 23px; margin: 30px 0 10px; letter-spacing: .01em; }
html.corn h2 { font-size: 20px; font-weight: 700; }
html.corn h1 { font-weight: 800; }
.lead { color: var(--muted); font-size: 19px; max-width: 34em; }
.kicker { display: inline-block; font-family: var(--mono); color: var(--accent-2); background: rgb(143 240 208 / .08); border: 1px solid rgb(143 240 208 / .35);
  font-weight: 600; font-size: 13px; margin: 0 0 16px; padding: 4px 12px; border-radius: 99px; }
.kicker::before { content: "~/"; opacity: .6; }
html.corn .kicker { font-family: var(--body); color: var(--on-accent-2); background: var(--accent-2); border: 0; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: 12px; }
html.corn .kicker::before { content: none; }
.hero { padding: 28px 0 18px; position: relative; }
.moon { position: absolute; right: -6px; top: 0; width: clamp(90px, 26vw, 170px); pointer-events: none; animation: float 7s ease-in-out infinite; z-index: -1; opacity: .95; }
@keyframes float { 50% { translate: 0 -10px; rotate: -4deg; } }
.cta { position: relative; overflow: hidden; display: inline-block; margin-top: 12px; background: var(--shimmer); background-size: 160% 100%; color: var(--on-accent);
  font-weight: 900; text-decoration: none; padding: 14px 26px; border-radius: 99px; box-shadow: 0 0 0 1px rgb(255 255 255 / .15) inset, 0 8px 28px -8px #ff9ccf;
  transition: transform .15s, box-shadow .15s, background-position .6s; }
.cta::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgb(255 255 255 / .55) 50%, transparent 70%); translate: -120% 0; transition: translate .7s; }
.cta:hover { transform: translateY(-2px); background-position: 100% 0; box-shadow: 0 0 0 1px rgb(255 255 255 / .2) inset, 0 12px 34px -8px #d9a6ff; }
.cta:hover::after { translate: 120% 0; }
html.corn .cta { background: var(--accent); box-shadow: 0 6px 0 var(--accent-deep); }
html.corn .cta::after { content: none; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; margin-top: 30px; }
.card { display: block; position: relative; border: 2px solid transparent; border-radius: var(--radius); padding: 18px 18px 18px 52px; color: var(--text); text-decoration: none;
  background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--frame) border-box; transition: box-shadow .2s, transform .2s; }
.card::before { content: "✧"; position: absolute; left: 18px; top: 16px; font-size: 22px; color: var(--gold); }
html.corn .card { padding-left: 18px; } html.corn .card::before { content: none; }
.card:hover { box-shadow: 0 0 24px -4px rgb(217 166 255 / .55); transform: translateY(-2px); }
html.corn .card:hover { box-shadow: none; transform: none; border-color: var(--accent); background: linear-gradient(var(--panel), var(--panel)) padding-box, linear-gradient(var(--accent), var(--accent)) border-box; }
.card h2 { margin: 0 0 4px; font-size: 21px; }
html.corn .card h2 { font-size: 19px; }
.card p { margin: 0; color: var(--muted); }
.soon { background: var(--panel); border: 2px dashed var(--line); border-radius: var(--radius); padding: 18px; color: var(--muted); }
.ornament { display: block; width: min(240px, 70%); height: 24px; margin: 36px auto 0; background: url(/ornament.svg) center / contain no-repeat; opacity: .9; }
@media (prefers-reduced-motion: reduce) { body::after, h1, h1 .sparkle, .moon { animation: none !important; } }

/* Voices */
.count { color: var(--accent-2); font-weight: 700; margin: 18px 0 8px; }
.finder { display: flex; gap: 8px; flex-wrap: wrap; position: sticky; top: 0; z-index: 2; padding: 10px 0; background: var(--bg); }
.finder input { flex: 1; min-width: 150px; font: inherit; color: var(--text); background: var(--panel); border: 2px solid var(--line); border-radius: 99px; padding: 9px 16px; }
.finder input:focus { outline: none; border-color: var(--accent); }
.finder input.miss { border-color: #e86a4a; }
.finder button { font: inherit; font-weight: 700; color: var(--on-accent); background: var(--accent); border: 0; border-radius: 99px; padding: 9px 16px; cursor: pointer; }
.voices { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.voices.grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
button.voice { width: 100%; display: flex; align-items: center; gap: 10px; font: inherit; color: var(--text); text-align: left; background: var(--panel); border: 2px solid var(--line); border-radius: 14px; padding: 10px 12px; cursor: pointer; }
button.voice:hover { border-color: var(--accent-2); }
button.voice.on { border-color: var(--accent); background: var(--panel-2); }
button.voice.flash { animation: flash 1.6s; }
@keyframes flash { 0%, 60% { box-shadow: 0 0 0 4px var(--accent); } 100% { box-shadow: none; } }
.play { width: 0; height: 0; border-left: 11px solid var(--accent); border-top: 7px solid transparent; border-bottom: 7px solid transparent; flex: none; }
button.voice.on .play { width: 11px; height: 14px; border: 0; border-left: 4px solid var(--accent); border-right: 4px solid var(--accent); }
.num { font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; }
.label { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.vname { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.desc { color: var(--muted); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grid button.voice { padding: 9px 10px; gap: 8px; }
.grid .num { min-width: 3.2ch; }
.pack { background: var(--panel); border: 2px solid var(--line); border-radius: var(--radius); margin-top: 10px; }
.pack summary { cursor: pointer; padding: 14px 16px; font-weight: 700; }
.pack summary .n { color: var(--accent-2); font-weight: 700; font-size: 14px; margin-left: 6px; }
.pack summary small { display: block; color: var(--muted); font-weight: 400; font-size: 14px; margin-top: 2px; }
.pitches { display: flex; gap: 6px; overflow-x: auto; width: 100%; padding-bottom: 2px; scrollbar-width: none; }
.finder .pitches button { background: var(--panel); color: var(--muted); border: 2px solid var(--line); font-size: 14px; padding: 5px 12px; white-space: nowrap; }
.finder .pitches button.on { background: var(--accent-2); border-color: var(--accent-2); color: var(--on-accent-2); }
.howto { background: var(--panel); border: 2px solid var(--accent); border-radius: var(--radius); padding: 4px 18px 12px; margin: 22px 0 6px; }
.howto h2 { margin-top: 14px; }
.howto ol { padding-left: 22px; margin: 8px 0; }
.howto li { margin: 6px 0; }
.howto code, .more code { background: var(--bg); color: var(--accent); padding: 2px 7px; border-radius: 6px; font-weight: 700; }
.howto .more { color: var(--muted); font-size: 15px; margin: 8px 0 4px; }
.pack .voices { padding: 0 12px 14px; }
.pack button.voice { background: var(--bg); }

footer { position: relative; z-index: 7;  /* above the corn, so the corn switch can always be tapped */ text-align: center; padding: 22px 16px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); background: rgb(16 10 28 / .78); backdrop-filter: blur(6px); }
html.corn footer { background: var(--bg); border-top-width: 2px; }
footer a { color: var(--muted); }
@media (prefers-reduced-motion: reduce) { h1 .corn, .wiggle { animation: none; } * { transition: none !important; scroll-behavior: auto !important; } }

/* Corn rain (corn.js) */
main { position: relative; z-index: 1; }
.top { position: relative; z-index: 7; }  /* above the corn, so the nav can always be tapped */
.sky { position: fixed; inset: 0; z-index: 5; pointer-events: none; overflow: hidden; }
.kernel { position: absolute; left: 0; top: 0; width: var(--size); height: calc(var(--size) * 1.6); pointer-events: auto; cursor: pointer;
  transform: translate(var(--x), var(--y0)); animation: fall var(--dur) linear var(--delay) infinite; touch-action: manipulation; }
.kernel i { display: block; width: 100%; height: 100%; background: url(/corn.svg) center / contain no-repeat;
  filter: drop-shadow(0 3px 4px rgb(0 0 0 / .35)); animation: sway calc(var(--dur) / 3) ease-in-out var(--delay) infinite alternate; }
.kernel.pop { height: var(--size); }
.kernel.pop i { background-image: url(/popcorn.svg); }
.kernel[data-burst] { animation-iteration-count: 1; animation-timing-function: cubic-bezier(.3, -.4, .7, 1); }
.kernel.popped i { animation: popped .35s ease-out forwards; }
@keyframes fall {
  to { transform: translate(calc(var(--x) + var(--dx)), 112vh) rotate(var(--spin)); }
}
@keyframes sway { from { translate: calc(var(--sway) * -1) 0; } to { translate: var(--sway) 0; } }
@keyframes popped { to { transform: scale(1.8); opacity: 0; } }
.puff { position: fixed; z-index: 6; pointer-events: none; transform: translate(-50%, -50%); font-weight: 900; font-size: 22px;
  color: var(--accent); -webkit-text-stroke: 1px #3a2a00; animation: puff .7s ease-out forwards; }
@keyframes puff { from { opacity: 1; scale: .6; } to { opacity: 0; scale: 1.6; translate: 0 -30px; } }
[data-burst] { cursor: pointer; display: inline-block; user-select: none; }
.wiggle { animation: wiggle .6s; }
@keyframes wiggle { 20% { rotate: -18deg; scale: 1.25; } 40% { rotate: 14deg; } 60% { rotate: -10deg; } 80% { rotate: 6deg; } }
h1 .corn { animation: bob 2.4s ease-in-out infinite; }
@keyframes bob { 50% { translate: 0 -6px; rotate: 8deg; } }
html:not(.corn) .cornbar { display: none; }
.cornbar { margin: 0 0 10px; display: flex; gap: 12px; justify-content: center; align-items: center; flex-wrap: wrap; }
.cornbar .popped { color: var(--accent); font-weight: 700; }
code { font-family: var(--mono); font-size: .92em; }

/* Home: gamer tags */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hero .lead { font-size: clamp(20px, 5vw, 26px); color: var(--text); max-width: 26em; margin-top: 4px; }
.gamertags { margin-top: 34px; }
.gamertags ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.gamertags li { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "platform copy" "tag copy"; align-items: center; gap: 2px 12px;
  border: 2px solid transparent; border-radius: var(--radius); padding: 12px 14px 12px 18px;
  background: linear-gradient(var(--panel), var(--panel)) padding-box, var(--frame) border-box; }
.gamertags .platform { grid-area: platform; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-2); }
.gamertags .tag { grid-area: tag; font-family: var(--mono); font-size: 19px; font-weight: 700; overflow-wrap: anywhere; user-select: all; }
.gamertags .copy { grid-area: copy; font: inherit; font-size: 14px; font-weight: 800; color: var(--on-accent); background: var(--shimmer); border: 0; border-radius: 99px; padding: 8px 14px; cursor: pointer; }
html.corn .gamertags li { background: var(--panel); border-color: var(--line); }
html.corn .copy { background: var(--accent); }
