@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=Raleway:wght@300;400;500;600&display=swap');

:root {
  --color-primary: #8B1A1A;
  --color-primary-dark: #5C0F0F;
  --color-accent: #C9913A;
  --color-bg: #FAF7F2;
  --color-bg-alt: #F0EAE0;
  --color-dark: #2C1508;
  --color-text: #3A2510;
  --color-text-muted: #7A6050;
  --color-border: #D8CABB;
  --color-white: #FFFFFF;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Raleway', sans-serif;
  --shadow-sm: 0 2px 8px rgba(44, 21, 8, 0.08);
  --shadow-md: 0 4px 20px rgba(44, 21, 8, 0.14);
  --shadow-lg: 0 8px 40px rgba(44, 21, 8, 0.2);
  --radius: 4px;
  --radius-lg: 10px;
  --transition: all 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  font-size: 1rem;
  line-height: 1.7;
  font-weight: 400;
}

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

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

ul {
  list-style: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.2;
  color: var(--color-dark);
}

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-padding {
  padding: 6rem 0;
}

.subtitle {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 600px;
  margin: 0.75rem auto 2.5rem;
  text-align: center;
  font-weight: 300;
  letter-spacing: 0.02em;
}

.primary-color-text {
  color: var(--color-primary);
}

/* ── Buttons ── */

.button {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
}

.button.primary {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

.button.primary:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.button.secondary {
  background: transparent;
  color: var(--color-white);
  border-color: var(--color-white);
}

.button.secondary:hover {
  background: var(--color-white);
  color: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ── Header / Nav ── */

header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: transparent;
  transition: var(--transition);
  padding: 1.25rem 0;
}

header.scrolled {
  background: var(--color-dark);
  box-shadow: var(--shadow-md);
  padding: 0.75rem 0;
}

header nav.container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  position: relative;
}

.logo a {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.03em;
  white-space: nowrap;
  transition: var(--transition);
}

.logo a:hover {
  color: var(--color-accent);
}

.nav-toggle-checkbox {
  display: none;
}

.nav-toggle-label {
  display: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--color-white);
  transition: var(--transition);
  z-index: 100;
}

.nav-toggle-label:hover {
  color: var(--color-accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  flex: 1;
  justify-content: center;
}

.nav-links li a {
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  transition: var(--transition);
  position: relative;
  padding-bottom: 2px;
}

.nav-links li a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width 0.3s ease;
}

.nav-links li a:hover {
  color: var(--color-white);
}

.nav-links li a:hover::after {
  width: 100%;
}

.nav-cta {
  flex-shrink: 0;
}

.nav-cta .button.primary {
  padding: 0.55rem 1.4rem;
  font-size: 0.82rem;
}

/* ── Hero ── */

.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  background: url('assets/hero.webp') center center / cover no-repeat;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(44, 21, 8, 0.82) 0%,
    rgba(139, 26, 26, 0.6) 60%,
    rgba(44, 21, 8, 0.72) 100%
  );
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  padding: 3rem 2rem;
}

.hero-content h1 {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

.hero-content h2 {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 2.5vw, 1.6rem);
  font-weight: 400;
  font-style: italic;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2.5rem;
  line-height: 1.4;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ── Servizi ── */

.servizi {
  background: var(--color-bg);
}

.servizi h2,
.galleria h2,
.chisiamo h2,
.processo h2,
.testimonianze h2,
.contatti h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  text-align: center;
  color: var(--color-dark);
  margin-bottom: 0.5rem;
  position: relative;
}

.servizi h2::after,
.galleria h2::after,
.chisiamo h2::after,
.processo h2::after,
.testimonianze h2::after,
.contatti h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--color-primary);
  margin: 0.75rem auto 0;
  border-radius: 2px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.service-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2.25rem 1.75rem;
  text-align: center;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}

.service-card i {
  font-size: 2.2rem;
  margin-bottom: 1.2rem;
  display: block;
}

.service-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--color-dark);
}

.service-card p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.65;
}

/* ── Galleria ── */

.galleria {
  background: var(--color-bg-alt);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  aspect-ratio: 4 / 3;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-item:hover img {
  transform: scale(1.07);
}

.gallery-item .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(44, 21, 8, 0.88) 0%, rgba(44, 21, 8, 0.2) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.gallery-item:hover .overlay {
  opacity: 1;
}

.gallery-item .overlay h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--color-white);
  margin-bottom: 0.25rem;
}

.gallery-item .overlay p {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.8);
}

/* ── Chi Siamo ── */

.chisiamo {
  background: var(--color-bg);
}

.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-top: 2.5rem;
}

.about-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.about-image img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.about-image:hover img {
  transform: scale(1.04);
}

.about-text p {
  color: var(--color-text);
  font-size: 1.02rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
  font-weight: 400;
}

.about-text p:last-child {
  margin-bottom: 0;
}

/* ── Processo ── */

.processo {
  background: var(--color-dark);
}

.processo h2 {
  color: var(--color-white);
}

.processo h2::after {
  background: var(--color-accent);
}

.processo .subtitle {
  color: rgba(255, 255, 255, 0.65);
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.process-step {
  text-align: center;
  padding: 2rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.04);
  transition: var(--transition);
}

.process-step:hover {
  background: rgba(201, 145, 58, 0.12);
  border-color: var(--color-accent);
  transform: translateY(-4px);
}

.process-step i {
  font-size: 2rem;
  margin-bottom: 1rem;
  display: block;
}

.process-step h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--color-white);
  margin-bottom: 0.6rem;
}

.process-step p {
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.65;
}

.process-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  max-height: 420px;
}

.process-image img {
  width: 100%;
  height: 420px;
  object-fit: cover;
}

/* ── Testimonianze ── */

.testimonianze {
  background: var(--color-bg-alt);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.testimonial-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--color-primary);
  transition: var(--transition);
  position: relative;
}

.testimonial-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.quote-icon {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  display: block;
  opacity: 0.7;
}

.testimonial-card p {
  font-size: 0.98rem;
  color: var(--color-text);
  line-height: 1.75;
  font-style: italic;
  margin-bottom: 1.25rem;
}

.testimonial-card h4 {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--color-primary);
  font-weight: 600;
}

/* ── Contatti ── */

.contatti {
  background: var(--color-bg);
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 4rem;
  margin-top: 2.5rem;
  align-items: start;
}

.contact-info h3,
.contact-form h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin-bottom: 1.5rem;
  color: var(--color-dark);
}

.contact-info p {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-size: 0.97rem;
  color: var(--color-text);
  line-height: 1.55;
}

.contact-info p i {
  color: var(--color-primary);
  font-size: 1.1rem;
  margin-top: 0.15rem;
  flex-shrink: 0;
}

.social-icons {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-icons a {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: var(--transition);
}

.social-icons a:hover {
  background: var(--color-accent);
  transform: translateY(-3px);
  box-shadow: var(--shadow-sm);
}

.contact-form form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-white);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 0.97rem;
  transition: var(--transition);
  outline: none;
  resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(139, 26, 26, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #B0A090;
}

.contact-form .button.primary {
  align-self: flex-start;
  margin-top: 0.5rem;
}

/* ── Footer ── */

footer {
  background: var(--color-dark);
  padding: 2.5rem 0;
  text-align: center;
}

footer .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.footer-logo {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.04em;
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.footer-social a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
}

footer p {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.03em;
}

/* ── Reveal Animations ── */

.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal:not(.revealed):not(.hero) {
  opacity: 0;
  transform: translateY(30px);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.hero.reveal {
  opacity: 1;
  transform: none;
}

/* ── Responsive ── */

@media (max-width: 768px) {
  header {
    padding: 1rem 0;
  }

  .nav-toggle-label {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-dark);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.25rem 2rem;
    gap: 0;
    box-shadow: var(--shadow-md);
  }

  .nav-links li {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav-links li:last-child {
    border-bottom: none;
  }

  .nav-links li a {
    display: block;
    padding: 0.75rem 0;
    font-size: 0.95rem;
  }

  .nav-toggle-checkbox:checked ~ .nav-links {
    display: flex;
  }

  .nav-cta {
    display: none;
  }

  .logo a {
    font-size: 1.2rem;
  }

  .hero-content {
    padding: 2rem 0;
    max-width: 100%;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .button {
    text-align: center;
  }

  .services-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .about-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .about-image img {
    height: 260px;
  }

  .process-steps {
    grid-template-columns: 1fr 1fr;
  }

  .contact-content {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .section-padding {
    padding: 4rem 0;
  }
}

@media (max-width: 480px) {
  .services-grid {
    grid-template-columns: 1fr;
  }

  .process-steps {
    grid-template-columns: 1fr;
  }

  .testimonials-grid {
    grid-template-columns: 1fr;
  }

  .hero-content h1 {
    font-size: 2.4rem;
  }

  .container {
    padding: 0 1.25rem;
  }
}
