:root{
  --dw-bg: rgba(6, 18, 52, .78);
  --dw-bg2: rgba(10, 25, 74, .86);
  --dw-border: rgba(160,210,255,.14);
  --dw-text: rgba(234,242,255,.92);
  --dw-muted: rgba(234,242,255,.68);
  --dw-neo: var(--neo, #6dffda);
  --dw-neo2: var(--neo2, #a8c7ff);
  --dw-cute: var(--cute, #ff7bd1);
}

/* Base (no forced positioning) */
.daily-widget{
  user-select:none;
  -webkit-tap-highlight-color: transparent;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
}

.daily-widget .dw-card{
  position: relative;
  border-radius: 18px;
  background: linear-gradient(180deg, var(--dw-bg2), var(--dw-bg));
  border: 1px solid var(--dw-border);
  box-shadow: 0 12px 35px rgba(0,0,0,.42);
  overflow: hidden;
}

.daily-widget .dw-head{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 14px 10px;
}

.daily-widget .dw-title{
  display:flex;
  align-items:center;
  gap: 10px;
  min-width: 0;
}

.daily-widget .dw-gem{
  width: 30px;
  height: 30px;
  border-radius: 12px;
  display:grid;
  place-items:center;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,.18), rgba(255,255,255,0) 55%),
              linear-gradient(135deg, rgba(109,255,218,.22), rgba(168,199,255,.10));
  border: 1px solid rgba(255,255,255,.12);
  position: relative;
  overflow: hidden;
}

.daily-widget .dw-gem::after{
  content:"";
  position:absolute;
  inset:-60%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.18), transparent);
  transform: rotate(25deg);
  animation: dwShine 3.2s linear infinite;
}

@keyframes dwShine{
  0%{ transform: translateX(-40%) rotate(25deg); opacity:0; }
  10%{ opacity:.6; }
  40%{ opacity:0; }
  100%{ transform: translateX(40%) rotate(25deg); opacity:0; }
}

.daily-widget .dw-name{
  display:flex;
  flex-direction:column;
  line-height:1.05;
  min-width: 0;
}

.daily-widget .dw-name strong{
  font-weight: 900;
  letter-spacing: .2px;
  font-size: 13px;
  color: var(--dw-text);
  white-space: nowrap;
  overflow:hidden;
  text-overflow: ellipsis;
}

.daily-widget .dw-name span{
  font-size: 12px;
  color: var(--dw-muted);
  white-space: nowrap;
  overflow:hidden;
  text-overflow: ellipsis;
}

.daily-widget .dw-right{
  display:flex;
  align-items:center;
  gap: 8px;
}

.daily-widget .dw-dot{
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--dw-neo);
  box-shadow: 0 0 0 0 rgba(109,255,218,.65);
  animation: dwPulse 1.8s ease-in-out infinite;
}
.daily-widget .dw-dot.off{
  background: rgba(255,255,255,.18);
  box-shadow: none;
  animation: none;
}
@keyframes dwPulse{
  0%{ box-shadow: 0 0 0 0 rgba(109,255,218,.55); }
  70%{ box-shadow: 0 0 0 10px rgba(109,255,218,0); }
  100%{ box-shadow: 0 0 0 0 rgba(109,255,218,0); }
}

.daily-widget .dw-pill{
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  color: var(--dw-text);
  background: rgba(255,255,255,.06);
  white-space: nowrap;
}

.daily-widget .dw-body{
  padding: 0 14px 14px;
}

.daily-widget .dw-row{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
.daily-widget .dw-row:first-child{ border-top: none; padding-top: 0; }

.daily-widget .dw-row .l{
  display:flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.daily-widget .dw-row .l .a{
  font-weight: 900;
  font-size: 13px;
  color: var(--dw-text);
}
.daily-widget .dw-row .l .b{
  font-size: 12px;
  color: var(--dw-muted);
}

.daily-widget .dw-btn{
  border: 0;
  border-radius: 14px;
  padding: 10px 12px;
  font-weight: 900;
  letter-spacing: .2px;
  cursor: pointer;
  color: #071025;
  background: linear-gradient(135deg, var(--dw-neo), var(--dw-neo2));
  box-shadow: 0 10px 25px rgba(0,0,0,.30);
  transition: transform .16s ease, filter .16s ease;
}
.daily-widget .dw-btn:hover{ transform: translateY(-1px); filter: brightness(1.06); }
.daily-widget .dw-btn:active{ transform: translateY(0); filter: brightness(.98); }
.daily-widget .dw-btn[disabled]{
  cursor:not-allowed;
  filter: grayscale(.3) brightness(.9);
  opacity:.8;
}

.daily-widget .dw-toast{
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  font-size: 12px;
  color: var(--dw-muted);
  display:none;
}
.daily-widget .dw-toast.show{ display:block; }
.daily-widget .dw-toast.good{ color: rgba(109,255,218,.95); }
.daily-widget .dw-toast.bad{ color: rgba(255,123,209,.95); }

.daily-widget .dw-confetti{
  position:absolute;
  inset:0;
  pointer-events:none;
  overflow:hidden;
}
.daily-widget .dw-confetti i{
  position:absolute;
  top:-10px;
  width: 8px;
  height: 14px;
  border-radius: 3px;
  background: rgba(255,255,255,.7);
  opacity:.95;
  animation: dwFall 900ms ease-out forwards;
}
@keyframes dwFall{
  to{ transform: translateY(160px) rotate(180deg); opacity:0; }
}

/* === Placement: Desktop Sidebar (fills the red box nicely) === */
.daily-widget.dw-in-sidebar{
  margin: 14px 10px 14px;
}
.daily-widget.dw-in-sidebar .dw-card{
  box-shadow: 0 10px 28px rgba(0,0,0,.35);
}
.daily-widget.dw-in-sidebar .dw-body{ padding-bottom: 12px; }

/* === Placement: Mobile Drawer menu === */
.daily-widget.dw-in-drawer{
  margin: 10px 12px 12px;
}
.daily-widget.dw-in-drawer .dw-card{
  border-radius: 16px;
}

/* === Always-visible Mobile Dock (small pill) === */
.daily-widget.dw-dock{
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 9999;
}
.daily-widget.dw-dock .dw-card{
  border-radius: 18px;
}
@media (min-width: 992px){
  .daily-widget.dw-dock{ display:none; }
}

/* Optional: if your site has fixed bottom navigation, lift the dock */
body.has-bottom-nav .daily-widget.dw-dock{
  bottom: 78px;
}
