/* ================================
   DESIGN SYSTEM - SpotLabs
   ================================ */

:root {
  /* Brand colors */
  --color-primary: #0B2333;
  --color-accent: #F2D27A;
  --color-text-light: #FFFFFF;
  --color-text-dark: #2C3E50;

  /* Supporting colors */
  --color-bg-light: #F8F9FA;
  --color-bg-section: #E8EDF2;
  --color-border: rgba(242, 210, 122, 0.2);

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --text-hero: clamp(2.5rem, 5vw, 4rem);
  --text-h1: clamp(2rem, 4vw, 3rem);
  --text-h2: clamp(1.75rem, 3.5vw, 2.5rem);
  --text-h3: clamp(1.25rem, 2vw, 1.5rem);
  --text-body: clamp(1rem, 1.5vw, 1.125rem);
  --text-small: 0.875rem;

  --weight-normal: 400;
  --weight-medium: 500;
  --weight-bold: 700;

  --line-tight: 1.2;
  --line-normal: 1.5;
  --line-loose: 1.8;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 6rem;
  --space-2xl: 8rem;

  --section-padding: clamp(4rem, 8vw, 6rem);

  /* Shadows & Effects */
  --shadow-sm: 0 2px 4px rgba(11, 35, 51, 0.1);
  --shadow-md: 0 4px 12px rgba(11, 35, 51, 0.15);
  --shadow-lg: 0 8px 24px rgba(11, 35, 51, 0.2);
  --shadow-gold: 0 4px 16px rgba(242, 210, 122, 0.3);

  --border-radius-sm: 4px;
  --border-radius-md: 8px;
  --border-radius-lg: 16px;

  --transition-fast: 150ms ease;
  --transition-normal: 300ms ease;
}

/* ================================
   RESET & BASE
   ================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  font-size: var(--text-body);
  line-height: var(--line-normal);
  color: var(--color-text-dark);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  margin: 0;
  padding: 0;
  overflow-x: hidden; /* Tylko na body, nie na html */
  width: 100%;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: var(--weight-bold);
  line-height: var(--line-tight);
  margin-bottom: var(--space-md);
}

h1 {
  margin-bottom: var(--space-lg);
}

h1 { font-size: var(--text-hero); }
h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); }

p {
  margin-bottom: var(--space-sm);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

ul {
  list-style: none;
}

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

/* ================================
   LAYOUT
   ================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  width: 100%;
  box-sizing: border-box;
}

.container-narrow {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2rem;
}

section.dark {
  background: var(--color-primary);
  color: var(--color-text-light);
}

section.light {
  background: var(--color-bg-light);
  color: var(--color-text-dark);
}

section {
  padding: var(--section-padding) 0;
  scroll-margin-top: 80px; /* Offset dla sticky navbar */
}

/* ================================
   NAVBAR
   ================================ */

nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-primary);
  padding: 1rem 0;
  transition: box-shadow var(--transition-normal);
}

nav.scrolled {
  box-shadow: var(--shadow-md);
}

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

.logo-link svg {
  height: 60px;
  width: auto;
}

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

.nav-menu a {
  color: var(--color-text-light);
  font-weight: var(--weight-medium);
  transition: color var(--transition-fast);
}

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

.nav-cta {
  background: var(--color-accent);
  color: var(--color-primary) !important;
  padding: 0.5rem 1.5rem;
  border-radius: var(--border-radius-md);
  font-weight: var(--weight-bold);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--color-accent);
  transition: all var(--transition-normal);
  border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* Mobile menu backdrop */
.menu-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(11, 35, 51, 0.8);
  z-index: 998; /* Below nav-menu (999) but above content */
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.menu-backdrop.active {
  display: block;
  opacity: 1;
}

@media (min-width: 769px) {
  .menu-backdrop {
    display: none !important;
  }
}

/* ================================
   HERO
   ================================ */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
}

.hero-content {
  max-width: 900px;
}

.hero-logo {
  margin: 0 auto 2rem;
  opacity: 0.9;
}

.hero h1 {
  margin-bottom: 1.5rem;
  color: var(--color-text-light);
}

.subtitle {
  font-size: 1.25rem;
  line-height: var(--line-loose);
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2.5rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.hero-content .cta-primary {
  margin-bottom: 5rem; /* Większy odstęp przed strzałką na mobile */
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 2rem;
  color: var(--color-accent);
  animation: bounce 2s infinite;
  text-decoration: none;
  cursor: pointer;
  will-change: transform; /* GPU acceleration hint */
}

/* GPU-optimized bounce animation using translate3d */
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translate3d(-50%, 0, 0);
  }
  40% {
    transform: translate3d(-50%, -10px, 0);
  }
  60% {
    transform: translate3d(-50%, -5px, 0);
  }
}

/* ================================
   BUTTONS & CTAs
   ================================ */

.cta-primary {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-primary);
  padding: 1rem 2.5rem;
  border-radius: var(--border-radius-md);
  font-size: 1.125rem;
  font-weight: var(--weight-bold);
  box-shadow: var(--shadow-gold);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  cursor: pointer;
  border: none;
}

.cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(242, 210, 122, 0.4);
}

.cta-secondary {
  display: inline-block;
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  padding: 0.875rem 2rem;
  border-radius: var(--border-radius-md);
  font-size: 1.125rem;
  font-weight: var(--weight-bold);
  transition: all var(--transition-fast);
}

.cta-secondary:hover {
  background: var(--color-primary);
  color: var(--color-text-light);
}

.link-subtle {
  color: var(--color-accent);
  font-weight: var(--weight-medium);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition-fast);
}

.link-subtle:hover {
  border-bottom-color: var(--color-accent);
}

/* ================================
   SECTIONS
   ================================ */

.section-intro {
  text-align: center;
  font-size: 1.125rem;
  color: rgba(44, 62, 80, 0.8);
  max-width: 700px;
  margin: 0 auto 3rem;
}

.section-cta {
  text-align: center;
  margin-top: 3rem;
}

h2 {
  text-align: center;
  margin-bottom: 3rem;
}

/* ================================
   PROBLEMS SECTION
   ================================ */

.problems {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.problem-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.problem-card {
  background: white;
  border-radius: var(--border-radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.problem-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-accent {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--color-accent);
}

.problem-card .icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

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

.problem-card ul {
  list-style: none;
}

.problem-card li {
  padding-left: 1.5rem;
  margin-bottom: 0.75rem;
  position: relative;
  color: var(--color-text-dark);
  line-height: 1.6;
}

.problem-card li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-weight: var(--weight-bold);
  font-size: 1.2rem;
}

/* ================================
   SERVICES SECTION
   ================================ */

.services {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

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

.service-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(242, 210, 122, 0.2);
  border-radius: var(--border-radius-lg);
  padding: 2.5rem;
  transition: all var(--transition-normal);
}

.service-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--color-accent);
}

.service-card h3 {
  color: var(--color-accent);
  margin-bottom: 1rem;
}

.service-card p {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.duration {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-primary);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius-sm);
  font-size: var(--text-small);
  font-weight: var(--weight-bold);
}

/* ================================
   RESULTS SECTION
   ================================ */

.results {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.result-box {
  background: white;
  padding: 2rem;
  border-radius: var(--border-radius-md);
  border-left: 4px solid var(--color-accent);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast);
}

.result-box:hover {
  transform: translateX(4px);
}

.result-box p {
  color: var(--color-primary);
  font-weight: var(--weight-medium);
  font-size: 1.125rem;
  margin: 0;
}

/* ================================
   ABOUT SECTION
   ================================ */

.about {
  text-align: center;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.about .container-narrow {
  width: 100%;
}

/* Content pages (privacy, kim-jestem) */
.content-page-section {
  padding-top: 8rem;
}

article {
  line-height: 1.7;
}

article h2 {
  color: var(--color-primary);
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
  text-align: left;
  border-bottom: 2px solid var(--color-accent);
  padding-bottom: 0.5rem;
}

article h3 {
  color: var(--color-accent);
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  text-align: left;
}

article ul,
article ol {
  margin-left: 2rem;
  margin-bottom: 1.5rem;
}

article li {
  margin-bottom: 0.75rem;
}

article hr {
  border: none;
  border-top: 1px solid var(--color-border);
  margin: 2.5rem 0;
}

article p {
  margin-bottom: 1rem;
}

article strong {
  color: var(--color-primary);
}

.content-page-footer {
  text-align: center;
  margin-top: 3rem;
}

.content-page-meta {
  font-size: 0.875rem;
  color: #6b7280;
  margin-top: 3rem;
}

.profile-photo {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--color-accent);
  box-shadow: var(--shadow-gold);
  margin: 0 auto 2rem;
}

.about h2 {
  color: var(--color-text-light);
  margin-bottom: 1.5rem;
}

.about p {
  color: rgba(255, 255, 255, 0.9);
  line-height: var(--line-loose);
  margin-bottom: 2rem;
}

.contact-info {
  margin-top: 2rem;
}

.contact-info h3 {
  color: var(--color-accent);
  margin-bottom: 1rem;
}

.contact-text {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2rem;
}

.privacy-note {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 1rem;
  font-style: italic;
}

/* CTA Section - Compact variant with visual distinction */
.cta-section {
  text-align: center;
  padding: var(--section-padding) 0;
  background: linear-gradient(180deg, var(--color-primary) 0%, #06141f 100%);
}

.cta-section .container-narrow {
  width: 100%;
  max-width: 500px;
}

.cta-section .contact-info {
  background: rgba(242, 210, 122, 0.05);
  border: 2px solid var(--color-accent);
  border-radius: var(--border-radius-lg);
  padding: 2.5rem 2rem;
  box-shadow: 0 8px 32px rgba(242, 210, 122, 0.15);
}

.cta-section h2 {
  color: var(--color-accent);
  margin-bottom: 1rem;
  font-size: 1.75rem;
}

.cta-section .contact-text {
  color: rgba(255, 255, 255, 0.9);
  line-height: var(--line-loose);
  margin-bottom: 1.5rem;
  font-size: 1.125rem;
}

.cta-section .cta-primary {
  margin-bottom: 1rem;
  transform: scale(1.05);
}

.cta-section .cta-primary:hover {
  transform: scale(1.08);
}

@media (max-width: 768px) {
  .cta-section .contact-info {
    padding: 2rem 1.5rem;
  }
}

/* Back to top button */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background: var(--color-accent);
  color: var(--color-primary);
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  font-weight: var(--weight-bold);
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  z-index: 997;
  opacity: 0;
  visibility: hidden;
  transform: translateY(100px);
  transition: all var(--transition-normal);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-gold);
}

.back-to-top:active {
  transform: translateY(-2px);
}

@media (max-width: 768px) {
  .back-to-top {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 45px;
    height: 45px;
    font-size: 1.25rem;
  }
}

/* ================================
   FOOTER
   ================================ */

footer {
  background: #081c29;
  padding: 2rem 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--text-small);
}

footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

footer a {
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--transition-fast);
}

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

.footer-social {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-social svg {
  vertical-align: middle;
}

/* ================================
   RESPONSIVE
   ================================ */

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 80px;
    right: -100%;
    width: 280px;
    height: calc(100vh - 80px);
    background: var(--color-primary);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    transition: right var(--transition-normal);
    box-shadow: var(--shadow-lg);
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-menu li {
    width: 100%;
  }

  .nav-menu a {
    font-size: 1.125rem;
    display: block;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(242, 210, 122, 0.1);
  }

  .nav-cta {
    display: block;
    text-align: center;
  }

  .hero {
    min-height: 90vh;
    padding-top: 4rem;
  }

  /* Wyłącz full-screen na mobile - za dużo scrollowania */
  .problems,
  .services,
  .results,
  .about {
    min-height: auto;
  }

  .hero-logo {
    width: 200px;
  }

  .problem-grid,
  .service-cards,
  .result-grid {
    grid-template-columns: 1fr;
  }

  footer .container {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  :root {
    --section-padding: 3rem;
  }

  .container,
  .container-narrow {
    padding: 0 1rem;
  }

  .logo-link svg {
    height: 40px;
  }

  .problem-card,
  .service-card {
    padding: 1.5rem;
  }
}
