/* Rival Eclipse contest page — brand: black starfield, gold #C9A227, navy #14141F. */
:root {
  --bg: #0a0a12; --bg2: #101019; --card: #14141f; --line: #23232f;
  --text: #eceaf4; --muted: #9a96ad; --accent: #c9a227; --accent2: #7c5cff;
  --ok: #3ddc84; --err: #ff6b6b;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: #050510; color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  min-height: 100vh;
}
#sky { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
header, main, footer { position: relative; z-index: 1; }
.wrap { width: 100%; max-width: 960px; margin: 0 auto; padding: 0 20px; }
a { color: var(--accent); }
h1 { font-size: clamp(2.2rem, 6vw, 3.4rem); letter-spacing: .04em; font-weight: 800; line-height: 1.1; }
h1 .gold {
  background: linear-gradient(100deg, #f3d27a, var(--accent) 45%, #f3d27a);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
h2 { font-size: 1.4rem; margin-bottom: 8px; }
h3 { font-size: 1.05rem; margin-bottom: 6px; }
.sub { color: var(--muted); font-size: .95rem; line-height: 1.5; }
header.hero { text-align: center; padding: 64px 20px 40px; }
header.hero .prize {
  display: inline-block; margin-top: 18px; padding: 10px 18px;
  border: 1px solid var(--accent); border-radius: 999px;
  color: var(--accent); font-weight: 700; font-size: .95rem;
}
header.hero .prize small { color: var(--muted); font-weight: 400; }
nav.tabs {
  display: flex; gap: 8px; justify-content: center; flex-wrap: wrap;
  margin: 0 auto 28px; max-width: 960px; padding: 0 20px;
}
nav.tabs a {
  padding: 10px 18px; border: 1px solid var(--line); border-radius: 999px;
  color: var(--text); text-decoration: none; font-weight: 600; font-size: .95rem;
  background: rgba(16, 16, 25, .85);
}
nav.tabs a.active { border-color: var(--accent); color: var(--accent); }
nav.tabs a .badge {
  display: inline-block; min-width: 20px; padding: 1px 6px; margin-left: 6px;
  border-radius: 999px; background: var(--accent); color: #0a0a12;
  font-size: .75rem; font-weight: 800; text-align: center;
}
section.panel { display: none; padding-bottom: 48px; }
section.panel.active { display: block; }
.card {
  background: linear-gradient(180deg, rgba(20, 20, 31, .94), rgba(17, 17, 25, .94));
  border: 1px solid var(--line); border-radius: 16px; padding: 22px; margin-bottom: 16px;
}
.card.gold-border { border-color: var(--accent); }
label { display: block; font-weight: 600; font-size: .9rem; margin: 14px 0 6px; }
input[type="text"], input[type="email"], select, textarea {
  width: 100%; background: #0d0d15; border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); padding: 12px 14px; font-size: 1rem; font-family: inherit;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
.btn {
  display: inline-block; background: linear-gradient(135deg, #d4af37, #8a6d1c);
  color: #0a0a12; font-weight: 700; font-size: 1rem; border: none; border-radius: 12px;
  padding: 13px 22px; cursor: pointer; font-family: inherit; text-decoration: none;
}
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.ghost {
  background: transparent; color: var(--text); border: 1px solid var(--line);
}
.btn.danger { background: transparent; color: var(--err); border: 1px solid var(--err); }
.btn.small { padding: 8px 14px; font-size: .9rem; border-radius: 10px; }
.btn.discord { background: #5865f2; color: #fff; }
.btn.discord:hover { background: #4752c4; }
.msg { margin-top: 12px; font-size: .95rem; min-height: 1.2em; }
.msg.ok { color: var(--ok); }
.msg.err { color: var(--err); }
.app-picker { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 640px) { .app-picker { grid-template-columns: 1fr; } }
.app-opt {
  border: 1px solid var(--line); border-radius: 14px; padding: 16px; cursor: pointer;
  background: rgba(13, 13, 21, .8);
}
.app-opt:hover { border-color: var(--accent); }
.app-opt.selected { border-color: var(--accent); background: rgba(201, 162, 39, .12); }
.app-opt b { display: block; font-size: 1.05rem; margin-bottom: 4px; }
.app-opt span { color: var(--muted); font-size: .85rem; line-height: 1.4; display: block; }
.drop {
  margin-top: 8px; border: 2px dashed var(--line); border-radius: 14px; padding: 22px;
  text-align: center; color: var(--muted); cursor: pointer;
}
.drop:hover { border-color: var(--accent); }
.drop input { display: none; }
.previews { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.preview { position: relative; width: 96px; }
.preview img {
  width: 96px; height: 96px; object-fit: cover; border-radius: 10px;
  border: 1px solid var(--line); display: block; cursor: zoom-in;
}
.preview .meta { font-size: .7rem; color: var(--muted); margin-top: 4px; word-break: break-all; }
.preview .x {
  position: absolute; top: -6px; right: -6px; width: 24px; height: 24px; border-radius: 50%;
  background: #0a0a12; border: 1px solid var(--err); color: var(--err);
  font-size: 14px; line-height: 22px; text-align: center; cursor: pointer; padding: 0;
}
.sub-item { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }
.sub-item:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.sub-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.sub-head .name { font-size: 1.1rem; font-weight: 700; }
.pill {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .75rem;
  font-weight: 700; border: 1px solid var(--line); color: var(--muted);
}
.pill.app-qr { color: var(--accent); border-color: var(--accent); }
.pill.app-eclips { color: #f3d27a; border-color: #f3d27a; }
.pill.app-remote { color: var(--accent2); border-color: var(--accent2); }
.pill.new { background: var(--accent); color: #0a0a12; border-color: var(--accent); }
.sub-meta { color: var(--muted); font-size: .85rem; margin: 4px 0 10px; }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.thumbs img {
  width: 72px; height: 72px; object-fit: cover; border-radius: 8px;
  border: 1px solid var(--line); cursor: zoom-in;
}
.thumb-wrap { position: relative; }
.thumb-wrap .x {
  position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%;
  background: #0a0a12; border: 1px solid var(--err); color: var(--err);
  font-size: 13px; line-height: 20px; text-align: center; cursor: pointer; padding: 0;
}
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row .spacer { flex: 1; }
.edit-name { display: none; margin-top: 10px; }
.edit-name.open { display: flex; gap: 8px; }
.edit-name input { flex: 1; }
.toggle { display: flex; align-items: center; gap: 12px; }
.toggle input { width: 20px; height: 20px; accent-color: var(--accent); }
.lightbox {
  position: fixed; inset: 0; background: rgba(0, 0, 0, .9); z-index: 10;
  display: none; align-items: center; justify-content: center; cursor: pointer;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 92vh; border-radius: 12px; }
footer { text-align: center; color: var(--muted); font-size: .85rem; padding: 24px 20px 40px; }
.hidden { display: none !important; }
.note {
  background: rgba(201, 162, 39, .08); border: 1px solid rgba(201, 162, 39, .4);
  border-radius: 12px; padding: 12px 16px; color: var(--text); font-size: .9rem; line-height: 1.5;
}
.note.warn { background: rgba(255, 107, 107, .07); border-color: rgba(255, 107, 107, .4); }
