 :root {
    --lime: #8DC63F; --teal: #00BCD4; --navy: #0D1E3D;
    --navy-light: #1a2f52; --lime-dark: #6fa32e; --teal-dark: #0097a7;
    --white: #ffffff; --muted: rgba(255,255,255,0.55);
    --border: rgba(255,255,255,0.12); --card-bg: rgba(255,255,255,0.06);
    --card-border: rgba(255,255,255,0.10); --error: #ff5f5f;
    --radius: 14px; --radius-sm: 8px;
  }
  * { box-sizing: border-box; margin: 0; padding: 0; }
  body { font-family: 'DM Sans', sans-serif; background: var(--navy); color: var(--white); min-height: 100vh; overflow-x: hidden; position: relative; }
  body::before {
    content: ''; position: fixed; inset: 0;
    background:
      radial-gradient(ellipse 80% 60% at 50% -10%, rgba(0,188,212,0.18) 0%, transparent 70%),
      radial-gradient(ellipse 50% 40% at 90% 80%, rgba(141,198,63,0.12) 0%, transparent 60%),
      repeating-linear-gradient(0deg, transparent, transparent 39px, rgba(255,255,255,0.015) 40px),
      repeating-linear-gradient(90deg, transparent, transparent 39px, rgba(255,255,255,0.015) 40px);
    pointer-events: none; z-index: 0;
  }
  .wrap { position: relative; z-index: 1; max-width: 520px; margin: 0 auto; padding: 0 16px 60px; }

  /* ─── Header ─── */
  .site-header { padding: 24px 0 20px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--border); margin-bottom: 28px; }
  .logo-svg { width: 80px; height: 80px; flex-shrink: 0; }
  .header-badge { margin-left: auto; background: rgba(141,198,63,0.15); border: 1px solid rgba(141,198,63,0.35); color: var(--lime); font-size: 10px; font-weight: 600; letter-spacing: 0.8px; text-transform: uppercase; padding: 4px 10px; border-radius: 20px; white-space: nowrap; }

  /* ─── Hero ─── */
  .hero { text-align: center; padding: 8px 0 32px; animation: fadeUp 0.6s ease both; }
  .hero .eyebrow { font-size: 11px; letter-spacing: 2px; text-transform: uppercase; color: var(--teal); font-weight: 500; margin-bottom: 10px; }
  .hero h1 { font-family: 'Bebas Neue', sans-serif; font-size: clamp(46px, 12vw, 72px); line-height: 0.95; letter-spacing: 1px; background: linear-gradient(135deg, #fff 0%, rgba(141,198,63,0.9) 50%, var(--teal) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; margin-bottom: 14px; }
  .hero .prize-pill { display: inline-flex; align-items: center; gap: 8px; background: linear-gradient(135deg, var(--lime) 0%, var(--teal) 100%); color: var(--navy); font-weight: 700; font-size: 13px; padding: 8px 20px; border-radius: 30px; letter-spacing: 0.3px; margin-bottom: 14px; }
  .hero p { color: var(--muted); font-size: 14px; line-height: 1.6; max-width: 340px; margin: 0 auto; }

  /* ─── Match card ─── */
  .match-card { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius); padding: 20px; margin-bottom: 24px; animation: fadeUp 0.6s ease 0.1s both; }
  .match-label { font-size: 10px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--teal); font-weight: 600; margin-bottom: 14px; display: flex; align-items: center; gap: 6px; }
  .match-label::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--teal); animation: pulse 1.5s infinite; }
  .match-teams { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .team { text-align: center; flex: 1; }
  .team-flag { width: 72px; height: 72px; object-fit: cover; border-radius: 6px; margin: 0 auto 8px; display: block; box-shadow: 0 2px 8px rgba(0,0,0,0.35); }
  .team-name { font-family: 'Bebas Neue', sans-serif; font-size: 18px; letter-spacing: 0.5px; }
  .vs-block { text-align: center; flex-shrink: 0; }
  .vs { font-family: 'Bebas Neue', sans-serif; font-size: 28px; color: var(--muted); }
  .match-meta { font-size: 11px; color: var(--muted); margin-top: 2px; display: flex; flex-direction: column; gap: 2px; align-items: center; }
  .match-info-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
  .match-chip { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
  .match-chip svg { width: 12px; height: 12px; opacity: 0.7; }

  /* ─── Section title ─── */
  .section-title { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); font-weight: 500; margin-bottom: 12px; padding-left: 2px; }

  /* ─── Prediction cards ─── */
  .predictions { margin-bottom: 28px; animation: fadeUp 0.6s ease 0.2s both; }
  .pred-card { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 12px; transition: border-color 0.2s; }
  .pred-card.filled { border-color: rgba(141,198,63,0.4); }
  .pred-header { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
  .pred-icon { width: 34px; height: 34px; border-radius: 8px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 16px; }
  .pred-icon.half1 { background: rgba(0,188,212,0.15); }
  .pred-icon.half2 { background: rgba(141,198,63,0.15); }
  .pred-icon.ft { background: rgba(255,190,50,0.15); }
  .pred-icon.goal { background: rgba(255,100,100,0.15); }
  .pred-title { font-size: 14px; font-weight: 500; }
  .pred-subtitle { font-size: 11px; color: var(--muted); margin-top: 2px; }
  .pred-status { margin-left: auto; width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 11px; transition: all 0.2s; flex-shrink: 0; }
  .pred-card.filled .pred-status { background: var(--lime); border-color: var(--lime); color: var(--navy); }

  /* ─── 1X2 Selector ─── */
  .outcome-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
  .outcome-btn {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 4px; padding: 14px 8px; border-radius: 12px; cursor: pointer;
    border: 1.5px solid var(--border); background: rgba(255,255,255,0.05);
    transition: all 0.18s; user-select: none;
  }
  .outcome-btn:hover { border-color: rgba(255,255,255,0.3); background: rgba(255,255,255,0.09); }
  .outcome-btn.selected { background: rgba(141,198,63,0.15); border-color: var(--lime); }
  .outcome-btn .o-symbol { font-family: 'Bebas Neue', sans-serif; font-size: 26px; line-height: 1; color: var(--white); }
  .outcome-btn.selected .o-symbol { color: var(--lime); }
  .outcome-btn .o-label { font-size: 10px; color: var(--muted); letter-spacing: 0.5px; text-align: center; line-height: 1.3; }
  .outcome-btn.selected .o-label { color: rgba(141,198,63,0.8); }
  .outcome-btn .o-team { font-size: 11px; font-weight: 500; color: var(--muted); text-align: center; line-height: 1.3; max-width: 80px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .outcome-btn.selected .o-team { color: var(--white); }

  /* Scorer dropdown */
  .select-wrap { position: relative; }
  .select-wrap select { width: 100%; appearance: none; background: rgba(255,255,255,0.07); border: 1px solid var(--border); color: var(--white); border-radius: 10px; padding: 12px 38px 12px 14px; font-size: 14px; font-family: 'DM Sans', sans-serif; cursor: pointer; transition: border-color 0.2s; }
  .select-wrap select:focus { outline: none; border-color: var(--teal); }
  .select-wrap select option { background: #0d1e3d; color: #fff; }
  .select-wrap::after { content: '▾'; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; font-size: 13px; }

  /* ─── Customer details ─── */
  .customer-form { margin-bottom: 28px; animation: fadeUp 0.6s ease 0.3s both; }
  .field { margin-bottom: 14px; }
  .field label { display: block; font-size: 12px; font-weight: 500; color: var(--muted); margin-bottom: 6px; letter-spacing: 0.3px; }
  .field label .req { color: var(--lime); margin-left: 2px; }
  .field input { width: 100%; background: rgba(255,255,255,0.07); border: 1px solid var(--border); border-radius: 10px; color: var(--white); font-family: 'DM Sans', sans-serif; font-size: 14px; padding: 13px 16px; transition: border-color 0.2s; }
  .field input:focus { outline: none; border-color: var(--teal); }
  .field input::placeholder { color: rgba(255,255,255,0.25); }
  .field .err-msg { font-size: 11px; color: var(--error); margin-top: 5px; display: none; }
  .field.has-error .err-msg { display: block; }
  .field.has-error input { border-color: var(--error); }

  .age-row { display: flex; align-items: center; gap: 8px; background: rgba(255,190,50,0.08); border: 1px solid rgba(255,190,50,0.2); border-radius: 10px; padding: 14px 16px; margin-bottom: 14px; }
  .age-row input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--lime); cursor: pointer; flex-shrink: 0; }
  .age-row label { font-size: 13px; color: rgba(255,255,255,0.8); cursor: pointer; line-height: 1.4; }

  .tc-row { display: flex; align-items: flex-start; gap: 8px; background: var(--card-bg); border: 1px solid var(--card-border); border-radius: 10px; padding: 14px 16px; margin-bottom: 20px; }
  .tc-row input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--lime); cursor: pointer; flex-shrink: 0; margin-top: 1px; }
  .tc-row label { font-size: 12px; color: var(--muted); cursor: pointer; line-height: 1.5; }
  .tc-row label a { color: var(--lime); text-decoration: none; }
  .tc-row label a:hover { text-decoration: underline; }

  .btn-submit { width: 100%; padding: 17px; background: linear-gradient(135deg, var(--lime) 0%, var(--teal) 100%); color: var(--navy); border: none; border-radius: var(--radius); font-family: 'Bebas Neue', sans-serif; font-size: 20px; letter-spacing: 1.5px; cursor: pointer; transition: opacity 0.2s, transform 0.1s; }
  .btn-submit:hover { opacity: 0.92; }
  .btn-submit:active { transform: scale(0.99); }
  .btn-submit:disabled { opacity: 0.45; cursor: not-allowed; }

  .state-screen { text-align: center; padding: 60px 20px; animation: fadeUp 0.5s ease both; }
  .state-icon { font-size: 56px; margin-bottom: 16px; display: block; }
  .state-screen h2 { font-family: 'Bebas Neue', sans-serif; font-size: 32px; margin-bottom: 10px; }
  .state-screen p { color: var(--muted); font-size: 14px; line-height: 1.6; max-width: 300px; margin: 0 auto; }

  #successScreen { display: none; text-align: center; padding: 60px 20px; animation: fadeUp 0.5s ease both; }
  .success-ring { width: 80px; height: 80px; border-radius: 50%; background: linear-gradient(135deg, var(--lime), var(--teal)); display: flex; align-items: center; justify-content: center; font-size: 36px; margin: 0 auto 24px; }
  #successScreen h2 { font-family: 'Bebas Neue', sans-serif; font-size: 36px; margin-bottom: 10px; }
  #successScreen p { color: var(--muted); font-size: 14px; line-height: 1.6; max-width: 320px; margin: 0 auto 8px; }
  .ref-box { display: inline-block; background: rgba(141,198,63,0.12); border: 1px solid rgba(141,198,63,0.3); border-radius: 8px; padding: 8px 20px; font-family: 'Bebas Neue', sans-serif; font-size: 18px; letter-spacing: 2px; color: var(--lime); margin: 16px 0; }

  .prizes { margin-bottom: 28px; animation: fadeUp 0.6s ease 0.15s both; }
  .prize-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
  .prize-item { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius-sm); padding: 14px 10px; text-align: center; }
  .prize-item.gold { border-color: rgba(255,190,50,0.35); background: rgba(255,190,50,0.07); }
  .prize-item.silver { border-color: rgba(180,180,180,0.3); background: rgba(180,180,180,0.05); }
  .prize-item.bronze { border-color: rgba(180,110,50,0.3); background: rgba(180,110,50,0.05); }
  .prize-emoji { font-size: 28px; margin-bottom: 6px; display: block; }
  .prize-rank { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
  .prize-val { font-family: 'DM Sans', sans-serif; font-size: 17px; letter-spacing: 0.5px; line-height: 1.2; }

  .site-footer { text-align: center; padding-top: 32px; margin-top: 32px; border-top: 1px solid var(--border); font-size: 11px; color: rgba(255,255,255,0.3); line-height: 1.8; }

  #toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%) translateY(20px); background: var(--navy-light); border: 1px solid var(--border); color: var(--white); font-size: 13px; padding: 10px 20px; border-radius: 30px; opacity: 0; transition: all 0.3s; z-index: 999; white-space: nowrap; pointer-events: none; }
  #toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

  @keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
  @keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

  /* ─── Tiebreaker card ─── */
  .pred-icon.tb { background: rgba(255,190,50,0.15); }
  .pred-card.tiebreaker { border-color: rgba(255,190,50,0.2); background: rgba(255,190,50,0.04); }
  .pred-card.tiebreaker.filled { border-color: rgba(255,190,50,0.55); }
  .pred-card.tiebreaker .pred-card.filled .pred-status { background: rgba(255,190,50,0.9); border-color: rgba(255,190,50,0.9); color: #1a1a00; }
  .tb-badge { display: inline-block; font-size: 9px; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; background: rgba(255,190,50,0.18); border: 1px solid rgba(255,190,50,0.4); color: rgba(255,190,50,0.9); padding: 2px 7px; border-radius: 10px; margin-left: 6px; vertical-align: middle; }
  .tb-hint { font-size: 11px; color: rgba(255,190,50,0.65); margin-top: 10px; text-align: center; line-height: 1.5; }
  /* Minute stepper */
  .minute-wrap { display: flex; align-items: center; justify-content: center; gap: 16px; }
  .minute-stepper { display: flex; align-items: center; background: rgba(255,255,255,0.07); border: 1px solid rgba(255,190,50,0.25); border-radius: 14px; overflow: hidden; }
  .minute-btn { background: none; border: none; color: var(--white); width: 44px; height: 50px; font-size: 20px; cursor: pointer; transition: background 0.15s; display: flex; align-items: center; justify-content: center; }
  .minute-btn:active { background: rgba(255,255,255,0.1); }
  .minute-display { display: flex; flex-direction: column; align-items: center; padding: 0 8px; min-width: 64px; }
  .minute-val { font-family: 'Bebas Neue', sans-serif; font-size: 36px; line-height: 1; color: rgba(255,190,50,0.95); }
  .minute-unit { font-size: 10px; color: rgba(255,190,50,0.6); letter-spacing: 1px; text-transform: uppercase; }
