/* ==========================================================================
   Cellex Giveaway — mobile first.
   Base styles target a phone; min-width queries scale up. Theme follows the
   main cellex.ae redesign: black canvas, Inter, tight tracking, blue accent.
   ========================================================================== */

:root {
  --black: #000;
  --panel: #101013;
  --panel-2: #17171b;
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.18);
  --text: #f5f5f7;
  --muted: #98989f;
  --muted-2: #6b6b73;
  --blue: #2997ff;
  --green: #30d158;
  --amber: #ff9f0a;
  --red: #ff453a;
  --r: 18px;
  --tap: 52px;             /* minimum comfortable touch target */
  --safe-b: env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--black);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.no-scroll { overflow: hidden; }

img { display: block; max-width: 100%; }
a { color: var(--blue); }

.wrap { width: 100%; max-width: 560px; margin: 0 auto; padding: 0 16px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ----------------------------------------------------------------- topbar */

.bar {
  position: sticky; top: 0; z-index: 60;
  height: 52px; display: flex; align-items: center;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.bar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.bar img { height: 26px; border-radius: 6px; }
.bar a { text-decoration: none; }
.bar .bar__link { color: var(--muted); font-size: 12px; font-weight: 600; }

/* The entry page follows the main Cellex site's floating, pill-shaped header. */
.entry-page .bar {
  position: absolute; inset: 0 0 auto; height: auto; padding: 14px 0;
  background: transparent; border-bottom: 0;
  backdrop-filter: none; -webkit-backdrop-filter: none;
}
.entry-page .bar .wrap {
  min-height: 60px; padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.24); border-radius: 999px;
  background: rgba(16, 16, 18, 0.9);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
}
.entry-page .bar img { width: auto; height: 32px; border-radius: 0; }
.entry-page .bar .bar__link {
  padding: 9px 16px; border-radius: 999px;
  background: #fff; color: #000; font-weight: 700;
}

/* ------------------------------------------------------------------- hero */

.hero {
  position: relative;
  padding: 26px 0 22px;
  text-align: center;
  overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: -60% -30% auto -30%; height: 340px;
  background: radial-gradient(closest-side, rgba(41, 151, 255, 0.22), transparent);
  pointer-events: none;
}
.hero .wrap { position: relative; }

.tag {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 12px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.04);
  font-size: 10px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted);
}
.tag i {
  width: 6px; height: 6px; border-radius: 50%; background: var(--green);
  animation: ping 2s infinite;
}
@keyframes ping {
  0% { box-shadow: 0 0 0 0 rgba(48, 209, 88, 0.6); }
  70% { box-shadow: 0 0 0 8px rgba(48, 209, 88, 0); }
  100% { box-shadow: 0 0 0 0 rgba(48, 209, 88, 0); }
}

h1 {
  font-size: clamp(2rem, 11vw, 2.9rem);
  line-height: 0.97;
  letter-spacing: -0.035em;
  font-weight: 700;
  margin: 14px 0 8px;
}
h1 .accent {
  background: linear-gradient(110deg, #2997ff, #7fe3e7);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p { margin: 0 auto; color: var(--muted); font-size: 0.92rem; max-width: 30ch; }

.hero--entry {
  min-height: 370px; padding: 112px 0 44px;
  display: flex; align-items: center;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.58) 0%, rgba(0, 0, 0, 0.75) 58%, #000 100%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.28), transparent 45%, rgba(0, 0, 0, 0.18)),
    url('../img/cellex-mangalore-hero.webp') center 44% / cover no-repeat;
}
.hero--entry::before { display: none; }
.hero--entry h1 { text-shadow: 0 3px 24px rgba(0, 0, 0, 0.72); }
.hero--entry p { color: rgba(245, 245, 247, 0.78); }

.meta {
  display: flex; justify-content: center; gap: 6px; flex-wrap: wrap;
  margin-top: 14px; font-size: 11px; color: var(--muted-2);
}
.meta b { color: var(--text); font-weight: 600; }
.meta span { padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; }

/* --------------------------------------------------------------- wizard */

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px 16px calc(18px + var(--safe-b));
  margin-bottom: 22px;
}

.prog { display: flex; gap: 5px; margin-bottom: 16px; }
.prog i {
  flex: 1; height: 3px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  transition: background 0.3s ease;
}
.prog i.on { background: var(--blue); }
.prog i.done { background: rgba(41, 151, 255, 0.45); }

.step-head { margin-bottom: 16px; }
.step-head .n { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted-2); font-weight: 700; }
.step-head h2 { font-size: 1.25rem; letter-spacing: -0.02em; margin: 4px 0 4px; }
.step-head p { margin: 0; color: var(--muted); font-size: 0.85rem; }

/* Steps are stacked and all visible without JS; the wizard hides them. */
.js-wizard .step { display: none; }
.js-wizard .step.is-active { display: block; animation: slide 0.28s cubic-bezier(0.22, 1, 0.36, 1); }
@keyframes slide { from { opacity: 0; transform: translateX(14px); } to { opacity: 1; transform: none; } }
.step + .step { margin-top: 26px; }
.js-wizard .step + .step { margin-top: 0; }

/* -------------------------------------------------------------- follow */

.warn {
  display: flex; gap: 10px;
  border: 1px solid rgba(255, 159, 10, 0.3);
  background: rgba(255, 159, 10, 0.07);
  border-radius: 14px; padding: 11px 13px; margin-bottom: 14px;
}
.warn svg { flex: none; margin-top: 2px; }
.warn p { margin: 0; font-size: 0.8rem; color: #ffd8a1; line-height: 1.45; }
.warn b { color: #fff; }

.follow {
  display: flex; align-items: center; gap: 12px; width: 100%;
  min-height: var(--tap);
  padding: 12px 14px; margin-bottom: 10px;
  border-radius: 15px; border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, 0.03);
  color: #fff; font-family: inherit; text-align: left; cursor: pointer;
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.follow:active { transform: scale(0.985); }
.follow .ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.follow--ig .ic { background: linear-gradient(45deg, #f09433, #dc2743 50%, #bc1888); }
.follow--fb .ic { background: #1877f2; }
.follow--wa .ic { background: #25d366; }
.follow:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.follow .tx { flex: 1; min-width: 0; }
.follow .tx b { display: block; font-size: 0.9rem; font-weight: 600; }
.follow .tx span { display: block; font-size: 0.74rem; color: var(--muted); }
.follow .st {
  font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted-2); flex: none;
}
.follow.is-done { border-color: rgba(48, 209, 88, 0.5); background: rgba(48, 209, 88, 0.08); }
.follow.is-done .st { color: var(--green); }

/* --------------------------------------------------------------- fields */

.f { margin-bottom: 14px; }
.f label { display: block; font-size: 0.8rem; font-weight: 600; margin-bottom: 6px; }
.f .req { color: var(--blue); }
.f .hint { font-size: 0.72rem; color: var(--muted-2); margin-top: 5px; }

.in, .sel {
  width: 100%; min-height: var(--tap);
  padding: 13px 14px;
  background: #08080a; color: #fff;
  border: 1px solid var(--line-2); border-radius: 14px;
  font-family: inherit; font-size: 16px;  /* 16px stops iOS zoom-on-focus */
  appearance: none;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.in::placeholder { color: #4e4e55; }
.in:focus, .sel:focus {
  outline: none; border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(41, 151, 255, 0.18);
}
.sel {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%2398989f' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px;
}
.sel option { background: #08080a; }

.tel { display: grid; grid-template-columns: 92px 1fr; gap: 8px; }
.tel .dial {
  display: grid; place-items: center; min-height: var(--tap);
  border: 1px solid var(--line-2); border-radius: 14px; background: #08080a;
  color: var(--muted); font-size: 0.9rem; font-weight: 600;
}

.f.bad .in, .f.bad .sel { border-color: var(--red); box-shadow: 0 0 0 3px rgba(255, 69, 58, 0.14); }
.err { display: block; color: #ff8a80; font-size: 0.76rem; margin-top: 5px; }

.chk {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 11px 0; cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  -webkit-tap-highlight-color: transparent;
}
.chk:last-of-type { border-bottom: 0; }
.chk input {
  appearance: none; flex: none; width: 24px; height: 24px; margin: 0;
  border: 1.5px solid var(--line-2); border-radius: 8px; background: #08080a;
  position: relative; cursor: pointer; transition: background 0.18s, border-color 0.18s;
}
.chk input:checked { background: var(--blue); border-color: var(--blue); }
.chk input:checked::after {
  content: ''; position: absolute; left: 8px; top: 3.5px; width: 5px; height: 11px;
  border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg);
}
.chk input:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.chk span { font-size: 0.82rem; color: var(--muted); line-height: 1.45; }

.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* -------------------------------------------------------------- buttons */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); padding: 14px 22px;
  border: 1px solid transparent; border-radius: 999px;
  font-family: inherit; font-size: 0.95rem; font-weight: 700;
  cursor: pointer; text-decoration: none;
  transition: background 0.2s, opacity 0.2s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(0.985); }
.btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.btn--pri { background: #fff; color: #000; }
.btn--gho { background: transparent; color: #fff; border-color: var(--line-2); }
.btn--full { width: 100%; }
.btn[disabled], .btn.off { opacity: 0.35; cursor: not-allowed; }

.nav-row { display: flex; gap: 10px; margin-top: 18px; }
.nav-row .btn[hidden] { display: none; }
.nav-row .btn--gho { flex: none; width: 52px; padding: 0; }
.nav-row .btn--pri { flex: 1; }

.gate { color: var(--amber); font-size: 0.78rem; margin: 10px 0 0; min-height: 1.1em; }
.fine { color: var(--muted-2); font-size: 0.7rem; text-align: center; margin: 12px 0 0; }

.alert { border-radius: 14px; padding: 12px 14px; margin-bottom: 16px; font-size: 0.83rem; }
.alert--err { background: rgba(255, 69, 58, 0.1); border: 1px solid rgba(255, 69, 58, 0.32); color: #ffb4ae; }
.alert ul { margin: 6px 0 0; padding-left: 17px; }

/* -------------------------------------------------------------- ticket */

.ticket {
  border: 1px dashed rgba(255, 255, 255, 0.28);
  border-radius: 16px; padding: 18px; text-align: center;
  background: rgba(41, 151, 255, 0.06); margin: 18px 0;
}
.ticket .c { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted-2); }
.ticket .n {
  font-family: ui-monospace, Menlo, monospace; font-weight: 700;
  font-size: clamp(1.25rem, 7vw, 1.8rem); letter-spacing: 0.1em; margin-top: 4px;
}

.list { margin: 0; padding-left: 18px; color: var(--muted); font-size: 0.85rem; }
.list li { margin-bottom: 8px; }
.list b { color: #fff; }

/* --------------------------------------------------------- small footer */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 14px 0 calc(14px + var(--safe-b));
}
.site-footer__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 18px;
}
.site-footer small { color: var(--muted-2); font-size: 0.66rem; line-height: 1.45; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: #fff; }

/* --------------------------------------------------------------- rules */

.rules-page { padding: 28px 0 42px; }
.rules-page .wrap { max-width: 760px; }
.rules-card {
  background: #fff;
  color: #111;
  border-radius: 26px;
  padding: 26px 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}
.rules-card__eyebrow {
  color: #68707c;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.rules-card h1 {
  color: #080808;
  font-size: clamp(2rem, 9vw, 3.3rem);
  margin: 8px 0;
}
.rules-card__date { margin: 0; color: #767676; font-size: 0.82rem; }
.rules-card__content { margin-top: 24px; }
.rule-item { padding: 17px 0; border-top: 1px solid #e8e8ea; }
.rule-item h2 { margin: 0 0 6px; color: #111; font-size: 1rem; }
.rule-item p { margin: 0; color: #56565c; font-size: 0.9rem; line-height: 1.65; }
.rules-card__action { margin-top: 18px; }
.btn--rules { width: 100%; background: #090909; color: #fff; }

/* ------------------------------------------------------ cookie banner */

.cs-back {
  position: fixed; inset: 0; z-index: 998;
  background: rgba(0, 0, 0, 0.72);
  opacity: 0; visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.cs-back.on { opacity: 1; visibility: visible; }

.cs {
  position: fixed; z-index: 999; left: 50%; top: 50%;
  width: min(440px, calc(100vw - 32px));
  background: #151518; border: 1px solid var(--line-2); border-radius: 24px;
  padding: 28px;
  text-align: center;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.62);
  transform: translate(-50%, -46%) scale(0.96);
  opacity: 0;
  transition: transform 0.28s ease, opacity 0.28s ease;
  pointer-events: none;
}
.cs.on { transform: translate(-50%, -50%) scale(1); opacity: 1; pointer-events: auto; }
.cs h2 { font-size: 1.35rem; margin: 0 0 8px; }
.cs p { margin: 0; color: var(--muted); font-size: 0.88rem; line-height: 1.55; }
.cs .btn { width: 100%; min-height: 50px; margin-top: 22px; padding: 12px 20px; font-size: 0.92rem; }

/* ------------------------------------------------------------ prose pages */

.prose { padding: 22px 0 40px; }
.prose h1 { font-size: clamp(1.7rem, 8vw, 2.2rem); margin: 10px 0 8px; text-align: left; }
.prose .upd { color: var(--muted-2); font-size: 0.78rem; margin: 0 0 20px; }
.prose h2 { font-size: 1rem; margin: 24px 0 8px; letter-spacing: -0.01em; }
.prose p, .prose li { color: var(--muted); font-size: 0.86rem; margin: 0 0 9px; }
.prose ul { padding-left: 18px; margin: 0 0 12px; }
.prose code { font-family: ui-monospace, Menlo, monospace; font-size: 0.8em; color: #7fe3e7; }
.prose pre {
  background: #08080a; border: 1px solid var(--line); border-radius: 14px;
  padding: 13px; overflow-x: auto; font-size: 0.72rem; color: #7fe3e7;
  font-family: ui-monospace, Menlo, monospace;
}
.prose table { width: 100%; border-collapse: collapse; font-size: 0.8rem; margin-bottom: 14px; }
.prose th { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line-2); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted-2); }
.prose td { padding: 8px 6px; border-bottom: 1px solid rgba(255, 255, 255, 0.05); color: var(--muted); vertical-align: top; }
.prose td:first-child { color: var(--text); }

.kv { border: 1px solid var(--line); border-radius: 16px; padding: 14px; margin-bottom: 12px; }
.kv .h { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.kv .h b { font-size: 0.92rem; }
.kv .s { font-size: 0.72rem; color: var(--muted-2); margin: 4px 0 10px; }
.kv dt { font-size: 9.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted-2); font-weight: 700; margin-top: 9px; }
.kv dd { margin: 3px 0 0; font-family: ui-monospace, Menlo, monospace; font-size: 0.7rem; word-break: break-all; color: #7fe3e7; }
.pill { font-size: 10px; font-weight: 700; padding: 3px 9px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); }
.pill--ok { border-color: rgba(48, 209, 88, 0.45); color: #7ee29a; }

/* ============================ scale up ==================================== */

@media (min-width: 600px) {
  body { font-size: 16px; }
  .wrap { max-width: 620px; padding: 0 24px; }
  .hero { padding: 44px 0 30px; }
  h1 { font-size: 3.2rem; }
  .hero p { font-size: 1rem; }
  .card { padding: 28px 26px; border-radius: 26px; }
  .rules-page { padding: 46px 0 64px; }
  .rules-card { padding: 42px 44px; border-radius: 32px; }
  .prose { padding: 34px 0 60px; }
}

@media (max-width: 599px) {
  .site-footer__row {
    align-items: center;
    flex-direction: column;
    text-align: center;
  }
}

@media (min-width: 900px) {
  .wrap { max-width: 680px; }
  h1 { font-size: 3.8rem; }
  .hero { padding: 58px 0 34px; }
  .prose .wrap { max-width: 760px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}
