/* ============================================================
   Reparații PVC — design tokens & layout
   ============================================================ */

:root {
  --color-bg: #dfe8ee;
  --color-bg-warm: #eef2f5;
  --color-surface: #f7fafc;
  --color-ink: #14202c;
  --color-ink-soft: #3d4f5f;
  --color-muted: #5c6f80;
  --color-brand: #1a3544;
  --color-brand-mid: #245066;
  --color-accent: #c45c26;
  --color-accent-hover: #a34a1c;
  --color-accent-soft: rgba(196, 92, 38, 0.12);
  --color-line: rgba(20, 32, 44, 0.12);
  --color-white: #ffffff;
  --color-hero-overlay: linear-gradient(
    105deg,
    rgba(15, 28, 40, 0.82) 0%,
    rgba(15, 28, 40, 0.55) 48%,
    rgba(15, 28, 40, 0.35) 100%
  );

  --font-display: "Outfit", system-ui, sans-serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1.25rem;
  --space-lg: 2rem;
  --space-xl: 3.5rem;
  --space-2xl: 5.5rem;

  --radius: 4px;
  --header-h: 4rem;
  --sticky-cta-h: 4.25rem;
  --max: 70rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-soft: 0 12px 40px rgba(15, 28, 40, 0.12);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 0.5rem);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--color-ink);
  background:
    radial-gradient(ellipse 120% 80% at 10% -20%, rgba(36, 80, 102, 0.14), transparent 55%),
    radial-gradient(ellipse 90% 60% at 100% 0%, rgba(196, 92, 38, 0.08), transparent 45%),
    linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg-warm) 40%, var(--color-surface) 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  padding-bottom: var(--sticky-cta-h);
}

@media (min-width: 768px) {
  body {
    padding-bottom: 0;
  }
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-brand-mid);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--color-accent);
}

h1,
h2,
h3,
.brand {
  font-family: var(--font-display);
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--color-ink);
}

h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
  margin: 0 0 var(--space-md);
}

h2 {
  font-size: clamp(1.65rem, 3.5vw, 2.25rem);
  margin: 0 0 var(--space-sm);
}

h3 {
  font-size: 1.2rem;
  margin: 0 0 var(--space-xs);
}

p {
  margin: 0 0 var(--space-md);
  color: var(--color-ink-soft);
}

.section-lead {
  max-width: 36rem;
  font-size: 1.125rem;
  margin-bottom: var(--space-lg);
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0.75rem 1.35rem;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  border: 2px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease),
    transform 0.2s var(--ease);
}

.btn:hover {
  text-decoration: none;
}

.btn:active {
  transform: translateY(1px);
}

.btn--primary {
  background: var(--color-accent);
  color: var(--color-white);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  color: var(--color-white);
}

.btn--ghost {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.55);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--color-white);
  border-color: var(--color-white);
}

.btn--outline {
  background: transparent;
  color: var(--color-brand);
  border-color: var(--color-brand);
}

.btn--outline:hover {
  background: var(--color-brand);
  color: var(--color-white);
}

.btn--whatsapp {
  background: #1fa855;
  color: var(--color-white);
}

.btn--whatsapp:hover {
  background: #198c46;
  color: var(--color-white);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ----- Header ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(247, 250, 252, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.brand {
  font-size: 1.15rem;
  color: var(--color-brand);
  text-decoration: none;
  white-space: nowrap;
}

.brand:hover {
  color: var(--color-accent);
}

.nav {
  display: none;
  align-items: center;
  gap: 1.5rem;
}

.nav a {
  color: var(--color-ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

.nav a:hover {
  color: var(--color-accent);
}

.header-phone {
  display: none;
  font-family: var(--font-display);
  font-weight: 650;
  color: var(--color-brand);
  text-decoration: none;
  white-space: nowrap;
}

.header-phone:hover {
  color: var(--color-accent);
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0.6rem;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: var(--color-surface);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--color-ink);
  border-radius: 1px;
  transition: transform 0.25s var(--ease), opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav--open {
  display: flex;
  position: absolute;
  top: var(--header-h);
  left: 0;
  right: 0;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: var(--space-md);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-line);
  box-shadow: var(--shadow-soft);
}

.nav--open a {
  padding: 0.85rem 0.5rem;
  border-bottom: 1px solid var(--color-line);
}

@media (min-width: 900px) {
  .nav {
    display: flex;
  }

  .nav-toggle {
    display: none;
  }

  .header-phone {
    display: inline-flex;
  }
}

/* ----- Hero ----- */
.hero {
  position: relative;
  min-height: min(92vh, 52rem);
  display: flex;
  align-items: flex-end;
  color: var(--color-white);
  overflow: hidden;
  isolation: isolate;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  animation: hero-zoom 18s var(--ease) forwards;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--color-hero-overlay);
}

.hero__content {
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
  padding: var(--space-2xl) 0 calc(var(--space-xl) + 0.5rem);
  opacity: 0;
  transform: translateY(1.5rem);
  animation: hero-rise 0.9s var(--ease) 0.15s forwards;
}

.hero__brand {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 7vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 0.95;
  color: var(--color-white);
  margin-bottom: var(--space-md);
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.25);
}

.hero h1 {
  color: var(--color-white);
  max-width: 18ch;
  font-size: clamp(1.35rem, 3.2vw, 1.85rem);
  font-weight: 550;
  letter-spacing: -0.01em;
  margin-bottom: var(--space-sm);
}

.hero__lead {
  max-width: 32rem;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.125rem;
  margin-bottom: var(--space-lg);
}

@keyframes hero-zoom {
  to {
    transform: scale(1);
  }
}

@keyframes hero-rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ----- Sections ----- */
.section {
  padding: var(--space-2xl) 0;
}

.section--alt {
  background: rgba(255, 255, 255, 0.45);
  border-block: 1px solid var(--color-line);
}

.section__head {
  margin-bottom: var(--space-lg);
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ----- Services ----- */
.services-grid {
  display: grid;
  gap: var(--space-md);
  list-style: none;
  margin: 0;
  padding: 0;
}

@media (min-width: 640px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1000px) {
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.service-item {
  padding: var(--space-md) 0;
  border-top: 1px solid var(--color-line);
}

.service-item h3 {
  color: var(--color-brand);
}

.service-item p {
  margin: 0;
  font-size: 0.98rem;
}

.service-item__icon {
  display: block;
  width: 2rem;
  height: 2px;
  background: var(--color-accent);
  margin-bottom: var(--space-sm);
}

/* ----- Why us ----- */
.why-list {
  display: grid;
  gap: var(--space-lg);
  list-style: none;
  margin: 0;
  padding: 0;
}

@media (min-width: 768px) {
  .why-list {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-xl);
  }
}

.why-item__num {
  display: block;
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-accent);
  line-height: 1;
  margin-bottom: var(--space-sm);
}

/* ----- Areas ----- */
.areas-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.areas-list li {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-brand);
  padding-bottom: 0.15rem;
  border-bottom: 2px solid var(--color-accent-soft);
}

/* ----- Gallery ----- */
.gallery-grid {
  display: grid;
  gap: var(--space-sm);
  grid-template-columns: 1fr 1fr;
}

@media (min-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
  }
}

.gallery-grid figure {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--color-brand);
}

.gallery-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.gallery-grid figure:hover img {
  transform: scale(1.04);
}

.gallery-grid figcaption {
  font-size: 0.85rem;
  color: var(--color-muted);
  padding: 0.5rem 0 0;
}

/* ----- FAQ ----- */
.faq-list {
  max-width: 44rem;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--color-line);
}

.faq-item {
  border-bottom: 1px solid var(--color-line);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-ink);
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  font-size: 1.35rem;
  font-weight: 400;
  color: var(--color-accent);
  transition: transform 0.25s var(--ease);
}

.faq-item[open] summary::after {
  content: "–";
}

.faq-item__body {
  padding: 0 0 1.25rem;
  color: var(--color-ink-soft);
}

.faq-item__body p:last-child {
  margin-bottom: 0;
}

/* ----- Contact ----- */
.contact-grid {
  display: grid;
  gap: var(--space-xl);
}

@media (min-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr 1.1fr;
    align-items: start;
  }
}

.contact-details {
  display: grid;
  gap: var(--space-md);
}

.contact-details dt {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted);
  margin: 0 0 0.2rem;
}

.contact-details dd {
  margin: 0;
  font-size: 1.15rem;
  color: var(--color-ink);
}

.contact-details a {
  color: var(--color-brand);
  text-decoration: none;
  font-weight: 600;
}

.contact-details a:hover {
  color: var(--color-accent);
}

.contact-form {
  display: grid;
  gap: var(--space-md);
  padding: var(--space-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.form-field {
  display: grid;
  gap: 0.35rem;
}

.form-field label {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-ink);
}

.form-field input,
.form-field textarea,
.form-field select {
  width: 100%;
  padding: 0.75rem 0.9rem;
  font: inherit;
  color: var(--color-ink);
  background: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
}

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 1px;
  border-color: transparent;
}

.form-field textarea {
  min-height: 8rem;
  resize: vertical;
}

.form-note {
  font-size: 0.9rem;
  color: var(--color-muted);
  margin: 0;
}

.map-frame {
  margin-top: var(--space-lg);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 16rem;
  background: var(--color-bg);
}

.map-frame iframe {
  width: 100%;
  height: 16rem;
  border: 0;
  display: block;
}

.map-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 16rem;
  padding: var(--space-md);
  text-align: center;
}

/* ----- Footer ----- */
.site-footer {
  padding: var(--space-xl) 0 var(--space-lg);
  background: var(--color-brand);
  color: rgba(255, 255, 255, 0.78);
}

.site-footer a {
  color: rgba(255, 255, 255, 0.92);
}

.site-footer a:hover {
  color: #ffd4b8;
}

.footer-grid {
  display: grid;
  gap: var(--space-lg);
}

@media (min-width: 700px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: var(--space-sm);
}

.footer-nap {
  margin: 0;
  font-style: normal;
  line-height: 1.7;
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-nav a {
  text-decoration: none;
  font-weight: 600;
}

.footer-legal {
  margin-top: var(--space-xl);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
}

/* ----- Mobile sticky CTA ----- */
.sticky-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  padding: 0.65rem 0.75rem calc(0.65rem + env(safe-area-inset-bottom));
  background: rgba(247, 250, 252, 0.95);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--color-line);
  box-shadow: 0 -8px 24px rgba(15, 28, 40, 0.1);
  transform: translateY(110%);
  transition: transform 0.35s var(--ease);
}

.sticky-cta.is-visible {
  transform: translateY(0);
}

.sticky-cta .btn {
  min-height: 2.85rem;
  font-size: 0.95rem;
  padding-inline: 0.75rem;
}

@media (min-width: 768px) {
  .sticky-cta {
    display: none;
  }
}

/* Prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero__media img,
  .hero__content,
  .reveal,
  .sticky-cta,
  .gallery-grid img {
    animation: none !important;
    transition: none !important;
    opacity: 1;
    transform: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .sticky-cta {
    transform: none;
  }
}
