/* =======================================================
   Drupal Brand Theme Override
   Fonts: Noto Sans (self-hosted, SIL OFL)
   Colors: official Drupal brand palette from new.drupal.org
   ======================================================= */

/* --- @font-face: Ubuntu (per logo/header) --- */

@font-face {
  font-family: "Ubuntu";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/ubuntu-400-regular.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Ubuntu";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/ubuntu-500-regular.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* --- @font-face: Noto Sans --- */

@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-300-regular-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-300-regular-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-400-regular-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-400-regular-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Noto Sans";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-400-italic-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-400-italic-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-500-regular-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-500-regular-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-700-regular-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-700-regular-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Noto Sans";
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-700-italic-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Sans";
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/noto-sans-700-italic-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* --- Font variables --- */
:root {
  --default-font: "Noto Sans", system-ui, sans-serif;
  --heading-font: "Noto Sans", system-ui, sans-serif;
  --nav-font:     "Noto Sans", system-ui, sans-serif;
}

/* --- Drupal brand color palette (from new.drupal.org) --- */
:root {
  --background-color:  #ffffff;
  --default-color:     #323946;   /* drupal-gray-darker  — body text */
  --heading-color:     #12285f;   /* drupal-navy         — headings  */
  --accent-color:      #009cde;   /* drupal-blue         — CTA, links, buttons */
  --surface-color:     #f8f9fc;   /* drupal-gray-mildest — card bg   */
  --contrast-color:    #ffffff;

  --nav-color:                      #12285f;
  --nav-hover-color:                #009cde;
  --nav-mobile-background-color:    #ffffff;
  --nav-dropdown-background-color:  #ffffff;
  --nav-dropdown-color:             #323946;
  --nav-dropdown-hover-color:       #009cde;
}

/* Dark background sections (hero, CTA) → Drupal dark navy */
.dark-background {
  --background-color: #091942;   /* drupal-dark-navy */
  --default-color:    #ffffff;
  --heading-color:    #ffffff;
  --surface-color:    #12285f;
  --contrast-color:   #ffffff;
}

/* Light background sections → Drupal very light gray */
.light-background {
  --background-color: #f8f9fc;   /* drupal-gray-mildest */
}

/* Typography */
body {
  font-family: var(--default-font);
  font-weight: 400;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  font-weight: 700;
  color: var(--heading-color);
}

/* Headings size scale (da new.drupal.org) */
h1 { font-size: 2.027rem; }
h2 { font-size: 1.802rem; }
h3 { font-size: 1.602rem; }
h4 { font-size: 1.424rem; }
h5 { font-size: 1.266rem; }
h6 { font-size: 1.125rem; }

/* Header logo */
.header .logo {
  color: #284544;
}
.header .logo:hover {
  color: var(--accent-color);
}
.header-drop {
  height: 36px;
  width: auto;
  color: #284544;   /* il path SVG usa fill="currentColor" */
}
.site-name {
  font-family: "Ubuntu", system-ui, sans-serif;
  font-weight: 500;
  font-size: 1.6rem;
  line-height: 1;
  color: #284544;
  white-space: nowrap;
}
.header .logo:hover .site-name,
.header .logo:hover .header-drop {
  color: var(--accent-color);
  filter: none;
}
.header-logo-img img {
  height: 55px;
  width: auto;
}

/* Page title banner (pagine interne) */
.page-title .breadcrumbs {
  display: inline-block;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 20px;
  padding: 3px 14px;
}

.page-title h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 14px;
}

.page-title {
  padding-bottom: 12px;
}

.page-title {
  background-image: repeating-linear-gradient(
    45deg,
    rgba(0, 156, 222, 0.5),
    rgba(0, 156, 222, 0.5) 12px,
    rgba(204, 237, 249, 1) 12px,
    rgba(204, 237, 249, 1) 58px
  );
  background-color: transparent;
}

/* Hero homepage — titolo in Ubuntu */
.hero h1 {
  font-family: "Ubuntu", system-ui, sans-serif;
  font-weight: 500;
}

/* Section title (h2 e sottotitolo p) */
.section-title h2 {
  font-size: 2rem;
  font-weight: 700;
}
.section-title p {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-color);
  font-weight: 500;
}

/* Cookie consent banner GDPR */
#cookie-consent-banner {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: #12285f;   /* drupal-navy */
  color: #ffffff;
  padding: 14px 20px;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.25);
}
.cc-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.cc-text {
  flex: 1;
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.5;
}
.cc-link {
  color: #009cde;
  text-decoration: underline;
  white-space: nowrap;
}
.cc-link:hover {
  color: #ccedfc;
}
.cc-buttons {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.cc-btn {
  padding: 7px 20px;
  border-radius: 4px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  line-height: 1.4;
  transition: background 0.2s, border-color 0.2s;
}
.cc-btn-accept {
  background: #009cde;
  color: #ffffff;
  border-color: #009cde;
}
.cc-btn-accept:hover {
  background: #007bb0;
  border-color: #007bb0;
}
.cc-btn-refuse {
  background: transparent;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.5);
}
.cc-btn-refuse:hover {
  border-color: #ffffff;
}
@media (max-width: 576px) {
  .cc-buttons {
    width: 100%;
    justify-content: flex-end;
  }
}

/* Titolo ridondante nel corpo del post (visivo, non heading — h1 è nel banner) */
.post-article-title {
  display: none; /* il titolo è già nell'h1 del banner page-title */
}

/* Data nelle card articoli in homepage */
.post-date-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent-color);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 10px;
}
.post-date-meta i {
  font-size: 0.9rem;
}

/* Service cards e post cards — immagini uniformi (equivalente scale_and_crop di Drupal) */
.service-item .img,
.post-img {
  height: 200px;
  overflow: hidden;
}
.service-item .img img,
.post-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
