/*
  Spin City Casino NZ - Light Theme Styles
  - Mobile-first, responsive
  - Semantic class naming (BEM-like)
  - Header primary color: #0c4cc0
  - Accessibility: focus styles, readable contrast
  - Components documented inline
*/

/* CSS Variables (theme) */
:root {
  --color-primary: #0c4cc0; /* header and primary accents */
  --color-primary-contrast: #ffffff;
  --color-bg: #ffffff;
  --color-surface: #f7f9fc;
  --color-text: #0f172a;
  --color-muted: #6b7280;
  --color-border: #e5e7eb;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --container: 1100px;
}

/* Base / Reset */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Focus styles for keyboard navigation */
:focus-visible {
  outline: 3px solid rgba(12,76,192,0.45);
  outline-offset: 2px;
}

/* Utilities */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1rem;
}
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: #000;
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 1000;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* Header */
.header {
  position: sticky; /* Fix screen on mobile when needed */
  top: 0;
  z-index: 50;
  background: var(--color-primary);
  color: var(--color-primary-contrast);
  box-shadow: var(--shadow-sm);
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
}
.header__brand img { display: block; }
.header a { color: var(--color-primary-contrast); }
.header__cta { display: flex; gap: 0.5rem; }

/* Navigation */
.nav { position: relative; }
.nav__toggle {
  background: transparent;
  border: 0;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.nav__toggle-bar {
  width: 22px;
  height: 2px;
  background: var(--color-primary-contrast);
  display: block;
  margin: 3px 0;
}
.nav__menu {
  position: absolute;
  right: 0;
  top: 60px;
  background: var(--color-primary);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  list-style: none;
  margin: 0;
  display: none; /* toggled on mobile */
}
.nav__menu.is-open { display: block; }
.nav__menu li { margin: 0; }
.nav__menu a { display: block; padding: 0.5rem 0.75rem; }

/* Breadcrumbs */
.breadcrumbs {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}
.breadcrumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0.5rem 1rem;
}
.breadcrumbs li { color: var(--color-muted); }
.breadcrumbs li+li::before {
  content: "/";
  margin: 0 0.5rem;
  color: var(--color-muted);
}
.breadcrumbs a { color: var(--color-text); }

/* Hero */
.hero {
  position: relative;
  isolate: isolate;
  overflow: clip;
  border-radius: var(--radius-lg); /* rounded edges for a nicer look */
}
.hero__image { width: 100%; height: auto; display: block; }
.hero__content {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 2rem);
  max-width: 520px;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.55); /* semi-transparent overlay */
  color: #fff;
  border-radius: var(--radius-md);
  z-index: 1;
}
.hero__actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* Buttons */
.btn { 
  display: inline-block; 
  padding: 0.65rem 1rem; 
  border-radius: 999px; 
  font-weight: 600; 
  border: 2px solid transparent; 
  transition: transform .05s ease, background .2s ease, color .2s ease; 
}
.btn--sm { padding: 0.45rem 0.75rem; font-size: 0.9rem; }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--color-primary); color: #fff; }
.btn--primary:hover { background: #0a45ae; text-decoration: none; }
.btn--secondary { background: #fff; color: var(--color-primary); }
.btn--secondary:hover { background: #f2f5ff; text-decoration: none; }
.btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,0.6); }
.btn--ghost:hover { background: rgba(255,255,255,0.12); text-decoration: none; }

/* Slots grid */
.slots { padding: 2rem 0; }
.slots__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}
.slots__item { border-radius: var(--radius-md); overflow: hidden; background: var(--color-surface); }
.slot-card { display: block; }
.slot-card img { display: block; width: 100%; height: auto; }

/* Main content */
.main { padding: 2rem 0; }
.content h1, .content h2, .content h3, .content h4 { line-height: 1.25; }
.content h1 { font-size: 1.75rem; margin: 0 0 1rem; }
.content h2 { font-size: 1.375rem; margin: 2rem 0 0.75rem; }
.content h3 { font-size: 1.125rem; margin: 1.25rem 0 0.5rem; }
.content h4 { font-size: 1rem; margin: 1rem 0 0.5rem; color: var(--color-muted); }
.content p { margin: 0 0 0.75rem; }
.content ul, .content ol { margin: 0 0 1rem 1.25rem; }

/* Tables: responsive stack on small screens */
.table-responsive { width: 100%; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-sm); overflow: hidden; }
.table th, .table td { padding: 0.75rem; border-bottom: 1px solid var(--color-border); text-align: left; vertical-align: top; }
.table thead th { background: var(--color-surface); font-weight: 700; }
.table tr:last-child td { border-bottom: 0; }

/* Mobile stacked table variant */
@media (max-width: 640px) {
  /* Slightly larger side indents for text on mobile */
  .container { padding: 0 1.25rem; }
  .table--stack thead { display: none; }
  .table--stack tr { display: block; border-bottom: 1px solid var(--color-border); }
  .table--stack td, .table--stack th[scope="row"] { display: grid; grid-template-columns: 1fr 2fr; gap: 0.5rem; border: 0; }
  .table--stack th[scope="row"] { color: var(--color-text); font-weight: 700; }
  .table--stack td::before { content: attr(data-label); font-weight: 700; color: var(--color-muted); }
}

/* Footer */
.footer { background: var(--color-surface); border-top: 1px solid var(--color-border); padding: 1.5rem 0; }
.footer__inner { display: grid; gap: 1rem; align-items: center; }
.footer__brand { color: var(--color-muted); }
.footer__brand p { margin: 0.5rem 0 0; }
.footer__nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.footer__nav a { color: var(--color-text); }

/* Footer payment icons */
.footer__payments { list-style: none; margin: 0.5rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 0.75rem; align-items: center; }
.footer__payments li { display: inline-flex; align-items: center; }
.footer__payments img { height: 22px; width: auto; display: block; filter: grayscale(1); opacity: 0.9; }
.footer__payments img:hover { filter: none; opacity: 1; }
@media (min-width: 640px) { .footer__payments img { height: 24px; } }

/* Footer payment icons */
.footer__payments { list-style: none; margin: 0.5rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 0.75rem; align-items: center; }
.footer__payments li { display: inline-flex; align-items: center; }
.footer__payments img { height: 22px; width: auto; display: block; filter: grayscale(1); opacity: 0.9; }
.footer__payments img:hover { filter: none; opacity: 1; }
@media (min-width: 640px) { .footer__payments img { height: 24px; } }

/* Breakpoints - enhance layout progressively */
@media (min-width: 640px) {
  .header__cta { display: flex; }
  .nav__menu { position: static; display: flex !important; background: transparent; box-shadow: none; padding: 0; }
  .nav__menu a { padding: 0.5rem 0.75rem; border-radius: 6px; }
  .nav__menu a:hover { background: rgba(255,255,255,0.12); text-decoration: none; }
  .nav__toggle { display: none; }

  /* Hero CTA: left-attached card on desktop */
  .hero__content {
    left: 2rem;
    right: auto;
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
    width: min(520px, 42vw);
    max-width: 520px;
    background: rgba(15, 23, 42, 0.55);
    padding: 1.25rem 1.5rem;
    display: block;
  }
  .hero__actions { gap: 1rem; }

  /* Slots grid: 6 per row on desktop */
  .slots__grid { grid-template-columns: repeat(6, 1fr); gap: 1rem; }
}

@media (min-width: 960px) {
  .content h1 { font-size: 2.25rem; }
  .content h2 { font-size: 1.5rem; }
}


