.diac-demo { margin: 0; color: var(--ex-color-ink); background: var(--ex-color-paper); font-family: var(--ex-font-sans); }
.diac-header, .diac-header *, .diac-header *::before, .diac-header *::after { box-sizing: border-box; }
body .diac-header a { color: inherit; text-decoration: none; }
.diac-icon { display: block; width: 1em; height: 1em; }

.diac-header {
  width: min(calc(100% - 28px), var(--ex-content-max));
  margin: 9px auto 0;
  padding-bottom: 10px;
  font-size: 16px;
}
.diac-header .diac-icon { flex: 0 0 auto; }
.diac-header__top {
  min-height: 38px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border-top: var(--ex-border-thin);
  border-bottom: var(--ex-border-thin);
}
.diac-header__utility, .diac-header__account, .diac-header__social { display: flex; align-items: center; }
.diac-header__utility { gap: 37px; padding-left: 8px; }
.diac-header__utility-link, .diac-header__account a { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
/* Colore, carattere e pulsanti della testata sono definiti qui. */
.diac-header { color: var(--ex-color-ink); font-family: var(--ex-font-sans); }
body .diac-header button { font: inherit; color: inherit; }
.diac-header .diac-header__utility-link { padding: 0; border: 0; background: none; cursor: pointer; }
.diac-header__account { justify-content: flex-end; gap: 38px; padding-right: 13px; }
.diac-header__account--logged-in { gap: 28px; }
.diac-header__greeting { white-space: nowrap; }
.diac-header__social { gap: 20px; }
.diac-header__social a {
  width: 23px; height: 23px; display: grid; place-items: center;
  font-size: 22px;
}
.diac-header__social a[aria-label="YouTube"] { width: 27px; }
.diac-header .diac-header__menu-button { display: none; border: 0; padding: 10px; background: var(--ex-color-muted); color: #000; cursor: pointer; }

.diac-header__brand { width: 500px; margin: 20px auto; display: block; }
.diac-header__brand img { display: block; width: 100%; height: auto; }
.diac-header__bottom {
  min-height: 32px;
  display: flex;
  align-items: center;
  border-top: var(--ex-border-thin);
  border-bottom: var(--ex-border-thin);
  text-transform: uppercase;
}
.diac-header__primary { flex: 1; }
.diac-header__primary-list { margin: 0; padding: 0; display: flex; justify-content: space-around; align-items: center; list-style: none; }
.diac-header__primary a { white-space: nowrap; }
.diac-header__search { display: inline-flex; align-items: center; gap: 4px; padding: 0 18px 0 15px; }
.diac-header__bottom time { padding: 5px 18px 5px 22px; border-left: var(--ex-border-thin); white-space: nowrap; text-transform: none; }
.diac-header__mobile-meta, .diac-header__mobile-nav { display: none; }

.diac-topics {
  width: min(75vw, 1440px);
  max-width: none;
  max-height: calc(100vh - 80px);
  margin: auto;
  padding: 28px 70px 48px;
  border: 0;
  color: #111;
  background: #fff;
  font-family: var(--ex-font-sans);
  overflow: auto;
}
.diac-topics::backdrop { background: rgb(0 0 0 / 80%); }
.diac-topics .diac-topics__close {
  position: absolute;
  top: 15px;
  right: 20px;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #000;
  font: 28px/1 Arial, sans-serif;
  cursor: pointer;
}
.diac-topics h2 { margin: 0 0 25px; text-align: center; font: 700 36px/1.2 "Playfair Display", Georgia, "Times New Roman", serif; }
.diac-topics__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 55px; }
.diac-topics ul { margin: 0; padding: 0; list-style: none; text-align: center; }
.diac-topics li { margin: 0; }
body .diac-topics a { display: block; padding: 10px 4px; color: inherit; text-decoration: none; font-size: 16px; line-height: 1.25; }
.diac-topics a:hover, .diac-topics a:focus-visible { text-decoration: underline; }

.diac-login {
  width: 640px;
  max-width: calc(100% - 28px);
  margin: auto;
  padding: 36px 40px 42px;
  border: 0;
  color: #111;
  background: #fff;
  font-family: Arial, Helvetica, sans-serif;
  overflow: visible;
}
.diac-login, .diac-login *, .diac-login *::before, .diac-login *::after { box-sizing: border-box; }
.diac-login::backdrop { background: rgb(0 0 0 / 80%); }
.diac-login .diac-login__close {
  position: absolute;
  top: 14px;
  right: 18px;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #000;
  font: 26px/1 Arial, sans-serif;
  cursor: pointer;
}
.diac-login h2 {
  margin: 0 0 12px;
  font: 700 34px/1.15 "Playfair Display", Georgia, "Times New Roman", serif;
}
.diac-login__form { display: grid; }
.diac-login__form label { margin: 0 0 6px; color: #4b4b4b; font-size: 14px; line-height: 1.2; }
.diac-login__form input {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 1px solid #708090;
  border-radius: 3px;
  outline-offset: 2px;
  background: #fff;
  color: #222;
  font: 14px Arial, Helvetica, sans-serif;
}
.diac-login__form > input { margin-bottom: 8px; }
.diac-login__password { position: relative; display: block; }
.diac-login .diac-login__password-toggle {
  position: absolute;
  top: 0;
  right: 4px;
  width: 42px;
  height: 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.diac-login__password-toggle img { width: 20px; height: 20px; }
.diac-login .diac-login__submit {
  width: 94px;
  height: 40px;
  margin-top: 10px;
  border: 0;
  background: #f2b817;
  color: #000;
  font: 14px Arial, Helvetica, sans-serif;
  cursor: pointer;
}
.diac-login__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 21px;
}
body .diac-login__actions a { display: inline-flex; align-items: center; gap: 5px; color: #111; text-decoration: none; font-size: 15px; }
.diac-login__actions img { width: 14px; height: 14px; }

@media (max-width: 767px) {
  .diac-header { width: 100%; margin-top: 0; }
  .diac-header__top { min-height: 69px; display: flex; justify-content: space-between; border-top: 0; }
  .diac-header__utility { padding-left: 9px; }
  .diac-header .diac-header__menu-button { display: grid; place-items: center; width: 36px; height: 37px; }
  .diac-header__menu-button .diac-icon { width: 21px; height: 21px; }
  .diac-header__desktop-utility, .diac-header__social--desktop { display: none; }
  .diac-header__account { gap: 18px; padding-right: 9px; font-size: 14px; }
  .diac-header__account--logged-in { gap: 18px; }
  .diac-header__account a { gap: 4px; }
  .diac-header__account .diac-icon { width: 15px; height: 15px; }
  .diac-header__brand { width: 226px; margin: 10px auto 9px; }
  .diac-header__bottom { display: none; }
  .diac-header__mobile-meta { min-height: 47px; display: flex; align-items: center; justify-content: space-between; border-top: var(--ex-border-thin); border-bottom: var(--ex-border-thin); }
  .diac-header__mobile-meta .diac-header__social { gap: 17px; padding-left: 28px; }
  .diac-header__mobile-meta time { align-self: stretch; display: flex; align-items: center; padding: 0 18px; border-left: var(--ex-border-thin); font-size: 14px; white-space: nowrap; }
  .diac-header__mobile-nav { padding: 8px 18px 14px; border-bottom: var(--ex-border-thin); background: #fff; }
  .diac-header__mobile-nav:not([hidden]) { display: grid; }
  .diac-header__mobile-list { margin: 0; padding: 0; list-style: none; }
  .diac-header__mobile-list li { margin: 0; }
  .diac-header__mobile-nav a { padding: 10px 0; border-bottom: 1px solid #ddd; text-transform: uppercase; font-size: 14px; }
  .diac-header__mobile-list a { display: block; }
  .diac-header .diac-header__mobile-nav button { padding: 10px 0; border: 0; border-bottom: 1px solid #ddd; background: transparent; text-align: left; text-transform: uppercase; font-size: 14px; cursor: pointer; }
  .diac-topics { width: calc(100% - 28px); max-height: calc(100vh - 28px); padding: 22px 24px 30px; }
  .diac-topics h2 { margin-bottom: 15px; font-size: 30px; }
  .diac-topics__grid { grid-template-columns: 1fr; gap: 0; }
  body .diac-topics a { padding-block: 8px; }

  .diac-login {
    width: 100%;
    max-width: none;
    padding: 34px 35px 38px;
  }
  .diac-login .diac-login__close { top: 14px; right: 13px; }
  .diac-login h2 { margin-bottom: 12px; font-size: 30px; }
  .diac-login__form input, .diac-login .diac-login__password-toggle { height: 42px; }
  .diac-login .diac-login__submit { width: 82px; height: 36px; margin-top: 8px; }
  .diac-login__actions { align-items: flex-start; flex-direction: column; gap: 23px; margin-top: 20px; }
  body .diac-login__actions a { font-size: 14px; }
}

@media (max-width: 350px) {
  .diac-header__account { gap: 10px; }
  .diac-header__mobile-meta .diac-header__social { gap: 10px; padding-left: 14px; }
  .diac-header__mobile-meta time { padding-inline: 12px; }
}
