/* ========================================================================
   Variables
   ======================================================================== */
:root {
  /* Brand Colors */
  --color-background: #060712;
  --color-surface: #101222;
  --color-surface-elevated: #181a2a;
  --color-text: #f5f5f7;
  --color-text-muted: #a0a3b5;

  --color-primary: #e63946; /* Main accent - poker chip red */
  --color-primary-soft: rgba(230, 57, 70, 0.12);

  --color-success: #2ecc71;
  --color-warning: #f1c40f;
  --color-danger: #e74c3c;

  /* Neutral Grays */
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2933;
  --gray-900: #111827;

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --font-size-xs: 0.75rem;   /* 12px */
  --font-size-sm: 0.875rem;  /* 14px */
  --font-size-base: 1rem;    /* 16px */
  --font-size-lg: 1.125rem;  /* 18px */
  --font-size-xl: 1.25rem;   /* 20px */
  --font-size-2xl: 1.5rem;   /* 24px */
  --font-size-3xl: 1.875rem; /* 30px */
  --font-size-4xl: 2.25rem;  /* 36px */
  --font-size-5xl: 3rem;     /* 48px */

  --line-height-tight: 1.15;
  --line-height-snug: 1.3;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.7;

  /* Spacing scale (0–96px) */
  --space-0: 0;
  --space-1: 0.25rem;  /* 4px */
  --space-2: 0.5rem;   /* 8px */
  --space-3: 0.75rem;  /* 12px */
  --space-4: 1rem;     /* 16px */
  --space-5: 1.25rem;  /* 20px */
  --space-6: 1.5rem;   /* 24px */
  --space-7: 1.75rem;  /* 28px */
  --space-8: 2rem;     /* 32px */
  --space-10: 2.5rem;  /* 40px */
  --space-12: 3rem;    /* 48px */
  --space-16: 4rem;    /* 64px */
  --space-20: 5rem;    /* 80px */
  --space-24: 6rem;    /* 96px */

  /* Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 999px;

  /* Shadows (subtle, for nightlife neon feel) */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.6);
  --shadow-sm: 0 4px 10px rgba(0, 0, 0, 0.65);
  --shadow-md: 0 12px 30px rgba(0, 0, 0, 0.7);
  --shadow-glow-primary: 0 0 18px rgba(230, 57, 70, 0.6);

  /* Transitions & Motion */
  --transition-fast: 120ms ease-out;
  --transition-normal: 200ms ease;
  --transition-slow: 320ms ease;
}

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  :root {
    --transition-fast: 0.001ms;
    --transition-normal: 0.001ms;
    --transition-slow: 0.001ms;
  }
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

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

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

body {
  margin: 0;
}

h1, h2, h3, h4, h5, h6,
p, figure, blockquote,
dl, dd {
  margin: 0;
}

ul, ol {
  margin: 0;
  padding: 0;
  list-style: none !important; /* Per requirements */
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

button {
  border: none;
  padding: 0;
  background: none;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Improve text rendering */
body, input, button, textarea, select {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========================================================================
   Base Styles
   ======================================================================== */
body {
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  background-color: var(--color-background);
  color: var(--color-text);
}

main {
  display: block;
}

/* Headings: sleek display font, controlled margins */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: var(--line-height-tight);
  color: var(--color-text);
}

h1 {
  font-size: var(--font-size-4xl);
  letter-spacing: 0.02em;
  margin-bottom: var(--space-4);
}

h2 {
  font-size: var(--font-size-3xl);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: var(--font-size-2xl);
  margin-bottom: var(--space-2);
}

h4 {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-2);
}

h5 {
  font-size: var(--font-size-lg);
  margin-bottom: var(--space-1);
}

h6 {
  font-size: var(--font-size-sm);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-1);
}

p {
  margin-bottom: var(--space-3);
  color: var(--color-text-muted);
}

strong, b {
  font-weight: 600;
}

/* Links: nightlife hover, must be white on hover */
a {
  position: relative;
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast),
              text-shadow var(--transition-fast);
}

a:hover {
  color: #fff !important; /* Per requirements */
  text-shadow: 0 0 12px rgba(230, 57, 70, 0.7);
}

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

/* ========================================================================
   Accessibility Helpers
   ======================================================================== */
.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;
}

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

/* ========================================================================
   Layout Utilities
   ======================================================================== */
.container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
  max-width: 1200px;
}

@media (min-width: 1440px) {
  .container {
    max-width: 1320px;
  }
}

/* Flex helpers */
.flex {
  display: flex;
}

.inline-flex {
  display: inline-flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.flex-col {
  display: flex;
  flex-direction: column;
}

.flex-wrap {
  flex-wrap: wrap;
}

.items-center {
  align-items: center;
}

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

.gap-2 {
  gap: var(--space-2);
}

.gap-4 {
  gap: var(--space-4);
}

/* Grid helpers */
.grid {
  display: grid;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Spacing utilities (common ones) */
.mt-0 { margin-top: 0 !important; }
.mt-4 { margin-top: var(--space-4) !important; }
.mt-8 { margin-top: var(--space-8) !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-4 { margin-bottom: var(--space-4) !important; }
.mb-8 { margin-bottom: var(--space-8) !important; }
.py-8 { padding-top: var(--space-8) !important; padding-bottom: var(--space-8) !important; }
.py-12 { padding-top: var(--space-12) !important; padding-bottom: var(--space-12) !important; }

/* ========================================================================
   Basic Components
   ======================================================================== */
/* Buttons: modern, casino-night style */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.7rem 1.6rem;
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color var(--transition-normal),
              color var(--transition-normal),
              box-shadow var(--transition-normal),
              transform var(--transition-fast),
              border-color var(--transition-normal);
}

.btn-primary {
  background: radial-gradient(circle at 10% 0%, #ff6b6b 0%, var(--color-primary) 40%, #b2182b 100%);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: radial-gradient(circle at 0% 0%, #ff8787 0%, var(--color-primary) 45%, #951320 100%);
  box-shadow: var(--shadow-md), var(--shadow-glow-primary);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-text);
  border-color: rgba(250, 250, 252, 0.22);
}

.btn-outline:hover {
  background-color: rgba(255, 255, 255, 0.06);
  border-color: rgba(250, 250, 252, 0.4);
}

.btn-ghost {
  background-color: transparent;
  color: var(--color-text-muted);
}

.btn-ghost:hover {
  background-color: rgba(255, 255, 255, 0.04);
  color: var(--color-text);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.btn:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

/* Inputs & forms: consistent, sleek */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="password"],
input[type="search"],
textarea,
select {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background-color: rgba(6, 7, 18, 0.9);
  color: var(--color-text);
  font-size: var(--font-size-sm);
  line-height: var(--line-height-normal);
  transition: border-color var(--transition-normal),
              box-shadow var(--transition-normal),
              background-color var(--transition-normal);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-text-muted);
  opacity: 0.7;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px rgba(230, 57, 70, 0.45);
  background-color: rgba(10, 12, 28, 1);
}

input[disabled],
textarea[disabled],
select[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

label {
  display: inline-block;
  margin-bottom: var(--space-1);
  font-size: var(--font-size-sm);
  color: var(--color-text);
}

/* Card: used for toernooi-info, events, etc. */
.card {
  position: relative;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top, rgba(230, 57, 70, 0.12) 0, transparent 45%),
              var(--color-surface);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.card-header {
  margin-bottom: var(--space-3);
}

.card-title {
  font-family: var(--font-display);
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-1);
}

.card-subtitle {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

.card-body {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

/* Pill for game type: Poker / Blackjack / Event, etc. */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.6rem;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--color-text-muted);
}

.badge-primary {
  border-color: rgba(230, 57, 70, 0.6);
  color: #fff;
  background: rgba(230, 57, 70, 0.18);
}

/* ========================================================================
   Site-Specific Flavour (Delta Arana)
   ======================================================================== */
/* Nightlife gradient background helper for hero sections */
.hero-night {
  background:
    radial-gradient(circle at 0% 0%, rgba(230, 57, 70, 0.35) 0, transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(63, 81, 181, 0.24) 0, transparent 50%),
    linear-gradient(135deg, #050612 0%, #05060d 40%, #05060f 100%);
  color: var(--color-text);
}

.hero-night-overlay {
  position: relative;
}

.hero-night-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  mix-blend-mode: screen;
  opacity: 0.2;
  background-image: radial-gradient(circle at 0 0, rgba(255, 255, 255, 0.18), transparent 55%),
                    radial-gradient(circle at 100% 0, rgba(255, 255, 255, 0.14), transparent 55%);
  pointer-events: none;
}

.hero-night-overlay > * {
  position: relative;
}

/* Subtle divider */
.divider {
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin: var(--space-6) 0;
}

/* Tag list styling for events / toernooien */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.tag {
  padding: 0.15rem 0.7rem;
  font-size: 0.75rem;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--color-text-muted);
}

/* Tables for toernooi-schema */
table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

thead {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

th, td {
  padding: 0.7rem 0.6rem;
  text-align: left;
}

tbody tr:nth-child(odd) {
  background-color: rgba(15, 17, 32, 0.9);
}

tbody tr:nth-child(even) {
  background-color: rgba(10, 11, 24, 0.9);
}

tbody tr:hover {
  background-color: rgba(230, 57, 70, 0.14);
}

th {
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

/* Footer utilities for nightlife site */
.footer {
  padding: var(--space-8) 0;
  background: linear-gradient(180deg, #050612 0%, #020308 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

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

.footer a:hover {
  color: #fff !important;
}
