/*
Theme Name: PustakBase Library
Description: Bilingual (Hindi/English) theme for the PustakBase Library Portal — physical library, digital e-library, documents and reading room. Design system ported from the finalized HTML/CSS/JS prototype (see docs/WCL_Prototype_Reference_Guide.md Section 2).
Author: PustakBase
Version: 1.0.136
Requires PHP: 7.4
Text Domain: pb-library
*/

:root {
	/* Base palette (Prototype Reference Guide 2.1) */
	--ink: #201C18;
	--ink-faint: #544B40;
	--paper: #ECE7DC;
	--paper-raised: #F8F5EC;
	--border: #D6CFBD;
	--slate: #5B6670;

	/* Role accent colors */
	--accent-employee-amber: #C98A2E;
	--accent-employee-ledger: #2F5D55;
	--accent-librarian: #3D6B8C;
	--accent-admin: #5C4470;
	--accent-danger: #B5432E;

	/* Typography (Prototype Reference Guide 2.2) */
	--font-display: 'Fraunces', 'Noto Serif Devanagari', serif;
	--font-body: 'Inter', 'Noto Sans Devanagari', sans-serif;
	--font-mono: 'IBM Plex Mono', monospace;
}

html {
	background: var(--paper);
	color: var(--ink);
	font-family: var(--font-body);
}

/* Browsers don't inherit font-family into form controls by default (their
   UA stylesheet sets a system font instead) — every button, input, select,
   and textarea across the portal was silently rendering in the browser's
   default UI font (Arial on most) instead of the site's actual typeface,
   even though every page's own CSS assumed inheritance from html/body.
   One reset here fixes it everywhere at once, instead of adding
   font-family to every individual .btn-primary/.button rule across a
   dozen page-specific stylesheets. */
button, input, select, textarea {
	font-family: inherit;
}

body {
	margin: 0;
}

h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-display);
}

code, kbd, samp, pre {
	font-family: var(--font-mono);
}

/* Real WCL/Coal India logo — a flattened image with a white background, so
   any placement on a dark surface (sidebars, dark header, auth hero panels)
   wraps it in a small white chip rather than fighting the JPEG's background.
   Light surfaces (cards on --paper-raised) can use the bare .pb-logo img
   directly with no chip. */
.pb-logo-chip {
	display: inline-flex;
	align-items: center;
	background: #fff;
	border-radius: 8px;
	padding: .4rem .7rem;
}

.pb-logo-chip img,
.pb-logo {
	display: block;
	height: 30px;
	width: auto;
}

.pb-logo-chip.lg img,
.pb-logo.lg {
	height: 46px;
}

/* Takes the header's former solid-black background — the header moved on
   to the warm ledger-amber gradient, so this dark tone now grounds the
   page at the bottom instead. Padding halved per design review. */
.pb-site-footer {
	background: var(--ink);
	border-top: 1px solid rgba(255, 255, 255, .12);
	padding: .8rem .75rem;
	text-align: center;
}

.pb-site-footer p {
	font-size: .75rem;
	color: rgba(255, 255, 255, .72);
	margin: 0;
}

.pb-site-footer p.hi {
	font-family: 'Noto Serif Devanagari', serif;
	font-size: .8rem;
	color: #fff;
	margin-bottom: .3rem;
}

/* Show/hide toggle injected by assets/js/password-toggle.js next to every
   password field (Login, Forgot/Reset Password, Activate). Global here
   rather than in auth.css/activate.css so both pick it up without
   duplicating the rules. */
.pb-pw-wrap { position: relative; width: 100%; }
.pb-pw-wrap input[type="password"],
.pb-pw-wrap input[type="text"] { padding-right: 2.6rem; }
.pb-pw-toggle {
	position: absolute;
	top: 50%;
	right: .55rem;
	transform: translateY(-50%);
	display: flex;
	align-items: center;
	justify-content: center;
	width: 1.9rem;
	height: 1.9rem;
	padding: 0;
	border: none;
	background: transparent;
	color: var(--slate, #6b7280);
	cursor: pointer;
	border-radius: 5px;
}
.pb-pw-toggle:hover { color: var(--ink, #111); }
.pb-pw-toggle:focus-visible { outline: 2px solid var(--accent-employee-amber, #b8860b); outline-offset: 1px; }
