/* ===== CSS Variables ===== */
:root {
  --color-bg: #f7f5f0;
  --color-bg-alt: #eeebe3;
  --color-surface: #ffffff;
  --color-surface-hover: #f3f0ea;
  --color-gold: #b8860b;
  --color-gold-light: #d4a017;
  --color-gold-dark: #966d0a;
  --color-text: #1e293b;
  --color-text-muted: #64748b;
  --color-border: #ddd8ce;
  --color-accent: #6366f1;
  --font-sans: 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-display: Georgia, 'Times New Roman', serif;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  --max-width: 1140px;
  --header-height: 64px;
  --transition: 0.2s ease;
}

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

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

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a {
  color: var(--color-gold);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover,
a:focus-visible {
  color: var(--color-gold-dark);
}

:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

/* ===== Layout ===== */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

main {
  flex: 1;
}

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

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

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

.logo img {
  display: block;
  height: 48px;
  width: auto;
  filter: invert(1);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--color-text);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  margin: 5px 0;
  transition: var(--transition);
}

.site-nav ul {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.site-nav a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--color-text-muted);
  font-size: 0.9375rem;
  font-weight: 500;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--color-gold);
  background: var(--color-surface);
}

/* ===== Hero ===== */
.hero {
  padding: 3rem 0 2rem;
  text-align: center;
  background: linear-gradient(180deg, #ffffff 0%, var(--color-bg) 100%);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  line-height: 1.2;
  color: var(--color-text);
  margin-bottom: 1rem;
}

.hero-lead {
  font-size: clamp(1rem, 2vw, 1.125rem);
  color: var(--color-text-muted);
  max-width: 720px;
  margin: 0 auto;
}

/* ===== Widget Section ===== */
.widget-section {
  padding: 1.5rem 0;
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.widget-section h2 {
  font-size: 1.375rem;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--color-gold);
}

.widget-wrapper {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-surface);
  box-shadow: var(--shadow);
}

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

/* ===== Content Sections ===== */
.content-section {
  padding: 3rem 0;
}

.content-section:nth-child(even) {
  background: var(--color-bg-alt);
}

.content-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 3vw, 1.875rem);
  color: var(--color-gold);
  margin-bottom: 1.25rem;
  line-height: 1.3;
}

.content-section h3 {
  font-size: 1.25rem;
  color: var(--color-text);
  margin: 2rem 0 0.75rem;
}

.content-section h4 {
  font-size: 1.0625rem;
  color: var(--color-gold-light);
  margin: 1.5rem 0 0.5rem;
}

.content-section p {
  margin-bottom: 1rem;
  color: var(--color-text-muted);
}

.content-section ul,
.content-section ol {
  margin: 0 0 1rem 1.5rem;
  color: var(--color-text-muted);
}

.content-section li {
  margin-bottom: 0.5rem;
}

.content-section li::marker {
  color: var(--color-gold);
}

/* ===== Casino Cards ===== */
.casino-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  transition: border-color var(--transition);
}

.casino-card:hover {
  border-color: var(--color-gold-dark);
}

.casino-card h3 {
  margin-top: 0;
  color: var(--color-gold);
}

/* ===== Tables ===== */
.table-wrapper {
  overflow-x: auto;
  margin: 1.5rem 0;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

thead {
  background: var(--color-surface);
}

th {
  padding: 0.875rem 1rem;
  text-align: left;
  font-weight: 600;
  color: var(--color-gold);
  white-space: nowrap;
  border-bottom: 2px solid var(--color-gold-dark);
}

td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-muted);
}

tbody tr:hover {
  background: var(--color-surface-hover);
}

tbody tr:last-child td {
  border-bottom: none;
}

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

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
  background: var(--color-surface);
}

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

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

.faq-item summary::after {
  content: '+';
  font-size: 1.25rem;
  color: var(--color-gold);
  transition: transform var(--transition);
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item summary:hover {
  background: var(--color-surface-hover);
}

.faq-answer {
  padding: 0 1.25rem 1rem;
  color: var(--color-text-muted);
}

/* ===== Contact Page ===== */
.contact-grid {
  display: grid;
  gap: 2rem;
  margin-top: 2rem;
}

.contact-info {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
}

.contact-info h2 {
  margin-bottom: 1.5rem;
}

.contact-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
  align-items: flex-start;
}

.contact-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: var(--color-bg-alt);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold);
}

.contact-item p {
  margin: 0;
}

.contact-item a {
  color: var(--color-gold);
}

.map-wrapper {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border);
  aspect-ratio: 4 / 3;
}

.map-wrapper iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* ===== 404 Page ===== */
.error-page {
  text-align: center;
  padding: 5rem 1.25rem;
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.error-code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 15vw, 8rem);
  color: var(--color-gold);
  line-height: 1;
  margin-bottom: 1rem;
}

.error-page h1 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-bottom: 1rem;
}

.error-page p {
  color: var(--color-text-muted);
  margin-bottom: 2rem;
  max-width: 480px;
}

.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  background: var(--color-gold);
  color: #ffffff;
  font-weight: 600;
  border-radius: var(--radius);
  transition: background var(--transition), transform var(--transition);
}

.btn:hover {
  background: var(--color-gold-dark);
  color: #ffffff;
  transform: translateY(-1px);
}

/* ===== Footer ===== */
.site-footer {
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  padding: 2.5rem 0 1.5rem;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: start;
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--color-gold);
  margin-bottom: 0.75rem;
}

.footer-contacts {
  list-style: none;
  margin: 0;
}

.footer-contacts li {
  margin-bottom: 0.5rem;
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

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

.footer-contacts a:hover {
  color: var(--color-gold);
}

.footer-social {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-text-muted);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.social-link:hover {
  background: #1877f2;
  border-color: #1877f2;
  color: #fff;
}

.social-link svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
  text-align: center;
  font-size: 0.8125rem;
  color: var(--color-text-muted);
}

/* ===== Cookie Banner ===== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 1.25rem;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

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

.cookie-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  justify-content: space-between;
}

.cookie-text {
  flex: 1;
  min-width: 240px;
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

.cookie-text a {
  color: var(--color-gold);
  text-decoration: underline;
}

.cookie-actions {
  display: flex;
  gap: 0.75rem;
  flex-shrink: 0;
}

.cookie-btn {
  padding: 0.625rem 1.25rem;
  border: none;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}

.cookie-btn-accept {
  background: var(--color-gold);
  color: #ffffff;
}

.cookie-btn-accept:hover {
  background: var(--color-gold-dark);
}

.cookie-btn-decline {
  background: transparent;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.cookie-btn-decline:hover {
  background: var(--color-surface-hover);
  color: var(--color-text);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
    padding: 1rem;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease;
  }

  .site-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0;
  }

  .site-nav a {
    padding: 0.875rem 1rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }

  .cookie-inner {
    flex-direction: column;
    text-align: center;
  }

  .cookie-actions {
    width: 100%;
    justify-content: center;
  }

  th,
  td {
    padding: 0.625rem 0.75rem;
    font-size: 0.8125rem;
  }
}

@media (min-width: 769px) {
  .contact-grid {
    grid-template-columns: 1fr 1.5fr;
    align-items: start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
