/* Nestlé Football Squad — Scratch & Win
   Mobile-first, RTL, responsive (phone → tablet → laptop) */

:root{
  --green:#0a7d3e;
  --green-dark:#04331c;
  --green-bright:#13a755;
  --ink:#0e1a12;
  --white:#ffffff;
  --err:#ff6b6b;
  --radius:14px;
  --maxw:520px;
  --shadow:0 10px 30px rgba(0,0,0,.35);
  font-synthesis:none;
}

*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%}
body{
  font-family:"Segoe UI",Tahoma,system-ui,"Noto Naskh Arabic","Noto Sans Arabic",Arial,sans-serif;
  color:var(--white);
  min-height:100svh;
  line-height:1.6;
  background:var(--green-dark);
  position:relative;
  overflow-x:hidden;
}

/* Stadium background */
.bg{
  position:fixed;inset:0;z-index:-1;
  background:
    linear-gradient(180deg, rgba(4,51,28,.86) 0%, rgba(2,20,12,.94) 100%),
    url("/assets/img/bg.webp") center/cover no-repeat;
}

.wrap{
  width:100%;
  max-width:var(--maxw);
  margin:0 auto;
  padding:22px 18px calc(22px + env(safe-area-inset-bottom));
  min-height:100svh;
  display:flex;
  flex-direction:column;
  align-items:center;
}

/* Brand / logo */
/* badge on the LEFT, title on the RIGHT (matches the original artwork) — single row on all sizes */
.brand{width:100%;display:flex;align-items:center;justify-content:center;gap:14px;padding:10px 0 16px;flex-wrap:nowrap;direction:ltr}
.brand__badge{flex:0 0 auto;width:clamp(62px,17vw,140px);height:auto;filter:drop-shadow(0 4px 14px rgba(0,0,0,.5))}
.brand__cta{min-width:0;line-height:1.35;text-align:right;text-shadow:0 2px 8px rgba(0,0,0,.45)}
.brand__cta span{display:block}
.brand__cta1{font-weight:600;font-size:clamp(15px,4vw,22px);opacity:.92}
.brand__cta2{font-weight:800;font-size:clamp(18px,5vw,28px);color:#fff;margin-top:1px}
.brand__swoosh{display:block;width:min(100%,280px);height:auto;margin:3px 0 0 auto}

/* Panel card */
.panel{
  width:100%;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  border-radius:var(--radius);
  padding:22px 18px;
  backdrop-filter:blur(6px);
  box-shadow:var(--shadow);
  text-align:center;
}
.panel__title{font-size:clamp(18px,4.6vw,24px);font-weight:700;margin-bottom:6px}
.panel__sub{opacity:.9;font-size:clamp(14px,3.6vw,17px);margin-bottom:14px}

/* Buttons */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  font:inherit;font-weight:700;cursor:pointer;text-decoration:none;
  border:none;border-radius:12px;
  padding:14px 22px;min-height:52px;width:100%;
  color:#fff;background:var(--green);
  transition:transform .06s ease, background .2s ease;
  -webkit-tap-highlight-color:transparent;
}
.btn:active{transform:scale(.98)}
.btn--primary{background:linear-gradient(180deg,var(--green-bright),var(--green));font-size:18px;margin-top:6px}
.btn--primary:hover{background:var(--green-bright)}
.btn--lang{background:rgba(255,255,255,.95);color:var(--green-dark);font-size:18px}
.btn--lang:hover{background:#fff}

/* Language picker */
.panel--lang{display:flex;flex-direction:column;gap:14px}
.lang-choices{display:flex;flex-direction:column;gap:12px;margin-top:6px}
.hero-img{width:min(78%,300px);height:auto;margin:14px auto 0;display:block}

/* Steps */
.steps{list-style:none;display:flex;flex-direction:column;gap:10px;text-align:start;margin-bottom:18px}
.steps li{
  display:flex;align-items:center;gap:12px;
  background:rgba(255,255,255,.07);border-radius:10px;padding:10px 12px;
  font-size:clamp(13px,3.4vw,15px);
}
.steps__n{
  flex:0 0 28px;width:28px;height:28px;border-radius:50%;
  background:var(--green-bright);color:#fff;font-weight:700;
  display:inline-flex;align-items:center;justify-content:center;font-size:14px;
}

/* Form */
.form{display:flex;flex-direction:column;gap:14px;text-align:start;margin-top:6px}
.field{display:flex;flex-direction:column;gap:6px}
.field__label{font-weight:600;font-size:14px}
.field__hint{font-size:12px;opacity:.7}
.field__err{color:var(--err);font-size:13px;font-weight:600}
.input{
  width:100%;font:inherit;font-size:16px;       /* 16px stops iOS zoom-on-focus */
  padding:13px 14px;border-radius:11px;
  border:1.5px solid rgba(255,255,255,.25);
  background:rgba(255,255,255,.97);color:var(--ink);
  outline:none;transition:border-color .15s ease, box-shadow .15s ease;
}
.input:focus{border-color:var(--green-bright);box-shadow:0 0 0 3px rgba(19,167,85,.25)}
.input.is-err{border-color:var(--err);box-shadow:0 0 0 3px rgba(255,107,107,.2)}
select.input{appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='%23555'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:left 14px center;background-size:12px;padding-inline-start:14px}
.input--serial{letter-spacing:3px;text-transform:uppercase;font-weight:700;text-align:center}

/* Alerts */
.alert{border-radius:10px;padding:11px 14px;margin-bottom:12px;font-weight:600;font-size:14px}
.alert--err{background:rgba(255,107,107,.16);border:1px solid var(--err);color:#ffd5d5}

/* Lang switch */
.lang-switch{margin-top:16px;font-size:14px;opacity:.85;display:flex;gap:10px;justify-content:center}
.lang-switch a{color:#fff;text-decoration:none}
.lang-switch a.active{color:var(--green-bright);font-weight:700;text-decoration:underline}

/* Thank you */
.panel--thanks .thanks-badge{margin-bottom:12px}
.panel--thanks .hero-img{margin:6px auto 18px}

/* Footer */
.foot{margin-top:auto;padding-top:22px;text-align:center;display:flex;flex-direction:column;align-items:center;gap:6px}
.foot__by{display:inline-flex;align-items:center;gap:8px;text-decoration:none;color:#fff;opacity:.92;
  background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.12);border-radius:999px;padding:7px 14px;transition:opacity .2s}
.foot__by:hover{opacity:1}
.foot__by span{font-size:12px;opacity:.7;letter-spacing:.3px}
.foot__by img{height:20px;width:auto;display:block}
.foot__copy{font-size:11px;opacity:.45}

/* ===== Tablet ===== */
@media (min-width:600px){
  :root{--maxw:560px}
  .wrap{padding-top:34px}
  .panel{padding:30px 28px}
  .lang-choices{flex-direction:row}
  .steps{flex-direction:row}
  .steps li{flex:1;flex-direction:column;text-align:center;gap:8px}
}

/* ===== Laptop / desktop ===== */
@media (min-width:1024px){
  :root{--maxw:640px}
  .brand__logo{width:380px}
  .panel{padding:36px 38px}
  .panel--form{max-width:640px}
}

/* Reduce motion */
@media (prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}
