/* =========================================================
   VietGamePlay landing page
   Full-screen, no-scroll, 4 views (home / products / contact / about)
   Color tone inspired by the reference: purple → pink gradient
   ========================================================= */

/* Drop GoogleSans-SemiBold.woff2 (or .ttf) into /fonts/ to load locally. */
@font-face {
  font-family: "GoogleSans";
  src: url("fonts/GoogleSans-Regular.ttf")   format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-0: #4b2a8f;
  --bg-1: #6f3fcf;
  --bg-2: #b84ad8;
  --bg-3: #ff6aa9;
  --ink: #ffffff;
  --ink-dim: rgba(255, 255, 255, .75);
  --ink-faint: rgba(255, 255, 255, .55);
  --accent: #ffd166;
  --pill: rgba(255, 255, 255, .14);
  --pill-hover: rgba(255, 255, 255, .24);
  --card: rgba(255, 255, 255, .10);
  --card-strong: rgba(255, 255, 255, .18);
  --radius: 18px;
  --shadow: 0 20px 60px rgba(0, 0, 0, .25);
  --font: "GoogleSans", "Segoe UI", "Inter", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

body {
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(1200px 700px at 85% 20%, rgba(255, 106, 169, .55), transparent 60%),
    radial-gradient(900px 600px at 10% 90%, rgba(184, 74, 216, .55), transparent 60%),
    linear-gradient(135deg, var(--bg-0) 0%, var(--bg-1) 45%, var(--bg-2) 100%);
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100%;
}

/* ----- background decorative blobs ----- */
.bg-blobs {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: .55;
}
.blob-1 { width: 420px; height: 420px; background: #ff6aa9; top: -100px; right: -60px; animation: drift 18s ease-in-out infinite alternate; }
.blob-2 { width: 500px; height: 500px; background: #6f3fcf; bottom: -120px; left: -120px; animation: drift 22s ease-in-out infinite alternate-reverse; }
.blob-3 { width: 300px; height: 300px; background: #ffd166; top: 45%; left: 55%; opacity: .25; animation: drift 26s ease-in-out infinite alternate; }

@keyframes drift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, -30px) scale(1.08); }
}

/* ========== HEADER ========== */
.topbar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 48px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
}
.logo img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .25));
}
.logo-text {
  font-family: "GoogleSans", "Google Sans", "Product Sans", var(--font);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: .5px;
}
.logo-text strong { font-weight: 600; }

.menu { display: flex; gap: 8px; align-items: center; }
.menu-link {
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  padding: 10px 18px;
  border-radius: 999px;
  transition: background .2s ease, transform .2s ease;
}
.menu-link:hover { background: var(--pill); }
.menu-link.active {
  background: var(--pill-hover);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .15);
}

/* ========== STAGE / VIEW SWITCH ========== */
.stage {
  position: relative;
  z-index: 5;
  overflow: hidden;
  min-height: 0;   /* allow grid child to shrink */
}
.view {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity .35s ease, transform .35s ease;
  padding: 0 48px;
  display: flex;
}
.view.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.view-title {
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 800;
  letter-spacing: .5px;
  margin: 0 0 14px;
}

/* ---------- HOME ---------- */
.view-home {
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.home-left {
  max-width: 560px;
  min-width: 0;
}
.hero-title {
  font-size: clamp(44px, 5.2vw, 80px);
  line-height: 1.02;
  margin: 0 0 18px;
  font-weight: 900;
  letter-spacing: -1px;
}
.hero-title .accent { color: var(--accent); }
.hero-sub {
  font-size: clamp(14px, 1.1vw, 17px);
  line-height: 1.55;
  color: var(--ink-dim);
  margin: 0 0 28px;
  max-width: 520px;
}
.cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(90deg, #ff6aa9, #ffd166);
  color: #2a0d56;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease;
}
.cta:hover { transform: translateY(-2px); box-shadow: 0 25px 70px rgba(0,0,0,.3); }
.cta.big { padding: 18px 32px; font-size: 17px; text-decoration: none; }

/* home illustration */
.home-right {
  position: relative;
  flex: 0 0 46%;
  height: 100%;
  min-height: 300px;
}
.float-card,
.float-controller,
.float-ring {
  position: absolute;
  border-radius: 22px;
  box-shadow: var(--shadow);
}
.float-card {
  width: 120px; height: 120px;
  background: linear-gradient(140deg, #ffd166, #ff6aa9);
  animation: bob 6s ease-in-out infinite;
}
.card-a { top: 12%; left: 10%; transform: rotate(-6deg); }
.card-b { top: 55%; left: 30%; width: 140px; height: 140px; background: linear-gradient(140deg, #7a5cff, #b84ad8); animation-delay: -2s; transform: rotate(8deg); }
.card-c { top: 20%; right: 8%;  width: 160px; height: 160px; background: linear-gradient(140deg, #3ad2ff, #7a5cff); animation-delay: -4s; transform: rotate(-12deg); }

.float-controller {
  top: 45%; right: 18%;
  width: 180px; height: 120px;
  background: radial-gradient(circle at 30% 40%, #fff 0, #fff 10%, transparent 11%),
              radial-gradient(circle at 70% 40%, #fff 0, #fff 10%, transparent 11%),
              linear-gradient(140deg, #5a2f9c, #2a1159);
  border-radius: 60px / 40px;
  animation: bob 7s ease-in-out infinite;
}

.float-ring {
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, .35);
  background: transparent;
  box-shadow: none;
}
.r1 { width: 320px; height: 320px; top: 12%; left: 28%; animation: spin 40s linear infinite; }
.r2 { width: 220px; height: 220px; bottom: 8%; right: 4%; animation: spin 60s linear infinite reverse; }

@keyframes bob {
  0%,100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50%     { transform: translateY(-14px) rotate(var(--r, 0deg)); }
}
.card-a { --r: -6deg; }
.card-b { --r:  8deg; }
.card-c { --r: -12deg; }

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ---------- PRODUCTS ---------- */
.view-products {
  flex-direction: column;
  padding: 0 48px 24px;
}
.view-products .view-title {
  margin-top: 8px;
  margin-bottom: 0;
}

/* Products header: title with filter pills right beside it */
.products-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 20px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.filter-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.pill {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  padding: 10px 18px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .2s ease, transform .2s ease;
}
.pill:hover { background: var(--pill); }
.pill.active {
  background: var(--pill-hover);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .15);
}

/* Hidden thumbs when filtered out */
.thumb.hidden {
  display: none;
}

.thumb-strip {
  display: flex;
  gap: 14px;
  padding: 8px 4px 14px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}
.thumb-strip::-webkit-scrollbar { display: none; }

.thumb {
  flex: 0 0 auto;
  width: 92px;
  height: 92px;
  border-radius: 18px;
  background: var(--card);
  border: 2px solid transparent;
  padding: 0;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
  animation: thumbIn .6s ease both;
}
.thumb:nth-child(1) { animation-delay: .05s; }
.thumb:nth-child(2) { animation-delay: .12s; }
.thumb:nth-child(3) { animation-delay: .19s; }
.thumb:nth-child(4) { animation-delay: .26s; }
.thumb:nth-child(5) { animation-delay: .33s; }
@keyframes thumbIn {
  from { opacity: 0; transform: translateY(18px) scale(.9); }
  to   { opacity: 1; transform: translateY(0)   scale(1);   }
}
.thumb:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 14px 28px rgba(0, 0, 0, .28);
}
.thumb img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.thumb.active {
  border-color: var(--accent);
  box-shadow: 0 10px 26px rgba(255, 209, 102, .35);
}
.thumb-caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  font-size: 10px;
  padding: 3px 4px;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.7));
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* big slider */
.slider {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  margin-top: 10px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.12);
  overflow: hidden;
  display: flex;
  align-items: center;
}
.slides {
  position: relative;
  flex: 1;
  height: 100%;
}
.slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  padding: 22px 60px;
  opacity: 0;
  transform: translateX(30px);
  transition: opacity .5s ease, transform .5s ease;
  pointer-events: none;
}
.slide.active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}
.slide-art {
  justify-self: center;
  width: min(280px, 70%);
  aspect-ratio: 1 / 1;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #fff;
  animation: floatArt 6s ease-in-out infinite;
}
.slide-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
@keyframes floatArt {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(-8px); }
}

.slide-info { min-width: 0; }
.slide-info .badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--pill);
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: .5px;
  margin-bottom: 10px;
}
.slide-info h3 {
  margin: 0 0 10px;
  font-size: clamp(24px, 2.6vw, 38px);
  font-weight: 800;
}
.slide-info p {
  color: var(--ink-dim);
  margin: 0 0 18px;
  line-height: 1.5;
  font-size: clamp(13px, 1vw, 15px);
}
.store-row { display: flex; gap: 10px; flex-wrap: wrap; }
.store-row .store {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: rgba(0,0,0,.35);
  border: 1px solid rgba(255,255,255,.15);
  color: #fff;
  text-decoration: none;
  border-radius: 10px;
  font-size: 14px;
  transition: background .2s ease, transform .2s ease;
}
.store-row .store:hover { background: rgba(0,0,0,.55); transform: translateY(-2px); }

/* slider arrows + dots */
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px; height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
  color: #fff;
  font-size: 28px;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: background .2s ease, transform .2s ease;
  z-index: 2;
}
.slider-arrow:hover { background: rgba(255,255,255,.35); transform: translateY(-50%) scale(1.05); }
.slider-arrow.prev { left: 14px; }
.slider-arrow.next { right: 14px; }

.dots {
  position: absolute;
  bottom: 14px;
  left: 0; right: 0;
  text-align: center;
}
.dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.35);
  margin: 0 4px;
  transition: background .2s ease, transform .2s ease;
}
.dot.active {
  background: var(--accent);
  transform: scale(1.4);
}

/* ---------- CONTACT ---------- */
.view-contact { align-items: center; justify-content: center; }
.contact-card {
  background: var(--card);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 28px;
  padding: 48px 64px;
  text-align: center;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  max-width: 560px;
}
.contact-lede {
  color: var(--ink-dim);
  font-size: 16px;
  margin: 0 0 28px;
  line-height: 1.55;
}
.contact-email {
  margin-top: 22px;
  color: var(--ink-faint);
  font-size: 14px;
}

/* ---------- ABOUT ---------- */
.view-about { align-items: center; justify-content: center; }
.about-card {
  background: var(--card);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 28px;
  padding: 44px 56px;
  max-width: 640px;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  text-align: center;
}
.about-lede {
  color: var(--ink-dim);
  line-height: 1.6;
  margin: 0 0 28px;
}
.founder {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 14px 22px;
  background: var(--card-strong);
  border-radius: 16px;
}
.founder-avatar {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: linear-gradient(140deg, #ff6aa9, #ffd166);
  display: grid; place-items: center;
  font-weight: 900;
  color: #2a0d56;
  font-size: 22px;
}
.founder-label { font-size: 12px; color: var(--ink-faint); text-align: left; }
.founder-name { font-weight: 700; font-size: 18px; text-align: left; }

/* ========== FOOTER ========== */
.footer {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 48px 18px;
  flex-wrap: wrap;
}
.foot-group { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.socials .social {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--pill);
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
  transition: background .2s ease, transform .2s ease;
}
.socials .social:hover { background: var(--pill-hover); transform: translateY(-2px); }
.socials .social svg { width: 14px; height: 14px; }

.middle { color: var(--ink-dim); font-size: 13px; }
.foot-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-dim);
  text-decoration: none;
}
.foot-line:hover { color: var(--ink); }
.foot-line .ic { width: 14px; height: 14px; opacity: .9; }

.stores { gap: 10px; }
.stores .store {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: #000;
  color: #fff;
  text-decoration: none;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.12);
  transition: transform .2s ease, background .2s ease;
}
.stores .store:hover { transform: translateY(-2px); background: #111; }
.stores .store .ic { width: 20px; height: 20px; }
.store-small { display: block; font-size: 9px; letter-spacing: .5px; line-height: 1; opacity: .8; }
.store-big { display: block; font-size: 13px; font-weight: 700; line-height: 1.1; }

/* ========== Responsiveness ========== */
@media (max-width: 900px) {
  .topbar { padding: 16px 20px; }
  .view { padding: 0 20px; }
  .view-products { padding: 0 20px 12px; }
  .footer { padding: 10px 20px 14px; gap: 10px; }

  .hero-title { font-size: 44px; }
  .home-right { display: none; }
  .slide { grid-template-columns: 1fr; padding: 16px 24px; gap: 16px; }
  .slide-art { width: min(140px, 40%); }
  .contact-card, .about-card { padding: 28px 24px; }
  .logo-text { display: none; }
}

@media (max-height: 640px) {
  .hero-title { font-size: 40px; }
  .hero-sub { display: none; }
  .thumb { width: 72px; height: 72px; }
  .contact-card, .about-card { padding: 24px 28px; }
}
