@import url("https://fonts.googleapis.com/css2?family=Great+Vibes&family=Poppins:wght@300;400;500;600&display=swap");

/* =========================
   VARIABILI
   ========================= */
:root {
  --bg-dark: #161e4b;
  --bg-overlay: rgba(22,30,75,0.85);
  --primary: #1a3c70;
  --primary-hover: #ffc048;
  --accent: #ffc048;
  --text-main: #ffffff;
  --text-muted: rgba(200,210,255,0.6);
  --card-radius: 16px;
  --shadow-soft: 0 20px 60px rgba(0,0,0,0.7);
}

/* =========================
   RESET BASE
   ========================= */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: "Poppins", system-ui, sans-serif;
  background: url("/giovanni/img/mare.jpg") center/cover no-repeat fixed;
  min-height: 100vh;
  color: var(--text-main);
}

body, .page-wrapper, .main, .card, .form-row {
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(80,120,255,0.12), transparent 40%),
    radial-gradient(circle at 80% 70%, rgba(180,200,255,0.08), transparent 40%);
  pointer-events: none;
}

/* =========================
   HERO
   ========================= */
.hero {
  position: relative;
  padding: 120px 1.2rem 60px;
  text-align: center;
  background: var(--bg-overlay);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(22,30,75,0.6), rgba(22,30,75,0.6));
  z-index: 0;
}

.hero-content {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* NAV HERO */
.hero-nav .nav-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: #cfd8ff; /* leggermente più chiaro */
  padding: 0.5rem 1rem;
  border-radius: 999px;
  transition: all 0.3s ease;
  text-shadow: 0 0 6px rgba(0,0,0,0.5);
}

.hero-nav .nav-link.active,
.hero-nav .nav-link:hover {
  color: var(--primary-hover); /* dorato/arancio */
  background: rgba(26,60,112,0.4);
  text-shadow: 0 0 10px var(--primary-hover);
}

/* =========================
   Choice buttons (Solo per me / Famiglia/Gruppo)
   ========================= */
.choice-buttons .btn {
  flex: 1;
  border-radius: 999px;
  padding: 0.75rem 1.4rem;
  font-size: 1rem;
  font-weight: 600;
  border: 2px solid var(--primary-hover);
  background: rgba(10,15,40,0.45);
  cursor: pointer;
  transition: all 0.25s ease;
  text-align: center;
  color: var(--primary-hover);
}

.choice-buttons .btn:hover {
  background: var(--primary-hover);
  color: #1B1B1B;
  box-shadow: 0 6px 15px rgba(255,209,102,0.7), inset 0 0 8px rgba(255,255,255,0.2);
  transform: translateY(-1px);
}

/* Stato selezionato più marcato */
.choice-buttons .btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 6px 20px rgba(47,73,255,0.7), inset 0 0 8px rgba(255,255,255,0.2);
  transform: translateY(-1px);
}

/* Hover su non selezionato */
.choice-buttons .btn:not(.active):hover {
  background: rgba(47,73,255,0.25);
  color: var(--accent);
  border-color: var(--primary-soft);
  box-shadow: 0 2px 8px rgba(47,73,255,0.4);
}

/* =========================
   Pulsanti + / - (btn outline)
   ========================= */
#groupCountMinus,
#groupCountPlus {
  border: 2px solid var(--primary-soft);
  background: rgba(10,15,40,0.45);
  color: var(--primary-soft);
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: 0 2px 8px rgba(47,73,255,0.4);
  transition: all 0.25s ease;
}

#groupCountMinus:hover,
#groupCountPlus:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 4px 15px rgba(47,73,255,0.7), inset 0 0 6px rgba(255,255,255,0.2);
  transform: translateY(-1px);
}

.nav-link {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  text-decoration: none;
  color: var(--text-muted);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  transition: all 0.2s ease;
}

.nav-link.active,
.nav-link:hover {
  color: var(--text-main);
  background: rgba(26,60,112,0.4);
}

/* HERO TITLE */
.hero-title {
  margin: 0.2rem 0 0.6rem;
}

.hero-script {
  font-family: "Great Vibes", cursive;
  font-size: clamp(2.8rem, 8vw, 3.8rem);
  color: var(--accent);
  text-shadow: 0 0 12px rgba(0,0,0,0.7);
}

.hero-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 1.4rem;
}

/* HERO INFO */
.hero-info {
  display: grid;
  gap: 0.8rem;
  padding: 1rem;
  margin-bottom: 1.6rem;
  backdrop-filter: blur(14px);
  background: rgba(22,30,75,0.55);
  border-radius: var(--card-radius);
  border: 1px solid rgba(255,255,255,0.15);
  box-shadow: var(--shadow-soft);
}

.label {
  font-size: 0.7rem;
  text-transform: uppercase;
  opacity: 0.7;
}

.value {
  font-size: 0.95rem;
}

/* HERO BUTTON */
.hero-cta {
  width: 100%;
  max-width: 280px;
  margin: 0.6rem auto 0;
  padding: 0.9rem 1.2rem;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 999px;
  border: 2px solid var(--primary-hover);
  background: var(--primary);
  color: var(--primary-hover);
  box-shadow: 0 0 12px rgba(80,120,255,0.6), inset 0 0 6px rgba(255,255,255,0.15);
  transition: all 0.3s ease;
  cursor: pointer;
}

.hero-cta:hover {
  background: var(--primary-hover);
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.5);
}

/* =========================
   MAIN / CARD
   ========================= */
.main {
  padding: 2rem 1rem 3rem;
}

.card {
  max-width: 700px;
  margin: 0 auto;
  padding: 1.5rem;
  border-radius: var(--card-radius);
  backdrop-filter: blur(14px);
  background: rgba(22,30,75,0.85);
  border: 1px solid rgba(255,255,255,0.15);
  box-shadow: var(--shadow-soft);
  position: relative;
}

/* CARD HEADER */
.card-header h2 {
  margin-top: 0;
  color: var(--accent);
}

.card-intro {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* FORM ELEMENTS */
.form-row {
  display: flex;
  flex-direction: column;
  margin-bottom: 0.9rem;
  gap: 0.25rem;
}

label {
  font-size: 0.85rem;
  color: var(--accent);
}

input,
textarea {
  padding: 0.6rem;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(0,0,0,0.3);
  color: #fff;
  outline: none;
  font-size: 0.95rem;
  transition: all 0.2s ease;
}

input:focus,
textarea:focus {
  border-color: var(--primary-hover);
  box-shadow: 0 0 6px rgba(47,73,255,0.5);
  background: rgba(6,12,40,0.85);
}

::placeholder {
  color: rgba(200,210,255,0.5);
}

/* =========================
   PULSANTI MODERNI
   ========================= */
.btn {
  border-radius: 999px;
  padding: 0.65rem 1.2rem;
  font-size: 0.95rem;
  font-weight: 500;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn.primary {
  background: var(--primary);
  color: var(--primary-hover);
  border: 2px solid var(--primary-hover);
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.btn.primary:hover {
  background: var(--primary-hover);
  color: var(--primary);
  box-shadow: 0 6px 15px rgba(0,0,0,0.5);
}

.btn.ghost {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn.ghost:hover {
  background: var(--accent);
  color: var(--primary);
}

.btn.outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn.outline:hover {
  background: var(--primary);
  color: var(--primary-hover);
}

/* CHOICE BUTTONS */
.choice-buttons {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.choice-buttons .btn#modeGroup.active {
  background: #FFD166; /* giallo caldo */
  color: #1B1B1B;
  border-color: #FFD166;
  box-shadow: 0 6px 20px rgba(255,209,102,0.7), inset 0 0 8px rgba(255,255,255,0.2);
  transform: translateY(-1px);
}

.choice-buttons .btn:not(.active):hover {
  background: rgba(47,73,255,0.25);
  color: var(--accent);
  border-color: var(--primary-soft);
  box-shadow: 0 2px 8px rgba(47,73,255,0.4);
}

/* ACTIONS */
.actions {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

.actions.single {
  justify-content: flex-end;
}

/* STATUS MESSAGE */
.status-message {
  padding: 0.6rem 0.8rem;
  border-radius: 10px;
  margin-bottom: 0.9rem;
  font-size: 0.86rem;
  background: rgba(11,18,54,0.85);
  border: 1px solid rgba(145,166,240,0.88);
  color: var(--accent);
}

.status-message.error {
  background: rgba(60,10,25,0.98);
  border-color: rgba(255,111,155,0.98);
  color: #ffe5f0;
}

/* FOOTER */
.footer {
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
  padding: 1rem;
}

/* =========================
   MOBILE
   ========================= */
@media (max-width: 600px) {
  .hero {
    padding: 1.5rem 1rem 2rem;
  }

  .main {
    padding: 1.5rem 1rem 2rem;
  }

  .card {
    padding: 1.2rem;
  }

  .hero-script {
    font-size: clamp(2rem, 10vw, 3rem);
  }
}