/* Materials catalog — filters + card grid (eisai-core) */

.eisai-mc-filters {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

@media (min-width: 768px) {
  .eisai-mc-filters {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-start;
  }
}

.eisai-mc-select {
  position: relative;
  max-width: 480px;
  width: 100%;
}

@media (min-width: 768px) {
  .eisai-mc-select {
    width: 306px;
  }
}

.eisai-mc-select-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 56px;
  padding: 12px 16px;
  border: 1px solid #d9d9d9;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  font-size: 16px;
  color: #1e1e1e;
  user-select: none;
}

.eisai-mc-select.open .eisai-mc-select-header {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-color: #9c026c;
}

.eisai-mc-select-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.eisai-mc-select-title img {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.eisai-mc-select-title span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.eisai-mc-select-arrow {
  display: inline-flex;
  transition: transform 0.2s ease;
}

.eisai-mc-select.open .eisai-mc-select-arrow {
  transform: rotate(90deg);
}

.eisai-mc-select-arrow img {
  width: 7px;
  height: 14px;
  transform: rotate(270deg);
}

.eisai-mc-select-options {
  display: none;
  position: relative;
  z-index: 20;
  background: #fff;
  border: 1px solid #9c026c;
  border-top: 0;
  border-radius: 0 0 12px 12px;
  padding: 0 16px 12px;
  max-height: 280px;
  overflow-y: auto;
}

@media (min-width: 768px) {
  .eisai-mc-select-options {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
  }
}

.eisai-mc-select.open .eisai-mc-select-options {
  display: block;
}

.eisai-mc-divider {
  margin: 0 0 15px;
  border-top: 1px solid #d9d9d9;
}

.eisai-mc-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
  cursor: pointer;
  font-size: 18px;
  color: #1e1e1e;
}

.eisai-mc-checkbox input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.eisai-mc-checkmark {
  width: 20px;
  height: 20px;
  border: 1.5px solid #8f96a1;
  border-radius: 4px;
  flex-shrink: 0;
  position: relative;
  background: #fff;
}

.eisai-mc-checkbox input:checked + .eisai-mc-checkmark {
  background: #9c026c;
  border-color: #9c026c;
}

.eisai-mc-checkbox input:checked + .eisai-mc-checkmark::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.eisai-mc-apply {
  margin-left: 0;
}

@media (min-width: 768px) {
  .eisai-mc-apply {
    margin-left: auto;
  }
}

.eisai-mc-apply .button {
  min-width: 170px;
  height: 56px !important;
  margin-top: 0 !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.eisai-mc-grid {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  gap: 20px 36px;
  --card-width: 100%;
}

@media (min-width: 768px) {
  .eisai-mc-grid {
    flex-direction: row;
  }
}

.eisai-mc-card {
  width: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  border: 3px solid #b5007c;
  box-sizing: border-box;
}

@media (min-width: 768px) {
  .eisai-mc-card {
    width: var(--card-width);
  }
}

.eisai-mc-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  font-size: 13px;
  color: #8f96a1;
}

.eisai-mc-card-link {
  text-decoration: none !important;
  color: inherit;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.eisai-mc-card-media {
  position: relative;
  margin: 0 10px;
}

.eisai-mc-card-media-inner {
  border-radius: 10px;
  overflow: hidden;
  height: 249px;
  background: #eef1f4;
}

.eisai-mc-card-media-inner img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  display: block;
}

.eisai-mc-fav {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 0;
  background: #fff;
  box-shadow: 0 0 3px #343434;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.eisai-mc-fav svg {
  width: 18px;
  height: 18px;
}

.eisai-mc-fav.is-on svg {
  fill: #ef4444;
  color: #ef4444;
}

.eisai-mc-fav:not(.is-on) svg {
  fill: none;
  stroke: #4b5563;
  stroke-width: 2;
}

.eisai-mc-chips {
  position: absolute;
  bottom: 10px;
  left: 10px;
  right: 10px;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-end;
  gap: 8px;
}

.eisai-mc-chips-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-start;
  min-width: 0;
  max-width: 58%;
}

.eisai-mc-chip {
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  line-height: 1.3;
}

.eisai-mc-chip-type {
  flex-shrink: 0;
  align-self: flex-end;
  text-align: right;
}

.eisai-mc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 10px 0;
  padding: 0 10px;
  align-items: flex-start;
}

.eisai-mc-tag {
  display: block;
  padding: 9px;
  border: 1.2px solid #8f96a1;
  border-radius: 7px;
  color: #8f96a1;
  line-height: 1.28;
  font-size: 12px;
}

@media (min-width: 768px) {
  .eisai-mc-tag {
    font-size: 14px;
  }
}

.eisai-mc-card-title {
  font-size: 18px;
  font-weight: 400;
  color: #000;
  padding: 0 10px 15px;
  line-height: 1.35;
}

.eisai-mc-status {
  padding: 40px 16px;
  text-align: center;
  color: #8f96a1;
  font-size: 16px;
}

.eisai-mc-status.is-error {
  color: #9c026c;
}

.eisai-mc-more-wrap {
  margin-top: 40px;
  display: flex;
  justify-content: center;
}

.eisai-mc-more {
  min-width: 10rem;
  padding: 0.875rem 2.5rem;
  border-radius: 12px;
  border: 1px solid #8f96a1;
  background: #fff;
  color: #1e1e1e;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.eisai-mc-more:hover {
  background: #f5f7f9;
}

.eisai-mc-more:disabled {
  opacity: 0.6;
  cursor: default;
}
