/* RCN SA Church Management System — admin theme overrides (light/dark mode) */

/* Brand hover accent — buttons and interactive headings turn this color on hover/focus. */
:root {
    --hover-accent: #CA2C29;
}

.btn:hover,
.btn:focus,
.btn:focus-visible {
    background-color: var(--hover-accent) !important;
    border-color: var(--hover-accent) !important;
    color: #fff !important;
}

.btn-link:hover,
.btn-link:focus {
    color: var(--hover-accent) !important;
}

a:hover,
a:focus,
.nav-link:hover,
.nav-link:focus,
.dropdown-item:hover,
.dropdown-item:focus,
h1 a:hover, h2 a:hover, h3 a:hover, h4 a:hover, h5 a:hover, h6 a:hover {
    color: var(--hover-accent) !important;
}

h1:hover, h2:hover, h3:hover, h4:hover, h5:hover, h6:hover {
    color: var(--hover-accent);
    transition: color .15s ease;
}

[data-bs-theme="dark"] {
    color-scheme: dark;
}

[data-bs-theme="dark"] body,
[data-bs-theme="dark"] .container-fluid.bg-white {
    background-color: #14161c !important;
    color: #e7e9ec;
}

[data-bs-theme="dark"] .sidebar,
[data-bs-theme="dark"] .bg-light,
[data-bs-theme="dark"] .navbar.bg-light {
    background-color: #1c1f27 !important;
    color: #e7e9ec;
}

[data-bs-theme="dark"] .content {
    background-color: #14161c;
}

[data-bs-theme="dark"] .text-dark {
    color: #e7e9ec !important;
}

/* The template's own CSS colors sidebar/top-nav links with var(--dark) (navy) — readable on
   the default light sidebar, but invisible once the sidebar itself goes dark. Force a light
   foreground here instead of touching --dark/--primary globally (those still need their
   normal values elsewhere, e.g. --primary as a badge background). */
[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link,
[data-bs-theme="dark"] .content .navbar .navbar-nav .nav-link {
    color: #e7e9ec;
}

[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link i {
    background: #262b38;
}

[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link:hover,
[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link.active {
    background: #262b38;
    color: #fff;
}

[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link:hover i,
[data-bs-theme="dark"] .sidebar .navbar .navbar-nav .nav-link.active i {
    background: #33384a;
}

[data-bs-theme="dark"] .content .navbar .navbar-nav .nav-link:hover,
[data-bs-theme="dark"] .content .navbar .navbar-nav .nav-link.active {
    color: #fff;
}

[data-bs-theme="dark"] .form-section-title {
    border-bottom-color: #fff;
}

[data-bs-theme="dark"] .table {
    color: #e7e9ec;
}

[data-bs-theme="dark"] .table-bordered,
[data-bs-theme="dark"] .table td,
[data-bs-theme="dark"] .table th {
    border-color: #33384a;
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    background-color: #1c1f27;
    color: #e7e9ec;
    border-color: #33384a;
}

[data-bs-theme="dark"] .dropdown-menu {
    background-color: #1c1f27;
    color: #e7e9ec;
}

[data-bs-theme="dark"] .dropdown-item {
    color: #e7e9ec;
}

[data-bs-theme="dark"] .dropdown-item:hover {
    background-color: #262b38;
}

[data-bs-theme="dark"] .card {
    background-color: #1c1f27;
    color: #e7e9ec;
}

/* Status / pillar badges */
.badge-pillar {
    background-color: var(--primary);
    color: #fff;
}

.status-active { color: #1cc88a; font-weight: 600; }
.status-inactive { color: #858796; font-weight: 600; }
.status-pending { color: #f6c23e; font-weight: 600; }

.member-photo-thumb {
    width: 42px;
    height: 42px;
    object-fit: cover;
    border-radius: 50%;
}

.form-section-title {
    border-bottom: 2px solid var(--primary);
    padding-bottom: .5rem;
    margin-bottom: 1.25rem;
    font-weight: 600;
}

@media (max-width: 576px) {
    .content .container-fluid { padding-left: 1rem; padding-right: 1rem; }
}
