.lwl-spell-book {
  --lwl-sb-bg-1: #0f1f2f;
  --lwl-sb-bg-2: #1f3d52;
  --lwl-sb-accent: #f5be62;
  --lwl-sb-accent-2: #6dd6c5;
  --lwl-sb-text: #f6f2eb;
  --lwl-sb-muted: #c2d2dd;
  --lwl-sb-card: rgba(8, 16, 27, 0.72);
  --lwl-sb-border: rgba(255, 255, 255, 0.16);
  --lwl-sb-paper: #e8dcc2;
  --lwl-sb-paper-ink: #2d2a22;
  --lwl-sb-paper-muted: #6f6758;
  color: var(--lwl-sb-text);
  background:
    radial-gradient(1200px 340px at -10% -15%, rgba(109, 214, 197, 0.22), transparent 60%),
    radial-gradient(900px 260px at 95% 0%, rgba(245, 190, 98, 0.22), transparent 58%),
    linear-gradient(145deg, var(--lwl-sb-bg-1), var(--lwl-sb-bg-2));
  border-radius: 22px;
  border: 1px solid var(--lwl-sb-border);
  box-shadow: 0 24px 60px rgba(4, 8, 14, 0.38);
  padding: 18px;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  font-family: "Spectral", Georgia, "Times New Roman", serif;
}

.lwl-spell-book__shell {
  display: grid;
  /* Row 1 (top-panel): content-sized so the new Add-to-Spellbook form below
     the search row never gets clipped by .lwl-spell-book__top-panel's
     overflow:hidden. Row 2 (book-panel): claims the remaining height. */
  grid-template-rows: minmax(170px, auto) minmax(0, 1fr);
  gap: 12px;
  height: 100%;
  min-height: 0;
}

.lwl-spell-book__top-panel {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  padding: 12px;
  background:
    radial-gradient(110% 130% at 18% 2%, rgba(119, 197, 255, 0.16), transparent 62%),
    radial-gradient(120% 120% at 82% 98%, rgba(245, 190, 98, 0.13), transparent 56%),
    linear-gradient(145deg, rgba(10, 18, 30, 0.72), rgba(13, 28, 43, 0.72));
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 190px);
  gap: 12px;
  min-height: 0;
  overflow: hidden;
}

.lwl-spell-book__utility {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.lwl-spell-book__stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-content: start;
}

.lwl-spell-book__stat {
  border: 1px solid var(--lwl-sb-border);
  border-radius: 12px;
  padding: 6px 10px;
  background: rgba(7, 13, 20, 0.45);
  text-align: center;
}

.lwl-spell-book__stat strong {
  display: block;
  font-size: 0.95rem;
}

.lwl-spell-book__stat span {
  display: block;
  font-size: 0.74rem;
  color: var(--lwl-sb-muted);
}

.lwl-spell-book__controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 220px);
  gap: 8px;
  margin: 0;
}

.lwl-spell-book__search,
.lwl-spell-book__select {
  border: 1px solid var(--lwl-sb-border);
  border-radius: 11px;
  background: rgba(6, 10, 17, 0.52);
  color: var(--lwl-sb-text);
  padding: 10px 11px;
  font-size: 14px;
}

.lwl-spell-book__search::placeholder {
  color: rgba(246, 242, 235, 0.65);
}

.lwl-spell-book__status {
  min-height: 16px;
  color: var(--lwl-sb-muted);
  font-size: 12px;
  margin: 0;
}

.lwl-spell-book__book-panel {
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.lwl-spell-book__book {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  gap: 10px;
  perspective: 1200px;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.lwl-spell-book__book-pages {
  position: relative;
  border: 1px solid var(--lwl-sb-border);
  border-radius: 16px;
  background:
    radial-gradient(120% 140% at 7% -6%, rgba(255, 240, 209, 0.7), rgba(237, 220, 187, 0.92) 56%, rgba(219, 201, 166, 0.96)),
    repeating-linear-gradient(175deg, rgba(126, 95, 53, 0.04) 0 2px, rgba(80, 54, 28, 0.02) 2px 4px);
  box-shadow: 0 14px 24px rgba(0, 0, 0, 0.24), inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  padding: 12px;
  overflow: hidden;
  transform-origin: left center;
  backface-visibility: hidden;
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.lwl-spell-book__book-pages::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 14% 18%, rgba(91, 59, 24, 0.05) 0 3px, transparent 4px),
    radial-gradient(circle at 81% 30%, rgba(54, 85, 92, 0.08) 0 2px, transparent 3px),
    radial-gradient(circle at 70% 84%, rgba(82, 60, 30, 0.06) 0 2px, transparent 3px);
  opacity: 0.58;
}

.lwl-spell-book__book-pages::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(73, 56, 38, 0.09), transparent 7%, transparent 93%, rgba(73, 56, 38, 0.09)),
    radial-gradient(100% 48% at 50% 1%, rgba(255, 255, 255, 0.35), transparent 72%);
  opacity: 0.45;
}

.lwl-spell-book__book.is-book-closed .lwl-spell-book__book-pages {
  transform: rotateY(-18deg) scale(0.99);
}

.lwl-spell-book__book.is-book-open .lwl-spell-book__book-pages {
  transform: rotateY(0deg) scale(1);
}

.lwl-spell-book__book.is-book-opening .lwl-spell-book__book-pages {
  animation: lwl-sb-book-open 480ms cubic-bezier(0.25, 0.72, 0.24, 1);
}

.lwl-spell-book__page-turn {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background:
    linear-gradient(100deg, rgba(255, 255, 255, 0.08) 0%, rgba(250, 240, 214, 0.58) 48%, rgba(255, 255, 255, 0.03) 100%);
  transform-origin: left center;
  z-index: 3;
}

.lwl-spell-book__book.is-page-turning.is-turn-forward .lwl-spell-book__page-turn {
  animation: lwl-sb-page-forward 520ms ease;
}

.lwl-spell-book__book.is-page-turning.is-turn-backward .lwl-spell-book__page-turn {
  animation: lwl-sb-page-backward 520ms ease;
}

.lwl-spell-book__index-tabs {
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: stretch;
  overflow: auto;
  min-height: 0;
  padding-right: 1px;
}

.lwl-spell-book__index-tab {
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-left: none;
  border-radius: 0 9px 9px 0;
  background: rgba(9, 16, 27, 0.72);
  color: var(--lwl-sb-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  min-height: 17px;
  padding: 3px 0;
  cursor: pointer;
  transition: transform 150ms ease, color 160ms ease, border-color 160ms ease, background-color 160ms ease;
}

.lwl-spell-book__index-tab:hover {
  transform: translateX(-1px);
  color: var(--lwl-sb-text);
}

.lwl-spell-book__index-tab.is-active {
  color: #16222f;
  border-color: rgba(245, 190, 98, 0.86);
  background: linear-gradient(180deg, rgba(245, 190, 98, 0.95), rgba(232, 170, 77, 0.95));
}

.lwl-spell-book__index-tab.is-empty {
  opacity: 0.62;
}

.lwl-spell-book__list {
  display: grid;
  gap: 12px;
  min-height: 0;
  max-height: none;
  overflow: auto;
  padding-right: 4px;
  position: relative;
  z-index: 1;
}

.lwl-spell-book__list.is-focus-mode {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-right: 0;
}

.lwl-spell-book__list.is-restoring {
  overflow: hidden;
}

.lwl-spell-book__list.is-focus-mode .lwl-spell-book__section-title {
  display: none;
}

.lwl-spell-book__section-title {
  font-size: 0.84rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--lwl-sb-paper-muted);
  margin-bottom: 2px;
  font-weight: 700;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.lwl-spell-book__card {
  --lwl-sb-status: #8e8677;
  border: 1px solid rgba(86, 64, 34, 0.22);
  border-left: 4px solid var(--lwl-sb-status);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(250, 242, 224, 0.95), rgba(242, 230, 204, 0.92));
  overflow: hidden;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  opacity: 0;
  transform: translateY(8px) scale(0.995);
  animation: lwl-sb-inscribe-in 560ms ease forwards;
  animation-delay: var(--lwl-entry-delay, 0ms);
  box-shadow: 0 10px 16px rgba(46, 30, 12, 0.08);
}

.lwl-spell-book__list.is-focus-mode .lwl-spell-book__card,
.lwl-spell-book__list.is-restoring .lwl-spell-book__card {
  margin: 0;
  width: min(860px, 100%);
  transition:
    opacity 190ms ease,
    transform 240ms ease,
    filter 220ms ease,
    max-height 220ms ease,
    border-width 180ms ease,
    margin 180ms ease,
    padding 180ms ease;
  transition-delay: var(--lwl-puff-delay, 0ms);
}

.lwl-spell-book__list.is-focus-mode .lwl-spell-book__card:not(.is-puffed) {
  opacity: 1;
}

.lwl-spell-book__list.is-focus-mode .lwl-spell-book__card.is-puffed,
.lwl-spell-book__list.is-restoring .lwl-spell-book__card.is-puffed {
  opacity: 0;
  transform: scale(0.92) translateY(14px);
  filter: blur(2px);
  width: 0;
  min-width: 0;
  pointer-events: none;
  max-height: 0;
  border-width: 0;
  padding: 0;
  margin: 0;
}

.lwl-spell-book__list.is-focus-mode .lwl-spell-book__card.is-focus-card {
  width: min(860px, 100%);
  max-height: 100%;
  overflow: auto;
  position: relative;
  z-index: 2;
  border-color: rgba(208, 162, 77, 0.72);
  box-shadow:
    0 22px 36px rgba(45, 29, 13, 0.24),
    0 0 0 1px rgba(208, 162, 77, 0.46),
    0 0 26px rgba(244, 192, 106, 0.32);
  transform: scale(1.015);
  animation: lwl-sb-focus-glow 320ms ease-out;
}

.lwl-spell-book__list.is-restoring .lwl-spell-book__card {
  transition-delay: var(--lwl-return-delay, 0ms);
}

.lwl-spell-book__list.is-restoring .lwl-spell-book__card.is-unfocusing {
  animation: lwl-sb-focus-glow-out 260ms ease-in;
}

.lwl-spell-book__card:hover {
  transform: translateY(-1px);
  border-color: rgba(163, 117, 63, 0.45);
  box-shadow: 0 14px 20px rgba(53, 37, 20, 0.16);
}

.lwl-spell-book__card.status-seen {
  --lwl-sb-status: #5d7fa8;
}

.lwl-spell-book__card.status-practiced {
  --lwl-sb-status: #4e9b88;
}

.lwl-spell-book__card.status-recalled {
  --lwl-sb-status: #bc8b3a;
}

.lwl-spell-book__card.status-mastered {
  --lwl-sb-status: #9a7be3;
}

.lwl-spell-book__card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 13px;
}

.lwl-spell-book__word {
  margin: 0;
  font-size: 1.18rem;
  color: var(--lwl-sb-paper-ink);
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.lwl-spell-book__dropcap {
  font-size: 1.22em;
  color: var(--lwl-sb-status);
  font-weight: 700;
  text-shadow: 0 0 10px rgba(255, 225, 160, 0.4);
}

.lwl-spell-book__word-text {
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: baseline;
  gap: 0.02em;
}

.lwl-spell-book__glyph {
  display: inline-block;
  opacity: 0;
  clip-path: inset(0 100% 0 0);
  transform: translateY(1px);
  filter: blur(0.6px);
  animation: lwl-sb-glyph-write 500ms ease forwards;
  animation-delay: calc(var(--lwl-entry-delay, 0ms) + var(--lwl-glyph-delay, 0ms) + 50ms);
}

.lwl-spell-book__glyph-space {
  display: inline-block;
  width: 0.35em;
}

.lwl-spell-book__meta {
  display: flex;
  gap: 10px;
  font-size: 12px;
  color: var(--lwl-sb-paper-muted);
  text-transform: capitalize;
}

.lwl-spell-book__meta-hint {
  text-transform: none;
  color: rgba(84, 67, 43, 0.72);
  font-style: italic;
}

.lwl-spell-book__fav {
  border: 1px solid rgba(87, 67, 40, 0.3);
  border-radius: 999px;
  background: rgba(243, 230, 201, 0.72);
  color: #493924;
  padding: 6px 12px;
  font-size: 12px;
  cursor: pointer;
}

.lwl-spell-book__fav.is-on {
  border-color: rgba(195, 147, 68, 0.72);
  background: rgba(244, 205, 129, 0.38);
}

.lwl-spell-book__card-body {
  border-top: 1px dashed rgba(89, 68, 40, 0.24);
  padding: 0 13px;
  max-height: 0;
  opacity: 0;
  transform: translateY(-6px) scale(0.99);
  transition: max-height 280ms ease, opacity 240ms ease, transform 240ms ease, padding 260ms ease;
}

.lwl-spell-book__card.is-open .lwl-spell-book__card-body {
  max-height: 420px;
  opacity: 1;
  transform: translateY(0) scale(1);
  padding: 12px 13px 13px;
}

.lwl-spell-book__card.is-focus-card.is-open .lwl-spell-book__card-body {
  max-height: min(52vh, 500px);
}

.lwl-spell-book__card-body p {
  margin: 0 0 7px;
  color: #3e352b;
  font-size: 13px;
}

.lwl-spell-book__ink-line {
  margin: 0 0 8px;
  color: #3d3528;
  font-size: 14px;
  line-height: 1.45;
  opacity: 0;
  transform: translateY(2px);
  transition: opacity 220ms ease, transform 220ms ease;
}

.lwl-spell-book__card.is-open .lwl-spell-book__ink-line {
  opacity: 1;
  transform: translateY(0);
}

.lwl-spell-book__card.is-open .lwl-spell-book__ink-line:nth-child(1) { transition-delay: 40ms; }
.lwl-spell-book__card.is-open .lwl-spell-book__ink-line:nth-child(2) { transition-delay: 90ms; }
.lwl-spell-book__card.is-open .lwl-spell-book__ink-line:nth-child(3) { transition-delay: 140ms; }

.lwl-spell-book__card.is-reveal-pulse {
  box-shadow: 0 0 0 1px rgba(188, 143, 71, 0.34), 0 10px 20px rgba(42, 25, 9, 0.16);
}

.lwl-spell-book__footer {
  margin-top: 10px;
}

.lwl-spell-book__folio {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto minmax(120px, 1fr);
  gap: 8px;
  align-items: center;
  margin: 0;
}

.lwl-spell-book__page-btn {
  border: 1px solid rgba(102, 77, 46, 0.34);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(244, 229, 195, 0.82), rgba(231, 210, 169, 0.74));
  color: #453824;
  padding: 9px 10px;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

.lwl-spell-book__page-btn:hover:not(:disabled) {
  border-color: rgba(159, 112, 48, 0.5);
}

.lwl-spell-book__page-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

.lwl-spell-book__page-indicator {
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(86, 68, 42, 0.84);
}

.lwl-spell-book__empty,
.lwl-spell-book__notice {
  border: 1px dashed rgba(93, 74, 43, 0.34);
  border-radius: 10px;
  padding: 14px;
  color: #5f5240;
  background: rgba(249, 239, 214, 0.72);
}

.lwl-spell-book__notice a {
  color: #6d4d27;
}

@keyframes lwl-sb-book-open {
  0% {
    transform: rotateY(-18deg) scale(0.99);
  }
  100% {
    transform: rotateY(0deg) scale(1);
  }
}

@keyframes lwl-sb-page-forward {
  0% {
    opacity: 0;
    transform: translateX(-5%) skewY(0deg);
  }
  28% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateX(90%) skewY(-2deg);
  }
}

@keyframes lwl-sb-page-backward {
  0% {
    opacity: 0;
    transform: translateX(90%) skewY(0deg);
  }
  28% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateX(-6%) skewY(2deg);
  }
}

@keyframes lwl-sb-inscribe-in {
  0% {
    opacity: 0;
    transform: translateY(8px) scale(0.995);
    filter: blur(2px);
  }
  65% {
    opacity: 1;
    filter: blur(0.2px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes lwl-sb-glyph-write {
  0% {
    opacity: 0;
    clip-path: inset(0 100% 0 0);
    transform: translateY(1px);
    filter: blur(0.7px);
  }
  65% {
    opacity: 1;
    filter: blur(0.25px);
  }
  100% {
    opacity: 1;
    clip-path: inset(0 0 0 0);
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes lwl-sb-focus-glow {
  0% {
    transform: scale(0.985);
    box-shadow:
      0 8px 18px rgba(45, 29, 13, 0.18),
      0 0 0 0 rgba(244, 192, 106, 0.08);
  }
  60% {
    transform: scale(1.022);
    box-shadow:
      0 24px 38px rgba(45, 29, 13, 0.26),
      0 0 0 4px rgba(244, 192, 106, 0.34),
      0 0 34px rgba(244, 192, 106, 0.4);
  }
  100% {
    transform: scale(1.015);
    box-shadow:
      0 22px 36px rgba(45, 29, 13, 0.24),
      0 0 0 1px rgba(208, 162, 77, 0.46),
      0 0 26px rgba(244, 192, 106, 0.32);
  }
}

@keyframes lwl-sb-focus-glow-out {
  0% {
    transform: scale(1.015);
    box-shadow:
      0 22px 36px rgba(45, 29, 13, 0.24),
      0 0 0 1px rgba(208, 162, 77, 0.46),
      0 0 26px rgba(244, 192, 106, 0.32);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 10px 16px rgba(46, 30, 12, 0.08);
  }
}

@media (max-width: 900px) {
  /* iPad-portrait / tablet fix: when the shell collapses to stacked panels
     the fixed root height + overflow:hidden clips the bottom. Release the
     outer clamps so the journey-stage scroll can take over; gestures stay
     inside the stage instead of bubbling up to Safari chrome. */
  .lwl-spell-book {
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  .lwl-spell-book__shell {
    /* Tablet — controls collapse to one column so the add-word form
       label + row + feedback line adds another ~30px on top of phone-portrait. */
    grid-template-rows: minmax(210px, auto) minmax(0, 1fr);
    height: auto;
  }

  .lwl-spell-book__top-panel {
    grid-template-columns: 1fr;
  }

  .lwl-spell-book__controls {
    grid-template-columns: 1fr 1fr;
  }

  .lwl-spell-book__stats {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lwl-spell-book__book {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .lwl-spell-book__index-tabs {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow: auto;
    padding-bottom: 4px;
  }

  .lwl-spell-book__index-tab {
    border-left: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 9px;
    min-width: 28px;
    padding: 6px 0;
  }

  .lwl-spell-book__folio {
    grid-template-columns: minmax(90px, 1fr) auto minmax(90px, 1fr);
  }
}

@media (max-width: 560px) {
  .lwl-spell-book {
    padding: 14px;
    border-radius: 16px;
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  .lwl-spell-book__shell {
    /* Phone — controls + add-word collapse to single column. */
    grid-template-rows: minmax(240px, auto) minmax(0, 1fr);
    height: auto;
  }

  .lwl-spell-book__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lwl-spell-book__controls {
    grid-template-columns: 1fr;
  }

  .lwl-spell-book__card-head {
    align-items: flex-start;
    gap: 8px;
  }

  .lwl-spell-book__fav {
    padding: 5px 9px;
    font-size: 11px;
  }

  .lwl-spell-book__folio {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lwl-spell-book__book-pages,
  .lwl-spell-book__page-turn,
  .lwl-spell-book__index-tab,
  .lwl-spell-book__card,
  .lwl-spell-book__ink-line {
    animation: none !important;
    transition: none !important;
  }
}

/* === Add-to-Spellbook row (matches existing dark utility controls) === */
.lwl-spell-book__add-word {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 8px 0 0;
}

.lwl-spell-book__add-word-label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lwl-sb-muted);
}

.lwl-spell-book__add-word-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(120px, 140px);
  gap: 8px;
}

.lwl-spell-book__add-word-input {
  border: 1px solid var(--lwl-sb-border);
  border-radius: 11px;
  background: rgba(6, 10, 17, 0.52);
  color: var(--lwl-sb-text);
  padding: 10px 11px;
  font-size: 14px;
}

.lwl-spell-book__add-word-input::placeholder {
  color: rgba(246, 242, 235, 0.55);
}

.lwl-spell-book__add-word-input:focus {
  outline: none;
  border-color: rgba(232, 195, 122, 0.55);
  box-shadow: 0 0 0 2px rgba(232, 195, 122, 0.18);
}

.lwl-spell-book__add-word-btn {
  border: 1px solid var(--lwl-sb-border);
  border-radius: 11px;
  background: linear-gradient(180deg, rgba(232, 195, 122, 0.22), rgba(180, 138, 70, 0.18));
  color: var(--lwl-sb-text);
  padding: 10px 12px;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, transform 120ms ease;
}

.lwl-spell-book__add-word-btn:hover:not(:disabled) {
  border-color: rgba(232, 195, 122, 0.55);
}

.lwl-spell-book__add-word-btn:active:not(:disabled) {
  transform: translateY(1px);
}

.lwl-spell-book__add-word-btn:disabled {
  opacity: 0.5;
  cursor: default;
}

.lwl-spell-book__add-word-feedback {
  min-height: 16px;
  font-size: 12px;
  color: var(--lwl-sb-muted);
  transition: color 200ms ease;
}

.lwl-spell-book__add-word-feedback.is-success {
  color: rgba(170, 218, 156, 0.95);
}

.lwl-spell-book__add-word-feedback.is-error {
  color: rgba(232, 154, 134, 0.95);
}

.lwl-spell-book__add-word-feedback.is-warning {
  color: rgba(232, 195, 122, 0.95);
}

.lwl-spell-book__add-word.is-submitting .lwl-spell-book__add-word-input,
.lwl-spell-book__add-word.is-submitting .lwl-spell-book__add-word-btn {
  opacity: 0.7;
}

@media (max-width: 520px) {
  .lwl-spell-book__add-word-row {
    grid-template-columns: minmax(0, 1fr) minmax(100px, 120px);
  }
}
