* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #000;
  color: #fff;
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.presentation-mode {
  overflow: hidden;
}

/* ─── Star Field Canvas ──────────────────────────────────────── */
#starfield {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* ─── Cinematic Letterbox Bars ───────────────────────────────── */
.letterbox {
  position: fixed;
  left: 0;
  right: 0;
  height: 0;
  background: #000;
  z-index: 100;
  transition: height 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.letterbox-top {
  top: 0;
}

.letterbox-bottom {
  bottom: 0;
}

.letterbox.visible {
  height: 8vh;
}

/* ─── Landing Page ───────────────────────────────────────────── */
.landing {
  text-align: center;
  padding: 1.5rem;
  max-width: 600px;
  width: 100%;
  position: relative;
  z-index: 1;
}

.landing h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  letter-spacing: -0.02em;
}

.landing .subtitle {
  font-size: 1rem;
  color: #888;
  margin-bottom: 1.25rem;
  font-weight: 300;
}

.landing .input-group {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.landing input[type="text"] {
  flex: 1;
  padding: 0.85rem 1rem;
  font-size: 1rem;
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  color: #fff;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}

.landing input[type="text"]::placeholder {
  color: #555;
}

.landing input[type="text"]:focus {
  border-color: #fff;
}

/* ─── Accordion ──────────────────────────────────────────────── */
.accordion {
  margin-bottom: 1rem;
  text-align: left;
}

.accordion-toggle {
  font-size: 0.8rem;
  font-weight: 400;
  color: #666;
  cursor: pointer;
  list-style: none;
  padding: 0.5rem 0;
  transition: color 0.2s;
  font-family: inherit;
}

.accordion-toggle::-webkit-details-marker {
  display: none;
}

.accordion-toggle::before {
  content: '+ ';
  font-weight: 300;
}

.accordion[open] .accordion-toggle::before {
  content: '- ';
}

.accordion-toggle:hover {
  color: #aaa;
}

.accordion-content {
  padding-top: 0.5rem;
}

.section-label {
  font-size: 0.75rem;
  color: #666;
  display: block;
  margin-bottom: 0.5rem;
}

/* ─── Attribute Chips ────────────────────────────────────────── */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.chip {
  padding: 0.3rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 400;
  background: #111;
  color: #888;
  border: 1px solid #333;
  border-radius: 100px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
  user-select: none;
}

.chip:hover {
  border-color: #666;
  color: #ccc;
}

.chip.disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.chip.selected {
  background: #fff;
  color: #000;
  border-color: #fff;
  font-weight: 600;
}

/* ─── Create Button ──────────────────────────────────────────── */
.create-btn {
  width: 100%;
  padding: 0.85rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  background: #fff;
  color: #000;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.2s;
  margin-bottom: 1.5rem;
}

.create-btn:hover {
  opacity: 0.85;
}

/* ─── Result ─────────────────────────────────────────────────── */
.result {
  display: none;
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 1rem;
  text-align: left;
}

.result.visible {
  display: block;
}

.result label {
  font-size: 0.8rem;
  color: #888;
  display: block;
  margin-bottom: 0.4rem;
}

.result .url-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.result .url-text {
  flex: 1;
  font-size: 0.85rem;
  word-break: break-all;
  color: #4dabf7;
}

.result .copy-btn {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  background: #222;
  color: #fff;
  border: 1px solid #444;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s;
  white-space: nowrap;
}

.result .copy-btn:hover {
  background: #333;
}

/* ─── Presentation Page ──────────────────────────────────────── */
.presentation {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.splash {
  text-align: center;
  cursor: pointer;
  user-select: none;
}

.splash-btn {
  font-size: 1rem;
  font-weight: 600;
  color: #000;
  background: #fff;
  border: none;
  border-radius: 50px;
  padding: 14px 36px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  animation: pulse 2.5s ease-in-out infinite;
  font-family: inherit;
}

@keyframes pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.8; }
}

/* ─── Word Display ───────────────────────────────────────────── */
.word-display {
  display: none;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  position: fixed;
  inset: 0;
  z-index: 20;
}

.word-display .word {
  font-size: clamp(2.5rem, 10vw, 6rem);
  font-weight: 900;
  opacity: 0;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-transform: uppercase;
  transition: opacity 1s ease-out, transform 1s ease-out;
  max-width: 90vw;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* Sentence style — thin, elegant, lowercase */
.word-display .word.sentence {
  font-size: clamp(1.1rem, 5vw, 2.8rem);
  font-weight: 200;
  text-transform: none;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.9);
}

/* Name reveal — massive, with glow, ALL CAPS */
.word-display .word.name {
  font-size: clamp(2.5rem, 12vw, 7rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  text-shadow:
    0 0 40px rgba(255, 255, 255, 0.5),
    0 0 80px rgba(255, 255, 255, 0.3),
    0 0 120px rgba(255, 255, 255, 0.15);
}

/* Finale — stays on screen, warm glow */
.word-display .word.finale {
  font-size: clamp(1.4rem, 6vw, 3.5rem);
  font-weight: 300;
  text-transform: none;
  letter-spacing: 0.05em;
  text-shadow:
    0 0 30px rgba(255, 255, 255, 0.3),
    0 0 60px rgba(255, 255, 255, 0.15);
}

/* ─── Ghost Button (post-finale) ─────────────────────────────── */
.ghost-btn-container {
  position: fixed;
  bottom: 10vh;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity 2s ease-in;
}

.ghost-btn-container.visible {
  opacity: 1;
  pointer-events: auto;
}

.ghost-btn {
  padding: 0.75rem 2rem;
  font-size: 0.9rem;
  font-weight: 400;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 100px;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: 0.05em;
  transition: all 0.3s;
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.8);
  border-color: rgba(255, 255, 255, 0.4);
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 600px) {
  .landing {
    padding: 1.25rem;
  }

  .landing h1 {
    font-size: 2rem;
  }

  .landing .subtitle {
    font-size: 0.9rem;
    margin-bottom: 1rem;
  }

  .landing .input-group {
    flex-direction: column;
  }

  .landing input[type="text"] {
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
  }

  .create-btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    margin-bottom: 1rem;
  }

  .splash-btn {
    font-size: 0.9rem;
    padding: 12px 28px;
  }

  .letterbox.visible {
    height: 5vh;
  }

  .ghost-btn-container {
    bottom: 8vh;
  }

  .ghost-btn {
    padding: 0.65rem 1.5rem;
    font-size: 0.85rem;
  }
}
