@import url("./typography-gazzetta.css?v=20260915-gazzetta1");

.deu-chat-launcher,
.deu-chat,
.deu-chat * {
  box-sizing: border-box;
}

/* Hero CTA kept in markup for easy future reactivation. */
.floating-cta {
  display: none !important;
}

.deu-chat-launcher {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 10020;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  background: rgba(8,8,8,.88);
  color: #fff;
  font: 600 10px/1 "Inter", Arial, sans-serif;
  letter-spacing: .08em;
  cursor: pointer;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 12px 30px rgba(0,0,0,.32);
}

.deu-chat-launcher__pulse {
  position: absolute;
  inset: -1px;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: inherit;
  animation: deuChatPulse 2.2s ease-out infinite;
}

@keyframes deuChatPulse {
  0% { transform: scale(.92); opacity: 0; }
  30% { opacity: .65; }
  100% { transform: scale(1.45); opacity: 0; }
}

.deu-chat {
  position: fixed;
  inset: 0;
  z-index: 10030;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s ease, visibility .28s ease;
}

.deu-chat.is-open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.deu-chat__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0,0,0,.58);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.deu-chat__panel {
  position: absolute;
  top: 18px;
  right: 18px;
  bottom: 18px;
  width: min(470px, calc(100vw - 36px));
  display: grid;
  grid-template-rows: auto minmax(0,1fr) auto auto auto;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(8,8,8,.97);
  color: #fff;
  box-shadow: 0 20px 80px rgba(0,0,0,.58);
  transform: translateX(24px);
  transition: transform .35s cubic-bezier(.2,.8,.2,1);
}

.deu-chat.is-open .deu-chat__panel { transform: translateX(0); }

.deu-chat__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.deu-chat__kicker,
.deu-chat__status,
.deu-chat-message > span {
  font: 500 9px/1.3 "Inter", Arial, sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.deu-chat__kicker { color: rgba(255,255,255,.48); }
.deu-chat__header h2 {
  margin: 5px 0 0;
  font-size: 31px;
  line-height: 1;
  letter-spacing: -.035em;
  font-weight: 500;
}

.deu-chat__feed {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
  overflow-y: auto;
  padding: 20px;
}

.deu-chat-message {
  max-width: 84%;
  padding: 12px 13px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.025);
}

.deu-chat-message--user {
  align-self: flex-end;
  border-color: rgba(255,255,255,.18);
  background: rgba(255,255,255,.05);
}

.deu-chat-message > span {
  display: block;
  margin-bottom: 5px;
  color: rgba(255,255,255,.34);
}

.deu-chat-message p {
  margin: 0;
  color: rgba(255,255,255,.84);
  font: 400 13px/1.5 "Inter", Arial, sans-serif;
  white-space: pre-wrap;
}

.deu-chat-message--processing {
  min-width: 168px;
  border-color: rgba(255,255,255,.11);
  background: rgba(255,255,255,.032);
  animation: deuChatProcessingEnter .22s cubic-bezier(.2,.8,.2,1) both;
}

.deu-chat-processing {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 20px;
}

.deu-chat-processing__label {
  color: rgba(255,255,255,.62);
  font: 400 13px/1.5 "Inter", Arial, sans-serif;
}

.deu-chat-processing__dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 10px;
}

.deu-chat-processing__dots i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(255,255,255,.78);
  opacity: .22;
  transform: translateY(0);
  animation: deuChatProcessingDot 1.05s ease-in-out infinite;
}

.deu-chat-processing__dots i:nth-child(2) { animation-delay: .14s; }
.deu-chat-processing__dots i:nth-child(3) { animation-delay: .28s; }

.deu-chat-message--resolved {
  animation: deuChatResponseResolve .2s ease-out both;
}

.deu-chat.is-busy .deu-chat__form > button,
.deu-chat__form > button:disabled {
  opacity: .42;
  cursor: progress;
}

.deu-chat__suggestions button:disabled {
  opacity: .32;
  cursor: progress;
}

@keyframes deuChatProcessingEnter {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes deuChatProcessingDot {
  0%, 60%, 100% { opacity: .2; transform: translateY(0); }
  30% { opacity: .95; transform: translateY(-2px); }
}

@keyframes deuChatResponseResolve {
  from { opacity: .58; }
  to { opacity: 1; }
}

.deu-chat__suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 0 20px 14px;
}

.deu-chat__suggestions button {
  padding: 7px 9px;
  border: 1px solid rgba(255,255,255,.12);
  background: transparent;
  color: rgba(255,255,255,.58);
  font: 500 10px/1.2 "Inter", Arial, sans-serif;
  cursor: pointer;
}

.deu-chat__suggestions button:hover {
  color: #fff;
  border-color: rgba(255,255,255,.3);
}

.deu-chat__form {
  display: grid;
  grid-template-columns: 1fr 48px;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid rgba(255,255,255,.08);
}

.deu-chat__form label { min-width: 0; }
.deu-chat__form textarea {
  width: 100%;
  min-height: 48px;
  max-height: 140px;
  resize: none;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.025);
  color: #fff;
  font: 400 13px/1.45 "Inter", Arial, sans-serif;
  outline: none;
}

.deu-chat__form textarea:focus { border-color: rgba(255,255,255,.35); }
.deu-chat__form > button {
  border: 1px solid rgba(255,255,255,.85);
  background: #f3f3f1;
  color: #080808;
  font-size: 20px;
  cursor: pointer;
  transition: opacity .18s ease;
}

.deu-chat__status {
  margin: 0;
  padding: 0 20px 14px;
  color: rgba(255,255,255,.28);
}

.deu-chat__sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

body.deu-chat-open { overflow: hidden !important; }

@media (max-width: 640px) {
  .deu-chat-launcher {
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
    width: 52px;
    height: 52px;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    box-shadow: 0 8px 18px rgba(0,0,0,.28);
  }

  .deu-chat-launcher__pulse {
    animation: none;
    opacity: .35;
  }

  .deu-chat,
  .deu-chat__panel {
    transition-duration: .14s;
  }

  .deu-chat__backdrop {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background: rgba(0,0,0,.9);
  }

  .deu-chat__panel {
    box-shadow: none;
  }

  .deu-chat__panel {
    top: max(8px, env(safe-area-inset-top));
    right: max(8px, env(safe-area-inset-right));
    bottom: max(8px, env(safe-area-inset-bottom));
    left: max(8px, env(safe-area-inset-left));
    width: auto;
  }

  .deu-chat__header,
  .deu-chat__feed { padding: 16px; }
  .deu-chat__suggestions { padding: 0 16px 12px; }
  .deu-chat__form { padding: 12px 16px; }
}

@media (max-width: 760px) {
  body.is-content-panel-open .deu-chat-launcher {
    display: none;
  }

  .content-panel__surface--contact .contact-media {
    min-height: 12.5rem;
  }

  .content-panel__surface--contact .contact-media__video {
    display: block !important;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(.78) contrast(1.04) saturate(.9);
    transform: none;
  }

  .content-panel__surface--contact .contact-form {
    gap: .52rem;
    overflow: visible;
  }

  .content-panel__surface--contact .contact-form textarea {
    min-height: 8.5rem;
    height: 8.5rem;
    max-height: 8.5rem;
  }

  .content-panel__surface--contact .contact-form__footer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    gap: .55rem;
    margin-top: .25rem;
    padding-bottom: calc(.35rem + env(safe-area-inset-bottom));
  }

  .content-panel__surface--contact .contact-form__footer button {
    display: inline-flex !important;
    width: 100%;
    min-height: 3rem;
    align-items: center;
    justify-content: space-between;
    visibility: visible !important;
    opacity: 1;
    position: relative;
    z-index: 2;
  }
}

/* Contact starts visually neutral; emphasis appears only on interaction. */
.hero-node--featured {
  border-color: rgba(179, 194, 216, 0.2);
  background: rgba(11, 13, 16, 0.82);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.028),
    0 0.8rem 2rem rgba(0,0,0,0.28);
}

.hero-node--featured::before {
  background: linear-gradient(90deg, rgba(160, 180, 205, 0.12), rgba(160, 180, 205, 0.025) 62%, transparent);
}

@media (min-width: 901px) {
  .hero-node--chat {
    --node-x: 14%;
    --node-y: 8%;
  }

  .hero-node--works {
    --node-x: 5%;
    --node-y: 58%;
  }

  .hero-node--launcher {
    --node-x: 50%;
    --node-y: 84%;
  }

  .hero-node--contact {
    --node-x: 87%;
    --node-y: 8%;
  }

  .hero-node--about {
    --node-x: 97%;
    --node-y: 59%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .deu-chat-launcher__pulse,
  .deu-chat-processing__dots i,
  .deu-chat-message--processing,
  .deu-chat-message--resolved {
    animation: none;
  }

  .deu-chat-processing__dots i { opacity: .62; }
  .deu-chat,
  .deu-chat__panel { transition-duration: .001ms; }
}


/* Integrated modal close cell — 2026-09-21 */
.deu-chat__header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 3.5rem;
  height: 3.5rem;
  min-height: 3.5rem;
  align-items: stretch;
  gap: 0;
  padding: 0;
}

.deu-chat__header > div {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.2rem 1.25rem;
}

.deu-chat__close.modal-close {
  --modal-close-size: 3.5rem;
  --modal-close-line: rgba(255, 255, 255, 0.08);
  width: 3.5rem;
  height: 3.5rem;
}

@media (max-width: 640px) {
  .deu-chat__header {
    grid-template-columns: minmax(0, 1fr) 3.25rem;
    height: 3.25rem;
    min-height: 3.25rem;
    padding: 0;
  }

  .deu-chat__header > div {
    padding: 0.14rem 1rem;
  }

  .deu-chat__close.modal-close {
    --modal-close-size: 3.25rem;
    width: 3.25rem;
    height: 3.25rem;
  }
}
