/* SYSTEM FLEX landing — typografia jak arsanit.pl: Open Sans */
:root {
  --flex-font: "Open Sans", Arial, Helvetica, sans-serif;
  --flex-ink: #1a1714;
  --flex-ink-soft: #3d3832;
  --flex-paper: #f3efe8;
  --flex-paper-2: #e8e2d8;
  --flex-muted: #7a7368;
  --flex-line: rgba(26, 23, 20, 0.12);
  --flex-accent: #c45c2a;
  --flex-accent-deep: #8f3d16;
  --flex-dark: #141210;
  --flex-green: #2f6b5a;
  --flex-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html { scroll-behavior: smooth; scroll-padding-top: 120px; }

#main.flex-main {
  background: var(--flex-paper);
  padding: 0 !important;
  max-width: none !important;
}
#main.flex-main > .container,
#main.flex-main .main-content-wrap { max-width: none; padding: 0; margin: 0; width: 100%; }

.flex-lp {
  font-family: var(--flex-font);
  color: var(--flex-ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  background: var(--flex-paper);
}
.flex-lp *,
.flex-lp *::before,
.flex-lp *::after { box-sizing: border-box; }
.flex-lp img { max-width: 100%; display: block; height: auto; }
.flex-lp a { color: inherit; text-decoration: none; }
.flex-lp h1, .flex-lp h2, .flex-lp h3, .flex-lp h4,
.flex-lp p, .flex-lp ul, .flex-lp dl, .flex-lp figure { margin: 0; }

.flex-lp .container {
  width: min(1160px, calc(100% - 2.5rem));
  margin-inline: auto;
  max-width: 1160px;
  padding-left: 0;
  padding-right: 0;
}

/* local section nav under Arsanit header */
.flex-subnav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(243, 239, 232, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--flex-line);
}
.flex-subnav ul {
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  gap: 0.15rem;
  margin: 0;
  padding: 0.55rem 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.flex-subnav a {
  display: block;
  padding: 0.45rem 0.65rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  white-space: nowrap;
  border-radius: 2px;
}
.flex-subnav a:hover,
.flex-subnav a.is-active { opacity: 1; color: var(--flex-ink); }
.flex-subnav-cta a {
  background: var(--flex-accent);
  color: #fff !important;
  opacity: 1 !important;
  margin-left: 0.35rem;
}
.flex-subnav-cta a:hover { background: var(--flex-accent-deep); }

.flex-eyebrow {
  display: inline-block;
  margin-bottom: 0.75rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--flex-accent);
}
.flex-display {
  font-family: var(--flex-font) !important;
  font-weight: 700 !important;
  line-height: 1.1 !important;
  letter-spacing: -0.03em;
  text-transform: none;
  color: inherit;
}
.flex-lede {
  font-size: 1.125rem;
  font-weight: 400;
  color: var(--flex-ink-soft);
  max-width: 38rem;
  margin-top: 0.75rem !important;
  line-height: 1.45;
}
.flex-lede-on-dark { color: rgba(255,255,255,0.75); }
.flex-note {
  margin-top: 1rem !important;
  font-size: 0.85rem;
  color: var(--flex-muted);
}
.flex-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.5rem; }
.flex-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.25rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border-radius: 2px;
  border: 0;
  transition: transform 0.25s var(--flex-ease), background 0.2s, color 0.2s;
}
.flex-btn:hover { transform: translateY(-1px); text-decoration: none; }
.flex-btn-primary { background: var(--flex-accent); color: #fff !important; }
.flex-btn-primary:hover { background: var(--flex-accent-deep); color: #fff !important; }
.flex-btn-ghost { border: 1px solid currentColor; background: transparent; color: inherit !important; }
.flex-btn-dark { background: var(--flex-ink); color: #fff !important; }

.flex-section { padding: 4.5rem 0; }
.flex-section-muted { background: var(--flex-paper-2); }
.flex-section-dark { background: var(--flex-dark); color: #fff; }

/* Hero */
.flex-hero {
  position: relative;
  min-height: min(78vh, 720px);
  display: grid;
  align-items: end;
  color: #fff;
  overflow: hidden;
}
.flex-hero-media { position: absolute; inset: 0; }
.flex-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  animation: flexHeroDrift 18s var(--flex-ease) infinite alternate;
}
@keyframes flexHeroDrift {
  from { transform: scale(1.04); }
  to { transform: scale(1.08) translate(-1%, -0.5%); }
}
.flex-hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(20,18,16,0.25) 0%, rgba(20,18,16,0.12) 35%, rgba(20,18,16,0.85) 100%),
    linear-gradient(90deg, rgba(20,18,16,0.5) 0%, transparent 55%);
}
.flex-hero-content {
  position: relative;
  z-index: 1;
  padding-bottom: 3.5rem !important;
  padding-top: 4rem !important;
}
.flex-hero h1 {
  font-size: clamp(2.25rem, 5.5vw, 3.6rem);
  max-width: 16ch;
  letter-spacing: -0.04em;
  line-height: 1.08 !important;
}
.flex-hero .flex-lede { color: rgba(255,255,255,0.82); }
.flex-hero-meta {
  margin-top: 2.25rem;
  padding-top: 1.15rem;
  border-top: 1px solid rgba(255,255,255,0.2);
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2.5rem;
  font-size: 0.8rem;
}
.flex-hero-meta strong { display: block; font-size: 0.95rem; margin-bottom: 0.15rem; }
.flex-hero-meta span {
  opacity: 0.7;
  text-transform: uppercase;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
}

/* System */
.flex-system-grid { display: grid; gap: 2.5rem; }
@media (min-width: 900px) {
  .flex-system-grid { grid-template-columns: 1.1fr 0.9fr; align-items: end; gap: 4rem; }
}
.flex-system-grid h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.flex-variant-cards { display: grid; gap: 1rem; }
.flex-variant {
  padding: 1.35rem 1.4rem;
  border: 1px solid var(--flex-line);
  background: #fff;
  transition: border-color 0.2s, transform 0.25s var(--flex-ease);
}
.flex-variant:hover { border-color: var(--flex-ink); transform: translateY(-2px); }
.flex-variant h3 {
  font-family: var(--flex-font) !important;
  font-size: 1.125rem !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem !important;
}
.flex-variant p { color: var(--flex-ink-soft); font-size: 0.92rem; margin: 0 !important; }
.flex-link-inline {
  display: inline-block;
  margin-top: 0.85rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--flex-accent) !important;
}
.flex-link-inline:hover { text-decoration: underline; }
.flex-tag {
  display: inline-block;
  margin-bottom: 0.55rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--flex-green);
}

/* Effects */
.flex-effects-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin-bottom: 2rem;
}
.flex-effects-head h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.flex-effects-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
}
@media (min-width: 600px) {
  .flex-effects-grid { grid-template-columns: repeat(2, 1fr); }
}
.flex-effect {
  position: relative;
  min-height: 280px;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  color: #fff !important;
  display: flex;
  align-items: flex-end;
  isolation: isolate;
}
@media (min-width: 600px) {
  .flex-effect { min-height: 0; }
}
.flex-effect img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  transition: transform 0.7s var(--flex-ease);
}
.flex-effect::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, transparent 25%, rgba(20,18,16,0.88) 100%);
}
.flex-effect:hover img { transform: scale(1.06); }
.flex-effect:hover { text-decoration: none; color: #fff !important; }
.flex-effect-body { padding: 1.4rem; width: 100%; }
.flex-effect-body h3 {
  font-family: var(--flex-font) !important;
  font-size: 1.35rem !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem !important;
  color: #fff !important;
}
.flex-effect-body p {
  margin: 0 0 0.9rem !important;
  font-size: 0.88rem;
  opacity: 0.85;
  max-width: 28ch;
  color: #fff !important;
}
.flex-link {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  border-bottom: 1px solid rgba(255,255,255,0.5);
  padding-bottom: 0.15rem;
}
.flex-is-soon::before {
  content: "W przygotowaniu";
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.35rem 0.55rem;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(6px);
  z-index: 2;
}
.flex-effect-ryfel {
  background: repeating-linear-gradient(90deg, #4a433c 0 8px, #3a342e 8px 14px);
}
.flex-effect-deska {
  background: linear-gradient(135deg, #5c4634, #2c241c);
}

/* Klinkier */
.flex-product-hero { display: grid; gap: 2rem; }
@media (min-width: 960px) {
  .flex-product-hero { grid-template-columns: 1.15fr 0.85fr; gap: 3rem; align-items: center; }
}
.flex-product-visual {
  position: relative;
  overflow: hidden;
  min-height: 380px;
  background: #111;
}
.flex-product-visual img {
  width: 100%;
  height: 100%;
  min-height: 380px;
  object-fit: cover;
  cursor: zoom-in;
}
.flex-product-copy h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.flex-feature-list {
  list-style: none;
  margin: 1.5rem 0 0 !important;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}
.flex-feature-list li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--flex-line);
  font-size: 0.95rem;
}
.flex-feature-list .num {
  font-family: var(--flex-font);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--flex-accent);
  letter-spacing: 0.04em;
}
.flex-spec-row {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.75rem !important;
}
@media (min-width: 600px) {
  .flex-spec-row { grid-template-columns: repeat(2, 1fr); }
}
.flex-spec {
  padding: 1rem 1.1rem;
  background: #fff;
  border: 1px solid var(--flex-line);
}
.flex-spec dt {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--flex-muted);
  margin-bottom: 0.25rem;
}
.flex-spec dd { margin: 0; font-weight: 600; }

.flex-swatch-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.65rem;
  margin-top: 2rem;
}
@media (min-width: 700px) {
  .flex-swatch-grid { grid-template-columns: repeat(4, 1fr); }
}
.flex-swatch {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: #222;
  cursor: pointer;
  margin: 0;
}
.flex-swatch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--flex-ease);
}
.flex-swatch:hover img { transform: scale(1.05); }
.flex-swatch figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 0.55rem 0.65rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.75));
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
}
.flex-swatch.is-active { outline: 2px solid var(--flex-accent); outline-offset: 2px; }

/* Placeholdery wizualne (brak finalnych assetów) */
.flex-ph {
  display: grid;
  place-items: center;
  position: relative;
  min-height: inherit;
  background: #3a342e;
  color: rgba(255,255,255,0.85);
  overflow: hidden;
}
.flex-product-visual.flex-ph { min-height: 380px; }
.flex-ph-label {
  position: relative;
  z-index: 1;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  padding: 0.75rem;
  max-width: 18ch;
}
.flex-swatch.flex-ph .flex-ph-label {
  font-size: 0.7rem;
  padding: 0.35rem;
}
.flex-swatch.flex-ph figcaption {
  z-index: 2;
}
.flex-ph-ryfel {
  background: repeating-linear-gradient(90deg, #4a433c 0 10px, #3a342e 10px 16px);
}
.flex-ph-ryfel-alt {
  background: repeating-linear-gradient(90deg, #5a534c 0 14px, #3a342e 14px 22px);
}
.flex-ph-deska {
  background: linear-gradient(135deg, #6b5340 0%, #3d2e22 55%, #2a1f18 100%);
}
.flex-ph-deska-alt {
  background: linear-gradient(135deg, #8a6a4a 0%, #5c4634 55%, #3a2c20 100%);
}
.flex-ph-stone {
  background:
    radial-gradient(circle at 30% 40%, rgba(255,255,255,0.12), transparent 40%),
    linear-gradient(145deg, #5a5550, #2e2b28);
}
.flex-ph-muted {
  background: linear-gradient(145deg, #6a6560, #3d3935);
  border: 1px dashed rgba(255,255,255,0.25);
}

/* Duo */
.flex-duo-layout { display: grid; gap: 2.5rem; }
@media (min-width: 900px) {
  .flex-duo-layout { grid-template-columns: 0.9fr 1.1fr; align-items: center; }
}
.flex-duo-layout h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.flex-duo-colors {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}
@media (min-width: 480px) {
  .flex-duo-colors { grid-template-columns: repeat(3, 1fr); }
}
.flex-duo-color {
  aspect-ratio: 1;
  overflow: hidden;
  background: #ddd;
  border: 1px solid rgba(255,255,255,0.18);
  min-height: 110px;
}
.flex-duo-color img { width: 100%; height: 100%; object-fit: cover; }
.flex-duo-meta {
  margin: 1.5rem 0 0 !important;
  font-size: 0.95rem !important;
  color: rgba(255,255,255,0.88);
}
.flex-duo-caption {
  margin: 1rem 0 0 !important;
  font-size: 0.9rem !important;
  color: rgba(255,255,255,0.8);
}
.flex-pill-row { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.5rem; }
.flex-pill {
  padding: 0.45rem 0.7rem;
  border: 1px solid rgba(255,255,255,0.22);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

/* Teasers */
.flex-teaser { display: grid; min-height: 340px; }
@media (min-width: 860px) {
  .flex-teaser { grid-template-columns: 1fr 1fr; }
  .flex-teaser-reverse .flex-teaser-copy { order: 2; }
  .flex-teaser-reverse .flex-teaser-media { order: 1; }
}
.flex-teaser-media {
  min-height: 260px;
  background: #222;
  position: relative;
  overflow: hidden;
}
.flex-teaser-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}
.flex-teaser-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem 1.75rem;
  background: var(--flex-paper);
}
@media (min-width: 860px) {
  .flex-teaser-copy { padding: 3rem 3.5rem; }
}
.flex-teaser-copy h3 {
  font-family: var(--flex-font) !important;
  font-size: clamp(1.5rem, 3vw, 2rem) !important;
  font-weight: 700 !important;
  margin: 0 0 0.75rem !important;
  letter-spacing: -0.03em;
}

/* Video / gallery / docs */
.flex-video-frame {
  position: relative;
  aspect-ratio: 16/9;
  background: #000;
  overflow: hidden;
  margin-top: 2rem;
}
.flex-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.flex-gallery {
  display: grid;
  gap: 0.65rem;
  grid-template-columns: 1fr 1fr;
}
@media (min-width: 800px) {
  .flex-gallery {
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 220px 220px;
  }
  .flex-gallery .flex-g-item:first-child { grid-row: span 2; }
}
.flex-g-item {
  overflow: hidden;
  background: #222;
  position: relative;
  min-height: 160px;
}
.flex-g-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--flex-ease);
  cursor: zoom-in;
}
.flex-g-item:hover img { transform: scale(1.05); }

.flex-cta-band { display: grid; gap: 2rem; }
@media (min-width: 900px) {
  .flex-cta-band { grid-template-columns: 1.2fr 0.8fr; align-items: center; }
}
.flex-doc-list {
  list-style: none;
  margin: 0 !important;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}
.flex-doc-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.1rem;
  background: #fff;
  border: 1px solid var(--flex-line);
  font-weight: 600;
  font-size: 0.9rem;
  transition: border-color 0.2s, transform 0.2s;
}
.flex-doc-list a:hover {
  border-color: var(--flex-ink);
  transform: translateX(3px);
  text-decoration: none;
  color: var(--flex-ink);
}
.flex-doc-list small { font-weight: 500; color: var(--flex-muted); }
.flex-cta-box {
  padding: 2rem;
  background: var(--flex-ink);
  color: #fff;
}
.flex-cta-box .flex-btn-ghost { color: #fff !important; }
.flex-cta-copy {
  margin: 0 0 1.5rem;
  max-width: 36rem;
  color: #fff;
  opacity: 1;
  font-size: 1.05rem;
  line-height: 1.5;
}

.flex-calc-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
  margin-top: 2rem;
}
@media (min-width: 600px) {
  .flex-calc-grid { grid-template-columns: repeat(2, 1fr); }
}
.flex-calc-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.35rem 1.4rem;
  background: #fff;
  border: 1px solid var(--flex-line);
  transition: border-color 0.2s, transform 0.25s var(--flex-ease);
}
.flex-calc-card:hover {
  border-color: var(--flex-ink);
  transform: translateY(-2px);
  text-decoration: none;
  color: inherit;
}
.flex-calc-brand {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--flex-accent);
}
.flex-calc-card strong {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.flex-calc-card span:last-child {
  font-size: 0.9rem;
  color: var(--flex-ink-soft);
}

/* lightbox */
.flex-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: rgba(10,8,6,0.92);
  padding: 2rem;
  align-items: center;
  justify-content: center;
}
.flex-lightbox.is-open { display: flex; }
.flex-lightbox img { max-width: min(960px, 100%); max-height: 85vh; object-fit: contain; }
.flex-lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.6rem 0.8rem;
  border: 1px solid rgba(255,255,255,0.3);
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}

/* Kalkulator — dopasowanie do języka FLEX (ostre narożniki, Open Sans, pełna szerokość) */
.flex-lp #arsanit-kalkulator {
  --ak-radius-lg: 2px;
  --ak-radius-xl: 2px;
  --ak-radius-2xl: 2px;
  --ak-accent-500: #c45c2a;
  --ak-accent-600: #8f3d16;
  --ak-accent-700: #8f3d16;
  font-family: var(--flex-font);
  padding: 0;
  max-width: none;
  width: 100%;
}
.flex-lp #arsanit-kalkulator .ak-product-picker,
.flex-lp #arsanit-kalkulator .ak-product-panel,
.flex-lp #arsanit-kalkulator .ak-shell,
.flex-lp #arsanit-kalkulator .ak-page-intro {
  max-width: none !important;
  width: 100%;
  margin-left: 0;
  margin-right: 0;
}
.flex-lp #arsanit-kalkulator,
.flex-lp #arsanit-kalkulator * {
  border-radius: 2px !important;
}
.flex-lp #arsanit-kalkulator input[type="range"] {
  border-radius: 2px !important;
}
.flex-lp #arsanit-kalkulator .ak-shell,
.flex-lp #arsanit-kalkulator .ak-form,
.flex-lp #arsanit-kalkulator .ak-product-tile,
.flex-lp #arsanit-kalkulator .brick-type-btn,
.flex-lp #arsanit-kalkulator .ak-input,
.flex-lp #arsanit-kalkulator .ak-result-card {
  border-radius: 2px !important;
}
