/* Custom Styles for Pragya — light design system (admin redesign 2026-11-23)
   Single clean LIGHT theme everywhere in the web/admin UI. No dark panels.
   Every text/background pair is WCAG AA — see the admin contrast audit. */

:root {
    --primary-color: #FFC400;        /* Ghana Gold (surfaces/accents only) */
    --secondary-color: #DC143C;      /* Ghana Red (accent only) */
    --success-color: #146C43;        /* deep green — white text 6.5:1 */
    --info-color: #0E7490;           /* white text 5.4:1 */
    --warning-color: #FFC107;
    --danger-color: #B02A37;         /* white text 6.5:1 */
    --page-bg: #F7F3EA;              /* soft warm off-white */
    --card-bg: #FFFFFF;
    --ink: #181A20;                  /* headings */
    --body-text: #33393F;            /* body copy — 11.7:1 on white */
    --muted: #4B5563;                /* secondary text — 7.5:1 on white, 6.9:1 on page bg */
    --placeholder-color: #5F6873;    /* 5.9:1 on white */
    --border-soft: #E4DCC8;
    --thead-bg: #F1EDE0;
    --gold-deep: #7A5200;            /* gold-toned TEXT on light tints */
    --link-color: #1D4ED8;           /* 6.7:1 on white */

    /* legacy aliases still referenced by older rules/templates */
    --light-color: #FFF8DC;
    --dark-color: #181A20;
    --body-bg: #F7F3EA;
    --text-primary: #181A20;
    --text-secondary: #4B5563;
    --border-color: #E4DCC8;
    --shadow-color: rgba(24, 26, 32, 0.06);
    --kente-pattern: linear-gradient(45deg, #FFD700 25%, #DC143C 25%, #DC143C 50%, #228B22 50%, #228B22 75%, #FFD700 75%);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--page-bg);
    color: var(--body-text);
    min-height: 100vh;
}

/* Cards: white, subtle border + soft shadow, 16px radius — never dark */
.card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-soft);
    border-radius: 16px;
    box-shadow: 0 2px 10px var(--shadow-color);
    transition: box-shadow 0.2s ease;
}

.card:hover {
    box-shadow: 0 4px 18px rgba(24, 26, 32, 0.09);
}

.card-body {
    padding: 2rem;
}

.card-header {
    background-color: #FFFFFF;
    border-bottom: 1px solid var(--border-soft);
    font-weight: 600;
    color: var(--ink);
    border-radius: 16px 16px 0 0 !important;
}

/* Feature icons (public pages) */
.feature-icon {
    width: 80px;
    height: 80px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 20px;
    font-size: 2rem;
    color: var(--ink);
    box-shadow: 0 4px 20px rgba(255, 196, 0, 0.35);
    border: 2px solid var(--success-color);
}

/* Buttons: gold surface + DARK ink text (never white on gold) */
.btn-primary {
    background-color: var(--primary-color);
    border: 1px solid #D9A400;
    border-radius: 12px;
    font-weight: 700;
    padding: 12px 28px;
    color: #1F1600;
    box-shadow: 0 2px 8px rgba(255, 196, 0, 0.35);
    transition: all 0.2s ease;
}

.btn-primary:hover, .btn-primary:focus {
    background-color: #F5B800;
    border-color: #C29200;
    color: #1F1600;
    box-shadow: 0 4px 14px rgba(255, 196, 0, 0.45);
}

.btn-success {
    background-color: var(--success-color);
    border: none;
    border-radius: 12px;
    font-weight: 600;
    padding: 12px 28px;
    color: #FFFFFF;
    transition: all 0.2s ease;
}

.btn-success:hover {
    background-color: #0F5132;
    color: #FFFFFF;
}

/* Service cards grid (public pages) */
.service-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.service-card {
    background: var(--card-bg);
    border: 1px solid var(--border-soft);
    border-radius: 24px;
    padding: 2.5rem;
    text-align: center;
    box-shadow: 0 2px 10px var(--shadow-color);
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.15);
}

.service-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
    background: var(--light-color);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

/* Bootstrap muted text at AA darkness */
.text-muted { color: var(--muted) !important; }

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--ink);
    font-weight: 700;
}

.display-4 {
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.lead {
    color: var(--body-text);
    font-size: 1.25rem;
    font-weight: 400;
}

.card-body h5 {
    color: var(--ink) !important;
}

.card-body p {
    color: var(--body-text) !important;
}

.card-body .text-muted {
    color: var(--muted) !important;
    opacity: 1;
}

/* NOTE: the old [data-bs-theme="dark"] card overrides were removed on purpose.
   The admin is explicitly LIGHT regardless of OS colour scheme (2026-11-23). */

/* Vehicle type cards (public pages) */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.vehicle-card {
    background: var(--card-bg);
    border: 2px solid var(--border-soft);
    border-radius: 20px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.vehicle-card:hover {
    border-color: var(--primary-color);
    background: rgba(255, 196, 0, 0.06);
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(255, 196, 0, 0.2);
}

.vehicle-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.vehicle-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 0.5rem;
}

.vehicle-price {
    color: var(--muted);
    font-weight: 500;
}

/* Status badges — every fill passes AA with its text colour */
.badge.bg-primary { background-color: #1D4ED8 !important; color: #FFFFFF; }   /* 6.7:1 */
.badge.bg-success { background-color: #146C43 !important; color: #FFFFFF; }   /* 6.5:1 */
.badge.bg-danger  { background-color: #B02A37 !important; color: #FFFFFF; }   /* 6.5:1 */
.badge.bg-info    { background-color: #0E7490 !important; color: #FFFFFF; }   /* 5.4:1 */
.badge.bg-secondary { background-color: #5A626B !important; color: #FFFFFF; } /* 6.2:1 */
.badge.bg-warning { background-color: #FFC107 !important; color: #212529; }   /* 9.5:1 */

/* Tables: light header band, dark readable rows */
.table {
    --bs-table-color: #33393F;
    color: var(--body-text);
}

.table thead th {
    background-color: var(--thead-bg);
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid var(--border-soft);
    white-space: nowrap;
}

.table tbody td {
    color: var(--body-text);
    border-bottom-color: #EFE9D8;
}

.table-hover tbody tr:hover {
    background-color: #FBF8F0;
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
    background-color: #FCFAF4;
    color: var(--body-text);
}

/* Forms */
.form-control, .form-select {
    color: var(--ink);
    border-color: #CFC7AE;
}

.form-control::placeholder {
    color: var(--placeholder-color);
    opacity: 1;
}

.form-label {
    color: var(--ink);
    font-weight: 600;
}

.form-text {
    color: var(--muted) !important;
}

/* ============ Admin dashboard components (2026-11-23) ============ */
.pg-stat-card .card-body {
    padding: 1.25rem 1.25rem 1.1rem;
}

.pg-stat-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    margin-bottom: 0.35rem;
}

.pg-stat-number {
    font-size: 2.1rem;
    line-height: 1.1;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.pg-stat-icon {
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
}

.pg-icon-blue  { background-color: #DBEAFE; color: #1D4ED8; }  /* glyph 5.5:1 */
.pg-icon-green { background-color: #D8EBDD; color: #006B3C; }  /* glyph 5.3:1 */
.pg-icon-gold  { background-color: #FFF0B8; color: #7A5200; }  /* glyph 6.1:1 */
.pg-icon-amber { background-color: #FDEBD3; color: #8A5A00; }  /* glyph 5.1:1 */

.pg-stat-sub {
    font-size: 0.875rem;
    font-weight: 600;
}

.pg-sub-green { color: #006B3C; }  /* 6.6:1 on white */
.pg-sub-blue  { color: #1D4ED8; }  /* 6.7:1 on white */
.pg-sub-muted { color: var(--muted); font-weight: 500; }

.pg-panel-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0;
}

.pg-btn-refresh {
    background-color: #FFFFFF;
    border: 1px solid #CFC7AE;
    color: var(--ink);
    font-weight: 600;
    border-radius: 10px;
}

.pg-btn-refresh:hover, .pg-btn-refresh:focus {
    background-color: #FFF0B8;
    border-color: #D9A400;
    color: #1F1600;
}

.pg-link {
    color: var(--link-color);
    font-weight: 600;
    text-decoration: none;
}

.pg-link:hover {
    color: #1E40AF;
    text-decoration: underline;
}

.pg-star { color: #B8860B; }  /* rating stars: graphical, 3.3:1 */

/* Footer styling */
.footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Remove browser default focus styles and use Bootstrap's */
:focus {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(29, 78, 216, 0.25);
}

/* Loading indicator */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(24, 26, 32, 0.2);
    border-radius: 50%;
    border-top-color: var(--ink);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive: phone-width admin (founder screenshot, 2026-11-23) */
@media (max-width: 767.98px) {
    .card-body { padding: 1.25rem; }
    .pg-stat-card .card-body { padding: 1.1rem 1.1rem 1rem; }
    .pg-stat-number { font-size: 2rem; }
    .pg-stat-icon { width: 48px; height: 48px; flex-basis: 48px; }
    .table-responsive { overflow-x: auto; }
}
