/* CardsClan – shared stylesheet */

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

:root {
  --accent:      #94ed1f;
  --accent-dark: #73bb16;
  --accent-bg:   #1a2a00;
  --bg:          #0d0d10;
  --surface:     #0f0b0b;
  --surface2:    #1e1e28;
  --text:        #f0f0f0;
  --muted:       #888;
  --border:      #222;
}

html, body {
  height: 100%;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  position: relative;
}

/* Subtle tiled background texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  /* background-image: url('assets/backgroundTileMain.png');
  background-size: 256px 256px;
  background-repeat: repeat;
  opacity: 1.0; */
  pointer-events: none;
  z-index: 0;
}

body > * {
  position: relative;
  z-index: 1;
}

body::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('assets/backgroundTileMain.png');
  background-size: 128px 128px;
  background-repeat: repeat;
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

/* ── Header ── */

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 2.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-wrap: wrap;
  position: relative;
}

header::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('assets/backgroundTileAlt.png');
  background-size: 128px 128px;
  background-repeat: repeat;
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.logo img {
  height: 38px;
  width: auto;
  display: block;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
}

nav a {
  color: var(--muted);
  text-decoration: none;
  padding: 0.3rem 0.75rem;
  font-size: 0.9rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  white-space: nowrap;
}

nav a:hover {
  color: var(--text);
  background: var(--surface2);
}

.header-sep {
  width: 1px;
  height: 20px;
  background: var(--border);
  margin: 0 0.5rem;
}

.header-ext-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-ext-links a {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.85rem;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  white-space: nowrap;
}

.header-ext-links a:hover {
  color: var(--accent);
  background: var(--accent-bg);
}

.header-ext-links svg {
  flex-shrink: 0;
}

/* ── Main ── */

main {
  min-height: calc(100vh - 64px - 96px);
}

/* ── Footer ── */

footer {
  padding: 2rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  color: var(--muted);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--accent);
}

footer::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('assets/backgroundTileAlt.png');
  background-size: 128px 128px;
  background-repeat: repeat;
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

/* ── Buttons ── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, border-color 0.2s;
}

.btn-header {
  padding: 0.45rem 1.1rem;
  font-size: 0.88rem;
  border-radius: 7px;
  background: var(--accent);
  color: #0d0d10;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  margin-left: 0.75rem;
}

.btn-header:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent);
  color: #0d0d10;
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-outline:hover {
  background: var(--accent);
  color: #0d0d10;
  transform: translateY(-2px);
}

/* ── Content section ── */

.section {
  padding: 4rem 2.5rem;
  max-width: 860px;
  margin: 0 auto;
}

.section-wide {
  max-width: 1040px;
}

.section h1 {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  font-weight: 800;
  margin-bottom: 1.5rem;
  letter-spacing: -0.5px;
}

.section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 2.5rem 0 0.75rem;
  color: var(--accent);
}

.section p {
  color: #ccc;
  margin-bottom: 1rem;
}

.section ul,
.section ol {
  color: #ccc;
  padding-left: 1.6rem;
  margin-bottom: 1rem;
}

.section li {
  margin-bottom: 0.45rem;
}

.section a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.section-divider {
  border: none;
  border-top: 2px solid var(--surface2);
  margin: 2.5rem 0;
}

.last-updated {
  display: inline-block;
  font-size: 0.8rem;
  color: var(--muted);
  background: var(--surface2);
  border-radius: 4px;
  padding: 0.2rem 0.6rem;
  margin-bottom: 1.5rem;
}

/* ── Hero ── */

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 2rem 5rem;
  background: radial-gradient(ellipse at 50% 0%, #2a1a00 0%, transparent 65%);
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 900;
  letter-spacing: -1px;
  line-height: 1.1;
  max-width: 700px;
}

.hero h1 span {
  color: var(--accent);
}

.hero p {
  color: var(--muted);
  font-size: 1.1rem;
  margin-top: 1.2rem;
  max-width: 500px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

/* ── Feature / info cards ── */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.6rem 1.5rem;
}

.card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.card p {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0;
}

.card .card-icon {
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
  display: block;
}

/* ── Game card / CTA ── */

.game-cta {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.game-cta-text h3 {
  font-size: 1.4rem;
  font-weight: 800;
}

.game-cta-text p {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0.4rem 0 0;
}

/* ── Tag ── */

.tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--accent-bg);
  color: var(--accent);
  border-radius: 4px;
  padding: 0.18rem 0.55rem;
}

/* ── Status / success ── */

.status-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 3rem 2rem;
  text-align: center;
  max-width: 480px;
  margin: 0 auto;
}

.status-icon {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  display: block;
}

.status-box h1 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.status-box p {
  color: var(--muted);
  margin-bottom: 0;
}

/* ── App download strip ── */

.app-strip {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 3rem 2.5rem;
  position: relative;
}

.app-strip::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('assets/backgroundTileAlt.png');
  background-size: 128px 128px;
  background-repeat: repeat;
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

.app-strip-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.app-icon {
  width: 140px;
  height: 140px;
  border-radius: 0px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.app-info {
  flex: 1;
  min-width: 200px;
}

.app-info h2 {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
}

.app-info p {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 1.1rem;
}

.store-badges {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  /* padding: 0.55rem 1.2rem; */
  border-radius: 8px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
  white-space: nowrap;
}

.store-badge:hover {
  border-color: var(--accent);
  background: var(--accent-bg);
  color: var(--accent);
  transform: translateY(-2px);
}

.store-badge svg {
  flex-shrink: 0;
}

/* ── Responsive ── */

@media (max-width: 640px) {
  header {
    padding: 0.9rem 1.2rem;
    gap: 0.5rem;
  }

  nav a {
    padding: 0.3rem 0.5rem;
    font-size: 0.82rem;
  }

  .header-ext-links .link-label {
    display: none;
  }

  .section {
    padding: 2.5rem 1.2rem;
  }

  .hero {
    padding: 3.5rem 1.2rem 3rem;
  }

  .game-cta {
    flex-direction: column;
    align-items: flex-start;
  }
}
