/* ===== VIVA HOME SYSTEMS — base ===== */
:root {
  --black: #0b0b0c;
  --black-soft: #17171a;
  --gold: #fed600;
  --gold-dark: #e0bd00;
  --white: #ffffff;
  --off-white: #f6f6f4;
  --gray: #6b6b70;
  --gray-light: #e7e7e5;
  --radius: 10px;
  --shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.25);
  --container: 1180px;
  --ff-head: "Poppins", sans-serif;
  --ff-body: "Inter", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--ff-body);
  color: var(--black);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

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

a { text-decoration: none; color: inherit; }

ul { list-style: none; }

svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4 {
  font-family: var(--ff-head);
  line-height: 1.15;
  font-weight: 700;
}

h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); }
h3 { font-size: 1.2rem; }

.eyebrow {
  display: inline-block;
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}
.eyebrow--dark { color: #b89d00; }

.section { padding: 96px 0; }
.section--off { background: var(--off-white); }
.section--dark { background: var(--black); color: var(--white); }
.section--dark .eyebrow { color: var(--gold); }

.section__head {
  max-width: 640px;
  margin: 0 auto 56px;
  text-align: center;
}
.section__lead { color: var(--gray); margin-top: 12px; }
.section--dark .section__lead { color: #c7c7cc; }

/* ===== buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 30px;
  border-radius: 999px;
  font-family: var(--ff-head);
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn--gold { background: var(--gold); color: var(--black); }
.btn--gold:hover { background: var(--gold-dark); }
.btn--black { background: var(--black); color: var(--white); }
.btn--black:hover { background: var(--black-soft); }
.btn--outline { border-color: rgba(255, 255, 255, 0.6); color: var(--white); }
.btn--outline:hover { background: rgba(255, 255, 255, 0.12); }
.btn--block { width: 100%; }

/* ===== header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.topbar { background: var(--black); color: #d8d8dc; font-size: 0.82rem; }
.topbar__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 24px;
}
.topbar__contact { display: flex; gap: 22px; }
.topbar__contact a { display: inline-flex; align-items: center; gap: 6px; transition: color 0.2s; }
.topbar__contact a:hover { color: var(--gold); }
.topbar__contact svg { font-size: 0.95rem; }
.topbar__note { color: #9c9ca1; }

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  gap: 20px;
}

.logo img { height: 54px; width: auto; }

.nav { display: flex; gap: 32px; margin-left: auto; }
.nav a {
  font-family: var(--ff-head);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  padding: 6px 0;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}
.nav a:hover::after { transform: scaleX(1); }

.navbar__cta { margin-left: 12px; }

.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.burger span {
  display: block;
  height: 2px;
  background: var(--black);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.burger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-active span:nth-child(2) { opacity: 0; }
.burger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== hero ===== */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  color: var(--white);
}
.hero__bg { position: absolute; inset: 0; z-index: -1; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.hero__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11, 11, 12, 0.55) 0%, rgba(11, 11, 12, 0.75) 55%, rgba(11, 11, 12, 0.92) 100%);
}
.hero__content { max-width: 660px; padding-top: 40px; padding-bottom: 40px; }
.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  margin-bottom: 20px;
}
.hero p {
  font-size: 1.1rem;
  color: #e4e4e8;
  max-width: 540px;
  margin-bottom: 34px;
}
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }

.scroll-indicator {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  width: 44px; height: 44px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ===== stats ===== */
.stats { background: var(--black); padding: 46px 0; }
.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}
.stat__num {
  display: block;
  font-family: var(--ff-head);
  font-weight: 800;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  color: var(--gold);
}
.stat__label {
  display: block;
  color: #c7c7cc;
  font-size: 0.9rem;
  margin-top: 4px;
}

/* ===== products ===== */
.products__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.product-card {
  background: var(--off-white);
  border-radius: var(--radius);
  padding: 34px 26px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  background: var(--white);
}
.product-card__icon {
  width: 56px; height: 56px;
  border-radius: 12px;
  background: var(--black);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 20px;
}
.product-card h3 { margin-bottom: 10px; }
.product-card p { color: var(--gray); font-size: 0.95rem; }

/* ===== why choose us ===== */
.why__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.why__image img {
  border-radius: var(--radius);
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4/5;
}
.why__content h2 { margin-bottom: 30px; }

.benefits-list { display: grid; gap: 22px; }
.benefits-list li { display: flex; gap: 14px; align-items: flex-start; }
.benefits-list__icon {
  flex-shrink: 0;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--black);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
}
.benefits-list strong { font-family: var(--ff-head); font-size: 1rem; }
.benefits-list p { color: #c7c7cc; font-size: 0.92rem; margin-top: 2px; }

/* ===== process ===== */
.process__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}
.process-step { position: relative; padding-top: 10px; }
.process-step__num {
  display: block;
  font-family: var(--ff-head);
  font-weight: 800;
  font-size: 2.6rem;
  color: var(--gray-light);
  margin-bottom: 6px;
}
.process-step h3 { margin-bottom: 10px; }
.process-step p { color: var(--gray); font-size: 0.95rem; }

/* ===== gallery ===== */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 220px;
  gap: 20px;
}
.gallery__item { border-radius: var(--radius); overflow: hidden; }
.gallery__item--big { grid-column: span 2; grid-row: span 2; }
.gallery__item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.gallery__item:hover img { transform: scale(1.06); }

/* ===== testimonials ===== */
.testimonials {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.testimonial-card {
  background: var(--off-white);
  border-radius: var(--radius);
  padding: 30px;
}
.testimonial-card__stars { color: var(--gold); letter-spacing: 2px; margin-bottom: 14px; }
.testimonial-card p { color: var(--black); margin-bottom: 18px; font-size: 0.96rem; }
.testimonial-card__author { font-family: var(--ff-head); font-weight: 600; font-size: 0.88rem; color: var(--gray); }

/* ===== CTA banner ===== */
.cta-banner { background: var(--gold); padding: 64px 0; }
.cta-banner__inner { text-align: center; }
.cta-banner h2 { margin-bottom: 10px; }
.cta-banner p { color: #4a4100; margin-bottom: 26px; }

/* ===== devis / contact ===== */
.devis__grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
}
.contact-list { margin-top: 28px; display: grid; gap: 16px; }
.contact-list li { display: flex; align-items: center; gap: 12px; }
.contact-list svg {
  width: 20px; height: 20px;
  color: var(--black);
  background: var(--gold);
  border-radius: 50%;
  padding: 8px;
  box-sizing: content-box;
}

.devis-form {
  background: var(--off-white);
  border-radius: var(--radius);
  padding: 36px;
  display: grid;
  gap: 18px;
}
.devis-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.field { display: grid; gap: 6px; }
.field label { font-size: 0.85rem; font-weight: 600; font-family: var(--ff-head); }
.field input, .field select, .field textarea {
  border: 1px solid var(--gray-light);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: var(--ff-body);
  font-size: 0.95rem;
  background: var(--white);
  resize: vertical;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(254, 214, 0, 0.25);
}
.devis-form__note { font-size: 0.85rem; color: var(--gray); min-height: 1.2em; }

/* ===== footer ===== */
.footer { background: var(--black); color: #c7c7cc; padding-top: 72px; }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 56px;
}
.footer__brand img { height: 50px; margin-bottom: 16px; }
.footer__brand p { font-size: 0.9rem; max-width: 280px; }
.footer__social { display: flex; gap: 12px; margin-top: 20px; }
.footer__social a {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid #3a3a3d;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, border-color 0.2s;
}
.footer__social a:hover { background: var(--gold); border-color: var(--gold); color: var(--black); }

.footer__col { display: grid; gap: 12px; align-content: start; }
.footer__col h4 {
  font-family: var(--ff-head);
  color: var(--white);
  font-size: 0.95rem;
  margin-bottom: 6px;
}
.footer__col a, .footer__col span { font-size: 0.9rem; transition: color 0.2s; }
.footer__col a:hover { color: var(--gold); }

.footer__bottom { border-top: 1px solid #2b2b2e; padding: 20px 0; }
.footer__bottom-inner { text-align: center; font-size: 0.85rem; color: #8c8c90; }

/* ===== back to top ===== */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--black);
  color: var(--gold);
  border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  z-index: 90;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }

/* ===== responsive ===== */
@media (max-width: 980px) {
  .why__grid, .devis__grid { grid-template-columns: 1fr; }
  .why__image { order: -1; }
  .products__grid { grid-template-columns: repeat(2, 1fr); }
  .process__grid { grid-template-columns: repeat(2, 1fr); }
  .testimonials { grid-template-columns: 1fr; }
  .stats__grid { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 200px; }
  .gallery__item--big { grid-column: span 2; grid-row: span 1; }
}

@media (max-width: 860px) {
  .topbar__note { display: none; }
  .nav {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(320px, 80%);
    background: var(--black);
    flex-direction: column;
    justify-content: center;
    gap: 28px;
    padding: 40px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    z-index: 200;
  }
  .nav.is-open { transform: translateX(0); }
  .nav a { color: var(--white); font-size: 1.1rem; }
  .navbar__cta { display: none; }
  .burger { display: flex; }
  .devis-form__row { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .section { padding: 64px 0; }
  .products__grid { grid-template-columns: 1fr; }
  .process__grid { grid-template-columns: 1fr; }
  .stats__grid { grid-template-columns: repeat(2, 1fr); gap: 30px 16px; }
  .gallery { grid-template-columns: 1fr; }
  .gallery__item--big { grid-column: span 1; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: span 2; }
}
