/* =====================================================
   Ograje Krabar – Shared Stylesheet
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ---------- Variables ---------- */
:root {
  --green-dark:   #1a3c1a;
  --green-mid:    #2C7B3F;
  --green-light:  #e8f2e8;
  --anthracite:   #3d3d3d;
  --gray:         #6b7280;
  --gray-light:   #f4f6f4;
  --white:        #ffffff;
  --border:       #d1ddd1;
  --shadow:       0 2px 12px rgba(26,60,26,.10);
  --shadow-hover: 0 6px 24px rgba(26,60,26,.18);
  --radius:       10px;
  --radius-lg:    16px;
  --transition:   .22s ease;
  --max-w:        1200px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--anthracite);
  background: var(--white);
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* ---------- Utility ---------- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.section    { padding: 80px 0; }
.section-sm { padding: 52px 0; }
.section--dark { background: var(--green-dark); color: var(--white); }
.section--gray { background: var(--gray-light); }

.tag {
  display: inline-block;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--green-mid);
  background: var(--green-light);
  border-radius: 30px;
  padding: 4px 14px;
  margin-bottom: 12px;
}
.section-label {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--green-mid);
  margin-bottom: 10px;
}
.section-title {
  font-size: clamp(1.75rem, 3.5vw, 2.6rem);
  font-weight: 800;
  color: var(--green-dark);
  line-height: 1.2;
  margin-bottom: 16px;
}
.section-title--white { color: var(--white); }
.section-subtitle {
  font-size: 1.05rem;
  color: var(--gray);
  max-width: 620px;
}
.section-subtitle--white { color: rgba(255,255,255,.80); }
.section-header { margin-bottom: 48px; }
.section-header--center { text-align: center; }
.section-header--center .section-subtitle { margin: 0 auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 28px;
  border-radius: var(--radius);
  font-size: .95rem;
  font-weight: 600;
  transition: var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--green-mid);
  color: var(--white);
}
.btn-primary:hover { background: var(--green-dark); transform: translateY(-1px); box-shadow: var(--shadow-hover); }
.btn-outline {
  border: 2px solid var(--white);
  color: var(--white);
}
.btn-outline:hover { background: var(--white); color: var(--green-dark); }
.btn-outline-dark {
  border: 2px solid var(--green-mid);
  color: var(--green-mid);
}
.btn-outline-dark:hover { background: var(--green-mid); color: var(--white); }
.btn-ghost { color: var(--green-mid); font-weight: 600; padding: 0; }
.btn-ghost:hover { color: var(--green-dark); }
.btn-ghost svg { transition: transform var(--transition); }
.btn-ghost:hover svg { transform: translateX(4px); }

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 8px rgba(0,0,0,.06);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.nav__brand img { height: 58px; width: auto; }
.nav__brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--green-dark);
}
.nav__links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav__link {
  padding: 6px 10px;
  border-radius: 7px;
  font-size: .86rem;
  font-weight: 500;
  color: var(--anthracite);
  transition: var(--transition);
}
.nav__link:hover, .nav__link.active { color: var(--green-dark); background: var(--green-light); }
.nav__cta { margin-left: 12px; padding: 10px 22px; font-size: .9rem; }
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
  border-radius: 6px;
  transition: var(--transition);
}
.nav__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--green-dark);
  border-radius: 2px;
  transition: var(--transition);
}
.nav__burger:hover { background: var(--green-light); }
.nav__burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger.open span:nth-child(2) { opacity: 0; }
.nav__burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav__mobile {
  display: none;
  flex-direction: column;
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 16px 24px 24px;
  gap: 4px;
}
.nav__mobile.open { display: flex; }
.nav__mobile .nav__link { display: block; padding: 10px 14px; }
.nav__mobile .btn-primary { margin-top: 8px; justify-content: center; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 560px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero--tall { min-height: 480px; }
.hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(26,60,26,.82) 0%, rgba(26,60,26,.45) 100%);
  z-index: 1;
}
.hero__content {
  position: relative;
  z-index: 2;
  color: var(--white);
  max-width: 680px;
  padding: 80px 0;
}
.hero__tag {
  display: inline-block;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.8);
  background: rgba(255,255,255,.15);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 30px;
  padding: 5px 16px;
  margin-bottom: 20px;
}
.hero__title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.12;
  margin-bottom: 18px;
}
.hero__subtitle {
  font-size: 1.12rem;
  color: rgba(255,255,255,.85);
  margin-bottom: 36px;
  max-width: 520px;
}
.hero__btns { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Feature strip ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--green-dark);
}
.feature {
  padding: 36px 28px;
  border-right: 1px solid rgba(255,255,255,.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.feature:last-child { border-right: none; }
.feature__icon {
  width: 44px;
  height: 44px;
  background: rgba(255,255,255,.12);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}
.feature__icon svg { width: 22px; height: 22px; fill: none; stroke: var(--white); stroke-width: 1.8; }
.feature__title { font-size: 1rem; font-weight: 700; color: var(--white); }
.feature__desc { font-size: .88rem; color: rgba(255,255,255,.7); line-height: 1.5; }

/* ---------- Cards ---------- */
.cards { display: grid; gap: 28px; }
.cards--2 { grid-template-columns: repeat(2, 1fr); }
.cards--3 { grid-template-columns: repeat(3, 1fr); }
.cards--4 { grid-template-columns: repeat(4, 1fr); }
.cards--6 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.card:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); border-color: var(--green-mid); }
.card__img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.card__body { padding: 22px 24px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.card__title { font-size: 1.05rem; font-weight: 700; color: var(--green-dark); }
.card__desc { font-size: .9rem; color: var(--gray); flex: 1; }
.card__footer { padding: 0 24px 20px; }

/* ---------- Spec table ---------- */
.spec-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.spec-table th {
  background: var(--green-dark);
  color: var(--white);
  font-weight: 600;
  padding: 12px 18px;
  text-align: left;
}
.spec-table td { padding: 11px 18px; border-bottom: 1px solid var(--border); }
.spec-table tr:last-child td { border-bottom: none; }
.spec-table tr:nth-child(even) td { background: var(--gray-light); }
.spec-table tr:hover td { background: var(--green-light); }
.spec-wrap {
  border-radius: var(--radius);
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  max-width: 100%;
  min-width: 0;
}

/* ---------- Table wrapper (alias) ---------- */
.table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  max-width: 100%;
}
.table-wrapper table {
  min-width: 600px;
  width: 100%;
}

/* ---------- Check list ---------- */
.checklist { display: flex; flex-direction: column; gap: 10px; }
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: .95rem;
}
.checklist li::before {
  content: '';
  display: block;
  width: 20px;
  height: 20px;
  min-width: 20px;
  background: var(--green-mid);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='white'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 12px;
  margin-top: 2px;
}

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step { text-align: center; padding: 32px 20px; }
.step__num {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--green-mid);
  color: var(--white);
  font-size: 1.4rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.step__title { font-size: 1rem; font-weight: 700; color: var(--green-dark); margin-bottom: 8px; }
.step__desc { font-size: .88rem; color: var(--gray); }

/* ---------- RAL swatches ---------- */
.ral-swatches { display: flex; gap: 16px; flex-wrap: wrap; }
.ral-swatch { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.ral-swatch__dot {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 3px solid var(--white);
  box-shadow: 0 0 0 1px var(--border), var(--shadow);
}
.ral-swatch__name { font-size: .78rem; font-weight: 600; color: var(--anthracite); text-align: center; }
.ral-swatch__code { font-size: .7rem; color: var(--gray); }

/* ---------- CTA banner ---------- */
.cta-banner {
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
  padding: 72px 0;
  text-align: center;
  color: var(--white);
}
.cta-banner__title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 12px;
}
.cta-banner__sub {
  font-size: 1.05rem;
  color: rgba(255,255,255,.8);
  margin-bottom: 32px;
}

/* ---------- Contact form ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.form-group label { font-size: .88rem; font-weight: 600; color: var(--green-dark); }
.form-group input,
.form-group select,
.form-group textarea {
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: .95rem;
  font-family: inherit;
  color: var(--anthracite);
  background: var(--white);
  transition: var(--transition);
  outline: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--green-mid);
  box-shadow: 0 0 0 3px rgba(74,124,63,.15);
}
.form-group textarea { resize: vertical; min-height: 130px; }
.contact-info { display: flex; flex-direction: column; gap: 24px; }
.contact-person {
  background: var(--green-light);
  border-radius: var(--radius-lg);
  padding: 24px;
  border-left: 4px solid var(--green-mid);
}
.contact-person__name { font-size: 1.05rem; font-weight: 700; color: var(--green-dark); margin-bottom: 10px; }
.contact-person a { display: flex; align-items: center; gap: 8px; font-size: .92rem; margin-bottom: 6px; color: var(--anthracite); }
.contact-person a:hover { color: var(--green-mid); }

/* ---------- Footer ---------- */
.footer {
  background: #3d3d3d;
  color: rgba(255,255,255,.85);
  padding: 60px 0 32px;
}
.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer__brand img { width: 230px; height: auto; margin-bottom: 18px; }
.footer__brand p { font-size: .9rem; color: rgba(255,255,255,.65); max-width: 280px; line-height: 1.6; }
.footer__title { font-size: .82rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.45); margin-bottom: 16px; }
.footer__links { display: flex; flex-direction: column; gap: 10px; }
.footer__links a { font-size: .9rem; color: rgba(255,255,255,.75); transition: var(--transition); }
.footer__links a:hover { color: var(--white); }
.footer__contact { display: flex; flex-direction: column; gap: 10px; }
.footer__contact a { font-size: .9rem; color: rgba(255,255,255,.75); display: flex; align-items: center; gap: 8px; transition: var(--transition); }
.footer__contact a:hover { color: var(--white); }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .82rem;
  color: rgba(255,255,255,.45);
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- WhatsApp float ---------- */
.wa-float {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 900;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,.40);
  transition: var(--transition);
}
.wa-float:hover { transform: scale(1.08); box-shadow: 0 6px 24px rgba(37,211,102,.55); }
.wa-float svg { width: 30px; height: 30px; fill: var(--white); }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .55s ease, transform .55s ease; }
.reveal.visible { opacity: 1; transform: none; }


/* ---------- Buttons – touch targets ---------- */
.btn { min-height: 44px; }

/* ---------- Responsive – Tablet 1024px ---------- */
@media (max-width: 1024px) {
  .cards--6 { grid-template-columns: repeat(2, 1fr); }
  .cards--4 { grid-template-columns: repeat(2, 1fr); }
  .features { grid-template-columns: repeat(2, 1fr); }
  .feature { border-right: none; border-bottom: 1px solid rgba(255,255,255,.08); }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- Responsive – Mobile 768px ---------- */
@media (max-width: 768px) {
  /* Layout */
  .section    { padding: 48px 0; }
  .section-sm { padding: 36px 0; }
  .container  { padding: 0 16px; }

  /* Nav */
  .nav__inner { height: 60px; }
  .nav__brand img { height: 44px; }
  .nav__links, .nav__cta { display: none; }
  .nav__burger { display: flex; }

  /* Hero */
  .hero { min-height: 380px; }
  .hero__content { padding: 48px 0; }
  .hero__title { font-size: clamp(1.6rem, 6vw, 2.2rem); }
  .hero__subtitle { font-size: .95rem; }
  .hero__btns { flex-direction: column; gap: 10px; }
  .hero__btns .btn { width: 100%; justify-content: center; }

  /* Typography */
  .section-title { font-size: clamp(1.4rem, 5vw, 2rem); }

  /* Cards */
  .cards--2, .cards--3, .cards--4, .cards--6 { grid-template-columns: 1fr; }

  /* Features strip */
  .features { grid-template-columns: 1fr; }
  .feature { border-right: none; border-bottom: 1px solid rgba(255,255,255,.08); padding: 24px 20px; }

  /* Steps */
  .steps { grid-template-columns: 1fr; }

  /* Inline 2-col grids → single column */
  div[style*="grid-template-columns:1fr 1fr"],
  div[style*="grid-template-columns: 1fr 1fr"],
  div[style*="grid-template-columns:2fr 1fr"],
  div[style*="grid-template-columns: 2fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
  /* Inline 3-col grids → single column */
  div[style*="grid-template-columns:repeat(3"] {
    grid-template-columns: 1fr !important;
  }

  /* Spec tables – horizontal scroll */
  .spec-wrap { border-radius: var(--radius); max-width: 100vw; overflow-x: auto; }
  .spec-table { min-width: 500px; }

  /* Footer */
  .footer__grid { grid-template-columns: 1fr; gap: 28px; }
  .footer__bottom { flex-direction: column; text-align: center; gap: 8px; }
  .footer__brand img { width: 180px !important; }

  /* Contact */
  .contact-grid { grid-template-columns: 1fr; gap: 32px; }

  /* Buttons */
  .btn { min-height: 48px; }

  /* WhatsApp */
  .wa-float { bottom: 18px; right: 18px; width: 52px; height: 52px; }

  /* CTA banner */
  .cta-banner { padding: 48px 0; }
  .cta-banner .btn { width: 100%; max-width: 320px; justify-content: center; }
}

/* ---------- Responsive – Small mobile 480px ---------- */
@media (max-width: 480px) {
  .hero__tag { font-size: .68rem; }
  .hero__title { font-size: clamp(1.4rem, 7vw, 1.9rem); }
  .section-title { font-size: clamp(1.3rem, 6vw, 1.7rem); }

  /* RAL swatches wrap */
  .ral-swatches { gap: 12px; }

  /* Steps: smaller padding */
  .step { padding: 24px 12px; }

  /* Obrazec polja – full width */
  .form-group input,
  .form-group select,
  .form-group textarea { font-size: 16px; /* prevents iOS zoom */ }

  /* Feature icon smaller */
  .feature__icon { width: 38px; height: 38px; }
}
