/* ========================================================================== */
/*  0. CSS RESET & BASE                                                          */
/* ========================================================================== */
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,
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-size: 100%;
  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: #F5F6FA;
  color: #162447;
  font-family: 'Montserrat', Arial, sans-serif;
  min-height: 100vh;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img, svg {
  max-width: 100%;
  display: block;
}
a {
  color: #E43F5A;
  text-decoration: none;
  transition: color .2s;
}
a:hover, a:focus {
  color: #162447;
  text-decoration: underline;
}
ul, ol {
  list-style: disc inside;
  margin-left: 1em;
  margin-bottom: 1em;
  padding: 0;
}
h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  color: #162447;
  margin-bottom: 16px;
  font-weight: bold;
  line-height: 1.1;
  letter-spacing: 0.01em;
}
h1 { font-size: 2.7rem; }
h2 { font-size: 2rem; color: #E43F5A; }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.15rem; }
h5, h6 { font-size: 1rem; }
p, li {
  font-family: 'Montserrat', Arial, sans-serif;
  color: #162447;
  font-size: 1rem;
  margin-bottom: 14px;
  line-height: 1.8;
}
strong {
  font-weight: 700;
}
.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 18px;
}
.content-wrapper {
  width: 100%;
}

/* ========================================================================== */
/*  1. HEADER and MAIN NAV                                                     */
/* ========================================================================== */
header {
  background: #fff;
  box-shadow: 0 2px 18px rgba(33,32,64,0.06);
  position: relative;
  z-index: 30;
  width: 100%;
}
header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 18px 15px 18px;
}
header img[alt="Trame di Stile"] {
  width: 160px;
  margin-right: 20px;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 600;
}
.main-nav a {
  padding: 8px 10px;
  color: #162447;
  border-radius: 5px;
  transition: background .15s, color .2s;
  font-size: 1rem;
}
.main-nav a:hover, .main-nav a:focus {
  background: #E43F5A;
  color: #fff;
}
.main-nav .cta-btn {
  background: #E43F5A;
  color: #fff;
  border-radius: 35px;
  padding: 10px 30px;
  margin-left: 16px;
  font-size: 1.06rem;
  letter-spacing: 0.05em;
  box-shadow: 0 6px 16px 0 rgba(228,63,90,0.08);
  font-family: 'Playfair Display', serif;
  transition: background .18s, color .18s, transform .15s;
  position: relative;
  border: 2px solid #E43F5A;
  outline: none;
}
.main-nav .cta-btn:hover, .main-nav .cta-btn:focus {
  background: #fff;
  color: #E43F5A;
  border-color: #E43F5A;
  transform: scale(1.04) rotate(-2deg);
}

.mobile-menu-toggle {
  display: none;
  background: #E43F5A;
  color: #fff;
  font-size: 2.3rem;
  border: none;
  border-radius: 16px;
  padding: 8px 14px;
  margin-left: 18px;
  cursor: pointer;
  box-shadow: 0 1px 13px rgba(228,63,90,0.15);
  transition: background 0.2s, transform 0.2s;
  z-index: 99;
}
.mobile-menu-toggle:active {
  background: #162447;
  transform: scale(.98) rotate(-6deg);
}

/* ========================================================================== */
/*  2. MOBILE NAV MENU                                                         */
/* ========================================================================== */
.mobile-menu {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: #fff;
  box-shadow: 0 0 28px 0 rgba(33,32,64,0.19);
  z-index: 1200;
  transform: translateX(100vw);
  transition: transform 0.44s cubic-bezier(.86,0,.07,1);
  will-change: transform;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
}
.mobile-menu.open {
  transform: translateX(0);
}
.mobile-menu-close {
  background: none;
  font-size: 2.3rem;
  padding: 13px 20px 13px 12px;
  border: none;
  color: #E43F5A;
  align-self: flex-end;
  cursor: pointer;
  margin: 15px 13px 7px 0;
  border-radius: 50%;
  transition: background .16s;
  z-index: 1202;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  background: #feeff1;
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
  padding: 30px 30px 20px 32px;
  margin-top: 12px;
}
.mobile-nav a {
  font-size: 1.32rem;
  color: #162447;
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.03em;
  border-radius: 6px;
  padding: 13px 8px 13px 6px;
  background: none;
  transition: background .17s, color .17s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: #f5f6fa;
  color: #E43F5A;
}

@media (max-width: 1050px) {
  .main-nav {
    gap: 12px;
  }
}
@media (max-width: 900px) {
  header .container {
    gap: 10px;
    padding-top: 15px;
    padding-bottom: 12px;
  }
}
@media (max-width: 768px) {
  .main-nav {
    display: none;
  }
  .mobile-menu-toggle {
    display: block;
  }
}

/* ========================================================================== */
/*  3. SECTIONS, PAGE STRUCTURE                                                */
/* ========================================================================== */
main {
  width: 100%;
  position: relative;
}
section {
  background: #F5F6FA;
  border-radius: 36px;
  margin-bottom: 60px;
  padding: 40px 20px;
  box-shadow: 0 4px 34px 0 rgba(228,63,90,0.09);
  transition: box-shadow .22s;
  position: relative;
  z-index: 1;
}
@media (max-width: 600px) {
  section {
    border-radius: 24px;
    margin-bottom: 32px;
    padding: 25px 8px;
  }
}

.features-grid, .card-container, .content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}
.features-grid {
  gap: 24px;
}
.card-container {
  gap: 24px;
}
.card {
  background: #fff;
  border-radius: 25px;
  margin-bottom: 20px;
  box-shadow: 0 6px 32px 0 rgba(33,32,64,0.08);
  position: relative;
  display: flex;
  flex-direction: column;
  transition: box-shadow .18s, transform .16s;
  min-width: 252px;
}
.card:hover, .card:focus-within {
  box-shadow: 0 10px 36px 0 rgba(228,63,90,.16);
  transform: translateY(-5px) scale(1.009) rotate(-2deg);
}
.card-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 24px 22px 20px 22px;
  min-height: 120px;
  gap: 8px;
}

.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}
@media (max-width: 768px) {
  .text-image-section {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
}

.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 3px 14px rgba(220,55,85,0.09);
  padding: 28px 26px 24px 22px;
  min-width: 210px;
  flex: 1 1 240px;
  transition: box-shadow .17s, transform .13s;
  min-height: 180px;
  margin-bottom: 20px;
  border: 2px dashed #E43F5A;
  position: relative;
}
.feature-item img {
  width: 41px;
  aspect-ratio: 1 / 1;
  margin-bottom: 10px;
  margin-top: -5px;
  animation: bounceIcon 2.4s infinite cubic-bezier(.5,1.4,.26,0.71);
}
@keyframes bounceIcon {
  0%, 100% { transform: translateY(0); }
  30% { transform: translateY(-12px) scale(1.07); }
  50% { transform: translateY(0); }
  65% { transform: translateY(-7px) scale(1.04); }
  90% { transform: translateY(0); }
}
.feature-item:hover, .feature-item:focus-within {
  box-shadow: 0 8px 38px 0 rgba(220,55,85,.15);
  transform: scale(1.025) rotate(-2deg);
}

/* ========================================================================== */
/*  4. BUTTONS & CTA                                                           */
/* ========================================================================== */
.cta-btn {
  display: inline-block;
  background: #E43F5A;
  color: #fff;
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 1.18rem;
  padding: 14px 38px;
  border-radius: 40px;
  box-shadow: 0 8px 32px 0 rgba(220,55,85,0.13);
  letter-spacing: 0.08em;
  margin-top: 18px;
  text-align: center;
  border: 2px solid #E43F5A;
  outline: none;
  transition: background .15s, color .18s, transform .18s, box-shadow .13s;
  position: relative;
  cursor: pointer;
  text-shadow: 0 2px 4px rgba(228,63,90,0.07);
}
.cta-btn:hover, .cta-btn:focus {
  background: #fff;
  color: #E43F5A;
  border-color: #E43F5A;
  box-shadow: 0 12px 36px 0 rgba(220,55,85,.18);
  transform: scale(1.04) rotate(2deg);
}

button, [type="button"], [type="submit"] {
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  outline: none;
  background: #E43F5A;
  color: #fff;
  border-radius: 18px;
  padding: 12px 26px;
  margin: 10px 6px 0 0;
  min-width: 110px;
  transition: background .13s, box-shadow .13s, color .13s, transform .09s;
  box-shadow: 0 3px 15px 0 rgba(220,55,85,0.08);
  cursor: pointer;
}
button:hover, button:focus, [type="button"]:hover, [type="submit"]:focus {
  background: #162447;
  color: #E43F5A;
  transform: scale(1.03);
}

/* ========================================================================== */
/*  5. TESTIMONIAL CARDS                                                       */
/* ========================================================================== */
.testimonial-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: #fff;
  border-radius: 22px;
  margin-bottom: 20px;
  box-shadow: 0 5px 20px 0 rgba(33,32,64,0.10);
  border-left: 10px solid #E43F5A;
  min-width: 220px;
  max-width: 640px;
  transition: box-shadow .17s;
  font-size: 1.08rem;
}
.testimonial-card p {
  color: #162447;
  font-size: 1.15rem;
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 500;
  margin-bottom: 8px;
}
.testimonial-card span {
  color: #E43F5A;
  font-size: 0.98rem;
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  margin-top: 8px;
}
.testimonial-card strong {
  color: #162447;
}

/* ========================================================================== */
/*  6. FOOTER                                                                  */
/* ========================================================================== */
footer {
  background: #162447;
  color: #fff;
  padding: 47px 0 18px 0;
  box-shadow: 0 -2px 16px 0 rgba(33,32,64,0.13);
  margin-top: 68px;
}
footer .container {
  display: flex;
  flex-direction: column;
  gap: 35px;
  align-items: flex-start;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 23px;
  margin-bottom: 14px;
}
.footer-nav a {
  color: #E43F5A;
  font-family: 'Montserrat', Arial, sans-serif;
  font-size: 1.01rem;
  transition: color 0.18s;
  border-radius: 7px;
  padding: 2px 6px;
}
.footer-nav a:hover, .footer-nav a:focus {
  color: #fff;
  background: #E43F5A;
}
.brand-info, .brand-info p {
  color: #fff;
  font-size: 1rem;
  font-family: 'Montserrat', Arial, sans-serif;
  margin-bottom: 9px;
}
.brand-info img {
  display: inline-block;
  width: 1.1em;
  margin-bottom: -2px;
}
.brand-info a {
  color: #F5F6FA;
  text-decoration: underline;
  transition: color 0.15s;
}
.brand-info a:hover, .brand-info a:focus {
  color: #E43F5A;
}

@media (max-width: 650px) {
  footer .container {
    gap: 16px;
    padding: 0 4px;
  }
  .footer-nav {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 7px;
  }
}

/* ========================================================================== */
/*  7. COOKIE BANNER & MODAL                                                   */
/* ========================================================================== */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1500;
  background: #fff;
  color: #162447;
  box-shadow: 0 -3px 34px 0 rgba(33,32,64,0.08);
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  padding: 24px 20px 18px 22px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
  font-size: 1.01rem;
  max-width: 745px;
  margin: 0 auto;
  animation: bannerFloatIn .8s cubic-bezier(.81,.26,.25,.91);
}
@keyframes bannerFloatIn {
  0% { transform: translateY(100%); opacity:0; }
  60% { opacity:.7; }
  100% { transform: translateY(0); opacity:1; }
}
.cookie-banner p {
  flex: 2 1 320px;
  margin-bottom: 0;
  font-size: 1.02rem;
}
.cookie-banner .banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.cookie-banner button {
  background: #E43F5A;
  color: #fff;
  border-radius: 22px;
  border: none;
  padding: 10px 17px;
  font-size: 1.04rem;
  font-family: 'Montserrat', Arial, sans-serif;
  margin: 0 3px;
  min-width: 110px;
  cursor: pointer;
  box-shadow: 0 2px 9px 0 rgba(228,63,90,0.10);
  transition: background .17s;
}
.cookie-banner button.cookie-settings-btn {
  background: #fff;
  color: #E43F5A;
  border: 2px solid #E43F5A;
}
.cookie-banner button:hover, .cookie-banner button:focus {
  background: #162447;
  color: #fff;
}
.cookie-banner button.cookie-settings-btn:hover, .cookie-banner button.cookie-settings-btn:focus {
  background: #E43F5A;
  color: #fff;
  border-color: #E43F5A;
}
@media (max-width: 650px) {
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px 7px 13px 10px;
    border-radius: 18px 18px 0 0;
    max-width: 99vw;
  }
}

.cookie-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(30,26,40,0.29);
  z-index: 1700;
  display: none;
  align-items: center;
  justify-content: center;
}
.cookie-modal-overlay.open {
  display: flex;
  animation: modalOverlayIn .33s;
}
@keyframes modalOverlayIn {
  0% { opacity: 0; }
  100% { opacity: 1; }
}
.cookie-modal {
  background: #fff;
  border-radius: 20px;
  max-width: 420px;
  width: 93vw;
  padding: 32px 28px 32px 28px;
  box-shadow: 0 12px 52px 0 rgba(228,63,90,.14);
  animation: slideInCookieModal .62s cubic-bezier(.77,-0.01,.18,1.04);
  position: relative;
  z-index: 1701;
}
@keyframes slideInCookieModal {
  0% { transform: translateY(80px) scale(.86); opacity:0; }
  70% { opacity:.72; }
  100% { transform: translateY(0) scale(1); opacity:1; }
}
.cookie-modal h3 {
  font-size: 1.3rem;
  color: #E43F5A;
  margin-bottom: 18px;
}
.cookie-modal .cookie-categories {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 20px;
}
.cookie-category {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 8px 0 8px 0;
}
.cookie-category label {
  font-family: 'Montserrat', Arial, sans-serif;
  color: #162447;
  font-size: 1.01rem;
}
.cookie-category input[type=checkbox] {
  accent-color: #E43F5A;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  cursor: pointer;
}
.cookie-category input[type=checkbox]:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.cookie-modal .cookie-modal-actions {
  display: flex;
  gap: 20px;
  width: 100%;
  justify-content: flex-end;
  margin-top: 15px;
}
.cookie-modal .btn-modal-cancel {
  background: #fff;
  color: #E43F5A;
  border: 2px solid #E43F5A;
  border-radius: 20px;
}
.cookie-modal .btn-modal-cancel:hover, .cookie-modal .btn-modal-cancel:focus {
  background: #E43F5A;
  color: #fff;
}
.cookie-modal-close {
  position: absolute;
  top: 15px;
  right: 17px;
  font-size: 1.7rem;
  background: none;
  border: none;
  color: #E43F5A;
  padding: 0;
  cursor: pointer;
  z-index: 1720;
}
.cookie-modal-close:hover, .cookie-modal-close:focus {
  color: #162447;
}

/* ========================================================================== */
/*  8. RESPONSIVE STYLES                                                       */
/* ========================================================================== */
@media (max-width: 920px) {
  h1 { font-size: 2.1rem; }
  h2 { font-size: 1.55rem; }
  .feature-item {
    min-width: 160px;
    padding: 18px 12px 16px 12px;
  }
}
@media (max-width: 700px) {
  .container { padding: 0 6px; }
  h1 { font-size: 1.45rem; }
  h2 { font-size: 1.04rem; }
  header img[alt="Trame di Stile"] {
    width: 120px;
  }
  section {
    padding: 16px 2px;
  }
  .testimonial-card {
    max-width: 97vw;
    padding: 14px 6px 12px 11px;
    border-radius: 14px;
  }
  .feature-item {
    min-width: 100px;
    font-size: .95em;
    padding: 10px 6px;
    border-radius: 13px;
  }
}

/* Responsive flex column for content grids on mobile */
@media (max-width: 950px) {
  .features-grid, .card-container, .content-grid {
    flex-direction: column;
    gap: 18px;
  }
}

/* ========================================================================== */
/*  9. UTILITIES & MICRO-INTERACTIONS                                          */
/* ========================================================================== */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-thumb {
  background: #F5F6FA;
  border-radius: 6px;
}
::-webkit-scrollbar-track {
  background: #fff;
}

.highlight, mark {
  background-color: #fff7d6;
  padding: 0 3px 1px 3px;
  border-radius: 4px;
}

/* Decorative playful dots (optional on cta or section) */
.playful-dot {
  position: absolute;
  border-radius: 50%;
  opacity: 0.17;
  pointer-events: none;
  z-index: 0;
  animation: swayDot 6s infinite alternate cubic-bezier(.5,1.4,.26,0.71);
}
@keyframes swayDot {
  0% { transform: translateY(0); }
  100% { transform: translateY(7px) scale(.97); }
}

/* Section divider ribbons, for playful separation */
.section-divider {
  width: 70px;
  height: 7px;
  background: #E43F5A;
  border-radius: 7px;
  margin: 19px auto 14px auto;
  display: block;
  opacity: 0.74;
  animation: wiggleDivider 2.7s infinite linear;
}
@keyframes wiggleDivider {
  0% { transform: rotate(0deg); }
  20% { transform: rotate(-3deg); }
  50% { transform: rotate(2deg); }
  80% { transform: rotate(-2deg); }
  100% { transform: rotate(0deg); }
}

@media (max-width:500px) {
  .footer-nav, .brand-info { font-size: 14px; }
}

/* ========================================================================== */
/* 10. FORMS & CONTACT BLOCKS                                                  */
/* ========================================================================== */
.contact-info-block {
  background: #fff;
  padding: 22px 16px 22px 22px;
  border-radius: 19px;
  box-shadow: 0 2px 22px 0 rgba(33,32,64,0.13);
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
  min-width: 220px;
  font-size: 1.07rem;
  position: relative;
}
.contact-info-block p {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 7px 0;
}
.contact-info-block img {
  width: 30px;
  height: 30px;
  margin-bottom: 0;
}

/* ========================================================================== */
/* 11. FUN FONTS IMPORT                                                        */
/* ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&family=Playfair+Display:wght@700;900&display=swap');

/* END OF STYLE.CSS */
