/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; }

:root {
  --bg: #f6f8fc;
  --surface: #ffffff;
  --text: #334155;
  --text-heading: #1e293b;
  --text-muted: #64748b;
  --accent: #6366f1;
  --accent-soft: #eef2ff;
  --accent-hover: #4f46e5;
  --highlight: #f59e0b;
  --border: #e8edf4;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --radius: 16px;
  --radius-sm: 10px;
}

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

body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

img, svg, video, iframe { max-width: 100%; height: auto; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

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

h1, h2, h3, h4 {
  line-height: 1.3;
  color: var(--text-heading);
  margin: 0 0 0.75em;
  font-weight: 600;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 700; }
h2 { font-size: clamp(1.35rem, 3vw, 1.65rem); margin-top: 2.25rem; }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.3rem); margin-top: 1.75rem; }
h4 { font-size: 1.05rem; margin-top: 1.25rem; }

p { margin: 0 0 1em; }

ul, ol { margin: 0 0 1em; padding-left: 1.4em; }
li { margin-bottom: 0.4em; }

table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 1em 0 1.5em;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1em 0 1.5em;
  border-radius: var(--radius-sm);
}

.table-wrap table { margin: 0; min-width: 280px; }

th, td {
  border-bottom: 1px solid var(--border);
  padding: 0.75em 1em;
  text-align: left;
  vertical-align: top;
}

th, tr:first-child td {
  background: var(--accent-soft);
  color: var(--text-heading);
  font-weight: 600;
}

tr:last-child td { border-bottom: none; }
tr:nth-child(even) td { background: #fafbfd; }

.visually-hidden {
  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: 1180px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 68px;
}

.site-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-logo img {
  height: 44px;
  width: auto;
}

.site-nav { display: flex; align-items: center; gap: 0.35rem; }

.site-nav a {
  color: var(--text-muted);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--accent);
  background: var(--accent-soft);
}

.menu-toggle {
  display: none;
  background: var(--accent-soft);
  border: none;
  cursor: pointer;
  padding: 0.55rem;
  border-radius: 10px;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-heading);
  margin: 5px 0;
  border-radius: 2px;
  transition: transform 0.3s;
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(160deg, #eef2ff 0%, #f8fafc 45%, #fef9ee 100%);
  color: var(--text-heading);
  padding: 3rem 0 2.5rem;
  border-bottom: 1px solid var(--border);
}

.hero h1 {
  color: var(--text-heading);
  max-width: 720px;
}

.hero p {
  color: var(--text-muted);
  font-size: 1.08rem;
  max-width: 720px;
}

/* ===== Layout with TOC ===== */
.page-layout {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 2rem;
  padding: 2.5rem 0 3.5rem;
  align-items: start;
}

.toc {
  position: sticky;
  top: 88px;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.25rem 1rem;
  max-height: calc(100vh - 110px);
  overflow-y: auto;
  font-size: 0.85rem;
  box-shadow: var(--shadow-sm);
}

.toc__title {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0 0 0.85rem;
}

.toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: toc;
}

.toc > nav > ol > li {
  counter-increment: toc;
  margin-bottom: 0.2rem;
}

.toc > nav > ol > li > a {
  display: block;
  padding: 0.4rem 0.6rem;
  color: var(--text);
  border-radius: 8px;
  font-weight: 500;
  transition: background 0.15s;
}

.toc > nav > ol > li > a::before {
  content: counter(toc) ". ";
  color: var(--accent);
  font-weight: 600;
}

.toc > nav > ol > li > a:hover,
.toc > nav > ol > li > a.is-active {
  background: var(--accent-soft);
  color: var(--accent);
}

.toc ol ol {
  padding-left: 0.85rem;
  margin: 0.2rem 0 0.4rem;
}

.toc ol ol a {
  display: block;
  padding: 0.25rem 0.55rem;
  color: var(--text-muted);
  font-size: 0.82rem;
  border-radius: 6px;
}

.toc ol ol a:hover {
  color: var(--accent);
  background: #f8fafc;
}

.article {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 2rem 2.25rem;
  min-width: 0;
  box-shadow: var(--shadow-sm);
}

/* ===== Author Box ===== */
.author-box {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  background: linear-gradient(135deg, #fafbff, #f5f3ff);
  border-radius: var(--radius);
  padding: 1.35rem 1.5rem;
  margin: 0 0 2rem;
}

.author-box__photo {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 3px solid #fff;
  box-shadow: var(--shadow-sm);
}

.author-box__name {
  font-weight: 600;
  font-size: 1.05rem;
  margin: 0 0 0.2rem;
  color: var(--text-heading);
}

.author-box__role {
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 500;
  margin: 0 0 0.5rem;
}

.author-box__bio {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.6;
}

/* ===== Casino Widget ===== */
.widget-section { margin: 0 0 2rem; }

.widget-shell {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}

.widget-shell iframe {
  width: 100%;
  border: none;
  display: block;
  overflow: hidden;
  min-height: 200px;
}

.widget-shell__overlay {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 2;
  cursor: pointer;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 1rem;
  background: transparent;
}

.widget-shell__overlay.is-visible { display: flex; }

.widget-shell__overlay-text {
  background: var(--surface);
  color: var(--text-heading);
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 500;
  pointer-events: none;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

/* ===== Casino review screenshots ===== */
.casino-preview {
  margin: 1rem 0 1.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.casino-preview img {
  width: 100%;
  height: auto;
  display: block;
}

/* ===== FAQ ===== */
.faq { margin-top: 1.5rem; }

.faq__item {
  border-radius: var(--radius-sm);
  margin-bottom: 0.6rem;
  overflow: hidden;
  background: #fafbfd;
  transition: box-shadow 0.2s;
}

.faq__item[open] {
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.faq__item summary {
  padding: 1rem 1.15rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-heading);
}

.faq__item summary::-webkit-details-marker { display: none; }

.faq__item summary::after {
  content: "+";
  font-size: 1.15rem;
  color: var(--accent);
  font-weight: 400;
  flex-shrink: 0;
  margin-left: 1rem;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  border-radius: 50%;
}

.faq__item[open] summary::after { content: "−"; }

.faq__answer {
  padding: 0 1.15rem 1.1rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* ===== Contact Page ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

.contact-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
}

.contact-card h2 {
  font-size: 1.2rem;
  margin-top: 0;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--accent-soft);
}

.contact-list { list-style: none; padding: 0; margin: 0; }

.contact-list li {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}

.contact-list li:last-child { border-bottom: none; }

.contact-list__icon {
  width: 40px;
  height: 40px;
  background: var(--accent-soft);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent);
  font-size: 1rem;
}

.contact-map {
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.contact-map iframe {
  width: 100%;
  height: 280px;
  border: 0;
}

/* ===== Footer ===== */
.site-footer {
  background: var(--surface);
  color: var(--text-muted);
  padding: 2.5rem 0 1.5rem;
  font-size: 0.9rem;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-col h3 {
  color: var(--text-heading);
  font-size: 0.95rem;
  margin: 0 0 1rem;
  font-weight: 600;
}

.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { margin-bottom: 0.45rem; }
.footer-nav a { color: var(--text-muted); }
.footer-nav a:hover { color: var(--accent); }

.footer-contact p { margin: 0 0 0.5rem; }
.footer-contact a { color: var(--text); }

.footer-form label {
  display: block;
  font-size: 0.82rem;
  margin-bottom: 0.3rem;
  color: var(--text-muted);
}

.footer-form input,
.footer-form textarea {
  width: 100%;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text-heading);
  font-size: 0.88rem;
  margin-bottom: 0.7rem;
  font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.footer-form input:focus,
.footer-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.footer-form textarea { resize: vertical; min-height: 72px; }

.btn {
  display: inline-block;
  padding: 0.65rem 1.35rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, transform 0.15s;
}

.btn:hover {
  background: var(--accent-hover);
  color: #fff;
  transform: translateY(-1px);
}

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

.btn--outline:hover {
  background: var(--bg);
  color: var(--text-heading);
  transform: none;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
}

.footer-bottom a { color: var(--text-muted); }

.footer-disclaimer {
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.footer-age {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  background: var(--bg);
  border-radius: var(--radius-sm);
}

.footer-age img { height: 40px; width: auto; border-radius: 6px; }

/* ===== Cookie Banner ===== */
.cookie-banner {
  position: fixed;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  z-index: 200;
  background: var(--surface);
  color: var(--text);
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  transform: translateY(calc(100% + 2rem));
  transition: transform 0.4s ease;
  max-width: 720px;
  margin: 0 auto;
}

.cookie-banner.is-visible { transform: translateY(0); }

.cookie-banner__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.cookie-banner p {
  margin: 0;
  font-size: 0.88rem;
  flex: 1;
  min-width: 200px;
  color: var(--text-muted);
}

.cookie-banner__actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* ===== 404 Page ===== */
.page-404 {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1rem;
}

.page-404__code {
  font-size: clamp(4rem, 15vw, 7rem);
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  margin: 0;
  opacity: 0.85;
}

.page-404 h1 { font-size: 1.5rem; margin: 1rem 0; }
.page-404 p { color: var(--text-muted); max-width: 480px; margin: 0 auto 1.5rem; }

/* ===== Redirect Page ===== */
.redirect-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #eef2ff, #f8fafc);
  color: var(--text-heading);
  text-align: center;
  padding: 2rem;
}

.redirect-page h1 { font-size: 1.5rem; }
.redirect-page img { max-width: 280px; margin: 1.5rem auto; }

/* ===== Scroll to top ===== */
.scroll-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 44px;
  height: 44px;
  background: var(--surface);
  color: var(--accent);
  border: 1px solid var(--border);
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.15rem;
  font-weight: 600;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s, box-shadow 0.2s;
  z-index: 50;
  box-shadow: var(--shadow-md);
}

.scroll-top.is-visible { opacity: 1; visibility: visible; }
.scroll-top:hover { box-shadow: 0 12px 28px rgba(99, 102, 241, 0.2); }

/* ===== Responsive ===== */
@media (max-width: 960px) {
  .page-layout { grid-template-columns: 1fr; }
  .toc { position: static; max-height: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .menu-toggle { display: block; }

  .site-nav {
    position: fixed;
    top: 68px;
    left: 1rem;
    right: 1rem;
    background: var(--surface);
    flex-direction: column;
    padding: 0.75rem;
    border-radius: var(--radius);
    transform: translateY(-130%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s, opacity 0.3s, visibility 0.3s;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
  }

  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .site-nav a { width: 100%; text-align: center; padding: 0.75rem; }

  .article { padding: 1.35rem 1.15rem; }
  .author-box { flex-direction: column; align-items: center; text-align: center; }
  .footer-grid { grid-template-columns: 1fr; }

  .widget-shell iframe { pointer-events: none; }
  .widget-shell.is-interactive iframe { pointer-events: auto; }
  .widget-shell__overlay.is-visible { display: flex; }

  .cookie-banner { left: 0.75rem; right: 0.75rem; bottom: 0.75rem; }
}

@media (max-width: 480px) {
  .cookie-banner__inner { flex-direction: column; align-items: stretch; }
  .cookie-banner__actions { justify-content: stretch; }
  .cookie-banner__actions .btn { flex: 1; text-align: center; }
}
