.gts-phrase-unavailable {
  margin: 1em 0;
  color: #475569;
}

.gts-phrase-app {
  box-sizing: border-box;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 4px 0 24px;
  color: #0f172a;
  line-height: 1.6;
  background: transparent;
}

.gts-phrase-app *,
.gts-phrase-app *::before,
.gts-phrase-app *::after {
  box-sizing: border-box;
}

.gts-phrase-app [hidden] {
  display: none !important;
}

.gts-phrase-heading:not([hidden]) {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 20px;
  margin: 0;
}

.gts-phrase-heading .gts-phrase-section-title,
.gts-phrase-heading .gts-phrase-context {
  margin: 0;
}

.gts-phrase-stance {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.gts-phrase-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 7.5rem;
  padding: 10px 16px;
  border: 2px solid #d1d5db;
  border-radius: 12px;
  background: #e5e7eb;
  color: #475569;
  cursor: pointer;
  font-weight: 700;
}

.gts-phrase-chip:hover,
.gts-phrase-chip:focus-visible {
  border-color: #9ca3af;
}

.gts-phrase-chip.is-on {
  color: #0f172a;
}

.gts-phrase-chip.is-on.is-blue {
  background: #dbeafe;
  border-color: #0ea5e9;
}

.gts-phrase-chip.is-on.is-yellow {
  background: #fef9c3;
  border-color: #eab308;
}

.gts-phrase-chip.is-on.is-red {
  background: #fee2e2;
  border-color: #f87171;
}

.gts-phrase-chip.is-on.is-brown {
  background: #f5ebe0;
  border-color: #b45309;
}

.gts-phrase-chip.is-on.is-green {
  background: #dcfce7;
  border-color: #22c55e;
}

.gts-phrase-chip.is-on.is-orange {
  background: #ffedd5;
  border-color: #fb923c;
}

.gts-phrase-pick-icons,
.gts-phrase-pick-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  width: 50%;
  max-width: 50%;
  margin: 0 auto;
}

.gts-phrase-pick-icons {
  margin: 0 auto 12px;
  justify-items: center;
  align-items: center;
}

.gts-phrase-pick-icon-btn {
  display: block;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  border-radius: 50%;
  line-height: 0;
}

.gts-phrase-pick-icon,
.gts-phrase-pick-icon.is-empty {
  display: block;
  width: 128px;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  height: auto;
  object-fit: cover;
  border-radius: 50%;
  background: #e2e8f0;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
  box-sizing: border-box;
  border: 3px solid transparent;
}

.gts-phrase-pick-icon-btn:hover .gts-phrase-pick-icon,
.gts-phrase-pick-icon-btn:focus-visible .gts-phrase-pick-icon {
  border-color: #fdba74;
  box-shadow: 0 0 0 2px #fb923c, 0 4px 12px rgba(15, 23, 42, 0.12);
}

.gts-phrase-pick-icon-btn:focus-visible {
  outline: none;
}

.gts-phrase-pick-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1;
  padding: 8px 6px;
  border: 1px solid #303030;
  border-radius: 12px;
  color: #0f172a;
  cursor: pointer;
  font-weight: 700;
  box-shadow: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.gts-phrase-pick-card:hover,
.gts-phrase-pick-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
}

.gts-phrase-pick-label {
  text-align: center;
  word-break: break-word;
  font-size: 32px;
  line-height: 1.2;
  font-weight: 700;
}

.gts-phrase-pick-card.is-blue {
  background: #dbeafe;
}

.gts-phrase-pick-card.is-blue:hover,
.gts-phrase-pick-card.is-blue:focus-visible {
  background: #eff6ff;
}

.gts-phrase-pick-card.is-yellow {
  background: #fef9c3;
}

.gts-phrase-pick-card.is-yellow:hover,
.gts-phrase-pick-card.is-yellow:focus-visible {
  background: #fefce8;
}

.gts-phrase-pick-card.is-red {
  background: #fee2e2;
}

.gts-phrase-pick-card.is-red:hover,
.gts-phrase-pick-card.is-red:focus-visible {
  background: #fef2f2;
}

.gts-phrase-pick-card.is-brown {
  background: #f5ebe0;
}

.gts-phrase-pick-card.is-brown:hover,
.gts-phrase-pick-card.is-brown:focus-visible {
  background: #faf6f1;
}

.gts-phrase-pick-card.is-green {
  background: #dcfce7;
}

.gts-phrase-pick-card.is-green:hover,
.gts-phrase-pick-card.is-green:focus-visible {
  background: #f0fdf4;
}

.gts-phrase-pick-card.is-orange {
  background: #ffedd5;
}

.gts-phrase-pick-card.is-orange:hover,
.gts-phrase-pick-card.is-orange:focus-visible {
  background: #fff7ed;
}

.gts-phrase-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.gts-phrase-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid #808080;
  border-radius: 12px;
  background: #fff;
  color: #0f172a;
  cursor: pointer;
  align-self: flex-start;
  font-weight: 600;
}

.gts-phrase-back:hover,
.gts-phrase-back:focus-visible {
  border-color: #7dd3fc;
  background: #f0f9ff;
}

.gts-phrase-section-title {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  margin: 0 0 16px;
  padding: 0 16px;
  background: #f5976c;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 24px;
  height: 64px;
  text-align: center;
  line-height: 64px;
  white-space: nowrap;
  overflow: hidden;
}

.gts-phrase-picker .gts-phrase-section-title {
  height: auto;
  min-height: 64px;
  line-height: 1.35;
  white-space: normal;
  padding: 12px 16px;
  margin-bottom: 36px;
}

.gts-phrase-context {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  margin: 0 0 16px;
  padding: 0 16px;
  background: #0ea5e9;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 24px;
  min-height: 64px;
  text-align: center;
  line-height: 1.35;
  word-break: break-word;
}

.gts-phrase-empty {
  padding: 24px 18px;
  line-height: 1.6;
  color: #475569;
}

.gts-phrase-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gts-phrase-nav-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  width: 100%;
  min-height: 88px;
  padding: 22px 18px;
  border: 1px solid #303030;
  border-radius: 16px;
  background: #fff;
  color: inherit;
  text-align: left;
  cursor: pointer;
  line-height: 1.45;
  word-break: break-word;
  font-weight: 700;
  font-size: 1.08rem;
  box-shadow: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gts-phrase-nav-card:hover,
.gts-phrase-nav-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.12);
  background: #f0f9ff;
}

.gts-phrase-nav-card-go {
  flex: 0 0 auto;
  color: #0ea5e9;
  font-size: 1.35rem;
  line-height: 1;
}

.gts-phrase-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 148px;
  padding: 22px 18px 24px;
  border: 1px solid #303030;
  border-radius: 16px;
  background: #fff;
  box-shadow: none;
}

.gts-phrase-card:hover,
.gts-phrase-card:focus-within {
  background: #f0fdf4;
  transform: none;
  box-shadow: none;
}

.gts-phrase-card-ja {
  display: inline-block;
  align-self: flex-start;
  width: fit-content;
  max-width: 100%;
  font-weight: 700;
  font-size: 20px;
  line-height: 1.5;
  word-break: break-word;
  background: #ffedd5;
  border-radius: 10px;
  padding: 4px 10px;
}

.gts-phrase-card-local {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gts-phrase-card-target {
  flex: 1 1 auto;
  line-height: 1.5;
  word-break: break-word;
  font-weight: 700;
  font-size: 32px;
}

.gts-phrase-card-kana,
.gts-phrase-card-en {
  font-size: 0.85em;
  line-height: 1.5;
  word-break: break-word;
  color: #64748b;
  font-weight: 400;
}

.gts-phrase-speak {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 44px;
  width: 44px;
  min-width: 44px;
  height: 44px;
  padding: 0;
  margin: 0;
  border: none;
  border-radius: 999px;
  background: #0ea5e9;
  color: #fff;
  cursor: pointer;
  box-shadow: none;
}

.gts-phrase-speak:hover,
.gts-phrase-speak:focus-visible {
  background: #0284c7;
  transform: scale(1.05);
}

.gts-phrase-speak::before {
  content: "▶";
  display: block;
  font-size: 0.85rem;
  line-height: 1;
  text-align: center;
}

.gts-phrase-guide {
  border: 1.5px solid #1b7a45;
  border-radius: 12px;
  padding: 18px 16px 16px;
  background: #fff;
  margin-top: 38px;
}

.gts-phrase-guide-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #111827;
  margin-bottom: 12px;
}

.gts-phrase-guide-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.gts-phrase-guide-steps li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: #374151;
  line-height: 1.4;
}

.gts-phrase-guide-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #1b7a45;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.gts-phrase-guide-ico {
  width: 28px;
  height: 28px;
  color: #1b7a45;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gts-phrase-guide-ico svg {
  width: 24px;
  height: 24px;
}

.gts-phrase-guide-note {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e5e7eb;
  font-size: 0.82rem;
  font-weight: 600;
  color: #6b7280;
  line-height: 1.5;
}
