/*
  styles.css — Light theme for ICE Casino
  - Background color: #e4f8ff
  - Header color: #ffffff
  - Responsive, accessible, mobile-friendly
  - BEM naming, CSS variables, comments per section
*/

/* =========== CSS Variables (Theme) =========== */
:root {
  --color-bg: #ffffff;         /* Page background set to white */
  --color-header: #ffffff;     /* Header background */
  --color-surface: #ffffff;    /* Cards/surfaces */
  --color-text: #0a2540;       /* Primary text */
  --color-muted: #40607a;      /* Secondary text */
  --color-primary: #0077ff;    /* Primary brand color */
  --color-primary-contrast: #ffffff; /* Contrast text on primary */
  --color-contrast: #111111;   /* Contrast for dark text */
  --color-overlay: transparent; /* No dark overlay on hero */
  --color-cta-bg: rgba(255, 255, 255, 0.78); /* CTA semi-transparent panel */

  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;

  --container-max: 1200px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 6px 20px rgba(0,0,0,0.12);
}

/* =========== Global Resets & Base =========== */
* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%; /* Avoid iOS font scaling */
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--color-text);
  background: var(--color-bg);
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  line-height: 1.6;
  overflow-x: hidden; /* Prevent horizontal scroll on mobile */
}

img {
  max-width: 100%;
  height: auto;
  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;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 16px;
}

.section-title {
  margin: 0 0 16px;
  font-size: 1.5rem;
}

/* Focus styles for accessibility */
:focus-visible {
  outline: 3px solid rgba(0, 119, 255, 0.5);
  outline-offset: 2px;
}

/* =========== Header =========== */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--color-header);
  box-shadow: var(--shadow-sm);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
}

.header__brand img {
  display: block;
}

/* =========== Breadcrumbs =========== */
.breadcrumbs {
  font-size: 0.9rem;
  color: var(--color-muted);
  padding: 8px 0;
}

.breadcrumbs__list {
  margin: 0;
  padding: 0 16px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.breadcrumbs__item { list-style: none; }
.breadcrumbs__link { color: inherit; text-decoration: none; }

/* =========== Hero Banner =========== */
.hero {
  position: relative;
  min-height: clamp(320px, 60svh, 640px); /* mobile-friendly viewport units */
  display: grid;
}

.hero__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* No overlay; keep banner colors */
.hero__overlay { display: none; }

.hero__cta {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 16px;
}

/* Semi-transparent field (card) that centers CTA content */
.hero__card {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 24px 20px;
  border-radius: var(--radius-lg);
  background: var(--color-cta-bg);
  backdrop-filter: saturate(140%) blur(6px);
  box-shadow: var(--shadow-md);
  max-width: min(720px, 96vw);
}

.hero__title {
  margin: 0;
  color: var(--color-contrast);
  font-size: clamp(2rem, 5vw, 3rem);
}

.hero__subtitle {
  margin: 0;
  color: var(--color-contrast);
  font-size: clamp(1.125rem, 2.5vw, 1.5rem);
}

/* =========== Buttons =========== */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.1);
  background: var(--color-surface);
  color: var(--color-text);
  text-decoration: none;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

.button--primary {
  background: var(--color-primary);
  color: var(--color-primary-contrast);
  border-color: transparent;
}

.button--contrast {
  background: #00c2ff;
  color: #00131f;
  border-color: transparent;
}

/* =========== Slots Grid =========== */
.slots { padding: 32px 0; }

.slots__grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* mobile */
  gap: 12px;
}

@media (min-width: 640px) {
  .slots__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
  .slots__grid { grid-template-columns: repeat(6, 1fr); }
}

.slots__item {
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
}

.slots__item img {
  border-radius: var(--radius); /* round slot images */
}

.slots__cta { margin-top: 16px; }

/* =========== Content & Tables =========== */
.main { padding: 24px 0 48px; }
.content { font-size: 1rem; }
.content__section { margin: 24px 0; }

.table-wrap {
  overflow-x: auto; /* safeguard on narrow screens */
  background: transparent;
}

.table {
  width: 100%;
  border-collapse: collapse;
  background: var(--color-surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.table th,
.table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  vertical-align: top;
}

.table thead th {
  background: #f5fbff;
  font-weight: 700;
}

.table tbody tr:last-child td { border-bottom: none; }

/* Mobile table adaptation: stack cells with labels */
@media (max-width: 700px) {
  .table thead { display: none; }
  .table,
  .table tbody,
  .table tr,
  .table td { display: block; width: 100%; }
  .table tr { border-bottom: 1px solid rgba(0,0,0,0.06); }
  .table td {
    display: grid;
    grid-template-columns: 40% 1fr;
    gap: 8px;
  }
  .table td::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--color-muted);
  }
}

/* =========== Accordion =========== */
.accordion { border-radius: var(--radius); overflow: hidden; background: var(--color-surface); box-shadow: var(--shadow-sm); }
.accordion__item + .accordion__item { border-top: 1px solid rgba(0,0,0,0.06); }
.accordion__title { margin: 0; }
.accordion__button {
  width: 100%;
  text-align: left;
  background: #f5fbff;
  border: none;
  padding: 14px 16px;
  font-weight: 700;
  cursor: pointer;
}
.accordion__button[aria-expanded="true"] { background: #eaf6ff; }
.accordion__panel { padding: 0 16px 16px; }

/* =========== Footer =========== */
.footer {
  background: var(--color-header);
  border-top: 1px solid rgba(0,0,0,0.06);
}

.footer__inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px 0;
}

.footer__payments {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
}

.footer__payments img { filter: saturate(0.9) contrast(1.1); }

/* Mobile-only extra left indentation in footer */
@media (max-width: 640px) {
  .footer .container { padding-left: 24px; }
}

.footer__links {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  gap: 12px;
}

.footer__link { color: var(--color-muted); text-decoration: none; }
.footer__copy { margin: 0; color: var(--color-muted); }
