/* ========================================================================
   Variables
   ======================================================================== */

:root {
  /* Colors - brand & semantic */
  --color-background: #ffffff;
  --color-surface: #ffffff;
  --color-surface-alt: #f8f9ff;
  --color-text: #1f2933;
  --color-text-muted: #6b7280;

  --color-primary: #5f8cff;          /* pastel blue */
  --color-primary-soft: #e4ecff;
  --color-primary-strong: #3c6df2;

  --color-accent-mint: #7ee2c3;
  --color-accent-lilac: #c9a7ff;
  --color-accent-pink: #ffb3d1;
  --color-accent-yellow: #ffe58a;

  --color-success: #16a34a;
  --color-warning: #f59e0b;
  --color-danger: #ef4444;

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

  /* Gradients - subtle rainbow & hero */
  --gradient-rainbow-soft: linear-gradient(135deg,
    rgba(95, 140, 255, 0.18),   /* blue */
    rgba(126, 226, 195, 0.2),   /* mint */
    rgba(201, 167, 255, 0.2),   /* lilac */
    rgba(255, 179, 209, 0.2),   /* pink */
    rgba(255, 229, 138, 0.22)   /* yellow */
  );

  --gradient-hero: radial-gradient(circle at top left,
    rgba(95, 140, 255, 0.25), transparent 55%),
    radial-gradient(circle at top right,
    rgba(201, 167, 255, 0.28), transparent 55%),
    radial-gradient(circle at bottom,
    rgba(126, 226, 195, 0.25), transparent 55%),
    #ffffff;

  /* 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,
    "Segoe UI", 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 */
  --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 (px) */
  --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: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-pill: 999px;

  /* Shadows (soft & airy) */
  --shadow-xs: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 10px 30px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 18px 45px rgba(15, 23, 42, 0.12);

  /* Transitions */
  --transition-fast: 120ms ease-out;
  --transition-base: 200ms ease-out;
  --transition-slow: 320ms ease;

  /* Layout */
  --container-width: 1120px;
  --container-padding-mobile: 1.25rem;
  --container-padding-desktop: 1.5rem;

  /* Z-index scale */
  --z-header: 40;
  --z-overlay: 50;
  --z-modal: 60;
  --z-toast: 70;
}

/* ========================================================================
   Reset & Normalize
   ======================================================================== */

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

html {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  margin: 0;
}

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

ul,
ol {
  padding: 0;
  list-style: none;
}

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

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

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

textarea {
  resize: vertical;
}

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

[hidden] {
  display: none !important;
}

/* ========================================================================
   Base Styles
   ======================================================================== */

body {
  font-family: var(--font-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  color: var(--color-text);
  background: var(--gradient-hero);
  -webkit-font-smoothing: antialiased;
}

main {
  min-height: 60vh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--gray-900);
}

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-2);
}

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

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

strong {
  font-weight: 600;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;
}

/* Links - pastel hover underline */

a {
  position: relative;
  transition: color var(--transition-base);
}

a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.15em;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg,
    var(--color-primary),
    var(--color-accent-mint),
    var(--color-accent-pink)
  );
  border-radius: 999px;
  transition: width var(--transition-base);
}

a:hover::after,
a:focus-visible::after {
  width: 100%;
}

/* Lists with custom bullets when needed */

ul.list-basic {
  list-style: disc;
  padding-left: 1.25rem;
}

ol.list-basic {
  list-style: decimal;
  padding-left: 1.25rem;
}

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

/* Container */

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding-mobile);
  padding-right: var(--container-padding-mobile);
}

@media (min-width: 768px) {
  .container {
    padding-left: var(--container-padding-desktop);
    padding-right: var(--container-padding-desktop);
  }
}

/* Layout helpers */

.flex {
  display: flex;
}

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

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

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

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

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

.items-start {
  align-items: flex-start;
}

.items-end {
  align-items: flex-end;
}

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

.justify-between {
  justify-content: space-between;
}

.justify-start {
  justify-content: flex-start;
}

.justify-end {
  justify-content: flex-end;
}

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

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

.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(2, minmax(0, 1fr));
  gap: var(--space-4);
}

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

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

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

.py-4 {
  padding-top: var(--space-4);
  padding-bottom: var(--space-4);
}

.py-6 {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
}

.py-8 {
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

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

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

/* Sticky CTA helper (e.g. "Zapytaj o ofertę") */

.sticky-cta {
  position: fixed;
  right: 1rem;
  bottom: 1.25rem;
  z-index: var(--z-overlay);
}

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

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem 1.5rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1;
  background: var(--color-primary);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
  transition:
    background-color var(--transition-base),
    box-shadow var(--transition-base),
    transform var(--transition-fast),
    border-color var(--transition-base);
}

.btn:hover {
  background: var(--color-primary-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

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

.btn-secondary {
  background: #ffffff;
  color: var(--color-primary-strong);
  border-color: rgba(148, 163, 184, 0.4);
  box-shadow: var(--shadow-xs);
}

.btn-secondary:hover {
  background: var(--color-primary-soft);
  box-shadow: var(--shadow-sm);
}

.btn-ghost {
  background: transparent;
  color: var(--color-primary-strong);
  border-color: transparent;
  box-shadow: none;
}

.btn-ghost:hover {
  background: rgba(148, 163, 184, 0.08);
}

.btn-sm {
  padding: 0.5rem 1.1rem;
  font-size: var(--font-size-xs);
}

.btn-lg {
  padding: 0.9rem 1.9rem;
  font-size: var(--font-size-base);
}

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

/* Form Inputs */

.input,
.select,
.textarea {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--gray-200);
  background-color: rgba(255, 255, 255, 0.98);
  padding: 0.7rem 0.9rem;
  font-size: var(--font-size-sm);
  line-height: 1.4;
  color: var(--color-text);
  box-shadow: 0 0 0 0 rgba(95, 140, 255, 0);
  transition:
    border-color var(--transition-base),
    box-shadow var(--transition-base),
    background-color var(--transition-base);
}

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

.input:focus-visible,
.select:focus-visible,
.textarea:focus-visible {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(95, 140, 255, 0.25);
}

.field-label {
  display: block;
  font-size: var(--font-size-sm);
  font-weight: 500;
  margin-bottom: 0.35rem;
}

.field-hint {
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
  margin-top: 0.25rem;
}

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

/* Card (for hero steps, opinie, event tiles, etc.) */

.card {
  position: relative;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.96);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(148, 163, 184, 0.18);
  backdrop-filter: blur(10px);
}

.card--soft {
  background: var(--gradient-rainbow-soft);
  box-shadow: var(--shadow-xs);
  border: none;
}

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

.card-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.card-meta {
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

/* Header-specific helpers (logo centered above nav) */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

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

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

.site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-3);
  font-size: var(--font-size-sm);
}

.site-nav a {
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-pill);
  color: var(--color-text-muted);
  transition:
    color var(--transition-base),
    background-color var(--transition-base);
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  background: rgba(95, 140, 255, 0.09);
  color: var(--color-primary-strong);
}

/* Footer helpers */

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

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

@media (min-width: 768px) {
  .site-footer-columns {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.footer-disclaimer {
  margin-top: var(--space-6);
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
  line-height: var(--line-height-relaxed);
}

/* Hero & slider helpers (colorful, mobile-first) */

.hero {
  padding-top: var(--space-8);
  padding-bottom: var(--space-10);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0.7rem;
  border-radius: var(--radius-pill);
  background: rgba(95, 140, 255, 0.08);
  border: 1px solid rgba(95, 140, 255, 0.25);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary-strong);
}

.hero-title {
  font-size: var(--font-size-3xl);
  line-height: var(--line-height-tight);
  margin-top: var(--space-3);
  margin-bottom: var(--space-3);
}

@media (min-width: 768px) {
  .hero-title {
    font-size: var(--font-size-4xl);
  }
}

.hero-subtitle {
  font-size: var(--font-size-base);
  color: var(--color-text-muted);
  max-width: 34rem;
}

.hero-slider {
  margin-top: var(--space-5);
}

/* Opinions / testimonials cards */

.testimonial-card {
  position: relative;
  border-radius: var(--radius-xl);
  background: #ffffff;
  padding: var(--space-5);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(201, 167, 255, 0.3);
}

.testimonial-quote {
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
}

.testimonial-author {
  margin-top: var(--space-3);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

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

/* Optional badge colors for event types */

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: var(--font-size-xs);
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.badge-blue {
  background: rgba(95, 140, 255, 0.12);
  color: var(--color-primary-strong);
}

.badge-mint {
  background: rgba(126, 226, 195, 0.16);
  color: #047857;
}

.badge-lilac {
  background: rgba(201, 167, 255, 0.16);
  color: #6b21a8;
}

.badge-pink {
  background: rgba(255, 179, 209, 0.16);
  color: #be185d;
}

/* ========================================================================
   Accessibility
   ======================================================================== */

:focus-visible {
  outline: 3px solid rgba(95, 140, 255, 0.8);
  outline-offset: 3px;
}

button:focus:not(:focus-visible),
[role="button"]:focus:not(:focus-visible),
a:focus:not(:focus-visible) {
  outline: none;
}

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