/* Astraro — Global Styles (Home + shared UI)
   Save as: Astraro/assets/css/style.css
*/

:root{
  --bg0:#f6f7ff;
  --bg1:#eef2ff;
  --bg2:#e6f7ff;

  --card: rgba(255,255,255,.75);
  --card2: rgba(255,255,255,.90);
  --stroke: rgba(15,23,42,.14);

  --text:#0b1020;
  --muted: rgba(11,16,32,.70);

  --accent:#4f46e5;
  --accent2:#22d3ee;
  --warn:#f59e0b;

  --shadow: 0 18px 40px rgba(0,0,0,.12);
  --shadow2: 0 10px 24px rgba(0,0,0,.10);

  --radius: 18px;
  --radius2: 26px;

  --max: 1120px;
  --gap: 18px;

  --ring: 0 0 0 3px rgba(79,70,229,.18);
  --ring2: 0 0 0 3px rgba(34,211,238,.18);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }

body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans", "Liberation Sans", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 12% 8%, rgba(124,92,255,.22), transparent 55%),
    radial-gradient(900px 600px at 88% 14%, rgba(34,211,238,.18), transparent 52%),
    radial-gradient(1200px 700px at 50% 100%, rgba(255,204,102,.10), transparent 55%),
    linear-gradient(180deg, var(--bg0), var(--bg1) 30%, var(--bg2));
  overflow-x:hidden;
}

a{ color:inherit; }
img{ max-width:100%; display:block; }

.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;
}

.skip-link{
  position:absolute;
  left:-999px;
  top:12px;
  padding:10px 12px;
  border-radius:12px;
  background: rgba(255,255,255,.12);
  border:1px solid var(--stroke);
  box-shadow: var(--shadow2);
  z-index:9999;
}
.skip-link:focus{ left:12px; outline:none; box-shadow: var(--ring), var(--shadow2); }

/* Topbar */
.topbar{
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: linear-gradient(180deg, rgba(255,255,255,.86), rgba(255,255,255,.62));
  border-bottom: 1px solid var(--stroke);
}
.topbar__inner{
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px 18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 16px;
}

.brand{
  display:flex;
  align-items:center;
  gap: 12px;
  user-select:none;
}
.brand__mark{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display:grid;
  place-items:center;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,.18), transparent 40%),
    linear-gradient(135deg, rgba(124,92,255,.85), rgba(34,211,238,.70));
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: 0 12px 28px rgba(124,92,255,.18);
  font-size: 18px;
}
.brand__title{
  font-weight: 800;
  letter-spacing: .3px;
  line-height: 1.05;
  font-size: 18px;
}
.brand__subtitle{
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.topbar__right{
  display:flex;
  align-items:center;
  gap: 10px;
}

/* Page layout */
.page{
  max-width: var(--max);
  margin: 0 auto;
  padding: 26px 18px 40px;
}

/* Hero */
.hero{
  position: relative;
  display:grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 22px;
  align-items: stretch;
  margin-top: 6px;
}

.hero__content{
  padding: 20px 0;
}

.hero__headline{
  font-size: clamp(32px, 4vw, 52px);
  letter-spacing: -.6px;
  margin: 8px 0 10px;
  line-height: 1.05;
}
.hero__lead{
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 15px;
  max-width: 60ch;
}

.hero__stats{
  display:flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.stat{
  flex: 1 1 220px;
  padding: 14px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,.72);
  border: 1px solid var(--stroke);
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
}
.stat__label{
  font-size: 12px;
  color: var(--muted);
}
.stat__value{
  font-size: 15px;
  font-weight: 700;
  margin-top: 6px;
}

/* Visual side */
.hero__visual{
  position: relative;
  min-height: 420px;
  border-radius: var(--radius2);
  overflow:hidden;
  background:
    radial-gradient(800px 420px at 30% 25%, rgba(124,92,255,.20), transparent 60%),
    radial-gradient(650px 380px at 80% 40%, rgba(34,211,238,.18), transparent 62%),
    linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow);
}

.grid-glow{
  position:absolute;
  inset:-60px;
  opacity:.55;
  background-image:
    linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 38px 38px;
  transform: rotate(8deg);
  filter: blur(.1px);
}
.orb{
  position:absolute;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  filter: blur(0px);
  opacity: .9;
  mix-blend-mode: screen;
  box-shadow: 0 30px 90px rgba(0,0,0,.20);
}
.orb--1{
  left: -40px;
  top: 40px;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,.24), transparent 45%),
              radial-gradient(circle at 60% 60%, rgba(124,92,255,.9), transparent 62%);
}
.orb--2{
  right: -60px;
  top: 120px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,.20), transparent 45%),
              radial-gradient(circle at 55% 55%, rgba(34,211,238,.85), transparent 64%);
}
.orb--3{
  left: 90px;
  bottom: -80px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,.16), transparent 48%),
              radial-gradient(circle at 55% 55%, rgba(255,204,102,.70), transparent 66%);
}

/* Cards */
.card{
  border-radius: var(--radius2);
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.04));
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow2);
}

.card--start{
  padding: 16px;
  max-width: 520px;
}

.card__header{
  margin-bottom: 12px;
}
.card__title{
  margin: 0;
  font-size: 16px;
  letter-spacing: .2px;
}
.card__hint{
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

/* Form */
.form-row{
  display:flex;
  flex-direction:column;
  gap: 8px;
  margin-top: 10px;
}
.label{
  font-size: 12px;
  color: var(--muted);
}
.input{
  width: 100%;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(7,10,20,.35);
  color: var(--text);
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.input::placeholder{ color: rgba(234,240,255,.45); }
.input:focus{
  border-color: rgba(79,70,229,.34);
  box-shadow: var(--ring);
}
.input--search{
  min-width: 240px;
  padding-left: 38px;
  background-image:
    radial-gradient(circle at 18px 50%, rgba(234,240,255,.35), rgba(234,240,255,.35) 2px, transparent 3px),
    linear-gradient(rgba(234,240,255,.32), rgba(234,240,255,.32));
  background-size: 0 0, 12px 1px;
  background-position: 0 0, 23px 24px;
  background-repeat: no-repeat;
}

/* Buttons */
.form-actions{
  display:flex;
  gap: 10px;
  align-items:center;
  margin-top: 12px;
}

.btn{
  cursor:pointer;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 14px;
  padding: 11px 14px;
  color: var(--text);
  background: rgba(255,255,255,.86);
  box-shadow: 0 10px 22px rgba(0,0,0,.20);
  transition: transform .12s ease, border-color .12s ease, background .12s ease, box-shadow .12s ease;
  user-select:none;
}
.btn:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.20);
  background: rgba(255,255,255,.08);
}
.btn:active{
  transform: translateY(0px);
}
.btn:focus{
  outline:none;
  box-shadow: var(--ring), 0 10px 22px rgba(0,0,0,.20);
}

.btn--primary{
  border-color: rgba(79,70,229,.26);
  background: linear-gradient(135deg, rgba(79,70,229,.92), rgba(34,211,238,.62));
}
.btn--primary:hover{
  border-color: rgba(79,70,229,.34);
  background: linear-gradient(135deg, rgba(79,70,229,1), rgba(34,211,238,.70));
}
.btn--ghost{
  background: rgba(255,255,255,.04);
}

/* Chips */
.chip{
  display:flex;
  gap: 8px;
  align-items:center;
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(255,255,255,.72);
  box-shadow: 0 10px 22px rgba(0,0,0,.12);
}
.chip__label{
  font-size: 11px;
  color: var(--muted);
}
.chip__value{
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .3px;
}
.chip--timer .chip__value{ color: var(--text); }

/* Callout */
.callout{
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
  min-height: 16px;
}

/* Arcade section */
.arcade{
  margin-top: 28px;
}
.arcade__top{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.section-title{
  margin: 0;
  font-size: 18px;
  letter-spacing: .2px;
}
.section-subtitle{
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

/* Game grid */
.games-grid{
  display:grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gap);
}

.game-card{
  grid-column: span 4;
  min-height: 160px;
}
.game-card__button{
  width:100%;
  height:100%;
  text-align:left;
  padding: 0;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.game-card__button:focus{ outline:none; }
.game-card__button:focus-visible .game-card__thumb,
.game-card__button:focus-visible .game-card__body{
  box-shadow: var(--ring2);
}

.game-card__thumb{
  height: 110px;
  border-radius: 18px;
  background:
    radial-gradient(120px 90px at 20% 30%, rgba(124,92,255,.35), transparent 65%),
    radial-gradient(120px 90px at 80% 40%, rgba(34,211,238,.28), transparent 68%),
    linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 26px rgba(0,0,0,.25);
}

.game-card__body{
  margin-top: 10px;
  padding: 12px 12px 14px;
  border-radius: 18px;
  background: rgba(255,255,255,.72);
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 26px rgba(0,0,0,.20);
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}
.game-card__button:hover .game-card__body{
  transform: translateY(-2px);
  border-color: rgba(15,23,42,.16);
  background: rgba(255,255,255,.86);
}

.game-card__title{
  margin: 0;
  font-size: 15px;
  letter-spacing: .1px;
}
.game-card__desc{
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  min-height: 30px;
}

.game-card__meta{
  margin-top: 10px;
  display:flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pill{
  font-size: 11px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(255,255,255,.86);
  color: rgba(255,255,255,.92);
}
.pill--mode{
  border-color: rgba(34,211,238,.22);
}
.pill--version{
  border-color: rgba(124,92,255,.22);
}

/* Skeleton cards */
.skeleton-card{
  grid-column: span 3;
  height: 180px;
  border-radius: 22px;
  border: 1px solid var(--stroke);
  background:
    linear-gradient(110deg, rgba(255,255,255,.03) 20%, rgba(255,255,255,.06) 40%, rgba(255,255,255,.03) 60%);
  background-size: 200% 100%;
  animation: shimmer 1.2s ease-in-out infinite;
}
@keyframes shimmer{
  0%{ background-position: 140% 0; }
  100%{ background-position: -40% 0; }
}

/* Empty state */
.empty-state{
  margin-top: 16px;
  padding: 18px;
  border-radius: 22px;
  border: 1px dashed rgba(255,255,255,.18);
  background: rgba(255,255,255,.03);
}
.empty-state h3{
  margin: 0 0 6px;
}
.empty-state p{
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

/* Footer */
.footer{
  border-top: 1px solid rgba(255,255,255,.08);
  background: rgba(7,10,20,.32);
  backdrop-filter: blur(10px);
}
.footer__inner{
  max-width: var(--max);
  margin: 0 auto;
  padding: 16px 18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.footer__brand{ font-weight: 800; }
.footer__sep{ color: rgba(11,16,32,.35); margin: 0 8px; }
.footer__muted{ color: var(--muted); font-size: 12px; }

/* Reward card */
.card--reward{ margin-top: 14px; }
.reward__row{ display:flex; gap:12px; align-items:center; flex-wrap:wrap; justify-content:space-between; }
.reward__row .btn{ min-width: 200px; }

/* Responsive */
@media (max-width: 980px){
  .hero{ grid-template-columns: 1fr; }
  .hero__visual{ min-height: 320px; }
  .game-card{ grid-column: span 6; }
  .skeleton-card{ grid-column: span 6; }
}

@media (max-width: 620px){
  .page{ padding-top: 18px; }
  .card--start{ max-width: 100%; }
  .game-card{ grid-column: span 12; }
  .skeleton-card{ grid-column: span 12; }
  .input--search{ min-width: 100%; }
}
