/* =========================================================
   Variables
   ========================================================= */
:root {
  /* Colors */
  --color-bg: #050816;
  --color-surface: #0f172a;
  --color-surface-soft: #111827;
  --color-text: #e5e7eb;
  --color-text-muted: #9ca3af;
  --color-border: #1f2937;

  --color-primary: #38bdf8; /* modern, energetic accent */
  --color-primary-soft: rgba(56, 189, 248, 0.15);
  --color-success: #22c55e;
  --color-warning: #eab308;
  --color-danger: #ef4444;

  --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: #1f2937;
  --gray-900: #111827;

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
    'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji',
    'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji';
  --font-heading: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont,
    'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;

  --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 */

  --line-height-tight: 1.1;
  --line-height-snug: 1.25;
  --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-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-xs: 0.125rem; /* 2px */
  --radius-sm: 0.25rem;  /* 4px */
  --radius-md: 0.5rem;   /* 8px */
  --radius-lg: 0.75rem;  /* 12px */
  --radius-xl: 1rem;     /* 16px */
  --radius-pill: 9999px;

  /* Shadows (subtle, modern for cards & modals) */
  --shadow-sm: 0 8px 20px rgba(15, 23, 42, 0.45);
  --shadow-md: 0 18px 45px rgba(15, 23, 42, 0.75);
  --shadow-soft: 0 0 0 1px rgba(148, 163, 184, 0.15);

  /* Transitions */
  --duration-fast: 120ms;
  --duration-normal: 200ms;
  --duration-slow: 300ms;
  --easing-standard: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html,
body {
  margin: 0;
  padding: 0;
}

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

body {
  min-height: 100vh;
}

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

picture {
  display: block;
}

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

ul,
ol {
  margin: 0;
  padding: 0;
}

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

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

/* Remove default button styles where necessary */
button {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

/* =========================================================
   Base Styles
   ========================================================= */
body {
  font-family: var(--font-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
  background: radial-gradient(circle at top, #0f172a 0, #020617 55%, #000 100%);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
}

main {
  min-height: 60vh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: var(--line-height-tight);
  color: #f9fafb;
}

h1 {
  font-size: clamp(2.25rem, 3vw + 1rem, 3.25rem);
  letter-spacing: -0.04em;
  margin-bottom: var(--space-4);
}

h2 {
  font-size: clamp(1.75rem, 2.2vw + 0.5rem, 2.25rem);
  letter-spacing: -0.03em;
  margin-bottom: var(--space-3);
}

h3 {
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-2);
}

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

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

p:last-child {
  margin-bottom: 0;
}

small {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

strong {
  font-weight: 600;
}

a {
  position: relative;
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--duration-normal) var(--easing-standard);
}

a:hover {
  color: #7dd3fc;
}

/* Underline only on hover for inline links */
a.inline-link {
  text-decoration: none;
}

a.inline-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.15em;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #38bdf8, #22c55e);
  transition: width var(--duration-normal) var(--easing-standard);
}

a.inline-link:hover::after {
  width: 100%;
}

hr {
  border: 0;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  margin: var(--space-6) 0;
}

/* =========================================================
   Accessibility & Motion
   ========================================================= */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

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

/* =========================================================
   Utilities
   ========================================================= */

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

.section {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
}

.section--tight {
  padding-top: var(--space-10);
  padding-bottom: var(--space-10);
}

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

.flex-row {
  flex-direction: row;
}

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

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

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

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

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

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

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

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

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

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

/* Spacing Utilities (margin/padding) */
.mt-0 { margin-top: 0; }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }

/* Text Utilities */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--color-text-muted); }

/* Screen Reader Only */
.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;
}

/* =========================================================
   Components
   ========================================================= */

/* Buttons - primary actions: rezerwacje, zapytania, kontakt */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-size: var(--font-size-sm);
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color var(--duration-normal) var(--easing-standard),
    border-color var(--duration-normal) var(--easing-standard),
    color var(--duration-normal) var(--easing-standard),
    box-shadow var(--duration-normal) var(--easing-standard),
    transform var(--duration-fast) var(--easing-standard);
}

.btn-primary {
  background: linear-gradient(135deg, #38bdf8, #22c55e);
  color: #020617;
  box-shadow: 0 16px 40px rgba(56, 189, 248, 0.4);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 60px rgba(56, 189, 248, 0.55);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-text);
  border-color: rgba(148, 163, 184, 0.6);
}

.btn-outline:hover {
  border-color: var(--color-primary);
  background-color: rgba(15, 23, 42, 0.95);
}

.btn-ghost {
  background-color: rgba(15, 23, 42, 0.7);
  color: var(--gray-100);
}

.btn-ghost:hover {
  background-color: rgba(15, 23, 42, 0.95);
}

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

/* Inputs - formularze kontaktowe, rezerwacje, zapytania */
.form-group {
  margin-bottom: var(--space-4);
}

.label {
  display: block;
  margin-bottom: var(--space-1);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--gray-200);
}

.input,
.textarea,
.select {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.4);
  background-color: rgba(15, 23, 42, 0.9);
  color: var(--color-text);
  font-size: var(--font-size-sm);
  transition:
    border-color var(--duration-normal) var(--easing-standard),
    background-color var(--duration-normal) var(--easing-standard),
    box-shadow var(--duration-normal) var(--easing-standard),
    transform var(--duration-fast) var(--easing-standard);
}

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

.input:focus,
.textarea:focus,
.select:focus {
  outline: none;
  border-color: var(--color-primary);
  background-color: rgba(15, 23, 42, 1);
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.55);
}

.textarea {
  min-height: 140px;
  resize: vertical;
}

.input--error,
.textarea--error,
.select--error {
  border-color: var(--color-danger);
}

.form-helper {
  margin-top: 0.3rem;
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
}

.form-error {
  margin-top: 0.3rem;
  font-size: var(--font-size-xs);
  color: var(--color-danger);
}

/* Cards - używane dla formatów eventów, opcji pokerowych, ofert biznesowych */
.card {
  position: relative;
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 55%),
    radial-gradient(circle at bottom right, rgba(34, 197, 94, 0.08), transparent 55%),
    var(--color-surface);
  border: 1px solid rgba(148, 163, 184, 0.24);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top, rgba(148, 163, 184, 0.12), transparent 55%);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-normal) var(--easing-standard);
}

.card:hover::before {
  opacity: 1;
}

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

.card-title {
  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);
}

.card-footer {
  margin-top: var(--space-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

/* Tag / badge for event type (np. "Event firmowy", "Poker offline") */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--font-size-xs);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background-color: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.6);
  color: var(--color-text-muted);
}

.badge-primary {
  background-color: var(--color-primary-soft);
  border-color: rgba(56, 189, 248, 0.8);
  color: #e0f2fe;
}

/* Simple pill label for statuses like "Dostępne", "Na zapytanie" */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.12rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--font-size-xs);
  background-color: rgba(15, 23, 42, 0.85);
}

.status-dot {
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 999px;
  background-color: var(--color-success);
}

/* Hero / Highlight band for main messages about REKO-CLEAN events */
.hero-band {
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.25), transparent 55%),
    radial-gradient(circle at bottom right, rgba(34, 197, 94, 0.25), transparent 55%),
    linear-gradient(135deg, #020617, #020617 50%, #020617);
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: var(--shadow-md);
}

.hero-band-title {
  font-size: clamp(2rem, 2.8vw + 0.8rem, 2.75rem);
  margin-bottom: var(--space-3);
}

.hero-band-subtitle {
  max-width: 36rem;
  color: var(--color-text-muted);
}

/* Navigation shell (for header/footer base styling) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.7));
  border-bottom: 1px solid rgba(148, 163, 184, 0.3);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding-top: var(--space-3);
  padding-bottom: var(--space-3);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.site-nav-link {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
  position: relative;
  padding-bottom: 0.15rem;
}

.site-nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, #38bdf8, #22c55e);
  transition: width var(--duration-normal) var(--easing-standard);
}

.site-nav-link:hover {
  color: var(--gray-50);
}

.site-nav-link:hover::after,
.site-nav-link--active::after {
  width: 100%;
}

.site-nav-link--active {
  color: var(--gray-50);
}

.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.3);
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.9), #020617);
}

.site-footer-meta {
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
}

/* Callout for important legal / participation notes (e.g. poker info) */
.callout {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background-color: rgba(15, 23, 42, 0.9);
  border-left: 3px solid var(--color-primary);
  font-size: var(--font-size-sm);
}

.callout-title {
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.callout-muted {
  border-left-color: var(--gray-500);
}

/* Responsive tweaks */
@media (max-width: 768px) {
  .section {
    padding-top: var(--space-10);
    padding-bottom: var(--space-10);
  }

  .hero-band {
    padding: var(--space-5);
  }

  .site-header-inner {
    padding-top: var(--space-2);
    padding-bottom: var(--space-2);
  }
}
