/*
Theme Name: Elexa Restored
Theme URI: https://elexa.pl/
Author: Elexa
Description: Odtworzony lokalnie serwis Elexa na podstawie ostatniej spójnej kopii Internet Archive.
Version: 1.0.0
Text Domain: elexa-restored
*/

:root {
  --navy-950: #111a3d;
  --navy-900: #192554;
  --navy-800: #202f68;
  --red-600: #d52e35;
  --red-700: #b92029;
  --ink: #182033;
  --muted: #667085;
  --line: #dfe3eb;
  --surface: #f4f6fa;
  --white: #ffffff;
  --shadow: 0 18px 48px rgba(17, 26, 61, 0.12);
  --radius: 4px;
  --container: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

body.nav-open { overflow: hidden; }

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

a { color: var(--navy-800); text-decoration: none; }
a:hover { color: var(--red-600); }

button, input { font: inherit; }

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link:focus {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 9999;
  padding: 10px 16px;
  color: var(--white);
  background: var(--navy-950);
  clip: auto;
  width: auto;
  height: auto;
}

.container { width: min(calc(100% - 40px), var(--container)); margin-inline: auto; }

.site-topbar {
  color: rgba(255, 255, 255, 0.88);
  background: var(--navy-950);
  font-size: 0.875rem;
}

.topbar-inner {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 28px;
}

.topbar-item { display: inline-flex; align-items: center; gap: 9px; color: inherit; }
.topbar-item svg { width: 16px; height: 16px; color: #ef4a50; }
.topbar-item:hover { color: var(--white); }

.site-header {
  position: relative;
  z-index: 50;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid rgba(31, 45, 99, 0.08);
}

.header-inner {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.site-brand img { width: 170px; }

.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 18px;
  color: var(--navy-950);
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--red-600); border-color: var(--red-600); }

.nav-dropdown { position: relative; }
.nav-dropdown > a::after { content: "⌄"; margin-left: 7px; font-size: 0.8rem; }
.nav-dropdown-menu {
  position: absolute;
  top: calc(100% - 1px);
  left: 0;
  width: 230px;
  padding: 10px;
  background: var(--white);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: 180ms ease;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-dropdown-menu a { min-height: 40px; width: 100%; padding: 0 12px; font-size: 0.82rem; text-transform: none; letter-spacing: 0; }

.nav-toggle {
  display: none;
  width: 46px;
  height: 46px;
  padding: 11px;
  color: var(--navy-950);
  background: transparent;
  border: 1px solid var(--line);
  cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; margin: 5px 0; background: currentColor; }

.hero-slider { position: relative; min-height: 690px; overflow: hidden; background: var(--navy-950); }
.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  background-position: center;
  background-size: cover;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.025);
  transition: opacity 700ms ease, transform 5s ease;
}
.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(10, 18, 49, 0.89) 0%, rgba(16, 26, 65, 0.68) 48%, rgba(16, 26, 65, 0.2) 76%);
}
.hero-slide.is-active { opacity: 1; visibility: visible; transform: scale(1); }
.hero-content { position: relative; z-index: 1; max-width: 760px; color: var(--white); }
.eyebrow { margin: 0 0 14px; color: var(--red-600); font-size: 0.82rem; font-weight: 900; letter-spacing: 0.16em; text-transform: uppercase; }
.hero-content h1 {
  max-width: 720px;
  margin: 0 0 22px;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
}
.hero-content p { max-width: 620px; margin: 0 0 34px; font-size: clamp(1.05rem, 2vw, 1.35rem); line-height: 1.55; color: rgba(255, 255, 255, 0.88); }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 26px;
  color: var(--white);
  background: var(--red-600);
  border: 1px solid var(--red-600);
  border-radius: 2px;
  font-size: 0.86rem;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  transition: 180ms ease;
}
.button:hover { color: var(--navy-950); background: var(--white); border-color: var(--white); transform: translateY(-2px); }
.button--navy { background: var(--navy-900); border-color: var(--navy-900); }
.button--outline { color: var(--navy-900); background: transparent; border-color: var(--navy-900); }
.button--outline:hover { color: var(--white); background: var(--navy-900); border-color: var(--navy-900); }

.hero-controls {
  position: absolute;
  z-index: 4;
  right: max(24px, calc((100% - var(--container)) / 2));
  bottom: 32px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero-dot {
  width: 34px;
  height: 5px;
  padding: 0;
  background: rgba(255,255,255,.45);
  border: 0;
  cursor: pointer;
}
.hero-dot.is-active { background: var(--red-600); }

.section { padding: 92px 0; }
.section--soft { background: var(--surface); }
.section--navy { color: var(--white); background: var(--navy-950); }
.section-heading { max-width: 760px; margin: 0 auto 48px; text-align: center; }
.section-heading--left { margin-left: 0; text-align: left; }
.section-heading h2,
.content-copy h2 { margin: 0; color: var(--navy-950); font-size: clamp(2rem, 4vw, 3rem); line-height: 1.12; letter-spacing: -0.03em; }
.section-heading p { margin: 16px auto 0; max-width: 650px; color: var(--muted); }
.section-heading::after,
.content-copy h2::after { content: ""; display: block; width: 48px; height: 3px; margin: 20px auto 0; background: var(--red-600); }
.section-heading--left::after,
.content-copy h2::after { margin-left: 0; }

.producer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.producer-card {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  color: var(--white);
  background: var(--navy-900);
  box-shadow: 0 12px 28px rgba(17,26,61,.12);
}
.producer-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms ease; }
.producer-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 25%, rgba(8,15,43,.94) 100%); }
.producer-card:hover img { transform: scale(1.05); }
.producer-card-content { position: absolute; z-index: 2; left: 26px; right: 26px; bottom: 24px; }
.producer-card h3 { margin: 0 0 4px; font-size: 1.75rem; }
.producer-card p { margin: 0; color: rgba(255,255,255,.78); line-height: 1.45; }
.producer-card-link { position: absolute; inset: 0; z-index: 3; }

.split { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr); gap: 72px; align-items: center; }
.split--reverse .split-media { order: -1; }
.split-media { position: relative; }
.split-media img { width: 100%; min-height: 520px; object-fit: cover; box-shadow: var(--shadow); }
.split-media::before { content: ""; position: absolute; z-index: -1; top: -18px; left: -18px; width: 44%; height: 48%; background: var(--red-600); }
.content-copy > p { color: #4f5b70; }
.content-copy .lead { color: var(--navy-950); font-size: 1.15rem; font-weight: 600; }
.check-list { display: grid; gap: 11px; padding: 0; margin: 26px 0 34px; list-style: none; }
.check-list li { position: relative; padding-left: 28px; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--red-600); font-weight: 900; }

.benefit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.benefit-card { padding: 32px; background: var(--white); border-top: 4px solid var(--red-600); box-shadow: 0 12px 34px rgba(17,26,61,.08); }
.benefit-number { display: block; margin-bottom: 18px; color: rgba(213,46,53,.35); font-size: 2.4rem; font-weight: 900; line-height: 1; }
.benefit-card h3 { margin: 0 0 10px; color: var(--navy-950); font-size: 1.2rem; }
.benefit-card p { margin: 0; color: var(--muted); }

.map-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.map-layout img { max-width: 420px; margin-inline: auto; }
.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.quote-card { position: relative; padding: 34px; background: var(--white); border: 1px solid var(--line); }
.quote-card::before { content: "“"; position: absolute; top: 12px; right: 24px; color: rgba(213,46,53,.16); font-family: Georgia, serif; font-size: 5rem; line-height: 1; }
.quote-card p { position: relative; margin: 0 0 20px; color: #4f5b70; }
.quote-card strong { color: var(--navy-950); }

.page-hero {
  position: relative;
  min-height: 410px;
  display: grid;
  align-items: center;
  color: var(--white);
  background: var(--navy-950) center / cover no-repeat;
}
.page-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,18,49,.9), rgba(10,18,49,.45)); }
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { margin: 0; font-size: clamp(2.7rem, 6vw, 4.8rem); line-height: 1; letter-spacing: -.04em; }
.page-hero p { max-width: 720px; margin: 20px 0 0; color: rgba(255,255,255,.86); font-size: 1.18rem; }

.brand-panel { padding: 34px; background: var(--surface); border-left: 4px solid var(--red-600); }
.brand-panel img { max-height: 220px; margin: auto; object-fit: contain; }

.catalog-tools { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.catalog-search { flex: 1 1 280px; min-height: 50px; padding: 0 16px; color: var(--ink); background: var(--white); border: 1px solid var(--line); }
.filter-button { min-height: 50px; padding: 0 16px; color: var(--navy-900); background: var(--white); border: 1px solid var(--line); font-weight: 800; cursor: pointer; }
.filter-button:hover,
.filter-button.is-active { color: var(--white); background: var(--navy-900); border-color: var(--navy-900); }
.catalog-count { margin: -12px 0 28px; color: var(--muted); font-size: .9rem; }
.catalog-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.product-card { display: flex; flex-direction: column; min-width: 0; background: var(--white); border: 1px solid var(--line); transition: 180ms ease; }
.product-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(17,26,61,.1); border-color: transparent; }
.product-image { aspect-ratio: 1.35; display: grid; place-items: center; padding: 18px; overflow: hidden; background: #fff; border-bottom: 1px solid var(--line); }
.product-image img { width: 100%; height: 100%; object-fit: contain; }
.product-placeholder { color: #9aa3b4; font-size: .75rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.product-content { display: flex; flex-direction: column; flex: 1; padding: 22px; }
.product-kicker { color: var(--red-600); font-size: .74rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.product-card h3 { margin: 8px 0 10px; color: var(--navy-950); font-size: 1.05rem; line-height: 1.3; }
.product-card p { margin: 0; color: var(--muted); font-size: .9rem; line-height: 1.55; }
.product-card .text-link { margin-top: auto; padding-top: 18px; color: var(--navy-900); font-size: .8rem; font-weight: 900; letter-spacing: .07em; text-transform: uppercase; }
.product-card.is-hidden { display: none; }

.scapa-card { padding: 24px; }
.scapa-card .product-content { padding: 0; }
.scapa-meta { margin: 12px 0; color: var(--navy-900); font-size: .88rem; font-weight: 700; }

.product-detail { display: grid; grid-template-columns: minmax(280px,.85fr) minmax(0,1.15fr); gap: 64px; align-items: start; }
.product-detail-media { min-height: 430px; display: grid; place-items: center; padding: 30px; background: var(--white); border: 1px solid var(--line); }
.product-detail-media img { max-height: 520px; object-fit: contain; }
.product-detail h1 { margin: 0 0 18px; color: var(--navy-950); font-size: clamp(2.2rem,4vw,3.5rem); line-height: 1.05; }
.product-description { padding: 22px 0; margin: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); white-space: pre-line; }

.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.contact-card { padding: 32px; background: var(--white); border: 1px solid var(--line); }
.contact-icon { width: 46px; height: 46px; display: grid; place-items: center; margin-bottom: 22px; color: var(--white); background: var(--red-600); border-radius: 50%; font-weight: 900; }
.contact-card h3 { margin: 0 0 8px; color: var(--navy-950); }
.contact-card p { margin: 0; color: var(--muted); }

.archive-note { padding: 16px 20px; color: #596579; background: #f7f8fb; border: 1px solid var(--line); font-size: .86rem; }

.cta {
  position: relative;
  padding: 90px 0;
  color: var(--white);
  background: var(--navy-950) url('/wp-content/uploads/2024/03/Elexa-narzedzia-do-obrobki-kabli.webp') center / cover no-repeat;
  text-align: center;
}
.cta::before { content: ""; position: absolute; inset: 0; background: rgba(12,21,55,.82); }
.cta .container { position: relative; z-index: 1; }
.cta h2 { margin: 0 0 10px; font-size: clamp(2.1rem,4vw,3.3rem); line-height: 1.1; }
.cta p { margin: 0 0 26px; color: rgba(255,255,255,.8); font-size: 1.08rem; }

.site-footer { color: rgba(255,255,255,.72); background: #0b1230; }
.footer-grid { display: grid; grid-template-columns: 1.3fr .8fr 1fr; gap: 60px; padding: 68px 0 52px; }
.footer-logo { width: 170px; margin-bottom: 22px; }
.footer-grid h3 { margin: 0 0 18px; color: var(--white); font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; }
.footer-grid p { margin: 0 0 10px; }
.footer-links { display: grid; gap: 9px; padding: 0; margin: 0; list-style: none; }
.footer-links a { color: rgba(255,255,255,.72); }
.footer-links a:hover { color: var(--white); }
.footer-bottom { padding: 18px 0; border-top: 1px solid rgba(255,255,255,.1); color: rgba(255,255,255,.48); font-size: .82rem; }

@media (max-width: 1020px) {
  .producer-grid, .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; gap: 42px; }
  .split-media { order: -1; }
  .split-media img { min-height: 430px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  .topbar-inner { justify-content: center; }
  .topbar-item:last-child { display: none; }
  .header-inner { min-height: 78px; }
  .site-brand img { width: 146px; }
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed;
    inset: 120px 0 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 20px;
    background: var(--white);
    overflow-y: auto;
  }
  .nav-open .site-nav { display: flex; }
  .site-nav a { width: 100%; min-height: 52px; border-bottom: 1px solid var(--line); }
  .nav-dropdown-menu { position: static; width: 100%; padding: 0 0 0 14px; opacity: 1; visibility: visible; transform: none; box-shadow: none; }
  .nav-dropdown > a::after { display: none; }
  .hero-slider { min-height: 610px; }
  .hero-content { padding-bottom: 58px; }
  .benefit-grid, .testimonial-grid, .contact-grid { grid-template-columns: 1fr; }
  .map-layout, .product-detail { grid-template-columns: 1fr; }
  .page-hero { min-height: 340px; }
}

@media (max-width: 580px) {
  .container { width: min(calc(100% - 28px), var(--container)); }
  .topbar-inner { gap: 14px; justify-content: flex-start; }
  .topbar-item:nth-child(2) { display: none; }
  .hero-slider { min-height: 570px; }
  .hero-content h1 { font-size: 2.7rem; }
  .section { padding: 68px 0; }
  .producer-grid, .catalog-grid { grid-template-columns: 1fr; }
  .producer-card { min-height: 360px; }
  .split-media img { min-height: 320px; }
  .footer-grid { grid-template-columns: 1fr; gap: 34px; }
  .page-hero { min-height: 300px; }
  .product-detail-media { min-height: 300px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
