/* ============================================================
   1xvet.click shared stylesheet (mobile-first, 320-430px canvas)
   All custom classes use the "g313-" prefix.
   Palette: #CC99FF | #1B263B | #BF360C | #E91E63 | #FFCCCB
   Dark tones = background, light tones = text/accent.
   ============================================================ */

:root {
  --g313-bg: #1B263B;
  --g313-bg-2: #14202f;
  --g313-bg-3: #21324a;
  --g313-card: #243752;
  --g313-purple: #CC99FF;
  --g313-orange: #BF360C;
  --g313-pink: #E91E63;
  --g313-pink-soft: #FFCCCB;
  --g313-ink: #FFCCCB;
  --g313-ink-strong: #ffffff;
  --g313-muted: #9fb3cc;
  --g313-border: rgba(204, 153, 255, 0.22);
  --g313-border-strong: rgba(204, 153, 255, 0.55);
  --g313-glow: rgba(204, 153, 255, 0.45);
  --g313-radius: 12px;
  --g313-radius-sm: 8px;
  --g313-header-h: 56px;
  --g313-nav-h: 62px;
  --g313-touch: 44px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 50% -10%, rgba(204, 153, 255, 0.18), transparent 60%),
    radial-gradient(800px 400px at 100% 100%, rgba(233, 30, 99, 0.12), transparent 60%),
    var(--g313-bg);
  color: var(--g313-ink);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, "Trebuchet MS", sans-serif;
  font-size: 15px;
  line-height: 1.55;
  min-height: 100vh;
  /* keep mobile canvas centred on wide screens */
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
  overflow-x: hidden;
}

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

a { color: var(--g313-purple); text-decoration: none; }
a:hover, a:focus { color: var(--g313-pink-soft); }

.g313-wrap {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding: 0 14px;
}

.g313-main {
  padding-bottom: calc(var(--g313-nav-h) + 24px);
}

/* ---------------- Asymmetric brand header ---------------- */
.g313-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(20, 32, 47, 0.96), rgba(27, 38, 59, 0.92));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--g313-border);
}

.g313-header__top {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  min-height: var(--g313-header-h);
}

.g313-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.g313-brand__logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--g313-border-strong);
  box-shadow: 0 0 0 2px rgba(204, 153, 255, 0.10);
  flex-shrink: 0;
}

.g313-brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  min-width: 0;
}

.g313-brand__name {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.3px;
  color: var(--g313-ink-strong);
}

.g313-brand__tag {
  font-size: 11px;
  color: var(--g313-purple);
  text-transform: uppercase;
  letter-spacing: 1.4px;
}

.g313-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.g313-btn {
  -webkit-appearance: none;
  appearance: none;
  border: none;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 16px;
  min-height: var(--g313-touch);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.25s ease, background 0.25s ease;
  font-family: inherit;
}

.g313-btn--login {
  background: transparent;
  color: var(--g313-pink-soft);
  border: 1px solid var(--g313-border-strong);
}

.g313-btn--register {
  background: linear-gradient(135deg, var(--g313-pink), var(--g313-orange));
  color: #fff;
  box-shadow: 0 4px 14px rgba(233, 30, 99, 0.35);
}

.g313-btn:hover { transform: translateY(-1px); }
.g313-btn--register:hover { box-shadow: 0 6px 18px rgba(233, 30, 99, 0.55); }

.g313-header__menu-btn {
  width: var(--g313-touch);
  height: var(--g313-touch);
  border-radius: 10px;
  border: 1px solid var(--g313-border);
  background: var(--g313-bg-3);
  color: var(--g313-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.25s ease;
}

.g313-header__menu-btn--active {
  background: var(--g313-purple);
  color: #fff;
  border-color: var(--g313-purple);
  box-shadow: 0 0 0 3px var(--g313-glow);
}

.g313-icon-bars {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 18px;
}
.g313-icon-bars span {
  display: block;
  height: 2px;
  width: 100%;
  background: currentColor;
  border-radius: 2px;
}

/* ---------------- Layered dropdown menu ---------------- */
.g313-menu {
  max-height: 0;
  overflow: hidden;
  background: var(--g313-bg-2);
  border-top: 1px solid transparent;
  transition: max-height 0.28s ease, border-color 0.28s ease;
}
.g313-menu--open {
  max-height: 520px;
  border-top-color: var(--g313-border);
}

.g313-menu__inner {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 12px 14px 16px;
}

.g313-menu__link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 12px;
  min-height: var(--g313-touch);
  border-radius: var(--g313-radius-sm);
  background: var(--g313-card);
  color: var(--g313-ink);
  border: 1px solid transparent;
  font-size: 13px;
  font-weight: 600;
  transition: border-color 0.2s ease, transform 0.15s ease, color 0.2s ease;
}
.g313-menu__link:hover {
  border-color: var(--g313-border-strong);
  color: var(--g313-ink-strong);
  transform: translateY(-1px);
}
.g313-menu__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--g313-purple);
  flex-shrink: 0;
  box-shadow: 0 0 6px var(--g313-glow);
}

/* ---------------- Promotional carousel ---------------- */
.g313-carousel {
  position: relative;
  margin: 14px 0 6px;
  border-radius: var(--g313-radius);
  overflow: hidden;
  border: 1px solid var(--g313-border);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}
.g313-carousel__viewport {
  overflow: hidden;
}
.g313-carousel__track {
  display: flex;
  transition: transform 0.5s ease;
  will-change: transform;
}
.g313-carousel__slide {
  flex: 0 0 100%;
  position: relative;
  cursor: pointer;
}
.g313-carousel__slide img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}
.g313-carousel__caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 14px 12px;
  background: linear-gradient(180deg, transparent, rgba(20, 32, 47, 0.92));
  font-size: 13px;
  color: var(--g313-pink-soft);
  font-weight: 600;
}
.g313-carousel__dots {
  position: absolute;
  bottom: 8px;
  right: 12px;
  display: flex;
  gap: 6px;
}
.g313-carousel__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 204, 203, 0.45);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}
.g313-carousel__dot--active {
  background: var(--g313-purple);
  transform: scale(1.25);
  box-shadow: 0 0 8px var(--g313-glow);
}

/* ---------------- Section headings ---------------- */
.g313-section {
  margin: 22px 0 6px;
}
.g313-section__title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 800;
  color: var(--g313-ink-strong);
  text-transform: uppercase;
  letter-spacing: 0.6px;
}
.g313-section__title::before {
  content: "";
  width: 4px;
  height: 18px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--g313-purple), var(--g313-pink));
  box-shadow: 0 0 8px var(--g313-glow);
}
.g313-section__more {
  margin-left: auto;
  font-size: 12px;
  color: var(--g313-purple);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

/* ---------------- H1 and intro ---------------- */
.g313-h1 {
  font-size: 22px;
  line-height: 1.25;
  margin: 14px 0 6px;
  color: var(--g313-ink-strong);
  font-weight: 800;
}
.g313-h1 b { color: var(--g313-purple); }
.g313-lead {
  margin: 0 0 6px;
  color: var(--g313-muted);
  font-size: 14px;
}

/* ---------------- Game grid (4 cols on 320, 4-5 on 375+) ---------------- */
.g313-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
@media (min-width: 375px) {
  .g313-grid { grid-template-columns: repeat(4, 1fr); gap: 12px; }
}
@media (min-width: 400px) {
  .g313-grid { grid-template-columns: repeat(5, 1fr); }
}

.g313-game {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  cursor: pointer;
  background: var(--g313-card);
  border: 1px solid var(--g313-border);
  border-radius: var(--g313-radius-sm);
  overflow: hidden;
  transition: transform 0.15s ease, border-color 0.2s ease, box-shadow 0.25s ease;
}
.g313-game:hover, .g313-game:focus {
  transform: translateY(-2px);
  border-color: var(--g313-border-strong);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}
.g313-game__img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: #0e1726;
}
.g313-game__name {
  font-size: 11px;
  line-height: 1.25;
  color: var(--g313-ink);
  padding: 6px 6px 7px;
  text-align: center;
  font-weight: 600;
  min-height: 30px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------------- Info / highlight cards ---------------- */
.g313-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.g313-card {
  background: var(--g313-card);
  border: 1px solid var(--g313-border);
  border-radius: var(--g313-radius);
  padding: 14px;
}
.g313-card h3 {
  margin: 0 0 6px;
  font-size: 14px;
  color: var(--g313-purple);
}
.g313-card p {
  margin: 0;
  font-size: 12.5px;
  color: var(--g313-muted);
  line-height: 1.5;
}

/* Horizontal compact strip */
.g313-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.g313-strip::-webkit-scrollbar { display: none; }
.g313-strip__item {
  flex: 0 0 64%;
  scroll-snap-align: start;
  background: var(--g313-card);
  border: 1px solid var(--g313-border);
  border-radius: var(--g313-radius);
  padding: 12px;
}

/* ---------------- SEO prose ---------------- */
.g313-prose {
  background: var(--g313-bg-2);
  border: 1px solid var(--g313-border);
  border-radius: var(--g313-radius);
  padding: 14px;
  margin: 18px 0;
}
.g313-prose h2 {
  margin: 0 0 8px;
  font-size: 15px;
  color: var(--g313-ink-strong);
}
.g313-prose p {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--g313-muted);
  line-height: 1.65;
}
.g313-prose p:last-child { margin-bottom: 0; }
.g313-prose a { font-weight: 600; }

/* ---------------- Restrained glow feedback ---------------- */
.g313-glow {
  position: relative;
  transition: box-shadow 0.25s ease, transform 0.15s ease;
}
.g313-glow--flash {
  box-shadow: 0 0 0 3px var(--g313-glow), 0 0 18px var(--g313-glow);
  transform: translateY(-1px);
}

/* ---------------- Extended footer panel (homepage only) ---------------- */
.g313-foot-extended {
  margin: 22px 0 4px;
  border-top: 1px solid var(--g313-border);
  padding-top: 18px;
}
.g313-foot-extended__brand {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}
.g313-foot-extended__brand img {
  width: 32px; height: 32px; border-radius: 8px; object-fit: cover;
  border: 1px solid var(--g313-border-strong);
}
.g313-foot-extended__brand p {
  margin: 0;
  font-size: 12px;
  color: var(--g313-muted);
  line-height: 1.5;
}
.g313-foot-extended__group {
  margin-bottom: 14px;
}
.g313-foot-extended__group h4 {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--g313-purple);
}
.g313-foot-extended__links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px 10px;
}
.g313-foot-extended__links a {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--g313-ink);
  padding: 6px 0;
}
.g313-foot-extended__links a::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--g313-pink);
  box-shadow: 0 0 6px rgba(233, 30, 99, 0.5);
}
.g313-foot-extended__promo {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.g313-foot-extended__promo button {
  -webkit-appearance: none;
  appearance: none;
  border: 1px solid var(--g313-border-strong);
  background: var(--g313-card);
  color: var(--g313-pink-soft);
  border-radius: 999px;
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.g313-foot-extended__promo button::before {
  content: "★";
  color: var(--g313-purple);
}
.g313-foot-extended__promo button:hover {
  color: #fff;
  border-color: var(--g313-purple);
  transform: translateY(-1px);
}
.g313-disclaimer {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px dashed var(--g313-border);
  border-radius: var(--g313-radius-sm);
  font-size: 11.5px;
  color: var(--g313-muted);
  line-height: 1.55;
}

/* ---------------- Universal footer ---------------- */
.g313-footer {
  border-top: 1px solid var(--g313-border);
  background: var(--g313-bg-2);
  padding: 14px;
  text-align: center;
  font-size: 11.5px;
  color: var(--g313-muted);
}
.g313-footer a { color: var(--g313-purple); }

/* ---------------- Bottom nav: outlined functional frame ---------------- */
.g313-nav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 10px;
  width: calc(100% - 20px);
  max-width: 460px;
  z-index: 60;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: rgba(20, 32, 47, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--g313-border-strong);
  border-radius: 16px;
  padding: 6px;
  gap: 4px;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.45);
}

.g313-nav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 52px;
  padding: 4px 2px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--g313-muted);
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  font-family: inherit;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.25s ease;
}
.g313-nav__item:hover {
  color: var(--g313-pink-soft);
  border-color: var(--g313-border);
}
.g313-nav__icon {
  width: 22px;
  height: 22px;
  display: block;
}
.g313-nav__icon svg { width: 100%; height: 100%; display: block; }
.g313-nav__label {
  font-size: 9.5px;
  letter-spacing: 0.3px;
}

/* Active state: icon fill variation + restrained glow */
.g313-nav__item--active {
  color: #fff;
  background: linear-gradient(180deg, rgba(204, 153, 255, 0.18), rgba(233, 30, 99, 0.12));
  border-color: var(--g313-border-strong);
  box-shadow: 0 0 0 2px var(--g313-glow);
}
.g313-nav__item--active .g313-nav__icon {
  filter: drop-shadow(0 0 6px var(--g313-glow));
}
.g313-nav__item--active .g313-nav__icon [data-fill] {
  fill: var(--g313-purple) !important;
}

/* Hide the mobile-only bottom nav on wide screens (out of mobile canvas) */
@media (min-width: 600px) {
  /* body is already capped at 480px, so the nav naturally stays in the
     mobile canvas; this guard keeps things tidy if max-width is raised. */
}

/* ---------------- Help-page reading modules ---------------- */
.g313-step-list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; counter-reset: g313-step; }
.g313-step-list li { counter-increment: g313-step; position: relative; padding: 12px 12px 12px 42px; background: var(--g313-card); border: 1px solid var(--g313-border); border-radius: var(--g313-radius-sm); color: var(--g313-muted); font-size: 13px; }
.g313-step-list li::before { content: counter(g313-step); position: absolute; left: 12px; top: 12px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; background: var(--g313-purple); color: var(--g313-bg); font-weight: 800; font-size: 12px; }
.g313-note { border-left: 3px solid var(--g313-pink); padding: 10px 12px; background: rgba(233,30,99,.09); color: var(--g313-ink); font-size: 12.5px; border-radius: 0 var(--g313-radius-sm) var(--g313-radius-sm) 0; }
.g313-checklist { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.g313-checklist li { padding: 9px 10px 9px 30px; position: relative; border-bottom: 1px solid var(--g313-border); color: var(--g313-muted); font-size: 12.5px; }
.g313-checklist li::before { content: "✓"; position: absolute; left: 8px; color: var(--g313-purple); font-weight: 800; }
.g313-compare { width: 100%; border-collapse: collapse; font-size: 11.5px; color: var(--g313-muted); }
.g313-compare th, .g313-compare td { padding: 9px 7px; border-bottom: 1px solid var(--g313-border); text-align: left; vertical-align: top; }
.g313-compare th { color: var(--g313-purple); font-size: 11px; text-transform: uppercase; letter-spacing: .4px; }
.g313-qa { display: grid; gap: 9px; }
.g313-qa details { background: var(--g313-card); border: 1px solid var(--g313-border); border-radius: var(--g313-radius-sm); padding: 11px 12px; }
.g313-qa summary { cursor: pointer; min-height: 24px; color: var(--g313-ink-strong); font-weight: 700; font-size: 13px; }
.g313-qa p { margin: 8px 0 0; color: var(--g313-muted); font-size: 12.5px; }
.g313-action-row { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 14px 0; }
.g313-action-row button { min-height: 44px; border: 1px solid var(--g313-border-strong); border-radius: var(--g313-radius-sm); background: linear-gradient(135deg, var(--g313-pink), var(--g313-orange)); color: #fff; font-weight: 800; cursor: pointer; font-family: inherit; }
.g313-action-row button:last-child { background: transparent; color: var(--g313-pink-soft); }
.g313-meta-line { color: var(--g313-muted); font-size: 12px; margin: 4px 0 12px; }

/* ---------------- Utilities ---------------- */
.g313-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;
}

.g313-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 0;
}
.g313-chips span {
  font-size: 11px;
  color: var(--g313-purple);
  border: 1px solid var(--g313-border);
  border-radius: 999px;
  padding: 4px 10px;
  background: var(--g313-bg-2);
}
