/* RESET + NORMALIZE (MOBILE FIRST) */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font: inherit;
  vertical-align: baseline;
  box-sizing: border-box;
}
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
  display: block;
}
body { line-height: 1.6; background: #F4F8FB; color: #1A3756; }
ol, ul { list-style: none; }
a { text-decoration: none; color: inherit; }
img { border: 0; max-width: 100%; }
button, input, textarea, select {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
  box-sizing: border-box;
}

/* ROOT, FONTS, COLOR VARIABLES + PRELOAD FONTS*/
:root {
  --color-primary: #1A3756;
  --color-secondary: #D0BA8B;
  --color-accent: #F4F8FB;
  --color-dark: #12223A;
  --color-body: #223A50;
  --color-white: #fff;
  --color-muted: #dbe7ef;
  --shadow-1: 0 4px 20px rgba(26,55,86,0.10);
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-sm: 6px;
  --transition: 0.25s cubic-bezier(.7, .2, .17, 1);
  --gap-section: 60px;
  --gap-content: 24px;
}
@media (min-width: 992px) {
  :root { --gap-section: 80px; --gap-content: 32px; }
}

/* FONTS: Playfair Display + Montserrat
   NOTE: For production, import via @import or link preload in <head> */
@import url('https://fonts.googleapis.com/css?family=Montserrat:400,500,700&display=swap');
@import url('https://fonts.googleapis.com/css?family=Playfair+Display:700,900&display=swap');

body {
  font-family: 'Montserrat', Arial, sans-serif;
  font-size: 16px;
  background: var(--color-accent);
  color: var(--color-body);
  letter-spacing: .01em;
  min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', serif;
  color: var(--color-primary);
  font-weight: 700;
  line-height: 1.13;
  margin-bottom: 16px;
  letter-spacing: 0.01em;
}
h1 {
  font-size: 2.35rem;
}
h2 {
  font-size: 1.7rem;
  margin-bottom: 0.6em;
}
h3 {
  font-size: 1.12rem;
}
.subtitle {
  font-size: 1.09rem;
  font-family: 'Montserrat', Arial, sans-serif;
  color: var(--color-dark);
  letter-spacing: .015em;
  margin-bottom: 16px;
}

p, ul, ol { color: var(--color-body); font-size: 1rem; }
strong { font-weight: 700; }

/* CONTAINER & GLOBAL LAYOUTS */
.container {
  width: 100%;
  max-width: 1140px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
  box-sizing: border-box;
}

.content-wrapper {
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 0;
}
.text-section {
  max-width: 680px;
}

/* SECTIONS & SPACING */
section {
  margin-bottom: 60px;
  padding: 40px 0 40px 0;
  background: none;
}
@media (max-width: 767px) {
  section { margin-bottom: 32px; padding: 32px 0; }
}

/* HERO SECTION */
.hero {
  padding: 0 0 32px 0;
  margin-bottom: 0;
}
.hero .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero .content-wrapper {
  align-items: center;
  text-align: center;
  gap: 16px;
  background: var(--color-accent);
  padding: 32px 20px 28px 20px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-1);
  border: 3.5px solid var(--color-secondary);
  margin: 0 auto;
  max-width: 640px;
}
.hero h1 {
  font-size: 2.1rem;
}
@media (min-width: 900px) {
  .hero h1 { font-size: 2.8rem; }
}

/* BUTTONS */
.btn-primary {
  padding: 12px 28px;
  background: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: 28px 6px 28px 6px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.04em;
  display: inline-block;
  box-shadow: 0 4px 16px rgba(26,55,86,0.12);
  cursor: pointer;
  transition: background 0.22s, box-shadow 0.22s, transform 0.13s;
  margin-top: 8px;
  position: relative;
  outline: none;
}
.btn-primary:hover, .btn-primary:focus {
  background: var(--color-secondary);
  color: var(--color-primary);
  box-shadow: 0 8px 32px rgba(208,186,139,0.22);
  transform: translateY(-2px) scale(1.035);
}

/* NAVIGATION */
header {
  background: var(--color-accent);
  box-shadow: 0 2px 12px rgba(26,55,86,0.03);
  border-bottom: 2.5px solid var(--color-secondary);
  position: relative;
}
header .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 16px;
  padding-bottom: 16px;
}
.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
}
.main-nav a {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  letter-spacing: 0.07em;
  font-size: 1.03rem;
  color: var(--color-primary);
  padding: 7px 13px 7px 10px;
  border-radius: var(--radius-sm);
  transition: background 0.17s, color 0.17s;
  position: relative;
}
.main-nav a:hover, .main-nav a:focus {
  background: var(--color-secondary);
  color: var(--color-white);
}

/* HAMBURGER & MOBILE MENU */
.mobile-menu-toggle {
  display: block;
  background: var(--color-secondary);
  color: var(--color-primary);
  border-radius: 8px;
  font-size: 2.15rem;
  border: none;
  padding: 6px 15px;
  cursor: pointer;
  z-index: 1201;
  transition: background 0.13s, color 0.13s;
  outline: none;
}
.mobile-menu-toggle:hover, .mobile-menu-toggle:focus {
  background: var(--color-primary);
  color: var(--color-secondary);
}

.mobile-menu {
  position: fixed;
  left: 0;
  top: 0;
  width: 100vw;
  height: 100vh;
  background: var(--color-accent);
  box-shadow: 0 0 0 9999px rgba(34,58,80,0.7);
  z-index: 1200;
  display: flex;
  flex-direction: column;
  transform: translateX(-110vw);
  transition: transform .33s var(--transition);
  pointer-events: none;
  opacity: 0;
}
.mobile-menu.active {
  transform: translateX(0);
  pointer-events: auto;
  opacity: 1;
}
.mobile-menu-close {
  align-self: flex-end;
  margin: 18px 22px 0 0;
  background: var(--color-secondary);
  color: var(--color-primary);
  border: none;
  border-radius: 6px;
  font-size: 2.1rem;
  padding: 4px 12px;
  cursor: pointer;
  transition: background 0.19s, color 0.19s;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  background: var(--color-primary);
  color: var(--color-secondary);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 24px;
  align-items: flex-start;
  padding: 36px 36px 0 32px;
}
.mobile-nav a {
  font-size: 1.22rem;
  font-weight: 500;
  color: var(--color-primary);
  padding: 8px 0;
  border-radius: 0 12px 12px 0;
  transition: background 0.19s, color 0.19s;
  min-width: 180px;
  display: flex;
  align-items: center;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: var(--color-secondary);
  color: var(--color-accent);
}

/* HIDE ON MOBILE OR DESKTOP */
.main-nav, .btn-primary {
  display: none;
}
@media (min-width: 900px) {
  .main-nav, .btn-primary {
    display: flex;
  }
  .mobile-menu-toggle, .mobile-menu {
    display: none !important;
  }
}
@media (max-width: 899px) {
  .main-nav, .btn-primary {
    display: none !important;
  }
  .mobile-menu-toggle {
    display: block !important;
  }
  .mobile-menu {
    display: flex !important;
  }
}

/* SECTIONS & CONTENT */
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
}
@media (max-width: 767px) {
  .section { margin-bottom: 36px; padding: 26px 10px; }
}

/* CARD CONTAINER, CARDS, FLEXBOX STRUCTURE */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
  margin-bottom: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 28px 22px;
  min-width: 245px;
  max-width: 380px;
  flex: 1 1 245px;
}

.card-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
}

.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
  width: 100%;
}

.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .content-grid, .card-container, .text-image-section {
    flex-direction: column;
    gap: 20px;
  }
}

/* FEATURE GRID + ITEMS (e.g., index, chi-siamo, galleria, servizi) */
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 32px;
  margin-top: 10px;
}
@media (max-width: 768px) {
  .feature-grid {
    flex-direction: column;
    gap: 22px;
    align-items: stretch;
  }
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  min-width: 210px;
  max-width: 330px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  padding: 24px 20px 22px 20px;
  box-shadow: var(--shadow-1);
  border: 2.5px solid var(--color-secondary);
  flex: 1 1 220px;
  transition: box-shadow 0.22s, border-color 0.16s, transform 0.11s;
}
.feature-item img {
  width: 48px; height: 48px;
  display: block;
}
.feature-item h3 {
  font-size: 1.18rem;
  color: var(--color-dark);
  margin-bottom: 0;
}
.feature-item p {
  font-size: 0.99rem;
  line-height: 1.5;
}
.feature-item:hover, .feature-item:focus-within {
  box-shadow: 0 10px 32px rgba(208,186,139,0.14);
  border-color: var(--color-primary);
  transform: translateY(-2px) scale(1.02);
}

/* TESTIMONIAL CARD */
.testimonial-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding: 20px 28px 16px 28px;
  margin-bottom: 24px;
  background: var(--color-accent);
  border-radius: var(--radius-md);
  box-shadow: 0 4px 24px rgba(34,58,80,0.11);
  border: 2.5px solid var(--color-secondary);
  max-width: 560px;
}
.testimonial-card p {
  color: #1A3756;
  font-weight: 500;
  font-size: 1.1rem;
  margin-bottom: .4em;
}
.testimonial-card span {
  font-size: 0.98rem;
  color: #7A7A7A;
}
@media (max-width: 767px) {
  .testimonial-card {
    padding: 15px 13px 12px 13px;
  }
}

/* UL/LI Styles in Context of Content */
ul, ol {
  margin-left: 1em;
  margin-bottom: 12px;
}
ul li, ol li {
  padding-left: 0.2em;
  margin-bottom: 10px;
  line-height: 1.5;
  font-size: 1rem;
}
ul li img {
  vertical-align: middle;
  margin-right: 7px;
}

/* TABLE-LIKE CONTACT INFO FOOTER */
.contact-info {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
  margin: 22px 0 11px 0;
  color: var(--color-primary);
  font-size: 0.95rem;
}
.contact-info img {
  margin-right: 8px;
  width: 21px; height: 21px;
}
@media (max-width: 768px) {
  .contact-info { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* FOOTER */
footer {
  background: var(--color-dark);
  color: var(--color-accent);
  padding: 32px 0 18px 0;
  margin-top: 50px;
  border-radius: 32px 32px 0 0;
  box-shadow: 0 -6px 20px rgba(26,55,86,.09);
  position: relative;
}
footer .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.footer-nav {
  display: flex;
  gap: 14px;
  font-size: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 5px;
  color: var(--color-secondary);
}
.footer-nav a {
  color: var(--color-secondary);
  transition: color 0.16s, background 0.16s;
  padding: 7px 9px;
  border-radius: 5px;
}
.footer-nav a:hover, .footer-nav a:focus {
  color: var(--color-dark);
  background: var(--color-secondary);
}
footer .copyright {
  margin-top: 11px;
  font-size: 0.97rem;
  color: #d4d4d4;
}

/* GEOMETRIC DECORATIVE ELEMENTS */
section .decorative {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  opacity: 0.09;
}

/* UTILITY CLASSES */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-2 { margin-top: 16px; }
.mt-4 { margin-top: 32px; }
.mb-2 { margin-bottom: 16px; }
.mb-4 { margin-bottom: 32px; }

/* RESPONSIVE FONT SCALE */
@media (min-width: 600px) {
  html { font-size: 17px; }
  h1 { font-size: 2.35rem; }
  h2 { font-size: 1.45rem; }
}
@media (min-width: 900px) {
  html { font-size: 18px; }
  h1 { font-size: 2.8rem; }
  h2 { font-size: 1.75rem; }
}
@media (min-width: 1200px) {
  html { font-size: 19px; }
  h1 { font-size: 3.1rem; }
  h2 { font-size: 2rem; }
}

/* FOCUS STATES */
a:focus, button:focus, .btn-primary:focus, .feature-item:focus-within {
  outline: 2.5px solid var(--color-secondary);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px #e6dfcf;
}

/* TRANSITIONS & MICRO INTERACTIONS */
a, button, .feature-item, .btn-primary {
  transition: all 0.20s cubic-bezier(.59,.01,.5,1.37);
}

/* COOKIE BANNER */
.cookie-banner {
  position: fixed;
  left: 0; right: 0;
  bottom: 0;
  z-index: 1400;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 20px 20px 16px 20px;
  background: var(--color-white);
  box-shadow: 0 -7px 30px rgba(26,55,86,0.11);
  border-top: 3.2px solid var(--color-secondary);
  gap: 24px;
  font-size: 1rem;
  animation: slidein-btm .37s cubic-bezier(.5,.75,.34,1);
}
@keyframes slidein-btm {
  from { transform: translateY(100px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.cookie-banner__text {
  flex: 1;
  color: var(--color-body);
  max-width: 540px;
}
.cookie-banner__actions {
  display: flex;
  gap: 13px;
}
.cookie-banner button {
  cursor: pointer;
  border-radius: 6px;
  border: none;
  font-size: 1rem;
  padding: 10px 20px;
  background: var(--color-secondary);
  color: var(--color-white);
  font-weight: 600;
  margin-left: 0;
  transition: background .14s, color .14s;
}
.cookie-banner button:hover, .cookie-banner button:focus {
  background: var(--color-primary);
  color: var(--color-secondary);
}
.cookie-banner .cookie-settings {
  background: var(--color-primary);
  color: var(--color-secondary);
}
.cookie-banner .cookie-settings:hover, .cookie-banner .cookie-settings:focus {
  background: var(--color-secondary);
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}
@media (max-width: 700px) {
  .cookie-banner { flex-direction: column; align-items: flex-start; gap: 12px; }
}

/* COOKIE SETTINGS MODAL */
.cookie-modal-overlay {
  position: fixed;
  z-index: 1500;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(34,58,80,0.64);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.21s;
}
.cookie-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}
.cookie-modal {
  background: var(--color-accent);
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 45px rgba(26,55,86,0.25);
  padding: 36px 32px 28px 32px;
  min-width: 320px;
  max-width: 96vw;
  display: flex;
  flex-direction: column;
  gap: 18px;
  animation: slidein-modal .47s cubic-bezier(.5,.75,.34,1);
}
@keyframes slidein-modal {
  from { transform: translateY(40px) scale(0.95); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}
.cookie-modal h2 {
  font-size: 1.32rem;
  color: var(--color-primary);
  margin-bottom: 17px;
}
.cookie-modal label {
  font-size: 1rem;
  font-family: 'Montserrat', sans-serif;
  color: var(--color-body);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0.7em;
}
.cookie-modal input[type="checkbox"] {
  accent-color: var(--color-secondary);
  height: 18px; width: 18px;
  margin-right: 6px;
}
.cookie-modal .cookie-modal-actions {
  display: flex;
  gap: 14px;
  margin-top: 14px;
  justify-content: flex-end;
}
.cookie-modal-close {
  position: absolute;
  top: 18px; right: 20px;
  background: var(--color-secondary);
  color: var(--color-primary);
  border-radius: 8px;
  font-size: 1.45rem;
  border: none;
  padding: 5px 10px;
  cursor: pointer;
  transition: background .13s, color .13s;
}
.cookie-modal-close:hover, .cookie-modal-close:focus {
  background: var(--color-primary);
  color: var(--color-secondary);
}
.cookie-modal-category {
  margin-bottom: 8px;
}
.cookie-modal-category strong {
  color: var(--color-dark);
  margin-right: 3px;
}
@media (max-width: 540px) {
  .cookie-modal { padding: 18px 7vw 22px 7vw; min-width: 0; }
}

/* GEOMETRIC/STRUCTURED VISUAL DETAILS */
.feature-item, .testimonial-card, .card, .hero .content-wrapper {
  border-radius: 16px 36px 20px 16px;
}

.card, .feature-item, .testimonial-card {
  border-bottom: 6px solid var(--color-secondary);
}

.hero .content-wrapper {
  border-top: 5px solid var(--color-secondary);
  box-shadow: 0 10px 44px rgba(26,55,86, 0.09);
}
h1, h2, h3 {
  font-family: 'Playfair Display', serif;
  text-transform: none;
  letter-spacing: 0.01em;
  font-weight: 700;
}
h1, h2 {
  /* subtle geometric accent */
  position: relative;
}
h1::after, h2::after {
  content: "";
  width: 32px;
  height: 4px;
  display: block;
  margin-top: 7px;
  background: var(--color-secondary);
  border-radius: 2px;
}

/* SHADOW, BORDER, AND EFFECTS */
.card, .feature-item, .testimonial-card {
  box-shadow: 0 4px 16px rgba(26,55,86,.08);
  transition: border-color .15s, box-shadow .21s, transform .14s;
  border: 2.5px solid var(--color-secondary);
}
.card:hover, .feature-item:hover, .testimonial-card:hover {
  border-color: var(--color-primary);
  box-shadow: 0 10px 32px rgba(208,186,139,.15);
  transform: translateY(-3px) scale(1.025);
  z-index: 2;
}

/* ACCESSIBILITY: COLOR CONTRAST IN TESTIMONIALS */
.testimonial-card {
  background: var(--color-accent);
  color: #151015;
}
.testimonial-card p, .testimonial-card span {
  color: #222;
}

/* GEOMETRIC SHAPED BUTTONS */
.btn-primary {
  border-radius: 28px 6px 28px 6px;
}

/* Scrollbar styling for geometric effect */
::-webkit-scrollbar {
  width: 9px; background: #e3e9f1;
}
::-webkit-scrollbar-thumb {
  background: var(--color-secondary);
  border-radius: 6px;
}

/* Hide some sections on print */
@media print {
  header, footer, .btn-primary, .mobile-menu, .cookie-banner, .cookie-modal { display: none !important; }
}
