/* ============================================================
   G&G GAMES 2026 — STYLESHEET
   Mobile-first · Dark theme
   ============================================================ */

/* --- 1. CUSTOM PROPERTIES --- */
:root {
  --bg:           #000000;
  --bg-2:         #080808;
  --bg-card:      #0d0d0d;
  --accent:       #FF8C00;
  --accent-2:     #CC3300;
  --gold:         #D4821A;
  --text:         #CCCCCC;
  --text-muted:   #666666;
  --border:       #1e1e1e;
  --font-display: 'Bebas Neue', sans-serif;
  --font-body:    'Inter', sans-serif;
  --radius:       8px;
  --radius-sm:    4px;
  --ease:         cubic-bezier(0.4, 0, 0.2, 1);
  --pad-section:  4rem 1.25rem;
  --max-w:        1100px;
  --max-w-text:   720px;
}

/* --- 2. RESET & BASE --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* --- 3. LAYOUT UTILITIES --- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.container--narrow {
  max-width: var(--max-w-text);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 8vw, 3.8rem);
  color: var(--accent);
  text-align: center;
  letter-spacing: 0.03em;
}
.section-eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 0.6rem;
}
.hidden { display: none !important; }

/* --- 4. HEADER --- */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0.9rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
  border-bottom: 1px solid transparent;
}
header.scrolled {
  background: rgba(0, 0, 0, 0.93);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.header-logo {
  height: 36px;
  width: auto;
}
.header-cta {
  display: inline-block;
  background: var(--accent);
  color: #000;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.1em;
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-sm);
  transition: background 0.2s, transform 0.15s;
}
.header-cta:hover {
  background: #ffaa00;
  transform: translateY(-1px);
}

/* --- 5. BUTTONS --- */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  letter-spacing: 0.1em;
  border-radius: var(--radius-sm);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
  text-align: center;
  cursor: pointer;
}
.btn:hover  { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: linear-gradient(135deg, #FF8C00 0%, #CC3300 100%);
  color: #000;
  font-size: clamp(1.25rem, 3.5vw, 1.5rem);
  padding: 1rem 2.5rem;
  box-shadow: 0 4px 22px rgba(255, 140, 0, 0.28);
}
.btn--primary:hover {
  box-shadow: 0 8px 36px rgba(255, 140, 0, 0.52);
}
.btn--large {
  font-size: clamp(1.4rem, 4vw, 1.85rem);
  padding: 1.2rem 3rem;
  width: 100%;
  max-width: 420px;
}
.btn--outline {
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-size: 1rem;
  padding: 0.75rem 2rem;
}
.btn--outline:hover { background: rgba(255, 140, 0, 0.1); }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}
.btn--shake { animation: shake 0.4s ease; }

/* --- 6. HERO --- */
#hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5.5rem 1.25rem 4rem;
  background: radial-gradient(ellipse 90% 65% at 50% 40%, #200900 0%, #000000 68%);
  position: relative;
  overflow: hidden;
}

.hero-logo {
  width: clamp(100px, 26vw, 180px);
  height: auto;
  margin-bottom: 1.5rem;
  animation: fire-glow 3s ease-in-out infinite;
}
.hero-eyebrow {
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(4rem, 18vw, 10rem);
  color: #ffffff;
  letter-spacing: 0.02em;
  line-height: 0.88;
  margin-bottom: 0.3rem;
}
.hero-title .accent { color: var(--accent); }
.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(0.9rem, 2.8vw, 1.35rem);
  color: var(--text-muted);
  letter-spacing: 0.2em;
  margin-bottom: 2rem;
}
.hero-urgency {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(204, 51, 0, 0.14);
  border: 1px solid rgba(204, 51, 0, 0.45);
  color: #FF6040;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 0.38rem 1rem;
  border-radius: 20px;
  margin-bottom: 1.75rem;
}
.scroll-hint {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-muted);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  animation: hint-bounce 2.2s ease-in-out infinite;
}
.scroll-hint-arrow {
  display: block;
  width: 1px;
  height: 30px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}
@keyframes hint-bounce {
  0%, 100% { opacity: 0.4; transform: translateX(-50%) translateY(0); }
  50%       { opacity: 0.9; transform: translateX(-50%) translateY(5px); }
}

/* --- 7. COUNTDOWN --- */
.countdown {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  justify-content: center;
  margin-bottom: 2rem;
}
.cd-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(255, 140, 0, 0.07);
  border: 1px solid rgba(255, 140, 0, 0.22);
  border-radius: var(--radius);
  padding: 0.7rem 0.55rem;
  min-width: 62px;
}
.cd-number {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 7vw, 2.9rem);
  color: var(--accent);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.cd-label {
  font-size: 0.52rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.2rem;
}
.cd-sep {
  font-family: var(--font-display);
  font-size: 2rem;
  color: rgba(255, 140, 0, 0.4);
  line-height: 1;
  padding-bottom: 0.6rem;
  margin: 0 -0.05rem;
}

/* --- 8. DESCRIZIONE --- */
#descrizione {
  padding: var(--pad-section);
  background: var(--bg-2);
}
#descrizione .intro-super {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 9vw, 5rem);
  color: #fff;
  text-align: center;
  letter-spacing: 0.02em;
  line-height: 0.9;
  margin-bottom: 2.5rem;
}
#descrizione .intro-super .line-accent {
  display: block;
  color: var(--accent);
}
.lead {
  font-size: clamp(1rem, 2.4vw, 1.12rem);
  color: var(--text);
  line-height: 1.82;
  margin-bottom: 1.2rem;
}
.badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin: 2rem 0;
}
.badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  padding: 0.3rem 0.9rem;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
}
.badge--solid  { background: var(--accent); color: #000; }
.badge--outline { border: 1px solid var(--accent); color: var(--accent); }

/* --- 9. TIMELINE (GIORNATA) --- */
#giornata {
  padding: var(--pad-section);
  background: var(--bg);
}
.timeline {
  position: relative;
  max-width: 620px;
  margin: 2.5rem auto 0;
  padding-left: 2.75rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 0.7rem;
  top: 0.3rem;
  bottom: 2rem;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent) 0%, var(--accent-2) 60%, transparent 100%);
}
.timeline-item {
  position: relative;
  margin-bottom: 2.25rem;
}
.timeline-item:last-child { margin-bottom: 0; }
.timeline-dot {
  position: absolute;
  left: -2.05rem;
  top: 0.3rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  box-shadow: 0 0 10px rgba(255, 140, 0, 0.7);
  flex-shrink: 0;
}
.timeline-time {
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--accent);
  letter-spacing: 0.15em;
  margin-bottom: 0.15rem;
}
.timeline-title {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 4vw, 1.7rem);
  color: #fff;
  letter-spacing: 0.02em;
  margin-bottom: 0.35rem;
  line-height: 1;
}
.timeline-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* --- 10. PREMIO --- */
#premio {
  padding: 5.5rem 1.25rem;
  background: radial-gradient(ellipse 85% 75% at 50% 50%, #1d0600 0%, #000 65%);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.trophy-icon {
  display: block;
  width: clamp(100px, 25vw, 180px);
  height: auto;
  margin: 0 auto 1.25rem;
  filter: drop-shadow(0 0 18px rgba(255, 215, 0, 0.45));
}
.master-title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 12vw, 7rem);
  background: linear-gradient(135deg, #FFD700 0%, #FF8C00 55%, #CC3300 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.02em;
  line-height: 0.88;
  margin-bottom: 2.25rem;
}
.premio-text {
  font-size: clamp(1rem, 2.4vw, 1.1rem);
  color: var(--text);
  line-height: 1.82;
  margin-bottom: 1.2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* --- 11. INFO GRID --- */
#info {
  padding: var(--pad-section);
  background: var(--bg-2);
}
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
  max-width: 820px;
  margin: 2.25rem auto 0;
}
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.1rem 1.2rem;
  transition: border-color 0.3s var(--ease);
}
.info-card:hover { border-color: rgba(255, 140, 0, 0.35); }
.info-card-icon {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
  display: block;
}
.info-card-label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 0.2rem;
}
.info-card-value {
  font-size: 1.05rem;
  color: #fff;
  font-weight: 600;
  line-height: 1.3;
}
.info-card-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* --- 12. CTA FINALE --- */
#cta-finale {
  padding: 5rem 1.25rem;
  background: var(--bg);
  text-align: center;
  border-top: 1px solid var(--border);
}
.cta-finale-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 9vw, 4.5rem);
  color: #fff;
  letter-spacing: 0.02em;
  margin-bottom: 0.6rem;
  line-height: 0.95;
}
.cta-finale-deadline {
  font-size: 0.82rem;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 2rem;
  line-height: 1.7;
}
.cta-finale-deadline strong { color: var(--accent-2); }
.cta-finale-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 1.25rem;
}

/* --- 13. FOOTER --- */
footer {
  background: #000;
  border-top: 1px solid var(--border);
  padding: 2rem 1.25rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.8;
}
.footer-logo {
  height: 60px;
  width: auto;
  margin: 0 auto 1rem;
}

/* --- 14. FORM — iscrizione.html --- */
.form-hero {
  padding: 6.5rem 1.25rem 2.5rem;
  text-align: center;
  background: radial-gradient(ellipse 85% 55% at 50% 0%, #200800 0%, #000 65%);
  border-bottom: 1px solid var(--border);
}
.form-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 8vw, 4rem);
  color: var(--accent);
  letter-spacing: 0.03em;
  margin-bottom: 1.75rem;
  line-height: 0.95;
}
.quota-box {
  background: var(--bg-card);
  border: 1px solid rgba(255, 140, 0, 0.28);
  border-radius: var(--radius);
  padding: 1.5rem;
  max-width: 520px;
  margin: 0 auto;
  text-align: left;
}
.quota-price {
  font-family: var(--font-display);
  font-size: 2.8rem;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 0.75rem;
}
.quota-includes {
  list-style: none;
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.85;
}
.quota-includes li::before {
  content: '✓ ';
  color: var(--accent);
  font-weight: 700;
}
.quota-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  line-height: 1.65;
}

/* Form body */
.registration-form {
  max-width: 620px;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
}
fieldset {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
legend {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0 0.5rem;
}
.form-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.form-group:last-child { margin-bottom: 0; }

label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.02em;
}
input[type="text"],
input[type="email"],
input[type="tel"],
select,
textarea {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.75rem 1rem;
  width: 100%;
  min-height: 44px;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 140, 0, 0.14);
}
input::placeholder, textarea::placeholder {
  color: var(--text-muted);
  font-size: 0.9rem;
}
textarea { resize: vertical; min-height: 80px; }

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23FF8C00' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}
select option { background: #1a1a1a; color: var(--text); }

/* Radio */
.radio-options {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.radio-option-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.6rem 1rem;
  min-height: 44px;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
  flex: 1;
  min-width: 90px;
  justify-content: center;
}
.radio-option-label input[type="radio"] {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
  min-height: unset;
  flex-shrink: 0;
}
.radio-option-label:has(input:checked) {
  border-color: var(--accent);
  background: rgba(255, 140, 0, 0.1);
  color: #fff;
}

/* Checkboxes */
.checkbox-group { display: flex; flex-direction: column; }
.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  cursor: pointer;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.checkbox-label:last-child { border-bottom: none; }
.checkbox-label input[type="checkbox"] {
  accent-color: var(--accent);
  width: 18px;
  height: 18px;
  min-height: unset;
  flex-shrink: 0;
  margin-top: 0.12rem;
  cursor: pointer;
}
.checkbox-label span {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.55;
}
.link-accent { color: var(--accent); text-decoration: underline; }

/* Error state */
.field-error {
  border-color: #cc3300 !important;
  box-shadow: 0 0 0 3px rgba(204, 51, 0, 0.14) !important;
}

/* Submit area */
.form-submit {
  margin-top: 2rem;
  text-align: center;
}
.form-posti {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(204, 51, 0, 0.1);
  border: 1px solid rgba(204, 51, 0, 0.3);
  border-radius: 20px;
  padding: 0.38rem 1rem;
  color: #FF6040;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}
.btn--submit { width: 100%; max-width: 420px; }
.btn--submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}
.submit-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 1rem;
  line-height: 1.65;
}
.form-error-msg {
  background: rgba(204, 51, 0, 0.14);
  border: 1px solid rgba(204, 51, 0, 0.45);
  color: #FF6040;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  margin-top: 1rem;
  display: none;
}

/* Back link */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  transition: color 0.2s;
  padding: 0.5rem 0;
}
.back-link:hover { color: var(--accent); }

/* Success */
.success-message {
  max-width: 560px;
  margin: 5rem auto 3rem;
  text-align: center;
  padding: 2rem 1.25rem;
  display: none;
}
.success-icon {
  font-size: clamp(3rem, 10vw, 4.5rem);
  margin-bottom: 1rem;
  display: block;
}
.success-message h2 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 8vw, 3.5rem);
  color: var(--accent);
  margin-bottom: 1rem;
  line-height: 0.95;
}
.success-message p {
  color: var(--text);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}

/* --- 15. ANIMATIONS --- */
@keyframes fire-glow {
  0%, 100% {
    filter: drop-shadow(0 0 8px rgba(255, 140, 0, 0.65))
            drop-shadow(0 0 22px rgba(204, 51, 0, 0.38));
  }
  50% {
    filter: drop-shadow(0 0 16px rgba(255, 140, 0, 0.9))
            drop-shadow(0 0 42px rgba(255, 80, 0, 0.6));
  }
}
@keyframes pulse-ring {
  0%, 100% { box-shadow: 0 0 0 0 rgba(204, 51, 0, 0.45); }
  50%       { box-shadow: 0 0 0 9px rgba(204, 51, 0, 0); }
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.17s; }
.reveal-d3 { transition-delay: 0.26s; }
.reveal-d4 { transition-delay: 0.35s; }
.reveal-d5 { transition-delay: 0.44s; }
.reveal-d6 { transition-delay: 0.53s; }

.urgency--critical { animation: pulse-ring 1.6s ease-in-out infinite; }

/* --- 16. TABLET (768px+) --- */
@media (min-width: 768px) {
  :root { --pad-section: 5.5rem 2rem; }

  .form-row { flex-direction: row; }
  .form-row .form-group { flex: 1; margin-bottom: 0; }

  .info-grid { grid-template-columns: repeat(3, 1fr); }

  .timeline { padding-left: 3.25rem; }
  .timeline::before { left: 0.8rem; }
  .timeline-dot { left: -2.45rem; }
}

/* --- 17. DESKTOP (1200px+) --- */
@media (min-width: 1200px) {
  .hero-logo { width: 200px; }
  .container { padding: 0 2rem; }
}

/* --- 18. ACCESSIBILITY --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
