/* ===== DIALOG RESET (korrekte Zentrierung) ===== */

dialog{
  position:fixed;
  inset:0;
  margin:0;
  padding:0;
  border:0;
  background:none;
  max-width:none;
  max-height:none;

  width:100%;
  height:100dvh;
  overflow:hidden;
}

dialog,
dialog * ,
dialog *::before,
dialog *::after{
  box-sizing:border-box;
}

dialog::backdrop{
  background:rgba(0,0,0,.45);
  backdrop-filter: blur(10px);
  animation:fade .18s ease;
}

/* echtes Zentrieren */
dialog[open]{
  display:block;
}

/* Desktop zentriert */
.dialog-card{
  position:absolute;
  top:50%;
  left:50%;
  transform:translate(-50%,-50%);
}

/* ================= CARD ================= */

.dialog-card{
  width:min(100%,420px);
  background:rgba(25,28,35,.92);
  backdrop-filter: blur(24px);
  border:1px solid rgba(255,255,255,.08);
  border-radius:22px;
  padding:1.6rem;
  box-shadow:0 30px 90px rgba(0,0,0,.65);
  color:#e8ecf1;
  animation:pop .16s ease;
  font-family:Nunito,system-ui;
}

/* TEXT */
h3{margin:.2rem 0 .4rem;font-size:1.25rem;text-align:center;}
.muted{color:#9aa4b2}

.email-preview{
  margin:.8rem 0 1rem;
  padding:.75rem 1rem;
  border-radius:14px;
  background:#0c0e12;
  font-family:monospace;
  word-break:break-all;
  font-size:.95rem;
}

.logo {
  font-weight:bold;
  margin:0 5px;
  -webkit-text-stroke:4px white; 
  paint-order:stroke fill;
}

.schwarz {
  color:black;
}

.rot {
  color:red;
}

/* CHECKBOX */
.check{
  display:flex;
  gap:.7rem;
  margin:1rem 0 1.3rem;
  line-height:1.4;
}

/* BUTTONS */
.actions{
  display:flex;
  justify-content:flex-end;
  gap:.6rem;
}

.btn,.btn-primary{
  padding:.75rem 1.25rem;
  border-radius:14px;
  border:0;
  cursor:pointer;
  font-size:.95rem;
}

.btn{
  background:#2a2f39;
  color:#fff;
}

.btn-primary{
  background:linear-gradient(135deg,#ff5858,#ff2d2d);
  color:#fff;
  font-weight:600;
}

/* ================= MOBILE = BOTTOM SHEET ================= */

@media (max-width:600px){

  .dialog-card{
    position:absolute;
    left:0;
    right:0;
    bottom:0;
    top:auto;
    transform:none;

    width:100%;
    max-width:100%;
    border-radius:22px 22px 0 0;

    padding:1.4rem 1.2rem calc(1.6rem + env(safe-area-inset-bottom));
    animation:sheet .22s cubic-bezier(.2,.8,.2,1);
  }

  .actions{
    flex-direction:column-reverse;
  }

  .btn,.btn-primary{
    width:100%;
    padding:1rem;
    font-size:1rem;
  }
}

/* ANIMATIONS */
@keyframes pop{from{transform:scale(.92);opacity:0}}
@keyframes sheet{from{transform:translateY(40px);opacity:0}}
@keyframes fade{from{opacity:0}}

.handle{
  width:42px;
  height:4px;
  border-radius:3px;
  background:#3a3f4b;
  margin:0 auto .8rem;
}