/* ─────────── GodsOlympus · Notifications ─────────── */
:root{
  --notif-bg:#f8efd9;
  --notif-bg-2:#f1e2b6;
  --notif-edge:rgba(170,126,59,.55);
  --notif-edge-soft:rgba(170,126,59,.22);
  --notif-text:#2a1f10;
  --notif-text-soft:rgba(42,31,16,.62);
  --notif-gold:#aa7e3b;
  --notif-gold-l:#e7c989;
  --notif-gold-d:#7a5421;
  --notif-shadow:0 18px 44px -16px rgba(122,84,33,.55),0 4px 14px -4px rgba(122,84,33,.25),inset 0 1px 0 rgba(255,255,255,.55);
  --notif-grad-gold:linear-gradient(135deg,#fff5d9 0%,#f1c279 38%,#aa7e3b 72%,#7a5421 100%);
  --notif-meander:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 8'><path d='M0 7 L0 2 L4 2 L4 5 L8 5 L8 0 L12 0 L12 5 L16 5 L16 2 L20 2 L20 5 L24 5' fill='none' stroke='%23aa7e3b' stroke-width='1' stroke-opacity='.55'/></svg>");
}
html.dark{
  --notif-bg:#19120a;
  --notif-bg-2:#231811;
  --notif-edge:rgba(231,201,137,.55);
  --notif-edge-soft:rgba(231,201,137,.18);
  --notif-text:#f4e8cf;
  --notif-text-soft:rgba(244,232,207,.62);
  --notif-gold:#e7c989;
  --notif-gold-l:#fff5d9;
  --notif-gold-d:#aa7e3b;
  --notif-shadow:0 22px 52px -18px rgba(0,0,0,.85),0 4px 16px -4px rgba(0,0,0,.55),inset 0 1px 0 rgba(255,245,217,.08);
  --notif-meander:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 8'><path d='M0 7 L0 2 L4 2 L4 5 L8 5 L8 0 L12 0 L12 5 L16 5 L16 2 L20 2 L20 5 L24 5' fill='none' stroke='%23e7c989' stroke-width='1' stroke-opacity='.55'/></svg>");
}

.notif-stack{
  position:fixed;
  top:max(1.2rem, calc(env(safe-area-inset-top, 0px) + 1.2rem));
  left:50%;
  transform:translateX(-50%);
  z-index:9000;
  display:flex;flex-direction:column;gap:.7rem;
  pointer-events:none;
  width:min(440px, calc(100vw - 2rem));
  max-height:calc(100vh - 3rem);
}
@media (min-width:760px){
  .notif-stack{
    left:auto;right:1.4rem;transform:none;
    top:max(5.2rem, calc(env(safe-area-inset-top, 0px) + 5.2rem));
  }
}

.notif{
  pointer-events:auto;
  position:relative;
  display:flex;align-items:stretch;
  min-width:0;width:100%;
  border-radius:14px;
  background:linear-gradient(180deg,var(--notif-bg) 0%,var(--notif-bg-2) 100%);
  border:1px solid var(--notif-edge);
  box-shadow:var(--notif-shadow);
  overflow:hidden;
  font-family:'Cormorant Garamond','Times New Roman',serif;
  animation:notifIn .55s cubic-bezier(.22,1,.36,1) forwards;
  transform-origin:top center;
}
.notif::before{
  content:'';position:absolute;left:10px;right:10px;top:1px;height:6px;
  background-image:var(--notif-meander);
  background-repeat:repeat-x;
  background-size:auto 6px;
  opacity:.65;
  pointer-events:none;
}
.notif::after{
  content:'';position:absolute;inset:3px;border-radius:11px;
  border:1px solid var(--notif-edge-soft);
  pointer-events:none;
}
.notif.exit{animation:notifOut .35s cubic-bezier(.6,.04,.98,.335) forwards}

.notif-accent{
  width:3px;flex-shrink:0;margin:14px 0 16px 8px;border-radius:2px;
  background:var(--notif-grad-gold);
  box-shadow:0 0 12px rgba(231,201,137,.45);
}
.notif-accent.err{background:linear-gradient(180deg,#f3d5a8 0%,#c0521e 55%,#7a2a10 100%);box-shadow:0 0 12px rgba(192,82,30,.45)}
.notif-accent.warn{background:linear-gradient(180deg,#fff0c4 0%,#e2a13b 55%,#9c6a18 100%);box-shadow:0 0 12px rgba(226,161,59,.45)}
.notif-accent.info{background:linear-gradient(180deg,#e9ecf0 0%,#9aa9bd 55%,#4f5e75 100%);box-shadow:0 0 12px rgba(154,169,189,.4)}

.notif-body{
  flex:1;display:flex;align-items:center;gap:.85rem;
  padding:1rem .55rem 1.05rem 1rem;
  min-width:0;
}

.notif-icon{
  width:38px;height:38px;border-radius:50%;flex-shrink:0;
  display:flex;align-items:center;justify-content:center;
  background:radial-gradient(circle at 30% 25%,#fff5d9 0%,#f1c279 45%,#aa7e3b 100%);
  color:#3d2a10;
  border:1px solid rgba(122,84,33,.55);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.6),0 4px 10px -2px rgba(122,84,33,.45);
}
.notif-icon.err{background:radial-gradient(circle at 30% 25%,#ffe2c4 0%,#e3814a 50%,#7a2a10 100%);color:#3d1808;border-color:rgba(122,42,16,.6)}
.notif-icon.warn{background:radial-gradient(circle at 30% 25%,#fff0c4 0%,#e2a13b 50%,#9c6a18 100%);color:#3d2a08;border-color:rgba(156,106,24,.6)}
.notif-icon.info{background:radial-gradient(circle at 30% 25%,#f4f6f9 0%,#9aa9bd 50%,#4f5e75 100%);color:#1e2632;border-color:rgba(79,94,117,.55)}
html.dark .notif-icon{box-shadow:inset 0 1px 0 rgba(255,255,255,.45),0 4px 12px -2px rgba(0,0,0,.55)}
.notif-icon svg{width:18px;height:18px;filter:drop-shadow(0 1px 0 rgba(255,255,255,.45))}
.notif-icon svg path.draw{stroke-dasharray:34;stroke-dashoffset:34;animation:notifDraw .55s .18s ease forwards}

.notif-text{
  flex:1;
  font-family:'Cormorant Garamond','Times New Roman',serif;
  font-size:1.05rem;
  font-weight:500;
  font-style:italic;
  letter-spacing:.005em;
  color:var(--notif-text);
  line-height:1.35;
  min-width:0;
  word-break:break-word;
  text-shadow:0 1px 0 rgba(255,255,255,.35);
}
html.dark .notif-text{text-shadow:0 1px 0 rgba(0,0,0,.55)}

.notif-close{
  width:30px;height:30px;border-radius:50%;
  border:1px solid var(--notif-edge-soft);
  background:transparent;cursor:pointer;
  display:flex;align-items:center;justify-content:center;
  flex-shrink:0;color:var(--notif-gold-d);
  transition:all .2s ease;
  margin:0 .4rem 0 .15rem;
  opacity:0;transform:scale(.85);
}
html.dark .notif-close{color:var(--notif-gold-l)}
.notif:hover .notif-close,.notif:focus-within .notif-close{opacity:1;transform:scale(1)}
.notif-close:hover{background:var(--notif-grad-gold);color:#1f1408;border-color:var(--notif-gold-d);box-shadow:0 2px 8px rgba(170,126,59,.4)}
.notif-close svg{width:11px;height:11px}

.notif-bar{
  position:absolute;bottom:0;left:0;right:0;height:2px;
  background:var(--notif-grad-gold);
  transform-origin:left;
  box-shadow:0 0 6px rgba(231,201,137,.7);
}
.notif-bar.err{background:linear-gradient(90deg,#7a2a10 0%,#c0521e 50%,#f3d5a8 100%);box-shadow:0 0 6px rgba(192,82,30,.55)}
.notif-bar.warn{background:linear-gradient(90deg,#9c6a18 0%,#e2a13b 50%,#fff0c4 100%);box-shadow:0 0 6px rgba(226,161,59,.55)}
.notif-bar.info{background:linear-gradient(90deg,#4f5e75 0%,#9aa9bd 50%,#e9ecf0 100%);box-shadow:0 0 6px rgba(154,169,189,.5)}

@keyframes notifIn{
  0%{opacity:0;transform:translateY(-24px) scale(.95);filter:blur(2px)}
  60%{opacity:1;filter:blur(0)}
  100%{opacity:1;transform:translateY(0) scale(1);filter:blur(0)}
}
@keyframes notifOut{
  0%{opacity:1;transform:translateY(0) scale(1);max-height:200px;margin-bottom:.7rem}
  100%{opacity:0;transform:translateY(-30px) scale(.92);max-height:0;margin:0;padding:0;border-width:0}
}
@keyframes notifDraw{to{stroke-dashoffset:0}}
@keyframes notifBar{from{transform:scaleX(1)}to{transform:scaleX(0)}}

@media (prefers-reduced-motion:reduce){
  .notif{animation-duration:.001s!important}
  .notif.exit{animation-duration:.001s!important}
  .notif-icon svg path.draw{animation:none!important;stroke-dashoffset:0!important}
}

/* ─────────── GodsOlympus · Confirm dialog ─────────── */
.cfd-overlay{
  position:fixed;inset:0;z-index:9100;
  display:flex;align-items:center;justify-content:center;padding:1rem;
  background:radial-gradient(circle at 50% 40%,rgba(42,31,16,.55) 0%,rgba(10,7,3,.78) 100%);
  backdrop-filter:blur(10px) saturate(1.2);
  -webkit-backdrop-filter:blur(10px) saturate(1.2);
  animation:cfdBgIn .3s ease forwards;
}
html.dark .cfd-overlay{background:radial-gradient(circle at 50% 40%,rgba(0,0,0,.6) 0%,rgba(0,0,0,.88) 100%)}
.cfd-overlay.exit{animation:cfdBgOut .22s ease forwards}

.cfd-box{
  width:100%;max-width:440px;
  border-radius:18px;
  background:linear-gradient(180deg,var(--notif-bg) 0%,var(--notif-bg-2) 100%);
  border:1px solid var(--notif-edge);
  box-shadow:0 30px 80px -20px rgba(0,0,0,.65),0 6px 20px -6px rgba(122,84,33,.45),inset 0 1px 0 rgba(255,255,255,.5);
  overflow:hidden;position:relative;
  animation:cfdBoxIn .4s cubic-bezier(.22,1,.36,1) forwards;
  font-family:'Cormorant Garamond','Times New Roman',serif;
}
html.dark .cfd-box{box-shadow:0 30px 80px -20px rgba(0,0,0,.85),0 6px 20px -6px rgba(0,0,0,.6),inset 0 1px 0 rgba(255,245,217,.08)}
.cfd-box::before{
  content:'';position:absolute;left:14px;right:14px;top:1px;height:7px;
  background-image:var(--notif-meander);
  background-repeat:repeat-x;
  background-size:auto 7px;
  opacity:.7;pointer-events:none;
}
.cfd-box::after{
  content:'';position:absolute;inset:4px;border-radius:14px;
  border:1px solid var(--notif-edge-soft);
  pointer-events:none;
}
.cfd-overlay.exit .cfd-box{animation:cfdBoxOut .25s ease forwards}

.cfd-top{display:flex;align-items:center;gap:.95rem;padding:1.6rem 1.6rem .8rem}
.cfd-ico{
  width:48px;height:48px;border-radius:50%;
  display:flex;align-items:center;justify-content:center;flex-shrink:0;
  background:radial-gradient(circle at 30% 25%,#fff5d9 0%,#f1c279 45%,#aa7e3b 100%);
  color:#3d2a10;border:1px solid rgba(122,84,33,.55);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.6),0 5px 14px -3px rgba(122,84,33,.5);
}
.cfd-ico.warn{background:radial-gradient(circle at 30% 25%,#fff0c4 0%,#e2a13b 50%,#9c6a18 100%);color:#3d2a08;border-color:rgba(156,106,24,.6)}
.cfd-ico.danger{background:radial-gradient(circle at 30% 25%,#ffe2c4 0%,#e3814a 50%,#7a2a10 100%);color:#3d1808;border-color:rgba(122,42,16,.6)}
.cfd-ico.info{background:radial-gradient(circle at 30% 25%,#f4f6f9 0%,#9aa9bd 50%,#4f5e75 100%);color:#1e2632;border-color:rgba(79,94,117,.55)}
.cfd-ico svg{width:24px;height:24px;filter:drop-shadow(0 1px 0 rgba(255,255,255,.5))}

.cfd-title{
  font-family:'Cinzel','Cormorant Garamond',serif;
  font-size:1.15rem;font-weight:600;
  color:var(--notif-text);line-height:1.25;
  letter-spacing:.06em;
  text-shadow:0 1px 0 rgba(255,255,255,.35);
}
html.dark .cfd-title{text-shadow:0 1px 0 rgba(0,0,0,.55)}

.cfd-msg{
  padding:0 1.6rem 1.05rem;
  font-family:'Cormorant Garamond','Times New Roman',serif;
  font-size:1.04rem;font-style:italic;line-height:1.5;
  color:var(--notif-text-soft);white-space:pre-line;
  position:relative;
}
.cfd-msg::before{
  content:'';position:absolute;left:1.6rem;right:1.6rem;top:0;height:1px;
  background:linear-gradient(90deg,transparent 0%,var(--notif-edge) 50%,transparent 100%);
  opacity:.55;
}

.cfd-btns{
  display:flex;gap:.6rem;
  padding:.9rem 1.4rem 1.3rem;
  justify-content:flex-end;
  position:relative;
}
.cfd-btns::before{
  content:'';position:absolute;left:1.6rem;right:1.6rem;top:0;height:1px;
  background:linear-gradient(90deg,transparent 0%,var(--notif-edge) 50%,transparent 100%);
  opacity:.45;
}

.cfd-btn{
  padding:.65rem 1.4rem;
  border-radius:11px;
  border:1px solid var(--notif-edge);
  font-family:'Cinzel','Cormorant Garamond',serif;
  font-size:.78rem;font-weight:600;
  letter-spacing:.16em;text-transform:uppercase;
  cursor:pointer;transition:all .25s ease;
  background:transparent;color:var(--notif-text);
}
.cfd-btn:focus-visible{outline:2px solid var(--notif-gold);outline-offset:2px}
.cfd-btn.cancel{background:transparent;color:var(--notif-text-soft);border-color:var(--notif-edge-soft)}
.cfd-btn.cancel:hover{background:rgba(170,126,59,.08);color:var(--notif-text);border-color:var(--notif-edge)}
html.dark .cfd-btn.cancel:hover{background:rgba(231,201,137,.08)}

.cfd-btn.ok{color:#1f1408;background:var(--notif-grad-gold);border-color:var(--notif-gold-d);box-shadow:0 4px 14px -4px rgba(170,126,59,.55),inset 0 1px 0 rgba(255,255,255,.45)}
.cfd-btn.ok:hover{transform:translateY(-1px);box-shadow:0 7px 20px -6px rgba(170,126,59,.65),inset 0 1px 0 rgba(255,255,255,.55)}
.cfd-btn.ok.warn{background:linear-gradient(135deg,#fff0c4 0%,#e2a13b 50%,#9c6a18 100%);border-color:#9c6a18;box-shadow:0 4px 14px -4px rgba(226,161,59,.6),inset 0 1px 0 rgba(255,255,255,.45)}
.cfd-btn.ok.warn:hover{box-shadow:0 7px 20px -6px rgba(226,161,59,.7),inset 0 1px 0 rgba(255,255,255,.55)}
.cfd-btn.ok.danger{background:linear-gradient(135deg,#ffe2c4 0%,#e3814a 50%,#7a2a10 100%);border-color:#7a2a10;box-shadow:0 4px 14px -4px rgba(192,82,30,.6),inset 0 1px 0 rgba(255,255,255,.4)}
.cfd-btn.ok.danger:hover{box-shadow:0 7px 20px -6px rgba(192,82,30,.7),inset 0 1px 0 rgba(255,255,255,.5)}
.cfd-btn.ok.info{background:linear-gradient(135deg,#f4f6f9 0%,#9aa9bd 50%,#4f5e75 100%);color:#1e2632;border-color:#4f5e75;box-shadow:0 4px 14px -4px rgba(79,94,117,.5),inset 0 1px 0 rgba(255,255,255,.4)}
.cfd-btn.ok.info:hover{box-shadow:0 7px 20px -6px rgba(79,94,117,.6),inset 0 1px 0 rgba(255,255,255,.5)}

@keyframes cfdBgIn{from{opacity:0}to{opacity:1}}
@keyframes cfdBgOut{from{opacity:1}to{opacity:0}}
@keyframes cfdBoxIn{
  0%{opacity:0;transform:scale(.92) translateY(18px);filter:blur(3px)}
  60%{filter:blur(0)}
  100%{opacity:1;transform:scale(1) translateY(0);filter:blur(0)}
}
@keyframes cfdBoxOut{from{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.94) translateY(10px)}}

@media (prefers-reduced-motion:reduce){
  .cfd-overlay,.cfd-box,.cfd-overlay.exit,.cfd-overlay.exit .cfd-box{animation-duration:.001s!important}
}
