.wd-practice-drawer__year-wheel-copy {
  display: grid;
  min-width: 0;
  gap: 3px;
  justify-items: start;
}

.wd-practice-drawer__year-wheel-title {
  color: var(--wd-practice-title);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
}

.wd-practice-drawer__year-wheel-next,
.wd-practice-drawer__year-wheel-countdown {
  color: var(--wd-practice-muted);
  font-size: .74rem;
  line-height: 1.35;
}

.wd-practice-drawer__year-wheel-button {
  display: grid;
  width: var(--wd-practice-control-size, 82px);
  height: var(--wd-practice-control-size, 82px);
  margin: 0;
  padding: 4px;
  overflow: hidden;
  place-items: center;
  border: 1px solid rgba(228, 191, 99, .42);
  border-radius: 50%;
  background: #182425;
  box-shadow: inset 0 0 12px rgba(0, 0, 0, .28), 0 0 18px rgba(228, 191, 99, .16);
  cursor: pointer;
  transition: filter .2s ease, transform .2s ease;
}

.wd-practice-drawer__year-wheel-button:hover {
  filter: brightness(1.08);
  transform: translateY(-2px) scale(1.035);
}

.wd-practice-drawer__year-wheel-button:focus-visible {
  outline: 3px solid #C69E3C;
  outline-offset: 4px;
}

.wd-practice-drawer__year-wheel-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

body.year-wheel-modal-open {
  overflow: hidden;
}

.year-wheel-modal[hidden] {
  display: none;
}

.year-wheel-modal {
  position: fixed;
  z-index: 2147483646;
  inset: 0;
  display: grid;
  padding: 20px;
  place-items: center;
  color: #25302E;
  font: inherit;
  opacity: 0;
  transition: opacity .18s ease;
}

.year-wheel-modal.is-open {
  opacity: 1;
}

.year-wheel-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 12, 14, .76);
  backdrop-filter: blur(7px);
}

.year-wheel-modal__dialog {
  position: relative;
  display: block;
  width: min(900px, 100%);
  max-height: min(92vh, 940px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  border: 1px solid rgba(181, 139, 55, .42);
  border-radius: 24px;
  background:
    radial-gradient(circle at 88% 4%, rgba(47, 145, 147, .13), transparent 30%),
    linear-gradient(155deg, #FBF7ED, #EEE3CB);
  box-shadow: 0 34px 90px rgba(0, 0, 0, .42), inset 0 1px rgba(255, 255, 255, .8);
  transform: translateY(14px) scale(.985);
  transition: transform .2s ease;
}

.year-wheel-modal.is-open .year-wheel-modal__dialog {
  transform: translateY(0) scale(1);
}

.year-wheel-modal__dialog:focus {
  outline: none;
}

.year-wheel-modal__header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 22px 15px;
  border-bottom: 1px solid rgba(111, 82, 35, .16);
  background: linear-gradient(155deg, #FBF7ED, #F2E8D3);
}

.year-wheel-modal__eyebrow {
  display: block;
  color: #936922;
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .09em;
  line-height: 1.2;
  text-transform: uppercase;
}

.year-wheel-modal__title {
  margin: 4px 0 0;
  color: #153B3D;
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  line-height: 1.15;
}

.year-wheel-modal__close {
  display: grid;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  padding: 0 0 3px;
  place-items: center;
  border: 1px solid rgba(122, 79, 29, .25);
  border-radius: 50%;
  background: rgba(255, 255, 255, .54);
  color: #61441C;
  font: inherit;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}

.year-wheel-modal__close:hover,
.year-wheel-modal__nav-button:hover,
.year-wheel-modal__today:hover {
  border-color: rgba(43, 145, 147, .52);
  background: rgba(43, 145, 147, .1);
}

.year-wheel-modal__close:focus-visible,
.year-wheel-modal__nav-button:focus-visible,
.year-wheel-modal__today:focus-visible,
.year-wheel-modal__festival:focus-visible {
  outline: 3px solid #C69E3C;
  outline-offset: 3px;
}

.year-wheel-modal__body {
  display: grid;
  gap: 18px;
  padding: 18px 22px 24px;
}

.year-wheel-modal__today-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #704A1B;
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .035em;
}

.year-wheel-modal__today-line::before,
.year-wheel-modal__today-line::after {
  width: min(80px, 14vw);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(140, 95, 40, .5));
  content: "";
}

.year-wheel-modal__today-line::after {
  transform: scaleX(-1);
}

.year-wheel-modal__stage {
  --wheel-size: min(58vw, 520px);
  position: relative;
  width: var(--wheel-size);
  height: var(--wheel-size);
  margin: 0 auto;
}

.year-wheel-modal__pointer {
  position: absolute;
  z-index: 12;
  top: -3px;
  left: 50%;
  width: 0;
  height: 0;
  border-right: 9px solid transparent;
  border-left: 9px solid transparent;
  border-top: 15px solid #B58A2C;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .28));
  transform: translateX(-50%);
}

.year-wheel-modal__image-wrap {
  position: absolute;
  z-index: 1;
  inset: 10%;
  display: grid;
  place-items: center;
  border-radius: 50%;
  filter: drop-shadow(0 15px 22px rgba(38, 28, 16, .24));
  transition: transform .85s cubic-bezier(.2, .72, .24, 1);
}

.year-wheel-modal__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.year-wheel-modal__scale {
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
}

.year-wheel-modal__scale-ring {
  position: absolute;
  inset: 17.5%;
  border: 1px solid rgba(255, 249, 230, .62);
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(83, 54, 19, .34), 0 0 14px rgba(0, 0, 0, .2);
}

.year-wheel-modal__scale-mark,
.year-wheel-modal__scale-month {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1px;
  height: 1px;
  transform: translate(-50%, -50%);
  transition: transform .65s cubic-bezier(.2, .72, .24, 1);
}

.year-wheel-modal__scale-mark i {
  position: absolute;
  top: -4px;
  left: 0;
  display: block;
  width: 1px;
  height: 8px;
  background: rgba(255, 249, 230, .72);
  box-shadow: 0 0 2px rgba(34, 23, 10, .9);
}

.year-wheel-modal__scale-month b {
  position: absolute;
  display: grid;
  min-width: 31px;
  min-height: 19px;
  padding: 2px 4px;
  place-items: center;
  border: 1px solid rgba(228, 191, 99, .42);
  border-radius: 7px;
  background: rgba(20, 34, 32, .82);
  box-shadow: 0 2px 7px rgba(0, 0, 0, .28);
  color: #FFF1C6;
  font-size: .58rem;
  font-weight: 800;
  letter-spacing: .025em;
  line-height: 1;
  transform: translate(-50%, -50%);
  text-transform: uppercase;
}

.year-wheel-modal__festivals {
  position: absolute;
  z-index: 6;
  inset: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.year-wheel-modal__festival-item {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 1px;
  height: 1px;
}

.year-wheel-modal__festival {
  position: absolute;
  display: grid;
  width: 78px;
  min-height: 42px;
  padding: 5px 7px;
  place-items: center;
  border: 1px solid rgba(111, 82, 35, .18);
  border-radius: 11px;
  background: rgba(255, 251, 240, .9);
  box-shadow: 0 5px 14px rgba(70, 47, 20, .11);
  color: #6A4B20;
  font: inherit;
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: border-color .18s ease, box-shadow .18s ease, color .18s ease, transform .65s cubic-bezier(.2, .72, .24, 1);
}

.year-wheel-modal__festival strong,
.year-wheel-modal__festival small {
  display: block;
  line-height: 1.1;
}

.year-wheel-modal__festival strong {
  font-size: .7rem;
}

.year-wheel-modal__festival small {
  color: #82745F;
  font-size: .6rem;
  font-weight: 600;
}

.year-wheel-modal__festival.is-selected {
  border-color: rgba(181, 138, 44, .78);
  box-shadow: 0 0 0 3px rgba(228, 191, 99, .2), 0 7px 18px rgba(70, 47, 20, .16);
  color: #936922;
}

.year-wheel-modal__festival.is-next::after {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 10px;
  height: 10px;
  border: 2px solid #FFF8E9;
  border-radius: 50%;
  background: #2B918F;
  content: "";
}

.year-wheel-modal__controls {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 10px;
}

.year-wheel-modal__nav-button,
.year-wheel-modal__today {
  min-height: 42px;
  padding: 8px 14px;
  border: 1px solid rgba(122, 79, 29, .24);
  border-radius: 12px;
  background: rgba(255, 255, 255, .48);
  color: #2D5655;
  font: inherit;
  font-size: .8rem;
  font-weight: 750;
  cursor: pointer;
}

.year-wheel-modal__nav-button--next {
  justify-self: stretch;
}

.year-wheel-modal__card {
  display: grid;
  gap: 11px;
  padding: 18px 20px;
  border: 1px solid rgba(101, 82, 46, .16);
  border-radius: 18px;
  background: rgba(255, 255, 255, .4);
  box-shadow: inset 0 1px rgba(255, 255, 255, .65);
}

.year-wheel-modal__card-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.year-wheel-modal__card-title {
  margin: 0;
  color: #704A1B;
  font-size: 1.18rem;
}

.year-wheel-modal__card-date {
  color: #936922;
  font-size: .8rem;
  font-weight: 800;
  text-align: right;
}

.year-wheel-modal__card-lead,
.year-wheel-modal__card-note {
  margin: 0;
  color: #5F685F;
  font-size: .88rem;
  line-height: 1.55;
}

.year-wheel-modal__card-note {
  color: #7B6543;
  font-size: .78rem;
}

.year-wheel-modal__symbols {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.year-wheel-modal__symbol {
  padding: 5px 9px;
  border: 1px solid rgba(111, 82, 35, .14);
  border-radius: 999px;
  background: rgba(181, 138, 44, .08);
  color: #685435;
  font-size: .72rem;
  font-weight: 700;
}

:root[data-wd-theme="dark"] .year-wheel-modal {
  color: #F2E8CF;
}

:root[data-wd-theme="dark"] .year-wheel-modal__dialog {
  border-color: rgba(228, 191, 99, .3);
  background:
    radial-gradient(circle at 88% 4%, rgba(47, 145, 147, .16), transparent 30%),
    linear-gradient(155deg, #152725, #0C171A);
  box-shadow: 0 34px 90px rgba(0, 0, 0, .7), inset 0 1px rgba(255, 244, 205, .08);
}

:root[data-wd-theme="dark"] .year-wheel-modal__header {
  border-bottom-color: rgba(228, 191, 99, .16);
  background: linear-gradient(155deg, #152725, #101F20);
}

:root[data-wd-theme="dark"] .year-wheel-modal__title,
:root[data-wd-theme="dark"] .year-wheel-modal__card-title {
  color: #F1D57E;
}

:root[data-wd-theme="dark"] .year-wheel-modal__eyebrow,
:root[data-wd-theme="dark"] .year-wheel-modal__card-date,
:root[data-wd-theme="dark"] .year-wheel-modal__today-line {
  color: #D9B75E;
}

:root[data-wd-theme="dark"] .year-wheel-modal__close,
:root[data-wd-theme="dark"] .year-wheel-modal__nav-button,
:root[data-wd-theme="dark"] .year-wheel-modal__today {
  border-color: rgba(228, 191, 99, .22);
  background: rgba(255, 249, 238, .06);
  color: #F2E8CF;
}

:root[data-wd-theme="dark"] .year-wheel-modal__festival {
  border-color: rgba(228, 191, 99, .22);
  background: rgba(13, 27, 28, .92);
  color: #E9DAB5;
  box-shadow: 0 5px 14px rgba(0, 0, 0, .28);
}

:root[data-wd-theme="dark"] .year-wheel-modal__festival small {
  color: #AAA38F;
}

:root[data-wd-theme="dark"] .year-wheel-modal__festival.is-selected {
  border-color: rgba(228, 191, 99, .72);
  color: #F1D57E;
}

:root[data-wd-theme="dark"] .year-wheel-modal__festival.is-next::after {
  border-color: #122426;
}

:root[data-wd-theme="dark"] .year-wheel-modal__scale-ring {
  border-color: rgba(228, 191, 99, .52);
  box-shadow: 0 0 0 1px rgba(5, 12, 13, .62), 0 0 14px rgba(0, 0, 0, .42);
}

:root[data-wd-theme="dark"] .year-wheel-modal__scale-mark i {
  background: rgba(241, 213, 126, .7);
}

:root[data-wd-theme="dark"] .year-wheel-modal__scale-month b {
  border-color: rgba(228, 191, 99, .38);
  background: rgba(8, 22, 23, .86);
  color: #F1D57E;
}

:root[data-wd-theme="dark"] .year-wheel-modal__card {
  border-color: rgba(228, 191, 99, .16);
  background: rgba(255, 249, 238, .045);
  box-shadow: inset 0 1px rgba(255, 244, 205, .05);
}

:root[data-wd-theme="dark"] .year-wheel-modal__card-lead {
  color: #C5C9BB;
}

:root[data-wd-theme="dark"] .year-wheel-modal__card-note {
  color: #B7A77E;
}

:root[data-wd-theme="dark"] .year-wheel-modal__symbol {
  border-color: rgba(228, 191, 99, .16);
  background: rgba(228, 191, 99, .07);
  color: #D6C89E;
}

@media (max-width: 700px) {
  .year-wheel-modal {
    padding: 8px;
  }

  .year-wheel-modal__dialog {
    max-height: 96vh;
    border-radius: 19px;
  }

  .year-wheel-modal__header {
    padding: 14px 15px 12px;
  }

  .year-wheel-modal__body {
    gap: 14px;
    padding: 14px 12px 18px;
  }

  .year-wheel-modal__stage {
    --wheel-size: min(92vw, 430px);
  }

  .year-wheel-modal__image-wrap {
    inset: 14%;
  }

  .year-wheel-modal__festival {
    width: 66px;
    min-height: 38px;
    padding: 4px 5px;
  }

  .year-wheel-modal__festival strong {
    font-size: .62rem;
  }

  .year-wheel-modal__festival small {
    font-size: .56rem;
  }

  .year-wheel-modal__scale-ring {
    inset: 31%;
  }

  .year-wheel-modal__scale-month b {
    min-width: 27px;
    min-height: 17px;
    padding: 2px 3px;
    font-size: .52rem;
  }

  .year-wheel-modal__controls {
    grid-template-columns: 1fr 1fr;
  }

  .year-wheel-modal__today {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .year-wheel-modal__card {
    padding: 15px;
  }

  .year-wheel-modal__card-heading {
    display: grid;
    gap: 3px;
  }

  .year-wheel-modal__card-date {
    text-align: left;
  }
}

@media (max-width: 420px) {
  .year-wheel-modal__stage {
    --wheel-size: calc(100vw - 32px);
  }

  .year-wheel-modal__festival {
    width: 61px;
  }

  .year-wheel-modal__scale-month b {
    min-width: 25px;
    font-size: .49rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wd-practice-drawer__year-wheel-button,
  .year-wheel-modal,
  .year-wheel-modal__dialog,
  .year-wheel-modal__image-wrap,
  .year-wheel-modal__festival,
  .year-wheel-modal__scale-mark,
  .year-wheel-modal__scale-month {
    transition: none;
  }
}
