/* ===== INDEX PAGE STYLES ===== */

:root {
  --primary:     #0d6efd;
  --secondary:   #764ba2;
  --accent:      #00b894;
  --dark:        #1a202c;
  --light:       #f7fafc;
  --muted:       #718096;
  --border:      #e2e8f0;
  --card-bg:     #e9f7ef;
  --card-border: #c7e9d4;
  --card-hover:  #76c893;
  --grad-start:  #667eea;
  --grad-end:    #764ba2;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  overflow-x: hidden;
}

/* ===== HERO ===== */
.modern-hero {
  position: relative;
  min-height: 72vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--grad-start) 0%, var(--secondary) 50%, var(--primary) 100%);
  overflow: hidden;
  padding: 44px 20px;
}

.modern-hero::before {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  top: -100px;
  left: -100px;
  pointer-events: none;
}

.modern-hero::after {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
  bottom: -200px;
  right: -150px;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: white;
  width: min(760px, 100%);
  animation: fadeInUp 0.8s ease-out;
}

.hero-logo {
  max-width: 96px;
  margin-bottom: 22px;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
  animation: float 3s ease-in-out infinite;
}

.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.1rem);
  font-weight: 750;
  margin-bottom: 14px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.1);
  line-height: 1.2;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  margin-bottom: 28px;
  opacity: 0.95;
  font-weight: 300;
  letter-spacing: 0.5px;
}

.hero-cta {
  display: inline-block;
  padding: 14px 34px;
  background: white;
  color: var(--grad-start);
  border-radius: 50px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  margin: 10px 8px;
}

.hero-cta:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(0,0,0,0.3);
}

/* Ghost variant — used on secondary CTA buttons */
.hero-cta--ghost {
  background: rgba(255,255,255,0.2);
  color: white;
  border: 2px solid white;
}

/* ===== SHARED SECTION HEADER ===== */
.section-header {
  text-align: center;
  margin-bottom: 36px;
}

.section-header h2 {
  font-size: clamp(1.8rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 10px;
}

.section-header p {
  font-size: 1rem;
  color: var(--muted);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== SERVICES ===== */
.services-section {
  padding: 56px 0;
  background: var(--light);
}

.service-card {
  background: var(--card-bg);
  border-radius: 15px;
  padding: 28px 24px;
  text-align: center;
  border: 1px solid var(--card-border);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  height: 100%;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(102,126,234,0.12);
  border-color: var(--card-hover);
}

.service-icon {
  display: inline-flex;
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
  border-radius: 24px;
  background: rgba(102,126,234,0.12);
  align-items: center;
  justify-content: center;
}

.service-icon img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.service-card h5 {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--dark);
  margin-bottom: 10px;
}

.service-card p {
  color: var(--muted);
  margin-bottom: 14px;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ===== STATS ===== */
.stats-section {
  background: linear-gradient(135deg, var(--grad-start) 0%, var(--primary) 100%);
  padding: 56px 0;
  color: white;
}

.stat-item {
  text-align: center;
  padding: 20px;
}

.stat-number {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 800;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 1rem;
  opacity: 0.9;
}

/* ===== FEATURED ARTICLES ===== */
.featured-section {
  padding: 56px 0;
}

.featured-main {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.1);
}

.featured-image {
  height: 300px;
  object-fit: cover;
  width: 100%;
  display: block;
}

.featured-badge {
  position: absolute;
  top: 20px;
  left: 20px;
  background: linear-gradient(135deg, var(--grad-start), var(--secondary));
  color: white;
  padding: 10px 20px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.85rem;
  z-index: 1;
}

.featured-content {
  padding: 28px;
}

.featured-content h3 {
  font-size: clamp(1.5rem, 2.8vw, 1.85rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 15px;
}

.featured-excerpt {
  color: #4a5568;
  line-height: 1.8;
  margin-bottom: 25px;
}

.featured-meta {
  display: flex;
  gap: 24px;
  margin-bottom: 20px;
  font-size: 0.9rem;
  color: var(--muted);
  flex-wrap: wrap;
}

.featured-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Sidebar */
.sidebar-heading {
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--dark);
  font-size: 1rem;
}

.article-card {
  display: flex;
  gap: 15px;
  padding: 15px;
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  text-decoration: none;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
  margin-bottom: 12px;
}

.article-card:hover {
  box-shadow: 0 8px 16px rgba(102,126,234,0.1);
  border-color: var(--primary);
}

.article-thumb {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.article-info h6 {
  color: var(--dark);
  font-weight: 600;
  margin-bottom: 5px;
  font-size: 0.95rem;
  line-height: 1.4;
}

.article-info small {
  color: var(--muted);
}

.view-all-link {
  display: block;
  text-align: center;
  margin-top: 20px;
}

/* ===== TESTIMONIALS ===== */
.testimonials-section {
  background: var(--light);
  padding: 56px 0;
}

.testimonial-carousel {
  position: relative;
  display: grid;
  grid-template-columns: 48px minmax(0,1fr) 48px;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
}

.testimonial-window {
  overflow: hidden;
  padding: 8px 2px 20px;
}

.testimonial-track {
  display: flex;
  gap: 24px;
  transition: transform 0.38s ease;
  will-change: transform;
}

.testimonial-card {
  flex: 0 0 calc((100% - 48px) / 3);
  min-width: 0;
  aspect-ratio: 1 / 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 28px 24px;
  overflow: hidden;
  text-align: center;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 15px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.testimonial-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(102,126,234,0.12);
  border-color: var(--card-hover);
}

.testimonial-avatar {
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  color: var(--primary);
  font-weight: 800;
  font-size: 1.2rem;
  background: rgba(102,126,234,0.12);
}

.testimonial-body {
  min-width: 0;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
}

.testimonial-stars {
  color: #fbbf24;
  font-size: 0.9rem;
  line-height: 1;
  letter-spacing: 0;
  margin-bottom: 10px;
}

.testimonial-text {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  color: var(--muted);
  font-size: 0.94rem;
  font-style: italic;
  line-height: 1.6;
  margin-bottom: 14px;
}

.testimonial-author {
  color: var(--dark);
  font-weight: 700;
  margin-top: auto;
  margin-bottom: 2px;
}

.testimonial-role {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 0;
}

.testimonial-arrow {
  width: 48px;
  height: 48px;
  display: inline-grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--grad-start) 0%, var(--secondary) 100%);
  box-shadow: 0 14px 28px rgba(102,126,234,0.25);
  transition: transform 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.testimonial-arrow:hover:not(:disabled),
.testimonial-arrow:focus-visible:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(102,126,234,0.32);
}

.testimonial-arrow:disabled {
  cursor: not-allowed;
  opacity: 0.38;
}

.testimonial-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.testimonial-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(102,126,234,0.25);
  transition: width 0.2s ease, background 0.2s ease;
  cursor: pointer;
}

.testimonial-dot.active {
  width: 24px;
  border-radius: 999px;
  background: var(--grad-start);
}

/* ===== CTA ===== */
.cta-section {
  background: linear-gradient(135deg, var(--grad-start) 0%, var(--secondary) 100%);
  padding: 56px 0;
  color: white;
  text-align: center;
}

.cta-section h2 {
  font-size: clamp(1.8rem, 3vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 12px;
}

.cta-section p {
  font-size: 1rem;
  margin-bottom: 28px;
  opacity: 0.95;
}

/* ===== UTILITY ===== */
.modern-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  transition: gap 0.3s ease, color 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.modern-link:hover {
  gap: 10px;
  color: var(--secondary);
}

.modern-link--lg {
  font-size: 1.05rem;
}

.language-polish {
  backdrop-filter: blur(12px);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
  .modern-hero   { min-height: 64vh; padding: 36px 18px; }
  .hero-logo     { max-width: 84px; }
  .featured-image { height: 260px; }
  .testimonial-card { flex-basis: calc((100% - 24px) / 2); }
}

@media (max-width: 768px) {
  .testimonial-carousel {
    grid-template-columns: 40px minmax(0,1fr) 40px;
    gap: 10px;
  }
  .testimonial-card  { flex-basis: 100%; }
  .testimonial-arrow { width: 40px; height: 40px; }
}

@media (max-width: 576px) {
  .modern-hero,
  .services-section,
  .stats-section,
  .featured-section,
  .testimonials-section,
  .cta-section { padding-top: 40px; padding-bottom: 40px; }

  .hero-cta {
    display: block;
    margin: 10px auto;
    width: min(260px, 100%);
  }

  .service-card,
  .testimonial-card,
  .featured-content { padding: 20px; }

  .testimonial-avatar {
    flex-basis: 48px;
    width: 48px;
    height: 48px;
    border-radius: 18px;
  }

  .featured-image { height: 220px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-content,
  .hero-logo,
  .testimonial-track {
    animation: none;
    transition: none;
  }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-20px); }
}

/* ===== FOOTER: Modern dynamic layout ===== */
.sd-footer {
  --sd-footer-bg: #000000;
  --sd-footer-surface: rgba(255, 255, 255, 0.04);
  --sd-footer-border: rgba(255, 255, 255, 0.14);
  --sd-footer-text: rgba(255, 255, 255, 0.88);
  --sd-footer-heading: #ffffff;
  --sd-footer-accent: #ffffff;
  --sd-footer-accent-2: #d9d9d9;
  position: relative;
  overflow: hidden;
  padding: 4.5rem 0 2rem;
  color: var(--sd-footer-text);
  background: var(--sd-footer-bg);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.sd-footer__glow {
  position: absolute;
  border-radius: 999px;
  filter: blur(42px);
  pointer-events: none;
  opacity: 0.5;
}

.sd-footer__glow--one { width: 220px; height: 220px; top: 6%; left: -50px; background: rgba(255, 255, 255, 0.08); }
.sd-footer__glow--two { width: 260px; height: 260px; right: -70px; bottom: 14%; background: rgba(255, 255, 255, 0.06); }

.sd-footer__container {
  position: relative;
  z-index: 1;
}

.sd-footer__top {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 2rem;
  align-items: start;
  grid-auto-flow: row dense;
}

.sd-footer__section {
  padding: 1.4rem;
  background: var(--sd-footer-surface);
  border: 1px solid var(--sd-footer-border);
  border-radius: 24px;
  box-shadow: 0 20px 44px rgba(0,0,0,0.35);
}

.sd-footer__brand-section,
.sd-footer__section--collapsible,
.sd-footer__section--newsletter { grid-column: span 3; }

.sd-footer__brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.sd-footer__logo-icon {
  width: 3rem;
  height: 3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: rgba(255,255,255,0.06);
  color: var(--sd-footer-heading);
  border: 1px solid rgba(255,255,255,0.08);
}

.sd-footer__logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--sd-footer-heading);
}

.sd-footer__tagline,
.sd-footer__newsletter-copy {
  margin: 0 0 1rem;
  line-height: 1.75;
  color: var(--sd-footer-text);
}

.sd-footer__brand-section .sd-footer__tagline {
  max-width: 20rem;
}

.sd-footer__section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.sd-footer__section-heading h5 {
  margin: 0;
  font-size: 1rem;
  color: var(--sd-footer-heading);
}

.sd-footer__toggle {
  display: none;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 0.95rem;
  border: 1px solid var(--sd-footer-border);
  border-radius: 999px;
  background: rgba(255,255,255,0.03);
  color: var(--sd-footer-text);
  font-weight: 700;
  cursor: pointer;
}

.sd-footer__toggle i { transition: transform 0.25s ease; }
.sd-footer__section[aria-expanded="true"] .sd-footer__toggle i { transform: rotate(180deg); }

.sd-footer__socials {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.2rem;
}

.sd-footer__socials a {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--sd-footer-heading);
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  text-decoration: none;
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.sd-footer__socials a:hover,
.sd-footer__socials a:focus-visible {
  transform: translateY(-3px);
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.28);
  color: #ffffff;
}

.sd-footer__links,
.sd-footer__contact-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.sd-footer__links li + li { margin-top: 0.7rem; }

.sd-footer__links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--sd-footer-text);
  text-decoration: none;
}

.sd-footer__links a i {
  font-size: 0.8rem;
  opacity: 0.65;
  transform: translateX(-4px);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.sd-footer__links a:hover,
.sd-footer__links a:focus-visible,
.sd-footer__contact-list a:hover,
.sd-footer__contact-list a:focus-visible,
.sd-footer__bottom a:hover,
.sd-footer__bottom a:focus-visible {
  color: #ffffff;
}

.sd-footer__contact-list {
  display: grid;
  gap: 0.9rem;
  color: var(--sd-footer-text);
}

.sd-footer__contact-list div {
  padding: 0.8rem 0.9rem;
  border-radius: 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
}

.sd-footer__contact-list a {
  color: inherit;
  text-decoration: none;
}

.sd-footer__newsletter-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem;
}

.sd-footer__newsletter-form input {
  width: 100%;
  min-width: 0;
  padding: 0.95rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.03);
  color: var(--sd-footer-text);
}

.sd-footer__newsletter-form button {
  padding: 0.95rem 1.3rem;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #4d4d4d, #ffffff);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.sd-footer__newsletter-form button:hover,
.sd-footer__newsletter-form button:focus-visible {
  filter: brightness(1.05);
}

.sd-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.14);
  font-size: 0.95rem;
}

.sd-footer__copyright { margin: 0; }
.sd-footer__legal { display: flex; align-items: center; gap: 1.1rem; flex-wrap: wrap; }

.sd-scroll-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--sd-footer-accent-2), var(--sd-footer-accent));
  box-shadow: 0 18px 38px rgba(0,0,0,0.28);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease;
  z-index: 999;
}

.sd-scroll-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.sd-scroll-top:hover, .sd-scroll-top:focus-visible { transform: translateY(-4px); }

@media (max-width: 1199.98px) {
  .sd-footer__brand-section,
  .sd-footer__section--newsletter,
  .sd-footer__section--collapsible { grid-column: span 6; }
}

@media (max-width: 991.98px) {
  .sd-footer__top { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .sd-footer__brand-section,
  .sd-footer__section--newsletter,
  .sd-footer__section--collapsible { grid-column: span 6; }
}

@media (max-width: 767.98px) {
  .sd-footer { padding: 3rem 0 1.5rem; }
  .sd-footer__top { grid-template-columns: 1fr; gap: 1.25rem; }
  .sd-footer__section {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 1rem;
  }
  .sd-footer__brand-section,
  .sd-footer__section--newsletter,
  .sd-footer__section--collapsible { grid-column: auto; }
  .sd-footer__section-heading { margin-bottom: 0; }
  .sd-footer__toggle { display: inline-flex; }
  .sd-footer__section[data-collapsible="true"] .sd-footer__links,
  .sd-footer__section[data-collapsible="true"] .sd-footer__contact-list,
  .sd-footer__section[data-collapsible="true"] .sd-footer__newsletter-copy,
  .sd-footer__section[data-collapsible="true"] .sd-footer__newsletter-form {
    display: none;
  }
  .sd-footer__section[data-collapsible="true"][aria-expanded="true"] .sd-footer__links,
  .sd-footer__section[data-collapsible="true"][aria-expanded="true"] .sd-footer__contact-list,
  .sd-footer__section[data-collapsible="true"][aria-expanded="true"] .sd-footer__newsletter-copy,
  .sd-footer__section[data-collapsible="true"][aria-expanded="true"] .sd-footer__newsletter-form {
    display: block;
  }
  .sd-footer__newsletter-form { grid-template-columns: 1fr; }
  .sd-footer__bottom { flex-direction: column; align-items: flex-start; }
  .sd-footer__legal { width: 100%; }
  .sd-footer__legal a { margin-right: 0.75rem; }
  .sd-scroll-top { right: 18px; bottom: 18px; width: 48px; height: 48px; border-radius: 16px; }
}

@media (max-width: 575.98px) {
  .sd-footer__brand-logo {
    align-items: flex-start;
  }
  .sd-footer__logo-text {
    font-size: 1.1rem;
  }
  .sd-footer__section-heading {
    align-items: flex-start;
    flex-direction: column;
  }
  .sd-footer__toggle {
    width: 100%;
    justify-content: center;
  }
  .sd-footer__socials a {
    width: 40px;
    height: 40px;
  }
}

@media (prefers-color-scheme: light) {
  .sd-footer {
    --sd-footer-bg: #000000;
    --sd-footer-surface: rgba(255, 255, 255, 0.04);
    --sd-footer-border: rgba(255, 255, 255, 0.14);
    --sd-footer-text: rgba(255, 255, 255, 0.88);
    --sd-footer-heading: #ffffff;
    border-top-color: rgba(255, 255, 255, 0.14);
  }
  .sd-footer__glow--one,
  .sd-footer__glow--two { opacity: 0.16; }
  .sd-footer__logo-icon { background: rgba(255,255,255,0.06); color: #ffffff; }
  .sd-footer__socials a,
  .sd-footer__toggle,
  .sd-footer__newsletter-form input { background: rgba(255,255,255,0.03); border-color: rgba(255,255,255,0.14); color: #ffffff; }
  .sd-footer__links a:hover,
  .sd-footer__contact-list a:hover,
  .sd-footer__bottom a:hover { color: #ffffff; }
  .sd-footer__bottom { border-top-color: rgba(255,255,255,0.14); }
}