/* Daily Deen Word — navy + gold, matches the website. */
.dw { --dw-navy: #10283f; --dw-gold: #a19771; --dw-gold-soft: #c9c0a0; --dw-blue: #2e6496; --dw-gray: #6b7480; --dw-line: #d9d2bf;
  position: relative; max-width: 30rem; margin: 0 auto; padding: 1.25rem 1rem 1.5rem; background: #fff; border: 1px solid var(--dw-line); border-radius: 22px; box-shadow: 0 12px 40px rgb(16 40 63 / .08); text-align: center; }
.dw-loading { padding: 3rem 0; color: var(--dw-gray); }

.dw-head { position: relative; padding: 0 2.75rem .9rem; }
.dw-eyebrow { margin: 0; font-size: .75rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: #6e6440; }
.dw-cat { margin: .25rem 0 0; font-size: 1.05rem; color: var(--dw-navy); }
.dw-cat span { color: var(--dw-gray); }
.dw-iconbtn { position: absolute; right: 0; top: 0; width: 2.5rem; height: 2.5rem; border-radius: 50%; border: 1.5px solid var(--dw-line); background: #fff; color: var(--dw-navy); font-weight: 800; font-size: 1.1rem; cursor: pointer; }
.dw-iconbtn:hover, .dw-iconbtn:focus-visible { border-color: var(--dw-gold); }

.dw-grid { display: grid; gap: .4rem; width: min(100%, calc(var(--len) * 3.9rem)); margin: .25rem auto .9rem; }
.dw-row { display: grid; grid-template-columns: repeat(var(--len), 1fr); gap: .4rem; }
.dw-row.is-shake { animation: dw-shake .4s; }
.dw-tile { display: grid; place-items: center; aspect-ratio: 1; min-width: 0; border: 2px solid var(--dw-line); border-radius: 10px; font: 800 clamp(1.3rem, 6vw, 1.9rem)/1 Manrope, system-ui, sans-serif; color: var(--dw-navy); text-transform: uppercase; background: #fff; user-select: none; }
.dw-tile.is-filled { border-color: #8d97a3; animation: dw-pop .12s; }
.dw-tile.is-correct { background: var(--dw-gold); border-color: var(--dw-gold); color: var(--dw-navy); }
.dw-tile.is-present { background: var(--dw-blue); border-color: var(--dw-blue); color: #fff; }
.dw-tile.is-absent { background: var(--dw-gray); border-color: var(--dw-gray); color: #fff; }
.dw-tile.is-flip { animation: dw-flip .45s ease both; }

.dw-hint { margin: 0 auto .9rem; max-width: 26rem; font-size: .98rem; color: var(--dw-navy); }
.dw-hint b { color: #6e6440; }
.dw-hintbtn { padding: .45rem .9rem; border-radius: 999px; border: 1.5px dashed var(--dw-gold); background: transparent; color: #6e6440; font-weight: 700; cursor: pointer; }

.dw-live { position: absolute; left: 50%; top: 4.5rem; z-index: 5; transform: translate(-50%, -6px); margin: 0; padding: .55rem 1rem; border-radius: 10px; background: var(--dw-navy); color: #fff; font-weight: 700; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; white-space: nowrap; }
.dw-live.is-on { opacity: 1; transform: translate(-50%, 0); }

.dw-kb { display: grid; gap: .4rem; }
.dw-kb[hidden] { display: none; }
.dw-kbrow { display: flex; justify-content: center; gap: .3rem; }
.dw-key { flex: 1; max-width: 2.6rem; min-height: 3.4rem; padding: 0; border: 0; border-radius: 8px; background: #ebe6d8; color: var(--dw-navy); font: 700 1rem Manrope, system-ui, sans-serif; cursor: pointer; display: grid; place-items: center; touch-action: manipulation; }
.dw-key--wide { max-width: 4.2rem; flex: 1.5; font-size: .8rem; }
.dw-key:active { transform: scale(.95); }
.dw-key:focus-visible, .dw-hintbtn:focus-visible { outline: 3px solid var(--dw-gold); outline-offset: 2px; }
.dw-key.is-correct { background: var(--dw-gold); color: var(--dw-navy); }
.dw-key.is-present { background: var(--dw-blue); color: #fff; }
.dw-key.is-absent { background: var(--dw-gray); color: #fff; opacity: .75; }

.dw-end[hidden] { display: none; }
.dw-reveal { margin: .5rem 0 1rem; padding: 1.25rem 1rem; border-radius: 16px; color: #f8f5ed; background: radial-gradient(ellipse at 80% 0%, #1d4a6e 0%, var(--dw-navy) 60%, #0a1b2c 100%); }
.dw-reveal .dw-eyebrow { color: var(--dw-gold-soft); }
.dw-answer { margin: .2rem 0 .5rem; font: 600 2.3rem/1.1 "Cormorant Garamond", Georgia, serif; letter-spacing: .08em; }
.dw-lesson { margin: 0 auto; max-width: 24rem; font-size: 1rem; line-height: 1.55; color: rgb(248 245 237 / .9); }
.dw-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; margin-bottom: .6rem; }
.dw-stat b { display: block; font: 800 1.6rem/1.2 Manrope, system-ui, sans-serif; color: var(--dw-navy); font-variant-numeric: lining-nums tabular-nums; }
.dw-stat span { font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--dw-gray); }
.dw-streak { margin: 0 0 .8rem; font-weight: 700; color: #6e6440; }
.dw-actions { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; }
.dw-next { margin: .9rem 0 0; font-size: .9rem; color: var(--dw-gray); }

.dw-modal { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 1rem; background: rgb(10 27 44 / .6); }
.dw-modal[hidden] { display: none; }
.dw-modal__card { width: min(100%, 26rem); max-height: 90vh; overflow: auto; padding: 1.5rem; border-radius: 18px; background: #fff; text-align: left; color: var(--dw-navy); }
.dw-modal__card h2 { margin: 0 0 .5rem; font: 600 1.8rem "Cormorant Garamond", Georgia, serif; }
.dw-modal__card p { margin: .4rem 0 .9rem; }
.dw-ex { display: flex; gap: .3rem; }
.dw-ex .dw-tile { width: 2.4rem; font-size: 1.1rem; }
.dw-close { width: 100%; margin-top: .5rem; }

@keyframes dw-flip { 0% { transform: rotateX(0); } 50% { transform: rotateX(90deg); } 100% { transform: rotateX(0); } }
@keyframes dw-pop { 50% { transform: scale(1.08); } }
@keyframes dw-shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
@media (prefers-reduced-motion: reduce) { .dw-tile, .dw-row { animation: none !important; } }
@media (max-width: 380px) { .dw { padding-inline: .5rem; } .dw-kbrow { gap: .22rem; } .dw-key { min-height: 3.1rem; } }

/* --- progress strip: level, streak, shields --- */
.dw-strip { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem; margin: 0 0 .7rem; }
.dw-chip { display: inline-flex; align-items: center; gap: .3rem; padding: .3rem .7rem; border-radius: 999px; background: #f4f0e4; color: var(--dw-navy); font-size: .82rem; border: 0; }
.dw-chip b { font-weight: 800; }
.dw-chip--level { cursor: pointer; background: var(--dw-navy); color: #f8f5ed; }
.dw-chip--level span { color: var(--dw-gold-soft); font-weight: 700; }
.dw-chip--level:focus-visible { outline: 3px solid var(--dw-gold); outline-offset: 2px; }
.dw-chip--shield svg { color: #6e6440; }

/* --- difficulty --- */
.dw-modes { display: inline-flex; gap: 0; margin: 0 auto .4rem; padding: 3px; border-radius: 999px; background: #f4f0e4; }
.dw-modes[hidden] { display: none; }
.dw-mode { padding: .35rem .9rem; border: 0; border-radius: 999px; background: transparent; color: var(--dw-navy); font: 700 .85rem Manrope, system-ui, sans-serif; cursor: pointer; }
.dw-mode.is-on { background: #fff; box-shadow: 0 1px 4px rgb(16 40 63 / .15); }
.dw-mode:disabled { opacity: .45; cursor: default; }
.dw-mode:focus-visible { outline: 3px solid var(--dw-gold); }
.dw-modenote { margin: 0 0 .6rem; font-size: .85rem; color: var(--dw-gray); }
.dw-modenote[hidden] { display: none; }
.dw-tile.is-ghost { color: #b9b29a; border-style: dashed; }

/* --- bars (team goal + level) --- */
.dw-bar { height: .6rem; border-radius: 999px; background: #ebe6d8; overflow: hidden; margin: .4rem 0; }
.dw-bar span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--dw-gold), #c2b37a); transition: width .8s ease; }
.dw-team { margin: 1rem 0 0; padding: .9rem 1rem; border-radius: 14px; background: #f8f5ed; text-align: left; }
.dw-team[hidden] { display: none; }
.dw-team__title, .dw-progress__title { margin: 0; font-weight: 800; font-size: .9rem; color: var(--dw-navy); }
.dw-team__num, .dw-progress__next { margin: 0; font-size: .85rem; color: var(--dw-gray); }
.dw-progress { margin: 0 0 1rem; padding: .9rem 1rem; border-radius: 14px; border: 1px solid var(--dw-line); text-align: left; }
.dw-link { margin-top: .5rem; padding: 0; border: 0; background: none; color: #6e6440; font-weight: 800; text-decoration: underline; cursor: pointer; }

/* --- rewards --- */
.dw-levelup, .dw-gem { margin: 0 0 1rem; padding: 1rem; border-radius: 14px; border: 2px solid var(--dw-gold); background: #fffdf6; animation: dw-pop .5s; }
.dw-levelup__name { margin: .2rem 0 0; font: 600 1.7rem/1.1 "Cormorant Garamond", Georgia, serif; color: var(--dw-navy); }
.dw-gem__text { margin: .4rem 0 .3rem; font: 600 1.25rem/1.35 "Cormorant Garamond", Georgia, serif; color: var(--dw-navy); }
.dw-gem__src { margin: 0; font-size: .8rem; font-weight: 700; color: #6e6440; }

/* --- collection --- */
.dw-coll__sum { color: var(--dw-gray); margin-top: 0; }
.dw-coll__group { margin: 0 0 1rem; }
.dw-coll__cat { margin: 0 0 .4rem; font-size: .78rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: #6e6440; }
.dw-coll__chips { display: flex; flex-wrap: wrap; gap: .3rem; }
.dw-wchip { padding: .25rem .55rem; border-radius: 8px; background: #f1eee6; color: #a49e8c; font: 700 .8rem Manrope, system-ui, sans-serif; letter-spacing: .05em; }
.dw-wchip.is-won { background: var(--dw-gold); color: var(--dw-navy); }
.dw-wchip.is-seen { background: #fff; color: var(--dw-gray); border: 1px solid var(--dw-line); }
.dw-coll__gem { margin: 0 0 .6rem; font-size: .95rem; }
.dw-coll__gem span { display: block; font-size: .75rem; font-weight: 700; color: #6e6440; }
.dw-coll__empty { color: var(--dw-gray); font-size: .9rem; margin: 0; }
.dw-list { padding-left: 1.1rem; margin: 0 0 1rem; }
.dw-list li { margin: .3rem 0; }

/* --- salah pause --- */
.dw-pause { position: absolute; inset: 0; z-index: 6; display: grid; place-content: start center; padding-top: 7rem !important; gap: .3rem; padding: 2rem; border-radius: inherit; background: rgb(16 40 63 / .96); color: #f8f5ed; }
.dw-pause[hidden] { display: none; }
.dw-pause .dw-eyebrow { color: var(--dw-gold-soft); }
.dw-pause__title { margin: 0; font: 600 2.2rem/1.1 "Cormorant Garamond", Georgia, serif; }
.dw-pause p:last-child { max-width: 20rem; margin: .4rem auto 0; color: rgb(248 245 237 / .85); }
