.dnd5e.sheet.item .magic-item-list {
  list-style: none;
  margin: 0;
  padding: 0 5px;
  overflow-y: auto;
}

.dnd5e.sheet.item .magic-item-list .item {
  line-height: 30px;
  padding: 0 2px;
  border-bottom: 1px solid #c9c7b8;
}

.dnd5e.sheet.item .magic-item-list .item .item-name {
  cursor: pointer;
}

.dnd5e.sheet.item .magic-item-list .item:last-child {
  border-bottom: none;
}

.dnd5e.sheet.item .spell-slots,
.dnd5e.sheet.item .spell-comps {
  font-size: 12px;
  text-align: center;
  color: #7a7971;
  border-right: 1px solid #c9c7b8;
}

.dnd5e.sheet.item .magic-item-list .item .spell-dc:disabled {
  color: #9a9a9a;
  border-color: #dad9d9;
}

.dnd5e.sheet.item .magicitems-content input[type="text"],
.dnd5e.sheet.item .magicitems-content select {
  height: 24px;
  border: 1px solid #7a7971;
  background: rgba(0, 0, 0, 0.05);
}

.dnd5e.sheet.item .magicitems-content .magic-item-charges {
  flex: 0.5;
}

.dnd5e.sheet.item .spell-drag-content {
  height: 70px;
  text-align: center;
  color: #828180;
  line-height: 5;
  border: 2px #828180 dashed;
}

.dnd5e.sheet.item .magicitems-content .item-controls {
  flex-basis: 2rem;
  display: flex;
  justify-content: center;
}

.dnd5e.sheet.item .magicitems-content .item-detail select {
  width: 100%;
}

.dnd5e.sheet.actor .magicitems-head {
  margin-top: 10px;
}

.dnd5e.sheet.actor .spell-rechargeable,
.dnd5e.sheet.actor .spell-level,
.dnd5e.sheet.actor .spell-consumption,
.dnd5e.sheet.actor .spell-upcast {
  font-size: 12px;
  color: #7a7971;
  text-align: center;
  border-right: 1px solid #c9c7b8;
}

.dnd5e.sheet.actor .spell-rechargeable {
  flex: 0 0 180px;
}

.dnd5e.sheet.actor .spell-level {
  flex: 0 0 60px;
}

.dnd5e.sheet.actor .spell-consumption {
  flex: 0 0 80px;
}

.dnd5e.sheet.actor .spell-upcast {
  flex: 0 0 60px;
}

.dnd5e.sheet.actor .inventory-list .item .magic-item-image {
  flex: 0 0 30px;
  background-size: 30px;
  margin-right: 5px;
}

.dnd5e.sheet.item .magicitems-content select.magic-item-charges-type {
  flex: 0.5;
}

.dnd5e.sheet.item .magicitems-content select.magic-item-destroy-check {
  flex: 0.5;
}

.dnd5e.sheet.item .magicitems-content select.magic-item-destroy-type {
  flex: 0.5;
}

.dnd5e.sheet.item .magicitems-content input.magic-item-destroy-dc {
  flex: 0.5;
}

.dnd5e.sheet.item .magicitems-content select.magic-item-destroy-check:disabled {
  color: #9a9a9a;
  border-color: #dad9d9;
}

.dnd5e.sheet.item .magicitems-content select.magic-item-destroy-type:disabled {
  color: #9a9a9a;
  border-color: #dad9d9;
}

.dnd5e.sheet.item .magicitems-content input.magic-item-recharge:disabled {
  color: #9a9a9a;
  border-color: #dad9d9;
}

.dnd5e.sheet.item .magicitems-content input.magic-item-destroy-dc:disabled {
  color: #9a9a9a;
  border-color: #dad9d9;
}

:not(.tidy5e).sheet .items-list .item .item-name .item-image .fa-dice-d20 {
  display: none;
}

/* New Tidy Styles */
[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"] .spell-rechargeable {
  flex: 0 0 11.25rem;
  text-align: center;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"] .spell-level {
  flex: 0 0 3.75rem;
  text-align: center;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"] .spell-consumption {
  flex: 0 0 5rem;
  text-align: center;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"] .spell-upcast {
  flex: 0 0 3.75rem;
  text-align: center;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"] .magicitems-spells-content .spell-slots > * {
  flex: 0;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"]
  :is(.magicitems-spells-content, .magicitems-feats-content)
  .magicitems-head
  h3 {
  font-size: 0.8125rem;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Actor"]
  :is(.magicitems-spells-content, .magicitems-feats-content)
  .magicitems-head {
  margin: 0 0 0.5rem 0.5rem;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Item"] .magicitems-content {
  flex: 1;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Item"] .magicitems-content .item-detail select {
  width: 100%;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Item"] .magicitems-content .item-controls {
  flex-basis: 2rem;
  display: flex;
  justify-content: center;
}

[data-sheet-module="tidy5e-sheet"][data-document-name="Item"] .magicitems-content .spell-drag-content {
  margin: 0.25rem;
  height: 4.375rem;
  text-align: center;
  color: var(--t5e-primary-font-color);
  color: var(--t5ek-primary-font-color);
  line-height: 5;
  border: 0.125rem dashed;
  border-color: var(--t5e-primary-font-color);
  border-color: var(--t5ek-primary-font-color);
}

.dnd5e2 .items-section .items-header .spell-slots,
.dnd5e2 .items-section .item .spell-slots {
  width: 50px;
}

.dnd5e2 .editable .items-section .items-header .spell-slots input {
  color: white;
  width: 50%;
}

.dnd5e2 .items-section .items-header .spell-rechargeable,
.dnd5e2 .items-section .item .spell-rechargeable {
  width: 150px;
  display: flex;
  gap: 0.1875rem;
  align-self: center;
  align-items: baseline;
}

.dnd5e2 .items-section .items-header .spell-level,
.dnd5e2 .items-section .item .spell-level {
  width: 40px;
}

.dnd5e2 .items-section .items-header .spell-consumption,
.dnd5e2 .items-section .item .spell-consumption {
  width: 60px;
}

.dnd5e2 .items-section .items-header .spell-upcast,
.dnd5e2 .items-section .item .spell-upcast {
  width: 50px;
  justify-content: center;
  padding: 0;
  position: relative;
}

.dnd5e2 .items-section .items-header .feat-consumption,
.dnd5e2 .items-section .item .feat-consumption {
  width: 70px;
  justify-content: center;
  padding: 0;
  position: relative;
}
