html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.card {
    border-radius: 14px;
}

.btn {
    border-radius: 10px;
}

.table thead th {
    vertical-align: middle;
}

/* ===== ERP Layout ===== */
.erp-wrapper {
    display: flex;
    min-height: 100vh;
    background: #f6f7fb;
}

.erp-sidebar {
    width: 260px;
    background: #111827;
    color: #fff;
    padding: 18px 14px;
    display: flex;
    flex-direction: column;
}

.sidebar-brand {
    font-size: 18px;
    font-weight: 700;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    margin-bottom: 14px;
}

.sidebar-user {
    padding: 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    margin-bottom: 16px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sidebar-link {
    text-decoration: none;
    color: #e5e7eb;
    padding: 10px 12px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    transition: 0.2s;
    font-weight: 500;
}

    .sidebar-link:hover {
        background: rgba(255, 255, 255, 0.10);
        color: #fff;
    }

.erp-main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.erp-topbar {
    background: #fff;
    padding: 14px 20px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.erp-content {
    padding: 20px;
}

/* UI polish */
.card {
    border-radius: 14px;
}

.btn {
    border-radius: 10px;
}

.table thead th {
    vertical-align: middle;
}

/* ===== Theme Variables ===== */
:root {
    --bg: #f6f7fb;
    --card: #ffffff;
    --text: #111827;
    --muted: #6b7280;
    --border: #e5e7eb;
    --topbar: #ffffff;
    --sidebar: #111827;
    --sidebarText: #e5e7eb;
    --sidebarHover: rgba(255, 255, 255, 0.10);
}

[data-theme="dark"] {
    --bg: #0b1220;
    --card: #0f172a;
    --text: #e5e7eb;
    --muted: #9ca3af;
    --border: rgba(255, 255, 255, 0.10);
    --topbar: #0f172a;
    --sidebar: #0b1220;
    --sidebarText: #e5e7eb;
    --sidebarHover: rgba(255, 255, 255, 0.12);
}

/* ===== Apply Theme ===== */
.erp-wrapper {
    background: var(--bg);
}

.erp-topbar {
    background: var(--topbar);
    border-bottom: 1px solid var(--border);
    color: var(--text);
}

.erp-content {
    color: var(--text);
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
}

.text-muted {
    color: var(--muted) !important;
}

.table {
    color: var(--text);
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
    color: var(--text);
}

.table-dark {
    --bs-table-bg: #111827;
}

[data-theme="dark"] .table-dark {
    --bs-table-bg: #0b1220;
}

.erp-sidebar {
    background: var(--sidebar);
    color: var(--sidebarText);
}

.sidebar-link {
    color: var(--sidebarText);
}

    .sidebar-link:hover {
        background: var(--sidebarHover);
        color: #fff;
    }

[data-theme="dark"] .form-control,
[data-theme="dark"] .form-select {
    background: #0b1220;
    color: #e5e7eb;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

    [data-theme="dark"] .form-control::placeholder {
        color: #9ca3af;
    }

[data-theme="dark"] .btn-outline-secondary {
    border-color: rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}
.sidebar-bottom {
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.10);
}
@keyframes fadeUp {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.96);
        filter: blur(6px);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.login-card {
    animation: fadeUp 0.85s cubic-bezier(.2,.8,.2,1) forwards;
}
    .login-card .header {
        animation: fadeUp 0.65s cubic-bezier(.2,.8,.2,1) forwards;
    }

    .login-card form {
        opacity: 0;
        animation: fadeUp 0.75s cubic-bezier(.2,.8,.2,1) forwards;
        animation-delay: 0.15s;
    }

    .login-card .hint-box {
        opacity: 0;
        animation: fadeUp 0.75s cubic-bezier(.2,.8,.2,1) forwards;
        animation-delay: 0.28s;
    }
