/*
 * Anvil Chapters - Frontend-Styling
 *
 * Nutzt DIREKT die echten CSS-Variablen des Anvil-of-War-Themes
 * (--bg-body, --bg-card, --accent, --gold, --text-body, --text-muted, --border
 * usw., siehe style.css "COLOUR SCHEME TOKENS"). Kein eigenes Fallback-System
 * mehr nötig, da dieses Plugin ausschließlich für dieses Theme gebaut ist.
 *
 * Jeder Chapter kann sein eigenes data-scheme=".." tragen (siehe
 * class-ach-render.php); da [data-scheme] eine reine Attribut-Selektor-Regel
 * ist, wirkt das automatisch nur innerhalb von .ach-chapter, ohne die globale
 * Farbschema-Wahl der Besucherin auf dem Rest der Seite zu beeinflussen.
 */

.ach-chapter {
	max-width: var(--content-max, 1140px);
	margin: 0 auto;
	padding: 2rem 1.5rem 4rem;
	background: var(--bg-content);
	color: var(--text-body);
}

.ach-hero {
	text-align: center;
	padding-bottom: 1.75rem;
	margin-bottom: 1.75rem;
	border-bottom: 2px solid var(--accent);
}

.ach-hero-logo {
	max-width: 140px;
	height: auto;
	margin: 0 auto 1rem;
	display: block;
	border-radius: var(--radius-sm, 4px);
	border: 1px solid var(--border-hi);
}

.ach-hero-title {
	margin: 0 0 0.4rem;
	color: var(--gold);
}

.ach-hero-motto {
	margin: 0;
	font-style: italic;
	color: var(--text-muted);
}

.ach-section {
	margin-bottom: 2.5rem;
	scroll-margin-top: calc(var(--hdr-height, 62px) + 16px);
}

.ach-section h2 {
	color: var(--gold);
	border-bottom: 1px solid var(--border-hi);
	padding-bottom: 0.4rem;
}

.ach-section h3 {
	color: var(--accent-hi);
	text-transform: none;
	letter-spacing: 0.02em;
	margin-top: 1.4rem;
}

.ach-kv-table,
.ach-compare-table,
.ach-paint-table {
	width: 100%;
	border-collapse: collapse;
	margin: 0.75rem 0 1.25rem;
	font-size: 0.92rem;
}

.ach-kv-table th,
.ach-kv-table td,
.ach-compare-table th,
.ach-compare-table td,
.ach-paint-table th,
.ach-paint-table td {
	padding: 0.5rem 0.7rem;
	border-bottom: 1px solid var(--border);
	text-align: left;
	vertical-align: top;
}

.ach-kv-table th {
	width: 34%;
	color: var(--text-muted);
	font-weight: 600;
}

.ach-compare-table th,
.ach-paint-table thead th {
	background: var(--bg-surface);
	color: var(--gold);
}

.ach-kv-table-inline th {
	width: auto;
}

.ach-one-sentence {
	font-size: 1.1rem;
	text-align: center;
	margin: 1.25rem 0;
	color: var(--text-head);
}

.ach-pillars {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 1rem;
	margin: 1rem 0;
}

.ach-pillar {
	background: var(--bg-card);
	border: 1px solid var(--border);
	border-radius: var(--radius-md, 8px);
	padding: 1rem;
}

.ach-pillar h4 {
	margin: 0 0 0.4rem;
	color: var(--gold);
	text-transform: none;
}

.ach-tonality {
	columns: 2;
	gap: 2rem;
	color: var(--text-body);
}

.ach-card-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 1.25rem;
}

.ach-card {
	background: var(--bg-card);
	border: 1px solid var(--border);
	border-radius: var(--radius-md, 8px);
	padding: 1.1rem;
}

.ach-card h3 {
	margin-top: 0;
}

.ach-card-meta {
	color: var(--text-muted);
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

.ach-portrait {
	width: 100%;
	max-width: 180px;
	height: auto;
	border-radius: var(--radius-sm, 4px);
	margin-bottom: 0.75rem;
}

.ach-hero-box {
	margin-top: 0.75rem;
	padding-top: 0.75rem;
	border-top: 1px dashed var(--border);
}

.ach-quote {
	font-style: italic;
	color: var(--text-muted);
}

.ach-anecdote {
	color: var(--text-muted);
	font-size: 0.92rem;
}

.ach-campaign {
	margin-bottom: 1.75rem;
}

.ach-swatch {
	display: inline-block;
	width: 14px;
	height: 14px;
	border-radius: 2px;
	vertical-align: middle;
	margin-right: 4px;
	border: 1px solid rgba(255,255,255,0.3);
}

/* --- Chapter-Liste / Archiv-Karten --- */

.ach-list-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 1.25rem;
}

.ach-list-card {
	display: block;
	text-align: center;
	background: var(--bg-card);
	border: 1px solid var(--border);
	border-radius: var(--radius-md, 8px);
	padding: 1.25rem 1rem;
	text-decoration: none;
	color: var(--text-body);
	transition: border-color var(--transition, .2s ease), transform var(--transition, .2s ease);
}

.ach-list-card:hover,
.ach-list-card:focus-visible {
	border-color: var(--gold);
	transform: translateY(-2px);
}

.ach-list-card img {
	max-width: 90px;
	height: auto;
	margin: 0 auto 0.75rem;
	display: block;
	border-radius: var(--radius-sm, 4px);
}

.ach-list-card h3 {
	margin: 0 0 0.3rem;
	color: var(--gold);
	font-size: 1rem;
}

.ach-list-card p {
	margin: 0;
	font-size: 0.85rem;
	font-style: italic;
	color: var(--text-muted);
}

@media (prefers-reduced-motion: reduce) {
	.ach-list-card { transition: none; }
}

@media (max-width: 600px) {
	.ach-tonality { columns: 1; }
	.ach-chapter { padding: 1.25rem 0.9rem; }
}

/* -- Dossier-PDF-Download (seit 1.2.0) -- */

.ach-hero-actions {
	margin: 1rem 0 0;
}

.ach-dossier-btn {
	display: inline-block;
	padding: 0.45rem 1.1rem;
	border: 1px solid var(--accent, #8a2417);
	border-radius: var(--radius-sm, 4px);
	color: var(--accent, #8a2417);
	text-decoration: none;
	font-size: 0.9rem;
	letter-spacing: 0.02em;
	transition: background 0.15s ease, color 0.15s ease;
}

.ach-dossier-btn:hover,
.ach-dossier-btn:focus {
	background: var(--accent, #8a2417);
	color: var(--bg-card, #fff);
}
