:root {
  --poe-bg: #fdfcf7;
  --poe-surface: #ffffff;
  --poe-card: #ffffff;
  --poe-border: #f1eee6;
  --poe-border-focus: #4338ca;
  --poe-indigo: #4338ca;
  --poe-indigo-hover: #3730a3;
  --poe-bronze: #92400e;
  --poe-text: #1f2937;
  --poe-muted: #6b7280;
  --poe-radius: 8px;
}

body {
  margin: 0;
  padding: 0;
  line-height: 1.6;
}

.poe-container {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 20px;
}

.poe-header {
  padding: 40px 0 24px;
  border-bottom: 1px solid var(--poe-border);
  background: #ffffff;
}

.poe-breadcrumbs {
  font-size: 0.875rem;
  color: var(--poe-muted);
  margin-bottom: 12px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.poe-breadcrumbs a {
  color: var(--poe-indigo);
  text-decoration: none;
  font-weight: 600;
}

.poe-breadcrumbs a:hover {
  text-decoration: underline;
}

.poe-title {
  font-family: "Merriweather", Georgia, "Times New Roman", serif;
  font-size: 2.25rem;
  font-weight: 700;
  margin: 0 0 8px;
  color: #111827;
  letter-spacing: -0.02em;
}

.poe-subtitle {
  font-size: 1.0625rem;
  color: var(--poe-muted);
  margin: 0;
}

.poe-main {
  padding: 32px 0 60px;
}

/* Search Card */
.poe-card {
  background: var(--poe-card);
  border: 1px solid var(--poe-border);
  border-radius: var(--poe-radius);
  padding: 24px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.03);
  margin-bottom: 24px;
}

.poe-input-row {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.poe-input {
  flex: 1;
  background: #ffffff;
  border: 1.5px solid #d1d5db;
  color: var(--poe-text);
  padding: 12px 16px;
  border-radius: 6px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.15s ease;
}

.poe-input:focus {
  outline: none;
  border-color: var(--poe-border-focus);
}

.poe-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--poe-indigo);
  color: #ffffff;
  border: none;
  padding: 12px 22px;
  border-radius: 6px;
  font-size: 0.9375rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
  white-space: nowrap;
}

.poe-btn-primary:hover {
  background: var(--poe-indigo-hover);
}

.poe-filters-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.poe-filter-lbl {
  font-size: 0.8125rem;
  color: var(--poe-muted);
  font-weight: 700;
  text-transform: uppercase;
}

.poe-form-chip {
  background: #f8fafc;
  color: var(--poe-muted);
  border: 1px solid #d1d5db;
  border-radius: 16px;
  padding: 4px 12px;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.poe-form-chip.active {
  background: var(--poe-indigo);
  color: #ffffff;
  border-color: var(--poe-indigo);
  font-weight: 700;
}

.poe-presets {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.poe-preset-lbl {
  font-size: 0.75rem;
  color: var(--poe-muted);
  font-weight: 600;
}

.poe-chip {
  background: #ffffff;
  color: var(--poe-muted);
  border: 1px solid #d1d5db;
  border-radius: 14px;
  padding: 3px 10px;
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.poe-chip:hover {
  border-color: var(--poe-indigo);
  color: var(--poe-indigo);
}

/* Status Bar */
.poe-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  font-size: 0.875rem;
  color: var(--poe-muted);
  font-weight: 600;
}

/* Anthology List */
.poe-anthology-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 32px;
}

.poe-poem-card {
  background: #ffffff;
  border: 1px solid var(--poe-border);
  border-radius: var(--poe-radius);
  padding: 32px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.03);
}

.poe-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f3f4f6;
  margin-bottom: 20px;
}

.poe-poem-title {
  font-family: "Merriweather", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: #111827;
}

.poe-poem-author {
  font-size: 0.9375rem;
  color: var(--poe-bronze);
  font-weight: 600;
  margin: 0;
}

.poe-poem-tags {
  display: flex;
  gap: 6px;
  align-items: center;
}

.poe-tag {
  background: #e0e7ff;
  color: var(--poe-indigo);
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.poe-lines-body {
  font-family: "Merriweather", Georgia, serif;
  font-size: 1.0625rem;
  line-height: 1.85;
  color: #27272a;
  margin-bottom: 24px;
  white-space: pre-line;
  padding-left: 8px;
  border-left: 2px solid #e5e7eb;
}

.poe-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid #f3f4f6;
}

.poe-meter-info {
  font-size: 0.8125rem;
  color: var(--poe-muted);
}

.poe-btn-copy {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  color: var(--poe-indigo);
  border: 1px solid var(--poe-indigo);
  padding: 6px 14px;
  border-radius: 4px;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.poe-btn-copy:hover {
  background: #eef2ff;
}

/* Ad slots */
.poe-ad-container {
  width: 100%;
  margin: 36px 0;
  display: flex;
  justify-content: center;
}

.poe-ad-box {
  width: 100%;
  max-width: 728px;
  min-height: 280px;
  background: #ffffff;
  border: 1px dashed var(--poe-border);
  border-radius: var(--poe-radius);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Content */
.poe-content-section {
  margin-top: 48px;
}

.poe-content-section h2 {
  font-family: "Merriweather", Georgia, serif;
  font-size: 1.5rem;
  color: #111827;
  margin-bottom: 16px;
}

.poe-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin: 28px 0;
}

.poe-feature-card {
  background: #ffffff;
  border: 1px solid var(--poe-border);
  border-radius: var(--poe-radius);
  padding: 20px;
}

.poe-feature-card h3 {
  font-size: 1.125rem;
  margin: 0 0 8px;
  color: var(--poe-indigo);
}

.poe-feature-card p {
  font-size: 0.875rem;
  color: var(--poe-muted);
  margin: 0;
}

.poe-footer {
  background: #ffffff;
  border-top: 1px solid var(--poe-border);
  padding: 28px 0;
  text-align: center;
  font-size: 0.875rem;
  color: var(--poe-muted);
}

.poe-footer a {
  color: var(--poe-indigo);
  text-decoration: none;
  font-weight: 600;
}

.poe-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.poe-consent-inner {
  max-width: 920px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.poe-consent-text {
  font-size: 0.875rem;
  color: #cbd5e1;
  margin: 0;
}

.poe-consent-actions {
  display: flex;
  gap: 8px;
}

.poe-btn-consent-yes {
  background: var(--poe-indigo);
  color: #ffffff;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
}

.poe-btn-consent-no {
  background: transparent;
  color: #94a3b8;
  border: 1px solid #475569;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
}

.poe-spinner {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-right: 6px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  vertical-align: -2px;
  animation: poe-spin 0.6s linear infinite;
}

.poe-spinner-lg {
  width: 20px;
  height: 20px;
  border-width: 2.5px;
  display: block;
  margin: 0 auto 12px;
}

@keyframes poe-spin {
  to { transform: rotate(360deg); }
}

.poe-loading-state {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--poe-muted);
  font-weight: 700;
}

#poeSearchBtn:disabled {
  opacity: 0.75;
  cursor: wait;
}

.poe-poem-card {
  animation: poe-fade-in 0.25s ease-out;
}

@keyframes poe-fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}
/* tf:dark-palette — generated by migrate_chrome.py */
/* Neutrals inherit the shared chrome tokens so all tools share one
   ground; brand hues are kept and lightened, never inverted. */
[data-theme="dark"] {
  --poe-bg: var(--tf-surface);
  --poe-surface: var(--tf-surface);
  --poe-card: var(--tf-surface);
  --poe-border: var(--tf-surface);
  --poe-border-focus: #8781da;
  --poe-indigo: #8781da;
  --poe-indigo-hover: #8681da;
  --poe-bronze: #d38f66;
  --poe-text: var(--tf-ink);
  --poe-muted: var(--tf-ink-faint);
}
