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;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* Splash screen container */
#splash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #2c3e50;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999;
    animation: fadeOut 1s ease forwards;
    animation-delay: 1.5s; /* fade out after 1.5s */
}

    /* Logo styling */
    #splash .logo {
        width: 100px;
        height: 100px;
        margin-bottom: 20px;
        animation: pulse 1.5s infinite;
    }
.container a {
    text-decoration: none;
}


/* Spinner animation */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #fff;
    border-top: 4px solid #f39c12;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-top: 20px;
}

/* Fade-out animation */
@keyframes fadeOut {
    to {
        opacity: 0;
        visibility: hidden;
    }
}

/* Spinner rotation */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Logo heartbeat effect */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}


/* ===== Base & Responsive Fonts ===== */
html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    margin: 0 0 60px 0;
    font-family: 'Segoe UI', sans-serif;
    background: #f5f6fa;
}

/* ===== Button & Form Focus ===== */
.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;
}

/* ===== Splash Screen ===== */
#splash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #2c3e50;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999;
    animation: fadeOut 1s ease forwards;
    animation-delay: 1.5s;
}

    #splash .logo {
        width: 100px;
        height: 100px;
        margin-bottom: 20px;
        animation: pulse 1.5s infinite;
    }

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #fff;
    border-top: 4px solid #f39c12;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-top: 20px;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        visibility: hidden;
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0%,100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

/* ===== Sidebar ===== */
.sidebar {
    width: 250px;
    background: #1f2a38;
    color: #fff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    overflow-y: auto;
    transition: width 0.3s ease, left 0.3s ease;
    z-index: 1000;
}

    .sidebar.collapsed {
        width: 70px;
    }

    .sidebar.active {
        left: 0;
    }

    .sidebar .brand {
        padding: 15px 20px;
        font-size: 1.3rem;
        font-weight: bold;
        border-bottom: 1px solid rgba(255,255,255,0.2);
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .sidebar a {
        color: #fff;
        padding: 12px 20px;
        display: flex;
        align-items: center;
        text-decoration: none;
        font-weight: 500;
        border-radius: 6px;
        margin: 5px 10px;
        transition: all 0.3s ease;
    }

        .sidebar a:hover {
            background: #34495e;
            padding-left: 30px;
        }

    .sidebar i {
        margin-right: 12px;
        min-width: 20px;
        text-align: center;
        font-size: 1.1rem;
    }

    .sidebar.collapsed a span {
        display: none;
    }

    .sidebar .submenu {
        display: none;
        flex-direction: column;
        margin-left: 15px;
    }

        .sidebar .submenu.show {
            display: flex;
        }

/* ===== Content ===== */
.content {
    flex-grow: 1;
    margin-left: 250px;
    transition: margin-left 0.3s ease;
    display: flex;
    flex-direction: column;
}

    .content.collapsed {
        margin-left: 70px;
    }

main {
    flex-grow: 1;
    padding: 20px;
}

footer {
    text-align: center;
    font-size: .9rem;
    color: #666;
    padding: 10px 0;
    border-top: 1px solid #ddd;
    background: #fff;
}

/* ===== Top Navbar ===== */
.topbar {
    background: #fff;
    padding: .5rem 1rem;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 999;
}

    .topbar .navbar-brand {
        font-weight: bold;
        color: #1f2a38;
    }

    .topbar .logout-btn {
        background: #e74c3c;
        border: none;
        color: #fff;
        padding: 6px 15px;
        border-radius: 5px;
        font-weight: 500;
        transition: background 0.2s;
    }

        .topbar .logout-btn:hover {
            background: #c0392b;
        }

.toggle-btn {
    cursor: pointer;
    font-size: 1.3rem;
    transition: transform 0.3s ease-in-out;
}

    .toggle-btn.rotate {
        transform: rotate(90deg);
    }

/* ===== Responsive Sidebar ===== */
@media (max-width:768px) {
    .sidebar {
        left: -250px;
    }

        .sidebar.active {
            left: 0;
        }

    .content, .content.collapsed {
        margin-left: 0 !important;
    }
}

/* site.css */

/* Make footer fixed at bottom */
footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #f8f9fa; /* match your theme */
    color: #333;
    text-align: center;
    padding: 10px 0;
    z-index: 1000;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.1);
}

/* Add spacing at bottom of content so it doesn't overlap footer */
.content {
    padding-bottom: 60px; /* height of footer + some padding */
}
