/* Dark mode for exacqlicenses.com — active only when <html data-theme="dark">.
   Toggle button lives in nav.php / navLVL1.php; choice stored in localStorage. */

html[data-theme="dark"] body {
    background-color: #12151a !important;
    color: #e8eaed !important;
}

html[data-theme="dark"] main,
html[data-theme="dark"] .page-section,
html[data-theme="dark"] section {
    background-color: #12151a !important;
    color: #e8eaed !important;
}

html[data-theme="dark"] h1,
html[data-theme="dark"] h2,
html[data-theme="dark"] h3,
html[data-theme="dark"] h4,
html[data-theme="dark"] h5,
html[data-theme="dark"] h6,
html[data-theme="dark"] p,
html[data-theme="dark"] li,
html[data-theme="dark"] label,
html[data-theme="dark"] span,
html[data-theme="dark"] strong,
html[data-theme="dark"] small {
    color: #e8eaed;
}

html[data-theme="dark"] a:not(.btn):not(.add-to-cart-btn):not(.details-btn):not(.dropdown-item):not(.nav-link) {
    color: #7ab8ff;
}

/* Navigation */
html[data-theme="dark"] #mainNav {
    background-color: #171b21 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .6);
}

html[data-theme="dark"] #mainNav .nav-link,
html[data-theme="dark"] #mainNav .navbar-brand {
    color: #e8eaed !important;
}

html[data-theme="dark"] .dropdown-menu {
    background-color: #1c2027 !important;
    border-color: #2c333c !important;
}

html[data-theme="dark"] .dropdown-item {
    color: #e8eaed !important;
}

html[data-theme="dark"] .dropdown-item:hover {
    background-color: #262c35 !important;
    color: #ffffff !important;
}

/* Cards, modals, boxes */
html[data-theme="dark"] .product-card,
html[data-theme="dark"] .modal-content,
html[data-theme="dark"] .cart-summary,
html[data-theme="dark"] .quick-order-form,
html[data-theme="dark"] .faq-card,
html[data-theme="dark"] .card {
    background-color: #1c2027 !important;
    color: #e8eaed !important;
    border-color: #2c333c !important;
}

html[data-theme="dark"] .product-card .description,
html[data-theme="dark"] .quick-order-note,
html[data-theme="dark"] .text-muted {
    color: #9aa4af !important;
}

html[data-theme="dark"] .cart-item {
    background-color: #1c2027 !important;
}

html[data-theme="dark"] .cart-item-details span {
    color: #a9b1ba !important;
}

html[data-theme="dark"] .cart-item-details strong,
html[data-theme="dark"] .cart-item-details strong[style] {
    background-color: #2c333c !important;
    color: #e8eaed !important;
}

/* Light panel behind product logos (dark logos on transparent PNGs) */
html[data-theme="dark"] .product-image-main,
html[data-theme="dark"] .cart-item-image,
html[data-theme="dark"] #cart-image {
    background-color: #eef1f5;
    border-radius: 8px;
    padding: 4px;
}

/* Tables (cart) */
html[data-theme="dark"] .table,
html[data-theme="dark"] .table th,
html[data-theme="dark"] .table td {
    background-color: transparent !important;
    color: #e8eaed !important;
    border-color: #2c333c !important;
}

html[data-theme="dark"] .table thead th {
    background-color: #1c2027 !important;
}

/* Forms */
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea,
html[data-theme="dark"] .form-checkout,
html[data-theme="dark"] .form-control {
    background-color: #22262c !important;
    color: #e8eaed !important;
    border-color: #3a4048 !important;
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder {
    color: #7d8791 !important;
}

/* Checkout steps (inline color:black on links) */
html[data-theme="dark"] .steps-container,
html[data-theme="dark"] .step-title,
html[data-theme="dark"] .step-title a[style] {
    color: #e8eaed !important;
}

html[data-theme="dark"] .grand-total {
    color: #e8eaed !important;
    background-color: transparent !important;
}

/* Buttons that are white in light mode */
html[data-theme="dark"] .details-btn {
    background-color: #262c35 !important;
    color: #e8eaed !important;
    border-color: #3a4048 !important;
}

html[data-theme="dark"] #quickAddToCartBtn {
    background-color: #1c2027 !important;
    color: #7ab8ff !important;
    border-color: #7ab8ff !important;
}

/* Footer */
html[data-theme="dark"] footer {
    background-color: #171b21 !important;
    color: #c6ccd2 !important;
}

/* Cart toast */
html[data-theme="dark"] .cart-alert {
    background-color: #1c2027 !important;
    color: #e8eaed !important;
    border: 1px solid #2c333c;
}

/* Modal close button visibility */
html[data-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* v2: kill light gradients/surfaces from styles.css */
html[data-theme="dark"] body,
html[data-theme="dark"] section,
html[data-theme="dark"] .page-section,
html[data-theme="dark"] #products {
    background-image: none !important;
}

html[data-theme="dark"] .home-information,
html[data-theme="dark"] .popular-topics-home {
    background: #12151a !important;
}

html[data-theme="dark"] .help-box {
    background: #1c2027 !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, .5) !important;
}

html[data-theme="dark"] .quick-order-intro > p:last-child,
html[data-theme="dark"] .quick-order-intro .eyebrow {
    color: #9aa4af !important;
}

html[data-theme="dark"] #loading-overlay {
    background: #12151a !important;
}

html[data-theme="dark"] .quick-order-form input,
html[data-theme="dark"] .quick-order-form select {
    background: #22262c !important;
    border-color: #3a4048 !important;
}

html[data-theme="dark"] .popular-topic-links a,
html[data-theme="dark"] .quick-order-intro .eyebrow {
    color: #7ab8ff !important;
}
