/* CBASCO Theme Modes — LIGHT MODE PAINT
 *
 * Same override strategy as the colorful section in theme-modes.css,
 * but with a paper-light palette. Many page CSS files (history.css,
 * strategy.css, shareholders.css, specifications.css, catalog.css,
 * packaging.css, tour.css, csr.css) hard-code dark colors like #0d1117.
 * We neutralize those here with !important so the entire site reads
 * as bright daylight in light mode. */

/* ─── Body & page-level wrappers ─── */
html[data-cb-theme="light"] body {
	background-color: #eef3f8 !important;
	color: var(--cb-text) !important;
}

html[data-cb-theme="light"] #cbas-history,
html[data-cb-theme="light"] #cbas-strategy,
html[data-cb-theme="light"] #cbas-csr,
html[data-cb-theme="light"] [id^="cbas-"]:not([id*="modal"]):not([id*="toolbar"]) {
	background-image: none !important;
	background-color: transparent !important;
	color: var(--cb-text) !important;
}

/* ─── Section default — paper white ─── */
html[data-cb-theme="light"] #primary > section,
html[data-cb-theme="light"] main > section,
html[data-cb-theme="light"] #primary > article > section,
html[data-cb-theme="light"] #primary > div > section,
html[data-cb-theme="light"] main > div > section,
html[data-cb-theme="light"] #cbas-history > section,
html[data-cb-theme="light"] #cbas-strategy > section {
	background-image: none !important;
	background-color: #ffffff !important;
	color: var(--cb-text) !important;
}

/* Hero — tinted with steel blue, still very bright */
html[data-cb-theme="light"] #primary > section:first-of-type,
html[data-cb-theme="light"] main > section:first-of-type,
html[data-cb-theme="light"] #cbas-history > section:first-of-type,
html[data-cb-theme="light"] #cbas-strategy > section:first-of-type {
	background-image: none !important;
	background-color: #e6eff8 !important;
	color: var(--cb-text) !important;
}

/* Odd (non-first) — pure paper */
html[data-cb-theme="light"] #primary > section:nth-of-type(odd):not(:first-of-type),
html[data-cb-theme="light"] main > section:nth-of-type(odd):not(:first-of-type),
html[data-cb-theme="light"] #cbas-history > section:nth-of-type(odd):not(:first-of-type),
html[data-cb-theme="light"] #cbas-strategy > section:nth-of-type(odd):not(:first-of-type) {
	background-color: #ffffff !important;
}

/* Even — pale silver band */
html[data-cb-theme="light"] #primary > section:nth-of-type(even),
html[data-cb-theme="light"] main > section:nth-of-type(even),
html[data-cb-theme="light"] #cbas-history > section:nth-of-type(even),
html[data-cb-theme="light"] #cbas-strategy > section:nth-of-type(even) {
	background-color: #f1f6fb !important;
}

/* Soften decorative dark pseudo-elements so the paper bg shows */
html[data-cb-theme="light"] #primary > section::before,
html[data-cb-theme="light"] #primary > section::after,
html[data-cb-theme="light"] main > section::before,
html[data-cb-theme="light"] main > section::after,
html[data-cb-theme="light"] #cbas-history > section::before,
html[data-cb-theme="light"] #cbas-history > section::after,
html[data-cb-theme="light"] #cbas-strategy > section::before,
html[data-cb-theme="light"] #cbas-strategy > section::after {
	opacity: .35 !important;
	mix-blend-mode: multiply;
}

/* ─── Inner cards / boxes — paint them paper-white too ─── */
html[data-cb-theme="light"] .cbf-feat-card,
html[data-cb-theme="light"] .cbf-intro-card,
html[data-cb-theme="light"] .cbf-cta-card,
html[data-cb-theme="light"] .cbab-card,
html[data-cb-theme="light"] .cbsh-card,
html[data-cb-theme="light"] .cbcat-card,
html[data-cb-theme="light"] .cbpk-card,
html[data-cb-theme="light"] .cbpl-card,
html[data-cb-theme="light"] .cbcert-card,
html[data-cb-theme="light"] .cb-feat-card,
html[data-cb-theme="light"] .cb-mgr-card,
html[data-cb-theme="light"] .cb-ceo-card,
html[data-cb-theme="light"] .cb-intro-card,
html[data-cb-theme="light"] .cb-tl-card,
html[data-cb-theme="light"] .cb-cap-card,
html[data-cb-theme="light"] .cb-mine-card,
html[data-cb-theme="light"] .cbas-card,
html[data-cb-theme="light"] .cbas-identity-card,
html[data-cb-theme="light"] .cbas-value-card,
html[data-cb-theme="light"] .cbas-process-step,
html[data-cb-theme="light"] .cbsh-pie-card,
html[data-cb-theme="light"] .cbsh-table-card,
html[data-cb-theme="light"] .cbtour-card,
html[data-cb-theme="light"] .cbtour-card-wrap,
html[data-cb-theme="light"] .cbcon-card,
html[data-cb-theme="light"] .cbsp-card,
html[data-cb-theme="light"] .cbsp-card-inner,
html[data-cb-theme="light"] .cbn-card {
	background-image: none !important;
	background-color: #ffffff !important;
	color: var(--cb-text) !important;
	border-color: rgba(43,108,140,.18) !important;
	box-shadow: 0 4px 18px rgba(15,30,50,.06) !important;
}

/* ─── Text colors inside sections — readable on white paper ─── */
html[data-cb-theme="light"] #primary > section,
html[data-cb-theme="light"] main > section,
html[data-cb-theme="light"] #cbas-history > section,
html[data-cb-theme="light"] #cbas-strategy > section {
	--cb-text:        #15212d;
	--cb-text-2:      #2a3e52;
	--cb-text-body:   #45596f;
	--cb-text-muted:  #6a7e92;
	--cb-highlight:   #1d4f6c;
}

html[data-cb-theme="light"] #primary > section h1,
html[data-cb-theme="light"] #primary > section h2,
html[data-cb-theme="light"] #primary > section h3,
html[data-cb-theme="light"] main > section h1,
html[data-cb-theme="light"] main > section h2,
html[data-cb-theme="light"] main > section h3,
html[data-cb-theme="light"] #cbas-history h1,
html[data-cb-theme="light"] #cbas-history h2,
html[data-cb-theme="light"] #cbas-history h3,
html[data-cb-theme="light"] #cbas-strategy h1,
html[data-cb-theme="light"] #cbas-strategy h2,
html[data-cb-theme="light"] #cbas-strategy h3 {
	color: var(--cb-text) !important;
}

html[data-cb-theme="light"] #primary > section p,
html[data-cb-theme="light"] main > section p,
html[data-cb-theme="light"] #cbas-history p,
html[data-cb-theme="light"] #cbas-strategy p,
html[data-cb-theme="light"] .cb-feat-desc,
html[data-cb-theme="light"] .cbf-feat-desc,
html[data-cb-theme="light"] .cbab-bio,
html[data-cb-theme="light"] .cbsh-text,
html[data-cb-theme="light"] .cbsp-text {
	color: var(--cb-text-body) !important;
}

html[data-cb-theme="light"] #primary > section .cbasco-sec-tag,
html[data-cb-theme="light"] main > section .cbasco-sec-tag,
html[data-cb-theme="light"] .cb-sec-tag,
html[data-cb-theme="light"] .cbas-sec-tag,
html[data-cb-theme="light"] .cbsh-sec-tag,
html[data-cb-theme="light"] .cbsp-sec-tag {
	color: var(--cb-highlight) !important;
	background: rgba(43,108,140,.08) !important;
}

html[data-cb-theme="light"] em {
	color: var(--cb-acc) !important;
	font-style: normal;
}

/* Stats / number readouts that some pages paint with white-on-dark gradients */
html[data-cb-theme="light"] .cbf-stat-num,
html[data-cb-theme="light"] .cbf-card-big-year,
html[data-cb-theme="light"] .cbab-num,
html[data-cb-theme="light"] .cbsh-stat-num {
	-webkit-text-fill-color: var(--cb-text) !important;
	background: none !important;
	color: var(--cb-text) !important;
}

/* Buttons — ghost variants need readable strokes */
html[data-cb-theme="light"] .cbasco-btn--ghost {
	color: var(--cb-text) !important;
	border-color: var(--cb-border-hover) !important;
}
html[data-cb-theme="light"] .cbasco-btn--ghost:hover {
	background: rgba(43,108,140,.08) !important;
	color: var(--cb-acc) !important;
}

/* Links inside sections */
html[data-cb-theme="light"] #primary > section a:not(.cbasco-btn):not(.cbn-filter):not([class*="btn"]),
html[data-cb-theme="light"] main > section a:not(.cbasco-btn):not(.cbn-filter):not([class*="btn"]) {
	color: var(--cb-acc);
}

/* Footer in light mode — keep its dark drama but adjust the seam */
html[data-cb-theme="light"] .cbasco-footer {
	background-color: #15212d !important;
	color: #ddeaf6 !important;
}
html[data-cb-theme="light"] .cbasco-footer * { color: inherit; }
html[data-cb-theme="light"] .cbasco-footer a:hover { color: #6aaecc !important; }

/* ═══════════════════════════════════════════════════════════════
   LIGHT-PAINT EXTENSION — contrast audit round 2
   Forms, placeholders, contact page, gradient-clipped hero titles,
   marquee edge fades. Every rule scoped to html[data-cb-theme="light"].
═══════════════════════════════════════════════════════════════ */

/* ─── Form fields (contact form, tour form, comments, search) ─── */
html[data-cb-theme="light"] .cbcon-form input,
html[data-cb-theme="light"] .cbcon-form textarea,
html[data-cb-theme="light"] .cbtour-field input[type="text"],
html[data-cb-theme="light"] .cbtour-field input[type="tel"],
html[data-cb-theme="light"] .cbtour-field input[type="email"],
html[data-cb-theme="light"] .cbtour-field input[type="date"],
html[data-cb-theme="light"] .cbtour-field input[type="number"],
html[data-cb-theme="light"] .cbtour-field select,
html[data-cb-theme="light"] .cbtour-field textarea,
html[data-cb-theme="light"] .cbasco-main input[type="search"]:not(.cbn-search-input),
html[data-cb-theme="light"] .comment-form input:not([type="submit"]),
html[data-cb-theme="light"] .comment-form textarea {
	background: #ffffff !important;
	border: 1px solid rgba(43,108,140,.32) !important;
	color: #15212d !important;
}

/* Archive search box — the pill wrapper (.cbn-search-inner) is the visible
   frame; the input itself must stay transparent & borderless in light mode
   too, exactly like dark/colorful, so no inner rectangle appears. */
html[data-cb-theme="light"] .cbn-search-input {
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	color: #15212d !important;
}
html[data-cb-theme="light"] .cbn-search-input::placeholder { color: #5a6e82 !important; }
html[data-cb-theme="light"] .cbcon-form input:focus,
html[data-cb-theme="light"] .cbcon-form textarea:focus,
html[data-cb-theme="light"] .cbtour-field input:focus,
html[data-cb-theme="light"] .cbtour-field select:focus,
html[data-cb-theme="light"] .cbtour-field textarea:focus {
	background: #ffffff !important;
	border-color: #2b6c8c !important;
	box-shadow: 0 0 0 3px rgba(43,108,140,.14) !important;
}
/* Placeholders — dark enough to actually read on white */
html[data-cb-theme="light"] .cbcon-form input::placeholder,
html[data-cb-theme="light"] .cbcon-form textarea::placeholder,
html[data-cb-theme="light"] .cbtour-field input::placeholder,
html[data-cb-theme="light"] .cbtour-field textarea::placeholder,
html[data-cb-theme="light"] .cbasco-main input::placeholder,
html[data-cb-theme="light"] .cbasco-main textarea::placeholder {
	color: #5a6e82 !important;
	opacity: 1 !important;
}
html[data-cb-theme="light"] .cbcon-form label,
html[data-cb-theme="light"] .cbtour-field label {
	color: #2a3e52 !important;
}
/* Native date-picker icon: undo the dark-mode invert hack */
html[data-cb-theme="light"] .cbtour-field input[type="date"]::-webkit-calendar-picker-indicator {
	filter: none !important;
}

/* ─── Contact page — info lines, expert cards, extensions (داخلی) ─── */
html[data-cb-theme="light"] .cbcon-line {
	background: #f3f7fb !important;
	border-color: rgba(43,108,140,.22) !important;
	color: #15212d !important;
}
html[data-cb-theme="light"] a.cbcon-line:hover {
	background: rgba(43,108,140,.10) !important;
	border-color: #2b6c8c !important;
}
html[data-cb-theme="light"] .cbcon-line--static { color: #45596f !important; }
html[data-cb-theme="light"] .cbcon-line strong  { color: #1d4f6c !important; }
html[data-cb-theme="light"] .cbcon-expert,
html[data-cb-theme="light"] .cbcon-main-card,
html[data-cb-theme="light"] .cbcon-social-strip {
	background: #ffffff !important;
	background-image: none !important;
	border-color: rgba(43,108,140,.18) !important;
	color: #15212d !important;
	box-shadow: 0 4px 18px rgba(15,30,50,.06) !important;
}
html[data-cb-theme="light"] .cbcon-expert-role  { color: #15212d !important; }
html[data-cb-theme="light"] .cbcon-expert-ext   { color: #45596f !important; }
html[data-cb-theme="light"] .cbcon-num,
html[data-cb-theme="light"] .cbcon-num a        { color: #1d4f6c !important; }
html[data-cb-theme="light"] .cbcon-main-card-value { color: #1d4f6c !important; }
html[data-cb-theme="light"] .cbcon-main-card-label { color: #2a3e52 !important; }

/* ─── Gradient-clipped hero titles — re-ink with dark steel gradient ─── */
html[data-cb-theme="light"] .cbpl-hero-title,
html[data-cb-theme="light"] .cbpl-stat-num,
html[data-cb-theme="light"] .cbcert-hero-title,
html[data-cb-theme="light"] .cbn-single__title,
html[data-cb-theme="light"] .cb-legal-title,
html[data-cb-theme="light"] .cbasco-single-title {
	background: linear-gradient(135deg, #10222e 15%, #1d4f6c 55%, #2b6c8c 100%) !important;
	-webkit-background-clip: text !important;
	background-clip: text !important;
	-webkit-text-fill-color: transparent !important;
}

/* ─── Hero subtitle / pill rows on light heroes ─── */
html[data-cb-theme="light"] .cbpl-hero-sub,
html[data-cb-theme="light"] .cbtour-hero-sub,
html[data-cb-theme="light"] .cbcon-hero p {
	color: #45596f !important;
}

/* ─── Marquee edge fades — fade into the LIGHT bar, not black ─── */
html[data-cb-theme="light"] .cbasco-marquee::before {
	background: linear-gradient(90deg, #ecf2f8, transparent) !important;
}
html[data-cb-theme="light"][dir="rtl"] .cbasco-marquee::before,
html[dir="rtl"][data-cb-theme="light"] .cbasco-marquee::before {
	background: linear-gradient(270deg, #ecf2f8, transparent) !important;
}

/* ─── Extra cards discovered in the audit ─── */
html[data-cb-theme="light"] .cbab-id-card,
html[data-cb-theme="light"] .cbab-pill-card,
html[data-cb-theme="light"] .cbpk-drawer,
html[data-cb-theme="light"] .cbsh-row,
html[data-cb-theme="light"] .cbsp-table-wrap,
html[data-cb-theme="light"] .cbcat-book-panel {
	background-image: none !important;
	background-color: #ffffff !important;
	color: var(--cb-text) !important;
	border-color: rgba(43,108,140,.18) !important;
}

/* ─── Main-contact card rows (راه‌های ارتباطی اصلی + امور سهام) ─── */
html[data-cb-theme="light"] .cbcon-main-card-row {
	background: #f3f7fb !important;
	border-color: rgba(43,108,140,.22) !important;
	color: #15212d !important;
}
html[data-cb-theme="light"] a.cbcon-main-card-row:hover {
	background: rgba(43,108,140,.10) !important;
	border-color: #2b6c8c !important;
}
html[data-cb-theme="light"] .cbcon-shares-card a.cbcon-main-card-row:hover {
	background: rgba(138,106,30,.10) !important;
	border-color: #8a6a1e !important;
}
html[data-cb-theme="light"] .cbcon-main-card-title { color: #15212d !important; }
html[data-cb-theme="light"] .cbcon-shares-desc     { color: #45596f !important; }
