/* PostgreManager — Custom CSS */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --pm-dark:    #1a1a2e;
    --pm-mid:     #16213e;
    --pm-deep:    #0f3460;
    --pm-accent:  #e94560;
    --pm-info:    #17a2b8;
    --pm-text:    #ddd;
    --pm-muted:   #aaa;
}

body, .main-header, .main-sidebar, .content-wrapper, .main-footer {
    font-family: 'Inter', sans-serif;
}

/* Input style */
.pm-input {
    background: rgba(255,255,255,0.07) !important;
    border-color: var(--pm-deep) !important;
    color: var(--pm-text) !important;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.pm-input:focus {
    border-color: var(--pm-accent) !important;
    box-shadow: 0 0 0 0.15rem rgba(233,69,96,0.25) !important;
    background: rgba(255,255,255,0.1) !important;
    color: #fff !important;
}
.pm-input option {
    background: var(--pm-mid);
    color: var(--pm-text);
}
.pm-input::placeholder { color: #555; }

/* Card base */
.card { border-radius: 8px !important; }
.card-header { border-radius: 8px 8px 0 0 !important; }

/* Table */
.table td, .table th { vertical-align: middle !important; border-color: #0f3460 !important; }
.table-responsive       { background: transparent !important; }

.table-hover tbody tr:hover td,
.table-hover tbody tr:hover th { background-color: rgba(233,69,96,0.12) !important; color: #fff !important; }

/* Light mode table hover */
body.pm-light .table-hover tbody tr:hover td,
body.pm-light .table-hover tbody tr:hover th { background-color: rgba(233,69,96,0.08) !important; color: #333 !important; }


/* Badge xs button */
.btn-xs {
    padding: 0.2rem 0.45rem;
    font-size: 0.72rem;
    border-radius: 4px;
}

/* Sidebar active link */
.nav-sidebar .nav-link.active {
    background-color: var(--pm-accent) !important;
    color: #fff !important;
}
.nav-sidebar .nav-link:hover {
    background-color: rgba(233,69,96,0.15) !important;
    color: #fff !important;
}

/* Content wrapper */
.content-wrapper { background: #111827; }

/* Page title */
.content-header h1 { color: #ddd; }

/* Dark footer */
.main-footer { background: #16213e !important; border-top: 1px solid #0f3460 !important; color: #aaa !important; }

/* Flash dismiss */
.alert { border-radius: 6px; }


/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--pm-dark); }
::-webkit-scrollbar-thumb { background: var(--pm-deep); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--pm-accent); }

/* History item hover */
.history-item:hover { background: rgba(255,255,255,0.05); }

/* Transition */
.btn, .nav-link, .card { transition: all 0.2s ease; }

/* ── Light Mode ───────────────────────────────────────────── */
body.pm-light,
body.pm-light .content-wrapper   { background: #f4f6f9 !important; color: #333 !important; }

/* Navbar */
body.pm-light .main-header       { background: #fff !important; border-bottom: 1px solid #ddd !important; }
body.pm-light .main-header .nav-link,
body.pm-light .main-header .navbar-nav i { color: #555 !important; }

/* Sidebar — light */
body.pm-light .main-sidebar               { background: #f8f9fa !important; border-right: 1px solid #dee2e6; }
body.pm-light .main-sidebar .brand-link   { background: #e9ecef !important; border-bottom: 1px solid #dee2e6 !important; }
body.pm-light .main-sidebar .brand-text   { color: #333 !important; }
body.pm-light .main-sidebar .fa-database  { color: #e94560 !important; }
body.pm-light .main-sidebar .user-panel .info a { color: #333 !important; }
body.pm-light .main-sidebar .user-panel small   { color: #777 !important; }
body.pm-light .main-sidebar .nav-header          { color: #999 !important; }
body.pm-light .main-sidebar .nav-link            { color: #444 !important; }
body.pm-light .main-sidebar .nav-link:hover      { background: rgba(233,69,96,0.1) !important; color: #e94560 !important; }
body.pm-light .main-sidebar .nav-link.active     { background: #e94560 !important; color: #fff !important; }
body.pm-light .main-sidebar .nav-icon            { color: inherit !important; }

/* Footer */
body.pm-light .main-footer       { background: #fff !important; border-top: 1px solid #ddd !important; color: #666 !important; }

/* Page title */
body.pm-light .content-header h1 { color: #333 !important; }
body.pm-light .breadcrumb-item a  { color: #e94560 !important; }

/* Cards */
body.pm-light .card              { background: #fff !important; border-color: #dee2e6 !important; }
body.pm-light .card-header       { background: #f8f9fa !important; border-color: #dee2e6 !important; }
body.pm-light .card-header h3,
body.pm-light .card-title        { color: #e94560 !important; }

/* Tables */
body.pm-light .table td,
body.pm-light .table th          { border-color: #dee2e6 !important; }
body.pm-light .table td          { color: #333 !important; }
body.pm-light .table thead th    { color: #fff !important; background-color: #0f3460 !important; font-weight: 600; letter-spacing: .03em; }

/* Badges */
body.pm-light .badge             { font-weight: 600; }
body.pm-light .badge-secondary   { background-color: #6c757d !important; color: #fff !important; }
body.pm-light .badge-success     { background-color: #28a745 !important; color: #fff !important; }
body.pm-light .badge-danger      { background-color: #dc3545 !important; color: #fff !important; }
body.pm-light .badge-warning     { background-color: #ffc107 !important; color: #212529 !important; }
body.pm-light .badge-info        { background-color: #17a2b8 !important; color: #fff !important; }
body.pm-light .badge-primary     { background-color: #e94560 !important; color: #fff !important; }



/* Override inline color styles on labels and text inside content */
body.pm-light .content label,
body.pm-light .content p,
body.pm-light .content small,
body.pm-light .content span:not(.badge) { color: #555 !important; }

body.pm-light .content [style*="color:#ddd"],
body.pm-light .content [style*="color: #ddd"]  { color: #333 !important; }
body.pm-light .content [style*="color:#aaa"],
body.pm-light .content [style*="color: #aaa"]  { color: #666 !important; }
/* Inputs */
body.pm-light .pm-input,
body.pm-light .form-control       { background: #fff !important; color: #333 !important; border-color: #ced4da !important; }
body.pm-light .pm-input::placeholder,
body.pm-light .form-control::placeholder { color: #999 !important; }
body.pm-light .pm-input:focus,
body.pm-light .form-control:focus  { border-color: #e94560 !important; box-shadow: 0 0 0 0.15rem rgba(233,69,96,0.2) !important; }
body.pm-light .pm-input option     { background: #fff; color: #333; }



