:root {
  --purple-dark: #170b38;
  --purple: #2a1660;
  --purple-mid: #3d2286;
  --purple-light: #5a35b8;
  --gold: #d9a441;
  --gold-light: #f0cf7a;
  --gold-dark: #b8842e;
  --text-light: #ece6f9;
  --text-muted: #bfb2e6;
  --white: #ffffff;
  --radius: 14px;
  --shadow: 0 20px 50px rgba(15, 6, 40, 0.45);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  background: var(--purple-dark);
  color: var(--text-light);
  scroll-behavior: smooth;
}

a { color: inherit; text-decoration: none; }

.hidden { display: none !important; }

/* ===== Header ===== */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 6vw;
  background: linear-gradient(90deg, var(--purple-dark), var(--purple));
  border-bottom: 1px solid rgba(217, 164, 65, 0.25);
  position: relative;
  z-index: 5;
}

.logo {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.logo .mark {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--white);
  text-transform: uppercase;
}

.logo .mark span {
  color: var(--gold-light);
}

.logo .sub {
  margin-top: 4px;
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.lang-switch {
  display: flex;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border-radius: 999px;
  border: 1px solid rgba(217, 164, 65, 0.3);
}

.lang-switch button {
  border: none;
  background: transparent;
  color: var(--text-muted);
  padding: 7px 16px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all .2s ease;
}

.lang-switch button.active {
  background: linear-gradient(135deg, var(--gold-light), var(--gold-dark));
  color: var(--purple-dark);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 20% 20%, var(--purple-light) 0%, transparent 45%),
              radial-gradient(circle at 80% 0%, var(--purple-mid) 0%, transparent 40%),
              linear-gradient(180deg, var(--purple-dark), var(--purple) 60%, var(--purple-dark));
  padding: 70px 6vw 0;
}

.hero .dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(240, 207, 122, 0.18) 1.5px, transparent 1.5px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 55% 60% at 50% 30%, black 60%, transparent 100%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  z-index: 2;
}

.hero h1 {
  font-size: clamp(26px, 4vw, 44px);
  font-weight: 800;
  margin: 0 0 18px;
  line-height: 1.25;
}

.hero p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-light);
  max-width: 720px;
  margin: 0 auto 30px;
}

.gold-rule {
  width: 70px;
  height: 3px;
  background: var(--gold);
  margin: 0 auto 22px;
  border-radius: 2px;
}

.skyline {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
  margin-top: 30px;
  opacity: 0.9;
}

/* ===== Form card ===== */
.form-section {
  position: relative;
  margin: -60px auto 60px;
  max-width: 640px;
  z-index: 3;
  padding: 0 6vw;
}

.card {
  background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  border: 1px solid rgba(217, 164, 65, 0.35);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(6px);
}

.card h2 {
  margin: 0 0 6px;
  font-size: 20px;
  color: var(--white);
}

.card .hint {
  margin: 0 0 22px;
  font-size: 13px;
  color: var(--text-muted);
}

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin: 16px 0 6px;
  color: var(--gold-light);
  letter-spacing: .3px;
}

textarea, input[type="text"], input[type="password"], input[type="date"], input[type="time"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.06);
  color: var(--white);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color .2s ease;
}

textarea { resize: vertical; min-height: 120px; }

textarea:focus, input:focus {
  border-color: var(--gold);
}

textarea::placeholder, input::placeholder { color: rgba(236,230,249,0.4); }

.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
  width: 100%;
  padding: 14px 20px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-dark));
  color: var(--purple-dark);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: .5px;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}

.btn-gold:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(217,164,65,0.35); }
.btn-gold:active { transform: translateY(0); }
.btn-gold:disabled { opacity: .6; cursor: default; transform: none; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid rgba(217,164,65,0.5);
  background: transparent;
  color: var(--gold-light);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}

.anon-note {
  margin-top: 14px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}

.status-msg {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 13px;
  display: none;
}
.status-msg.ok { display: block; background: rgba(90, 200, 130, 0.15); color: #9fe8b6; border: 1px solid rgba(90,200,130,.35); }
.status-msg.err { display: block; background: rgba(220, 90, 90, 0.15); color: #f2a9a9; border: 1px solid rgba(220,90,90,.35); }

/* honeypot */
.hp-field { position: absolute; left: -9999px; top: -9999px; }

footer.site-footer {
  text-align: center;
  padding: 24px 6vw 40px;
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== Admin ===== */
.admin-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.admin-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 6vw;
  background: radial-gradient(circle at 50% 0%, var(--purple-mid) 0%, transparent 55%),
              linear-gradient(180deg, var(--purple-dark), var(--purple));
}

.admin-card {
  width: 100%;
  max-width: 460px;
}

.filter-card {
  max-width: 560px;
}

.filter-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.filter-grid .full { grid-column: 1 / -1; }

.stat-row {
  display: flex;
  gap: 14px;
  margin: 22px 0 6px;
}

.stat-box {
  flex: 1;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(217,164,65,0.25);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}

.stat-box .num {
  font-size: 26px;
  font-weight: 800;
  color: var(--gold-light);
}

.stat-box .label {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 6vw;
  background: var(--purple-dark);
  border-bottom: 1px solid rgba(217,164,65,0.25);
}

.top-bar .user {
  font-size: 13px;
  color: var(--text-muted);
}

.error-box {
  background: rgba(220, 90, 90, 0.15);
  color: #f2a9a9;
  border: 1px solid rgba(220,90,90,.35);
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 16px;
}

.success-box {
  background: rgba(90, 200, 130, 0.15);
  color: #9fe8b6;
  border: 1px solid rgba(90,200,130,.35);
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 16px;
}

/* ===== Showcase ===== */
.showcase-shell {
  min-height: 100vh;
  background: radial-gradient(circle at 15% 10%, var(--purple-light) 0%, transparent 45%),
              radial-gradient(circle at 85% 90%, var(--purple-mid) 0%, transparent 45%),
              linear-gradient(180deg, var(--purple-dark), var(--purple) 55%, var(--purple-dark));
  padding: 40px 4vw 60px;
}

.showcase-header {
  text-align: center;
  margin-bottom: 36px;
}

.showcase-header .badge {
  display: inline-block;
  padding: 6px 18px;
  border-radius: 999px;
  border: 1px solid rgba(217,164,65,0.5);
  color: var(--gold-light);
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.showcase-header h1 {
  font-size: clamp(24px, 3.5vw, 38px);
  margin: 0 0 8px;
}

.showcase-header .meta {
  color: var(--text-muted);
  font-size: 14px;
}

.showcase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 22px;
  max-width: 1400px;
  margin: 0 auto;
}

.proposal-card {
  background: linear-gradient(160deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02));
  border: 1px solid rgba(217, 164, 65, 0.3);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(14px);
  animation: cardIn .5s ease forwards;
}

@keyframes cardIn {
  to { opacity: 1; transform: translateY(0); }
}

.proposal-card .msg {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--white);
  white-space: pre-wrap;
  word-break: break-word;
}

.proposal-card .divider {
  height: 1px;
  background: rgba(217,164,65,0.25);
  margin: 16px 0 10px;
}

.proposal-card .who {
  font-size: 12.5px;
  color: var(--gold-light);
  font-weight: 700;
}

.proposal-card .time {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--text-muted);
}

@media (max-width: 640px) {
  .filter-grid { grid-template-columns: 1fr; }
  .site-header { padding: 14px 5vw; }
  .form-section { margin-top: -40px; }
}
