/* ============================================
   Soggiorno Semplice — Stylesheet
   Palette: arancione corallo #E8632C, nero #1A1A1A, panna #FBF7F1
   ============================================ */

:root {
  --accent: #E8632C;
  --accent-dark: #C24F1E;
  --accent-soft: #F2703A;
  --black: #1A1A1A;
  --cream: #FFFFFF;
  --white: #FFFFFF;
  --border-soft: #1A1A1A;
  --track-soft: #E7DFD3;
  --surface-alt: #FFF9F9;
  --card-shadow: 0 6px 20px rgba(26, 26, 26, 0.07);
  --font-serif: 'Playfair Display', 'EB Garamond', Georgia, serif;
  --font-sans: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --max-width: 1140px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--black);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

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

h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 16px;
}

h1 { font-size: clamp(2.1rem, 4.5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.15rem; }

p { margin: 0 0 16px; }

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 10px;
}

.section {
  padding: 88px 0;
  position: relative;
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.pillars .pillar.reveal:nth-child(2) { transition-delay: 0.1s; }
.pillars .pillar.reveal:nth-child(3) { transition-delay: 0.2s; }

.reviews-grid .review-card.reveal:nth-child(2) { transition-delay: 0.1s; }
.reviews-grid .review-card.reveal:nth-child(3) { transition-delay: 0.2s; }

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal.is-visible {
    transition: none;
    opacity: 1;
    transform: none;
  }
}

/* ---------- Geometric section dividers (triangle notches) ---------- */
.notch {
  position: absolute;
  left: 0;
  right: 0;
  width: 100%;
  height: 55px;
  overflow: hidden;
  line-height: 0;
  z-index: 1;
  pointer-events: none;
}

.notch svg { display: block; width: 100%; height: 100%; }
.notch--top { top: 0; }
.notch--lg { height: 90px; }

.notch-icon {
  position: absolute;
  top: 62px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--white);
  z-index: 2;
  pointer-events: none;
}

.notch-icon svg { width: 22px; height: 22px; display: block; }

.section--tight { padding: 64px 0; }

.section--divider {
  position: relative;
  border-top: 3px solid var(--accent);
}

.section--alt { background: var(--surface-alt); }

.section-head {
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-head p { color: #55504A; font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 32px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}

.btn:hover { transform: translateY(-1px); }

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

.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }

.btn-secondary {
  background: transparent;
  color: var(--black);
  border-color: var(--black);
}

.btn-secondary:hover { background: var(--black); color: var(--white); }

.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.cta-group--center { justify-content: center; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border-soft);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
  padding-top: 0;
  padding-bottom: 0;
}

.site-header { overflow: visible; }

.brand {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 100%;
  /* reserve space in the nav row so the nav links don't creep left under the logo */
  min-width: 190px;
}

/* Logo sits in normal flow now, vertically centered by the flex row itself
   (.site-header .container has align-items: center) — this guarantees true
   centering with no clipping, since the header is the first element on the
   page and anything overflowing above it would be cut by the viewport edge. */
.brand img {
  height: 76px;
  width: auto;
  display: block;
}

.brand-fallback {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-fallback svg { height: 40px; width: 40px; flex-shrink: 0; }

.brand-text { line-height: 1.05; }

.brand-text .brand-line1 {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--black);
  display: block;
}

.brand-text .brand-line2 {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  color: var(--black);
  display: block;
}

/* nav toggle (mobile) */
.nav-toggle { display: none; }

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 8px;
  margin: 0;
  padding: 0;
}

.main-nav a {
  display: inline-block;
  padding: 10px 16px;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 4px;
  transition: color 0.2s ease, background 0.2s ease;
}

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

.main-nav a.nav-cta {
  background: var(--accent);
  color: var(--white);
}

.main-nav a.nav-cta:hover { background: var(--accent-dark); color: var(--white); }

@media (max-width: 760px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background: none;
    border: 2px solid var(--black);
    border-radius: 4px;
    cursor: pointer;
  }

  .nav-toggle span,
  .nav-toggle span::before,
  .nav-toggle span::after {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--black);
    position: relative;
  }

  .nav-toggle span::before,
  .nav-toggle span::after {
    content: "";
    position: absolute;
  }

  .nav-toggle span::before { top: -6px; }
  .nav-toggle span::after { top: 6px; }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--border-soft);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }

  .main-nav.is-open { max-height: 260px; }

  .main-nav ul {
    flex-direction: column;
    padding: 12px 24px 20px;
  }

  .main-nav a { display: block; padding: 12px 4px; }
}

/* ---------- Hero ---------- */
.hero {
  padding: 96px 0 88px;
  text-align: center;
}

.hero .container { max-width: 820px; }

.hero p.subtitle {
  font-size: 1.15rem;
  color: #4A453F;
  max-width: 640px;
  margin: 0 auto 36px;
}

/* ---------- Hero (full-bleed photo variant) ---------- */
.hero--photo {
  position: relative;
  min-height: 74vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  padding: 0;
  text-align: left;
}

.hero-media { position: absolute; inset: 0; }

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-media-fallback {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #F2703A 0%, #E8632C 48%, #1A1A1A 130%);
  overflow: hidden;
}

.hero-media-fallback svg {
  width: 55%;
  max-width: 380px;
  opacity: 0.16;
}

.hero-media-fallback .fallback-note {
  position: absolute;
  bottom: 18px;
  right: 22px;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.8);
  font-family: var(--font-sans);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(26,26,26,0.1) 0%, rgba(26,26,26,0.65) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 130px 24px 64px;
  max-width: 720px;
}

.hero-content .eyebrow {
  color: var(--accent-soft);
  background: rgba(26,26,26,0.55);
  padding: 6px 14px;
  border-radius: 4px;
  display: inline-block;
}
.hero-content h1 { color: var(--white); }
.hero-content p.subtitle { color: rgba(255,255,255,0.9); margin-left: 0; }
.hero-content .cta-group { justify-content: flex-start; }

@media (max-width: 700px) {
  .hero--photo { min-height: 60vh; }
  .hero-content { padding: 90px 20px 44px; }
}

/* ---------- Story (alternating image/text, inspired by reference layout) ---------- */
.story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.story-media {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--cream);
}

.story-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.story-media .story-fallback {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  background: linear-gradient(160deg, #FBF7F1 0%, #F1E4D6 100%);
  border: 1px dashed var(--border-soft);
}

.story-media .story-fallback svg { width: 60px; height: 60px; color: var(--accent); }

.story-media .story-fallback span {
  font-size: 0.78rem;
  color: #8A8377;
  padding: 0 28px;
  text-align: center;
}

.story-text p { color: #4A453F; }

@media (max-width: 860px) {
  .story { grid-template-columns: 1fr; }
  .story-media { order: -1; }
}

/* ---------- Pillars ---------- */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.pillar {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 36px 28px;
  text-align: left;
  box-shadow: var(--card-shadow);
}

.pillar .pillar-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  color: var(--accent);
}

.pillar h3 {
  text-transform: uppercase;
  font-family: var(--font-sans);
  font-size: 0.98rem;
  letter-spacing: 0.04em;
  margin-bottom: 10px;
}

.pillar p { color: #4A453F; font-size: 0.98rem; margin: 0; }

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

/* ---------- Checklist services ---------- */
.section--dark {
  background: var(--black);
  color: var(--cream);
}

.section--dark .section-head p { color: #C9C3B8; }
.section--dark .eyebrow { color: var(--accent-soft); }

.checklist {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 32px;
  max-width: 880px;
  margin: 0 auto;
}

.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 1.02rem;
  list-style: none;
}

.checklist li svg {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  color: var(--accent-soft);
  margin-top: 2px;
}

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

/* ---------- Transparency ---------- */
.transparency {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}

.transparency-visual {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  padding: 28px;
  box-shadow: var(--card-shadow);
}

.portal-mockup {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 24px;
}

.transparency-checklist {
  margin: 0;
  padding: 0;
  list-style: none;
}

.transparency-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--border-soft);
  font-size: 0.94rem;
  color: #3A3630;
}

.transparency-checklist li:last-child { border-bottom: none; }

.transparency-checklist li svg {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--accent);
}

.transparency-tagline {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--accent-dark);
  margin-top: 24px;
}

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

/* ---------- Calcolatore netto ---------- */
.calc-box {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  padding: 40px;
  max-width: 920px;
  margin: 0 auto;
  box-shadow: var(--card-shadow);
}

.calc-controls {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr;
  gap: 28px;
  align-items: end;
  margin-bottom: 36px;
  padding-bottom: 32px;
  border-bottom: 1px dashed var(--border-soft);
}

.calc-field label,
.calc-field-label {
  display: block;
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 10px;
}

.calc-field input[type="range"] {
  width: 100%;
  height: 6px;
  border-radius: 4px;
  background: var(--track-soft);
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  margin-top: 6px;
}

.calc-field input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--white);
  box-shadow: 0 0 0 1px var(--accent);
  cursor: pointer;
}

.calc-field input[type="range"]::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--white);
  box-shadow: 0 0 0 1px var(--accent);
  cursor: pointer;
  border: none;
}

.calc-value {
  margin-top: 10px;
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-dark);
}

.calc-input-unit {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 4px;
  padding: 10px 14px;
  background: var(--cream);
}

.calc-input-unit input {
  border: none;
  background: transparent;
  width: 100%;
  font-size: 1rem;
  font-family: var(--font-sans);
  color: var(--black);
}

.calc-input-unit input:focus { outline: none; }

.calc-toggle {
  display: flex;
  border: 1px solid var(--black);
  border-radius: 4px;
  overflow: hidden;
}

.calc-toggle-btn {
  flex: 1;
  padding: 10px 14px;
  background: var(--white);
  border: none;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  color: var(--black);
  transition: background 0.15s ease, color 0.15s ease;
}

.calc-toggle-btn + .calc-toggle-btn { border-left: 1px solid var(--black); }

.calc-toggle-btn.is-active {
  background: var(--black);
  color: var(--white);
}

.calc-results {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 28px;
}

.calc-panel {
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 24px;
}

.calc-panel--accent {
  border-color: var(--accent);
  background: #FFF6F1;
}

.calc-panel h3 {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 16px;
}

.calc-list { list-style: none; margin: 0 0 18px; padding: 0; }

.calc-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border-soft);
  font-size: 0.9rem;
  color: #4A453F;
}

.calc-list li:last-child { border-bottom: none; }

.calc-list li span:last-child { font-weight: 600; color: var(--black); white-space: nowrap; }

.calc-netto {
  font-size: 1rem;
  padding-top: 14px;
  border-top: 2px solid var(--black);
}

.calc-netto strong {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.7rem;
  color: var(--accent-dark);
  margin-top: 4px;
}

.calc-delta {
  text-align: center;
  font-size: 1rem;
  color: #3A3630;
  margin-bottom: 8px;
}

.calc-delta strong { color: var(--accent-dark); }

.calc-disclaimer {
  text-align: center;
  font-size: 0.78rem;
  color: #8A8377;
  margin: 0;
}

@media (max-width: 780px) {
  .calc-controls { grid-template-columns: 1fr; }
  .calc-results { grid-template-columns: 1fr; }
  .calc-box { padding: 28px 22px; }
}

/* ---------- Reviews ---------- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: stretch;
}

.review-card {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--card-shadow);
}

.review-card .stars {
  color: var(--accent);
  font-size: 1.05rem;
  letter-spacing: 2px;
  margin-bottom: 14px;
}

.review-card p.quote {
  font-size: 0.98rem;
  color: #3A3630;
  flex: 1;
}

.review-card .author {
  font-weight: 700;
  font-size: 0.9rem;
  margin-top: 12px;
}

.review-card--photo {
  padding: 0;
  overflow: hidden;
  aspect-ratio: 1 / 1;
}

.review-card--photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: var(--white);
}

.review-card.placeholder {
  border-style: dashed;
  color: #8A8377;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.92rem;
}

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

/* ---------- Final CTA ---------- */
.final-cta {
  text-align: center;
  background: var(--white);
  border-top: 1px solid var(--border-soft);
}

.final-cta h2 { margin-bottom: 10px; }
.final-cta p { color: #4A453F; margin-bottom: 32px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--black);
  color: #C9C3B8;
  padding: 56px 0 28px;
  font-size: 0.92rem;
  position: relative;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

.footer-grid h4 {
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.footer-grid p, .footer-grid a { color: #C9C3B8; margin: 0 0 8px; display: block; }
.footer-grid a:hover { color: var(--accent-soft); }

.footer-brand .brand-line1,
.footer-brand .brand-line2 { color: var(--white); }

.footer-logo {
  height: 64px;
  width: auto;
  display: block;
  margin-bottom: 12px;
}

.footer-bottom {
  border-top: 1px solid #333029;
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  color: #8A8377;
}

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

/* ---------- Contact page ---------- */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
  align-items: start;
}

.contact-info {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 32px;
  box-shadow: var(--card-shadow);
}

.contact-info h3 { font-size: 1rem; text-transform: uppercase; letter-spacing: 0.04em; font-family: var(--font-sans); }

.contact-info .info-row {
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 0.96rem;
}

.contact-info .info-row svg {
  width: 20px;
  height: 20px;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 3px;
}

.contact-info .legal {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px dashed var(--border-soft);
  font-size: 0.85rem;
  color: #6B665D;
}

.contact-form {
  background: var(--white);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 36px;
  box-shadow: var(--card-shadow);
}

.form-group { margin-bottom: 20px; }

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--border-soft);
  border-radius: 4px;
  font-family: var(--font-sans);
  font-size: 0.96rem;
  background: var(--cream);
  color: var(--black);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-group textarea { resize: vertical; min-height: 130px; }

.form-group--consent { margin-bottom: 22px; }

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 400;
  font-size: 0.85rem;
  color: #4A453F;
  cursor: pointer;
}

.consent-label input[type="checkbox"] {
  width: auto;
  margin-top: 3px;
  accent-color: var(--accent);
  flex-shrink: 0;
}

.consent-label a { color: var(--accent-dark); text-decoration: underline; }

@media (max-width: 860px) {
  .contact-layout { grid-template-columns: 1fr; }
}

.page-hero {
  padding: 64px 0 40px;
  text-align: center;
}

.page-hero p { color: #4A453F; max-width: 560px; margin: 0 auto; }

.whatsapp-float {
  position: fixed;
  bottom: 22px;
  right: 22px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  z-index: 200;
  transition: transform 0.2s ease, background 0.2s ease;
}

.whatsapp-float:hover { background: var(--accent-dark); }

.whatsapp-float:hover { transform: scale(1.08); }

.whatsapp-float svg { width: 32px; height: 32px; }

@media (max-width: 600px) {
  .whatsapp-float { bottom: 16px; right: 16px; width: 50px; height: 50px; }
  .whatsapp-float svg { width: 28px; height: 28px; }
}
