:root {
  --progress-completed: #174d38;
}

.resume-card {
  width: min(920px, 90vw);
  margin: 0 auto 26px;
  padding: 14px 16px;
  border: 1px solid #cfc8b6;
  border-left: 3px solid var(--forest);
  border-radius: 3px;
  background: #faf8f1d9;
  box-shadow: 0 8px 28px #39332608;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.resume-copy {
  min-width: 0;
}

.resume-kicker {
  margin: 0 0 4px;
  color: #85837a;
  letter-spacing: .11em;
  font-size: 10px;
}

.resume-title {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.45;
}

.resume-title strong {
  margin-right: 7px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  font-weight: 400;
}

.resume-meta {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.resume-button,
.export-card-button {
  flex: none;
  min-height: 34px;
  padding: 7px 14px;
  border: 1px solid var(--forest);
  border-radius: 18px;
  background: transparent;
  color: var(--forest);
  cursor: pointer;
  font-size: 12px;
  transition: background .18s, color .18s, transform .18s;
}

.resume-button:hover,
.export-card-button:hover {
  background: var(--forest);
  color: #fff;
}

.resume-button:active,
.export-card-button:active {
  transform: translateY(1px);
}

.resume-button:focus-visible,
.export-card-button:focus-visible,
.study-complete-toggle:focus-visible {
  outline: 2px solid var(--rust);
  outline-offset: 2px;
}

.learning-summary {
  min-height: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
}

.learning-summary-title {
  white-space: nowrap;
  color: #85837a;
  letter-spacing: .09em;
  font-size: 10px;
}

.learning-summary strong {
  margin: 0 2px;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 14px;
  font-weight: 400;
}

.learning-summary .is-completed strong {
  color: var(--progress-completed);
}

.learning-summary-note {
  margin-left: auto;
  color: #8e8b82;
  font-size: 10px;
}

.card-learning-actions {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px dashed #d9d3c5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.study-complete-toggle {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1.5px solid #aaa697;
  border-radius: 50%;
  background: #faf8f1;
  cursor: pointer;
  box-shadow: 0 1px 3px #39332610;
  transition: background .18s, border-color .18s, transform .18s;
}

.study-complete-toggle:hover {
  border-color: var(--forest);
  transform: scale(1.08);
}

.study-complete-toggle.is-complete {
  border-color: var(--forest);
  background: var(--forest);
}

.word-card.is-resume-target {
  animation: resume-card-highlight 1.6s ease;
}

@keyframes resume-card-highlight {
  0%, 100% { box-shadow: 0 8px 28px #39332608; }
  28% { box-shadow: 0 0 0 3px #174d3838, 0 8px 28px #39332608; }
}

.export-card-button[aria-busy="true"] {
  cursor: wait;
  opacity: .68;
}

.feature-toast {
  position: fixed;
  z-index: 50;
  left: 50%;
  bottom: 28px;
  max-width: min(90vw, 520px);
  padding: 10px 16px;
  border: 1px solid #ffffff26;
  border-radius: 22px;
  background: #171913ee;
  color: #fff;
  box-shadow: 0 10px 28px #17191338;
  font-size: 12px;
  line-height: 1.45;
  opacity: 0;
  transform: translate(-50%, 10px);
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}

.feature-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 700px) {
  .resume-card {
    width: 90vw;
    margin-bottom: 18px;
    padding: 12px 13px;
    align-items: flex-end;
  }

  .resume-title strong {
    display: block;
    margin-bottom: 1px;
  }

  .resume-button {
    padding-inline: 12px;
  }

  .learning-summary {
    gap: 8px;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
  }

  .learning-summary::-webkit-scrollbar {
    display: none;
  }

  .learning-summary-note {
    display: none;
  }

  .export-card-button {
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .feature-toast,
  .resume-button,
  .export-card-button,
  .study-complete-toggle {
    transition: none;
  }
}
