:root {
  /* Primitive Tokens (Base Palette) */
  --color-primary: #0B1F3B;
  --color-accent: #22C55E;
  --color-secondary: #38BDF8;
  --color-slate-50: #F8FAFC;
  --color-slate-100: #F1F5F9;
  --color-slate-200: #E2E8F0;
  --color-slate-300: #CBD5E1;
  --color-slate-400: #94A3B8;
  --color-slate-500: #64748B;
  --color-slate-800: #1E293B;
  --color-slate-900: #0F172A;
  --color-white: #FFFFFF;
  --color-black: #000000;

  /* Semantic Tokens (Theme: Light) */
  --bg-page: var(--color-slate-50);
  --bg-surface: var(--color-white);
  --bg-surface-elevated: var(--color-white);
  --bg-header: rgba(255, 255, 255, 0.95);

  --text-main: var(--color-slate-900);
  --text-muted: var(--color-slate-500);
  --text-inverse: var(--color-white);

  --border-color: var(--color-slate-200);
  --border-focus: var(--color-secondary);

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);

  /* Shared Tokens */
  --font-main: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji;
  --container-width: 1200px;
  --header-height: 70px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
}

[data-theme="dark"] {
  /* Semantic Tokens (Theme: Dark) */
  --bg-page: #0B1120;
  /* Deep blue-black */
  --bg-surface: #1E293B;
  /* Slate 800 */
  --bg-surface-elevated: #334155;
  /* Slate 700 */
  --bg-header: rgba(15, 23, 42, 0.95);
  /* Slate 900 with opacity */

  --text-main: #F1F5F9;
  /* Slate 100 */
  --text-muted: #94A3B8;
  /* Slate 400 */
  --text-inverse: #0F172A;
  /* Slate 900 */

  --border-color: #334155;
  /* Slate 700 */
  --border-focus: var(--color-secondary);

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.5);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5), 0 2px 4px -2px rgb(0 0 0 / 0.5);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5), 0 4px 6px -4px rgb(0 0 0 / 0.5);
}

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

html {
  scroll-behavior: smooth;
  font-family: var(--font-main);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color 0.3s, color 0.3s;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

ul {
  list-style: none;
}

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

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: 1rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  text-align: center;
}

.btn-primary {
  background-color: var(--color-accent);
  color: var(--text-inverse);
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.4);
}

.btn-secondary {
  background-color: var(--bg-surface);
  color: var(--text-main);
  /* Changed from primary for better dark mode visibility */
  border: 1px solid var(--border-color);
}

[data-theme="dark"] .btn-secondary {
  color: var(--text-main);
  background-color: transparent;
  border-color: var(--border-color);
}

.btn-secondary:hover {
  border-color: var(--color-accent);
  /* Changed from primary */
  background-color: var(--bg-surface-elevated);
  /* Changed from generic grey */
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--text-main);
  /* Changed from primary to semantic text main */
  margin-bottom: 1rem;
  text-align: center;
}

.section-desc {
  text-align: center;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 3rem;
  font-size: 1.125rem;
}

section {
  padding: 5rem 0;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background-color: var(--bg-header);
  backdrop-filter: blur(10px);
  z-index: 1000;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s, border-color 0.3s;
  display: flex;
  align-items: center;
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--border-color);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--primary);
  letter-spacing: -0.025em;
}

.main-nav ul {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.main-nav a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
}

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

.header-cta {
  display: none;
}

@media (min-width: 900px) {
  .header-cta {
    display: inline-flex;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
}

/* Mobile Nav */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-main);
  cursor: pointer;
}

@media (max-width: 900px) {
  .mobile-toggle {
    display: block;
  }

  .main-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    background: var(--bg-surface);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transform: translateY(-150%);
    transition: transform 0.3s ease-in-out;
    z-index: 999;
  }

  .main-nav.active {
    transform: translateY(0);
  }

  .main-nav ul {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
  }
}

/* Hero */
#hero {
  padding-top: calc(var(--header-height) + 4rem);
  background: radial-gradient(circle at top right, #e0f2fe, transparent 40%),
    radial-gradient(circle at bottom left, #dcfce7, transparent 40%);
  text-align: center;
}

[data-theme="dark"] #hero {
  background: radial-gradient(circle at top right, rgba(14, 165, 233, 0.15), transparent 40%),
    radial-gradient(circle at bottom left, rgba(34, 197, 94, 0.1), transparent 40%);
}

.hero-content h1 {
  font-size: 3rem;
  line-height: 1.2;
  color: var(--text-main);
  margin-bottom: 1.5rem;
  font-weight: 800;
}

.hero-content p {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 2.5rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 4rem;
}

.hero-preview {
  position: relative;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  /* Force 16:9 aspect ratio */
  aspect-ratio: 16/9;
  max-width: 900px;
  margin: 0 auto;
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.hero-slideshow {
  width: 100%;
  height: 100%;
  position: relative;
}

.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  z-index: 1;
}

.hero-slide.active {
  opacity: 1;
  z-index: 2;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Ken Burns Effect defaults */
  transform-origin: center center;
  transform: scale(1);
}

.hero-slide.active img {
  animation: kenBurns 15s infinite alternate;
}

@keyframes kenBurns {
  0% {
    transform: scale(1);
  }

  100% {
    transform: scale(1.1);
  }
}

/* Social Proof */
#zaufanie {
  background: var(--bg-surface);
  padding: 3rem 0;
  border-bottom: 1px solid var(--border-color);
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 2rem;
  text-align: center;
  margin-bottom: 3rem;
}

.metric-item strong {
  display: block;
  font-size: 2.5rem;
  color: var(--color-accent);
  font-weight: 800;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.testimonial-card {
  background: var(--bg-page);
  padding: 2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.testimonial-text {
  font-style: italic;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.testimonial-author {
  font-weight: 600;
  color: var(--text-main);
}

/* Benefits & Cards */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.card {
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  transition: transform 0.2s, background-color 0.3s;
}

.card:hover {
  transform: translateY(-5px);
  border-color: var(--color-accent);
}

.card h3 {
  color: var(--text-main);
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.card p {
  color: var(--text-muted);
}

/* Process */
.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  counter-reset: process;
}

.process-step {
  text-align: center;
  position: relative;
}

.process-step::before {
  counter-increment: process;
  content: counter(process);
  width: 40px;
  height: 40px;
  background: var(--color-primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  margin: 0 auto 1.5rem;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.pricing-card {
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  text-align: center;
  transition: all 0.3s;
}

.pricing-card.highlight {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 2px var(--color-accent);
}

.pricing-tier {
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.875rem;
}

.pricing-size {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 1rem 0;
}

.pricing-calc {
  max-width: 400px;
  margin: 0 auto 3rem;
  background: var(--bg-surface);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  text-align: center;
}

.pricing-calc input {
  width: 100px;
  padding: 0.5rem;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  margin: 0 0.5rem;
  background: var(--bg-page);
  color: var(--text-main);
}

/* FAQ Accordion */
.faq-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  margin-bottom: 1rem;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.faq-trigger {
  width: 100%;
  padding: 1.5rem;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--text-main);
}

.faq-trigger:hover {
  background-color: var(--bg-surface-elevated);
}

.faq-trigger[aria-expanded="true"] .icon {
  transform: rotate(180deg);
}

.faq-content {
  display: none;
  padding: 0 1.5rem 1.5rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
}

.faq-icon {
  transition: transform 0.3s;
}

/* Contact Form */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  max-width: 800px;
  margin: 0 auto;
}

.contact-form {
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  transition: border-color 0.2s;
  background: var(--bg-page);
  color: var(--text-main);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-secondary);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

.checkbox-group {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.checkbox-group input {
  margin-top: 0.25rem;
}

.honey {
  display: none !important;
}

/* Footer */
.site-footer {
  background: var(--color-slate-900);
  color: white;
  padding: 4rem 0 2rem;
  margin-top: auto;
  border-top: 1px solid var(--border-color);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

/* Footer columns */
.footer-col h4 {
  margin-bottom: 1.5rem;
  color: var(--color-secondary);
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: var(--color-slate-400);
}

.footer-links a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  font-size: 0.875rem;
}

/* Cookie Banner */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: var(--bg-surface);
  padding: 1.5rem;
  box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
  z-index: 2000;
  border-top: 1px solid var(--border-color);
  display: none;
}

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

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

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

/* Cookie Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-body {
  padding: 1.5rem;
}

.modal-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border-color);
  text-align: right;
  background: var(--bg-page);
}

.consent-option {
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 24px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked+.slider {
  background-color: var(--color-accent);
}

input:disabled+.slider {
  opacity: 0.5;
  cursor: not-allowed;
}

input:checked+.slider:before {
  transform: translateX(20px);
}

/* Print */
@media print {

  .site-header,
  .site-footer,
  .hero-actions,
  #cookie-banner {
    display: none;
  }
}

/* Blog Styles */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.blog-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform 0.2s;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.blog-content {
  padding: 1.5rem;
}

.blog-date {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  display: block;
}

.blog-title {
  font-size: 1.25rem;
  color: var(--text-main);
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.blog-excerpt {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.blog-search {
  margin-bottom: 3rem;
  display: flex;
  gap: 1rem;
  max-width: 600px;
  margin: 0 auto 3rem;
}