/*
 * Base Stylesheet for "ŻEL-BUD" Wiesław Żelek
 * Nowoczesny, jasny, eventowy, elegancki, dynamiczny, profesjonalny
 * Mobile-first, przejrzyste typografie, akcenty: granat, złoto, grafit
 */

/* =============================================
   1. VARIABLES (CSS CUSTOM PROPERTIES)
   ============================================= */

:root {
  /* Color Palette - Jasny eventowy styl */
  --color-background: #ffffff;
  --color-surface: #f8fafc;
  --color-surface-elevated: #ffffff;

  --color-text: #111827; /* very dark slate */
  --color-text-muted: #6b7280; /* gray-500 */
  --color-text-soft: #9ca3af; /* gray-400 */

  /* Brand / Accent Colors - granat, złoto, grafit */
  --color-primary: #0b1a3c; /* deep navy */
  --color-primary-soft: #1d2b52;
  --color-primary-light: #314581;

  --color-accent-gold: #d3a74a; /* warm gold */
  --color-accent-gold-soft: rgba(211, 167, 74, 0.12);

  --color-ink-dark: #111827; /* grafit text */

  /* Semantic States */
  --color-success: #16a34a;
  --color-warning: #f59e0b;
  --color-danger: #dc2626;

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

  /* Typography - nowoczesna typografia (sans + display) */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --font-display: "Poppins", "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Font Sizes (rem, base 16px) */
  --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 Heights */
  --line-height-tight: 1.1;
  --line-height-snug: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.7;

  /* Spacing Scale (px translated to rem, 1rem = 16px) */
  --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 */

  /* Radii */
  --radius-sm: 0.25rem;   /* 4px */
  --radius-md: 0.5rem;    /* 8px */
  --radius-lg: 0.75rem;   /* 12px */
  --radius-xl: 1rem;      /* 16px */
  --radius-full: 9999px;

  /* Shadows - subtelne, eventowe, eleganckie */
  --shadow-soft: 0 8px 20px rgba(15, 23, 42, 0.06);
  --shadow-medium: 0 14px 35px rgba(15, 23, 42, 0.12);
  --shadow-strong: 0 18px 45px rgba(15, 23, 42, 0.16);

  /* Transitions */
  --transition-fast: 150ms ease-out;
  --transition-normal: 220ms ease-out;
  --transition-slow: 320ms ease-out;

  /* Layout */
  --container-width: 1120px;
  --container-padding-x: 1.5rem;
}

/* =============================================
   2. RESET / NORMALIZE
   ============================================= */

/* Box sizing */
*, *::before, *::after {
  box-sizing: border-box;
}

/* Remove default margins */
body, h1, h2, h3, h4, h5, h6, p,
figure, blockquote, dl, dd,
ul, ol {
  margin: 0;
}

ul, ol {
  padding-left: 1.25rem;
}

/* Remove list styles on lists with a class */
ul[class], ol[class] {
  list-style: none;
  padding-left: 0;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Body defaults */
body {
  min-height: 100vh;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Images & media responsive */
img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

/* Forms inherit font */
input, button, textarea, select {
  font: inherit;
}

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

/* Remove default link styling for visited */
a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

/* Prevent text overflows */
 p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

/* =============================================
   3. BASE STYLES
   ============================================= */

body {
  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 - nowoczesne, lekko display */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--color-primary);
}

h1 {
  font-size: var(--font-size-3xl);
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-4);
}

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

h3 {
  font-size: var(--font-size-xl);
  line-height: var(--line-height-snug);
  margin-bottom: var(--space-3);
}

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

h5 {
  font-size: var(--font-size-base);
  margin-bottom: var(--space-2);
}

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

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

p.lead {
  font-size: var(--font-size-lg);
  line-height: var(--line-height-relaxed);
  color: var(--color-text-muted);
}

strong {
  font-weight: 600;
}

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

/* Links - akcent granat / złoto */
a {
  color: var(--color-primary-light);
  text-decoration: none;
  transition: color var(--transition-normal),
              opacity var(--transition-fast);
}

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

a:active {
  opacity: 0.85;
}

/* Sections spacing */
section,
.section {
  padding-top: var(--space-10);
  padding-bottom: var(--space-10);
}

/* =============================================
   4. UTILITIES
   ============================================= */

/* Container */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding-x);
  padding-right: var(--container-padding-x);
}

/* Layout 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-column {
  display: flex;
  flex-direction: column;
}

.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;
  }
}

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

.text-right {
  text-align: right;
}

.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-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.pt-0 { padding-top: 0; }
.pb-0 { padding-bottom: 0; }

/* Screen-reader only utility */
.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;
}

/* Hero / Slider specific helpers */
.hero-full {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-gray-900);
  color: #ffffff;
}
.hero h1,
.hero-full h1{
    color: #fff;
}
.notice-entertainment p,
.hero-full p,
.notice-entertainment__title{
    color: #fff;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(11, 26, 60, 0.9), rgba(11, 26, 60, 0.55));
}

.hero-content {
  position: relative;
  z-index: 1;
}

.badge-note {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  background-color: var(--color-gray-900);
  color: #ffffff;
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

.badge-note--warning {
  background-color: rgba(220, 38, 38, 0.85);
}

/* =============================================
   5. COMPONENTS
   ============================================= */

/* Buttons - primary, ghost, outline
   Używane np. dla CTA typu "Zapytaj o ofertę" / "Zorganizuj event" */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color var(--transition-normal),
              color var(--transition-normal),
              border-color var(--transition-normal),
              box-shadow var(--transition-normal),
              transform var(--transition-fast);
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
  color: #ffffff;
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-medium);
  background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary));
}

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

.btn-ghost {
  background-color: rgba(15, 23, 42, 0.04);
  color: var(--color-primary);
}

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

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

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

.btn-gold {
  background: linear-gradient(135deg, #f7d083, var(--color-accent-gold));
  color: #111827;
  box-shadow: var(--shadow-medium);
}

.btn-gold:hover {
  filter: brightness(1.05);
}

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

/* Inputs & forms - formularz kontaktowy, zapytania ofertowe */

.input,
textarea,
select {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-gray-300);
  background-color: #ffffff;
  font-size: var(--font-size-sm);
  color: var(--color-text);
  transition: border-color var(--transition-fast),
              box-shadow var(--transition-fast),
              background-color var(--transition-fast);
}

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

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

.input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--color-primary-light);
  box-shadow: 0 0 0 1px var(--color-primary-light), 0 0 0 4px rgba(49, 69, 129, 0.18);
}

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

.form-label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-gray-700);
}

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

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

/* Cards - np. dla sekcji "Eventy wyjazdowe", "Poker eventowy", opinie klientów */

.card {
  position: relative;
  border-radius: var(--radius-lg);
  background-color: var(--color-surface-elevated);
  box-shadow: var(--shadow-soft);
  padding: var(--space-5);
  overflow: hidden;
}

.card--muted {
  background-color: var(--color-surface);
  box-shadow: none;
  border: 1px solid var(--color-gray-200);
}

.card__badge {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  background-color: rgba(15, 23, 42, 0.86);
  color: #ffffff;
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

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

.card__title {
  font-size: var(--font-size-xl);
  margin-bottom: 0.25rem;
}

.card__subtitle {
  font-size: var(--font-size-sm);
  color: var(--color-text-soft);
}

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

/* Entertainment-only notice component
   Używać na każdej podstronie obok treści o pokerze/ruletce/blackjacku */

.notice-entertainment {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  background-color: var(--color-accent-gold-soft);
  border: 1px solid rgba(211, 167, 74, 0.6);
  font-size: var(--font-size-xs);
  color: var(--color-gray-900);
}

.notice-entertainment__icon {
  margin-top: 0.15rem;
  font-size: 1rem;
}

.notice-entertainment__title {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.15rem;
}

/* Navigation (basic styling, extend per layout) */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: var(--font-size-sm);
}

.nav a {
  position: relative;
  padding: 0.25rem 0;
  color: var(--color-gray-700);
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.15rem;
  width: 0;
  height: 2px;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, var(--color-accent-gold), var(--color-primary-light));
  transition: width var(--transition-normal);
}

.nav a:hover {
  color: var(--color-primary);
}

.nav a:hover::after {
  width: 100%;
}

.nav a.is-active {
  color: var(--color-primary);
}

.nav a.is-active::after {
  width: 100%;
}

/* Footer basic styling */

.site-footer {
  border-top: 1px solid var(--color-gray-200);
  background-color: var(--color-gray-50);
  padding-top: var(--space-8);
  padding-bottom: var(--space-6);
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

.site-footer__bottom {
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--color-gray-200);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 768px) {
  .site-footer__bottom {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* =============================================
   6. ACCESSIBILITY & REDUCED MOTION
   ============================================= */

/* Focus visible outlines */
:focus-visible {
  outline: 2px solid var(--color-accent-gold);
  outline-offset: 3px;
}

/* Better outline on dark backgrounds */
[data-theme="dark"] :focus-visible,
.hero-full :focus-visible {
  outline-color: #fbbf24;
}

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

/* =============================================
   7. RESPONSIVE TYPOGRAPHY TWEAKS
   ============================================= */

@media (min-width: 640px) {
  h1 {
    font-size: var(--font-size-4xl);
  }

  h2 {
    font-size: calc(var(--font-size-2xl) * 1.05);
  }
}

@media (min-width: 1024px) {
  h1 {
    font-size: var(--font-size-5xl);
  }

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