/* ===== ACCESSIBILITY ===== */
:root {
	--green-dark: #00483c;
	--green-darker: #1a2e28;
	--green-text: #313e3b;
	--yellow: #d5d52b;
	--yellow-dark: #b8b824;
	--radius: 6px;
}

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border-width: 0;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }
@keyframes slideDown { from { opacity: 0; transform: translateY(-5px) } to { opacity: 1; transform: translateY(0) } }
.fade-in  { animation: fadeIn 0.2s ease }
.slide-down { animation: slideDown 0.2s ease }
.sidebar-nav::-webkit-scrollbar       { width: 4px }
.sidebar-nav::-webkit-scrollbar-track { background: transparent }
.sidebar-nav::-webkit-scrollbar-thumb { background: rgba(213,213,43,.45); border-radius: 2px }
html, body { margin: 0; padding: 0; height: 100%; overflow: hidden }

body {
	font-family: 'Space Grotesk', sans-serif;
	background: #f3f7f5;
	color: var(--green-text);
}

#app { display: block; }

/* ===== PHILO-LYCEE THEME OVERRIDES (TAILWIND UTILITIES) ===== */
.bg-gray-50, .bg-slate-50  { background-color: #f3f7f5 !important; }
.bg-slate-900              { background-color: var(--green-darker) !important; }
.hover\:bg-slate-800:hover { background-color: #28423b !important; }
.text-slate-900, .text-slate-800 { color: #21332e !important; }
.text-slate-700, .text-slate-600 { color: #3a4c47 !important; }
.text-slate-500, .text-slate-400 { color: #667a74 !important; }
.text-slate-300            { color: rgba(255,255,255,.84) !important; }

.bg-emerald-700, .bg-emerald-800   { background-color: var(--green-dark) !important; }
.hover\:bg-emerald-800:hover       { background-color: #006457 !important; }
.text-emerald-700, .text-emerald-800, .text-emerald-900 { color: var(--green-dark) !important; }
.bg-emerald-50, .bg-emerald-100    { background-color: rgba(0,72,60,.08) !important; }
.border-emerald-200, .border-emerald-500 { border-color: rgba(0,72,60,.2) !important; }

.bg-amber-50  { background-color: rgba(213,213,43,.15) !important; }
.border-amber-200 { border-color: rgba(213,213,43,.42) !important; }
.text-amber-700, .text-amber-800 { color: #5d5d14 !important; }

.border-slate-700  { border-color: rgba(255,255,255,.12) !important; }
.border-slate-200, .border-gray-200 { border-color: rgba(0,0,0,.09) !important; }
.bg-white {
	background: #ffffff !important;
	box-shadow: 0 6px 22px rgba(0,0,0,.05);
}

.rounded, .rounded-md, .rounded-lg, .rounded-xl, .rounded-2xl {
	border-radius: var(--radius) !important;
}

.fixed.inset-y-0.left-0.z-40.w-72 {
	box-shadow: 10px 0 30px rgba(0,0,0,.22);
}

/* ===== ENTRY TYPE BADGES ===== */
.entry-type-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	font-size: 0.72rem;
	font-weight: 600;
	padding: 0.2rem 0.65rem;
	border-radius: 99px;
	border: 1px solid;
}
.entry-type-badge.type-cours   { background: rgba(0,72,60,.09); color: var(--green-dark); border-color: rgba(0,72,60,.2); }
.entry-type-badge.type-philo   { background: rgba(90,60,170,.09); color: #4c1d95; border-color: rgba(90,60,170,.2); }
.entry-type-badge.type-litt    { background: rgba(180,140,0,.12); color: #78600a; border-color: rgba(180,140,0,.28); }
.entry-type-badge.type-concept { background: rgba(0,0,0,.05); color: #374151; border-color: rgba(0,0,0,.12); }
.entry-type-badge.type-couple  { background: rgba(0,0,0,.05); color: #374151; border-color: rgba(0,0,0,.12); }

/* ===== ENTRY CONTENT — PROSE STYLES ===== */
.entry-content {
	color: #2d3d39;
	line-height: 1.72;
	font-size: 0.95rem;
}

/* Preamble (before first h2) */
.entry-preamble {
	margin-bottom: 1.5rem;
}

/* Section cards */
.section-card {
	background: #fff;
	border: 1px solid rgba(0,0,0,.08);
	border-radius: 10px;
	padding: 1.5rem 1.75rem;
	margin-bottom: 1.25rem;
	box-shadow: 0 2px 8px rgba(0,72,60,.05);
}

/* Headings */
.entry-content h1 {
	font-size: 1.5rem;
	font-weight: 700;
	color: #1a2e28;
	margin-bottom: 0.75rem;
}
.entry-content h2 {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--green-dark);
	margin-bottom: 1rem;
	padding-bottom: 0.4rem;
	border-bottom: 2px solid rgba(0,72,60,.12);
}
.entry-content h3 {
	font-size: 0.95rem;
	font-weight: 700;
	color: #2d3d39;
	margin-top: 1.25rem;
	margin-bottom: 0.5rem;
}

/* Aside blocks (Notion callouts) */
.entry-content aside {
	background: rgba(213,213,43,.13);
	border-left: 3px solid var(--yellow);
	padding: 0.85rem 1.1rem;
	border-radius: 0 var(--radius) var(--radius) 0;
	font-style: italic;
	color: #4a5042;
	margin: 0.75rem 0 1.25rem;
	font-size: 0.9rem;
}

/* Blockquotes (text extracts in corpus) */
.entry-content blockquote {
	border-left: 3px solid var(--green-dark);
	background: rgba(0,72,60,.05);
	padding: 1rem 1.25rem;
	border-radius: 0 var(--radius) var(--radius) 0;
	font-style: italic;
	color: #2d3d39;
	margin: 1rem 0;
}
.entry-content blockquote p { margin: 0 0 0.5rem; }
.entry-content blockquote p:last-child { margin-bottom: 0; }

/* Lists */
.entry-content ul, .entry-content ol {
	padding-left: 1.35rem;
	margin: 0.6rem 0;
}
.entry-content ul { list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li { margin-bottom: 0.3rem; }
.entry-content li > ul, .entry-content li > ol { margin: 0.2rem 0 0.2rem 0.75rem; }

/* Inline emphasis */
.entry-content strong { font-weight: 700; color: #1a2e28; }
.entry-content em     { font-style: italic; }

/* Paragraphs */
.entry-content p { margin-bottom: 0.75rem; }
.entry-content p:last-child { margin-bottom: 0; }

/* Code */
.entry-content code {
	font-family: 'JetBrains Mono', 'Fira Code', monospace;
	background: rgba(0,72,60,.08);
	padding: 0.1em 0.35em;
	border-radius: 4px;
	font-size: 0.88em;
	color: var(--green-dark);
}

/* Internal navigation links */
.entry-content .internal-link {
	color: var(--green-dark);
	text-decoration: underline;
	text-decoration-color: rgba(0,72,60,.35);
	text-underline-offset: 2px;
	cursor: pointer;
	transition: text-decoration-color 0.15s;
}
.entry-content .internal-link:hover {
	text-decoration-color: var(--green-dark);
}

/* Dead links (unresolved .md links) */
.entry-content .dead-link {
	color: #667a74;
	font-style: italic;
}

/* Horizontal rules */
.entry-content hr {
	border: none;
	border-top: 1px solid rgba(0,72,60,.12);
	margin: 1.25rem 0;
}

/* ===== CARD HOVER ===== */
.card-hover {
	transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card-hover:hover {
	transform: translateY(-3px);
	box-shadow: 0 12px 28px rgba(0,72,60,.14);
}

/* ===== INTERNAL LINKS (global) ===== */
.internal-link {
	color: var(--green-dark);
	text-decoration: underline;
	text-decoration-color: rgba(0,72,60,.35);
	text-underline-offset: 2px;
	cursor: pointer;
	transition: text-decoration-color 0.15s;
}
.internal-link:hover { text-decoration-color: var(--green-dark); }
.dead-link { color: #667a74; font-style: italic; }

/* ===== HIDE SCROLLBAR (internal nav) ===== */
.hide-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }
.hide-scrollbar::-webkit-scrollbar { display: none; }
