* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
}

.navbar {
    /* background: linear-gradient(135deg, #304186 0%, #2a3c7a 100%); */
    box-shadow: 0 4px 20px rgba(48, 65, 134, 0.3);
    padding: 0.8rem 0;
    position: relative;
    overflow: hidden;
    border-bottom: #20c997;

    border-bottom: 20px solid #304186;
    padding-bottom: 2.5px;
}

.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.navbar-content {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    /* padding: 0 2rem; */


    margin-right: 10px;
    padding-right: 0;
    padding-left: 2rem;

}

.logo-section {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-left: 150px;
}

.logo-image {
    height: 110px;
    width: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem;
}

.logo-text-container {
    /* color: white; */
    color: #304186;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin-bottom: 0.25rem;
    letter-spacing: 0.5px;
    font-family: 'Inter', sans-serif;
}

.tagline {
    font-size: 0.95rem;
    /* color: #ffd700; */
    color: red;
    font-weight: 500;
    font-style: italic;
    font-family: 'Inter', sans-serif;
}

.flag-container {
    margin-right: 0;
    padding-right: 0;
}

.flag {
    display: flex;
    flex-direction: column;
    width: 180px;
    height: 100px;
}

.flag div {
    height: 33.3px;
}

.red {
    background-color: red;
}

.light-blue {
    background-color: lightblue;
}

.dark-blue {
    background-color: #2a2f6b;
}

/* Main Content */
.main-content {
    padding: 3rem 0;
    min-height: calc(100vh - 120px);
}

.hero-section {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 3rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, rgba(48, 65, 134, 0.05) 0%, rgba(255, 215, 0, 0.05) 100%);
    border-radius: 50%;
    transform: translate(50%, -50%);
}

.welcome-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #304186;
    margin-bottom: 1rem;
    line-height: 1.2;
    position: relative;
}

.welcome-subtitle {
    font-size: 1.2rem;
    color: #6c757d;
    margin-bottom: 2rem;
    font-weight: 400;
}

.instruction-card {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    border-left: 4px solid #304186;
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.instruction-text {
    font-size: 1rem;
    line-height: 1.7;
    color: #495057;
    margin-bottom: 1rem;
}

.instruction-text:last-child {
    margin-bottom: 0;
}

.highlight-link {
    color: #304186;
    text-decoration: none;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(48, 65, 134, 0.1);
    transition: all 0.3s ease;
}

.highlight-link:hover {
    background: rgba(48, 65, 134, 0.2);
    transform: translateY(-1px);
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
}

.btn-custom {
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-register {
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.btn-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
    color: white;
}

.btn-login {
    background: linear-gradient(135deg, #304186 0%, #2a3c7a 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(48, 65, 134, 0.3);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(48, 65, 134, 0.4);
    color: white;
}

/* Program Tabs */
.programs-section {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.program-tabs {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: none;
    padding: 0 2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.program-tabs .nav-link {
    color: #6c757d;
    border: none;
    padding: 1rem 1.5rem;
    font-weight: 500;
    border-radius: 8px 8px 0 0;
    margin-top: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    background: transparent;
}

.program-tabs .nav-link:hover {
    color: #304186;
    background: rgba(48, 65, 134, 0.05);
}

.program-tabs .nav-link.active {
    color: #304186;
    background: white;
    font-weight: 600;
    box-shadow: 0 -4px 8px rgba(0, 0, 0, 0.1);
}

/* Search Section */
.search-section {
    padding: 2rem;
}

.search-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    border-radius: 8px;
}

.entries-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #6c757d;
}

.entries-select,
.search-input {
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.entries-select:focus,
.search-input:focus {
    border-color: #304186;
    box-shadow: 0 0 0 0.2rem rgba(48, 65, 134, 0.25);
    outline: none;
}

.search-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-input {
    width: 250px;
}

/* Data Table */
.table-container {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    font-size: 0.9rem;
    margin: 0;
}

.data-table th {
    background: linear-gradient(135deg, #304186 0%, #2a3c7a 100%);
    color: white;
    padding: 1rem 0.75rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.data-table th:hover {
    background: linear-gradient(135deg, #2a3c7a 0%, #304186 100%);
}

.data-table th::after {
    content: "↕";
    position: absolute;
    right: 0.5rem;
    opacity: 0.7;
    font-size: 0.8rem;
}

.data-table td {
    padding: 1rem 0.75rem;
    color: #495057;
    border-bottom: 1px solid #f1f3f4;
    vertical-align: top;
    transition: all 0.3s ease;
}

.data-table tbody tr {
    transition: all 0.3s ease;
}

.data-table tbody tr:hover {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

/* Status badges for requirements */
.requirement-badge {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    display: inline-block;
}

.date-badge {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    display: inline-block;
}



/**
 *REGISTER & LOGIN 
 */
 .form-card {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.card-header {
    padding: 10px 15px;
    font-size: 14px;
    font-weight: 500;
}

.form-container {
    padding: 15px;
}

.form-group-input {
    margin-bottom: 12px;
}

.form-row {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.form-row .form-group-input {
    flex: 1;
    margin-bottom: 0;
}

label {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.required {
    color: #e74c3c;
}
.select2-container--bootstrap .select2-selection--single {
    height: 38.5px;
  }

/* input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
select {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 12px;
    background-color: #fff;
    transition: border-color 0.2s ease;
    height: 32px;
} */

/* input:focus,
select:focus {
    outline: none;
    border-color: #4A90E2;
    box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.1);
} */
 .form-control:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: #4A90E2;
}

.prefilled {
    background-color: #fff3cd !important;
    color: #856404;
}

.password-field {
    background-color: #fff3cd !important;
    color: #856404;
    letter-spacing: 1px;
    font-weight: bold;
}
.select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 8px center;
    background-repeat: no-repeat;
    background-size: 12px;
    padding-right: 30px;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 15px 0;
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    height: auto;
    margin-top: 1px;
}

.checkbox-group label {
    margin-bottom: 0;
    font-size: 12px;
    line-height: 1.3;
    cursor: pointer;
}

.terms-link {
    color: #4A90E2;
    text-decoration: none;
}

.terms-link:hover {
    text-decoration: underline;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.btn {
    /* flex: 1; */
    padding: 8px 15px;
    border: none;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    height: 36px;
}


/* .btn-secondary {
    background-color: #3333;
    color: #fff;
    border: 1px solid #ddd;
} */


.tutorial-section {
    background: #4A90E2;
    color: white;
    padding: 8px 15px;
    text-align: center;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.tutorial-section:hover {
    background: #357abd;
}

.tutorial-section::before {
    content: "🎓 ";
    margin-right: 4px;
}

/* Three column layout for wider forms */
.form-row-triple {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.form-row-triple .form-group-input {
    flex: 1;
    margin-bottom: 0;
}


/*SIDE BAR*/
/* Main container for sidebar and content */
.main-container {
    display: flex;
    min-height: calc(100vh - 80px); /* Adjust based on your navbar height */
    height: auto;
    overflow: visible;
}

/* Sidebar styles */
.sidebar {
    width: 270px;
    background-color: #f8f9fa;
    border-right: 1px solid #dee2e6;
    overflow-y: auto;
    flex-shrink: 0;
    transition: width 0.3s ease;
}

/* Dark theme option for sidebar */
.sidebar.dark {
    background-color: #343a40;
    border-right-color: #495057;
}

.sidebar-nav {
    padding: 1rem 0;
}

.nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-item {
    margin-bottom: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    color: #495057;
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 0 25px 25px 0;
    margin-right: 0.7rem;
    white-space: nowrap;
    font-size: 14px;
}

.nav-link:hover {
    background-color: #e9ecef;
    color: #212529;
    text-decoration: none;
}

.nav-link.active {
    background-color: #007bff;
    color: white;
}

.nav-icon {
    margin-right: 0.75rem;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

/* Content wrapper */
.content-wrapper {
    flex: 1;
    min-width: 0;
    overflow: visible;
    /* padding: 1.5rem; */
    padding: 0.7rem;
    background-color: #ffffff;
}

/* Toggle button for collapsible sidebar (optional) */
.sidebar-toggle {
    position: fixed;
    top: 50%;
    left: 250px;
    transform: translateY(-50%);
    background-color: #007bff;
    color: white;
    border: none;
    padding: 0.5rem;
    border-radius: 0 0.25rem 0.25rem 0;
    cursor: pointer;
    z-index: 1000;
    transition: left 0.3s ease;
}

.sidebar.collapsed {
    width: 60px;
}

.sidebar.collapsed + .sidebar-toggle {
    left: 60px;
}

.sidebar.collapsed .nav-link span {
    display: none;
}

.sidebar.collapsed .nav-link {
    justify-content: center;
    margin-right: 0;
    border-radius: 0;
}

.sidebar.collapsed .nav-icon {
    margin-right: 0;
}

/* Responsive Design */
@media (max-width: 992px) {
    .navbar-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .logo-section {
        flex-direction: column;
        gap: 1rem;
        margin-left: 0px;
    }

    .logo-text {
        font-size: 1.5rem;
    }

    .welcome-title {
        font-size: 2rem;
    }

    .program-tabs {
        padding: 0 1rem;
    }

    .program-tabs .nav-link {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }

    .flag-line {
        display: none;
    }
    .login-side-image{
        display: none;
    }
}
@media (max-width: 900px) {
    .form-card {
        max-width: 100%;
    }

    .form-row-triple {
        flex-wrap: wrap;
    }

    .form-row-triple .form-group-input {
        flex: 1 1 45%;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 2rem 0;
    }

    .hero-section {
        padding: 2rem 1.5rem;
    }

    .welcome-title {
        font-size: 1.75rem;
    }

    .action-buttons {
        flex-direction: column;
        gap: 0.75rem;
    }

    .btn-custom {
        width: 100%;
    }

    .search-controls {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }

    .search-control {
        justify-content: center;
    }

    .search-input {
        width: 100%;
    }

    .data-table {
        font-size: 0.8rem;
    }

    .data-table th,
    .data-table td {
        padding: 0.75rem 0.5rem;
    }

    .program-tabs {
        flex-direction: column;
        padding: 1rem;
    }

    .program-tabs .nav-link {
        width: 100%;
        margin: 0.25rem 0;
        border-radius: 6px;
    }

    .flag-line {
        display: none;
    }
    .sidebar {
        width: 60px;
    }
    
    .nav-link span {
        display: none;
    }
    
    .nav-link {
        justify-content: center;
        margin-right: 0;
        border-radius: 0;
    }
    
    .nav-icon {
        margin-right: 0;
    }

}
      
    
@media (max-width: 600px) {

    .form-row,
    .form-row-triple {
        flex-direction: column;
        gap: 0;
    }

    .form-row .form-group,
    .form-row-triple .form-group-input {
        margin-bottom: 12px;
        flex: 1 1 100%;
    }

    .button-group {
        flex-direction: column;
    }
}
@media (max-width: 576px) {
    .hero-section {
        padding: 1.5rem 1rem;
    }

    .logo-text {
        font-size: 1.2rem;
    }

    .welcome-title {
        font-size: 1.5rem;
    }

    .kenya-flag {
        width: 100px;
        height: 60px;
    }

    .flag {
        height: 60px;
        width: 100px;
    }

    .flag div {
        height: 20px;
    }

    .logo-image {
        height: 60px;
    }

    .flag-line {
        display: none;
    }
    .main-container {
        flex-direction: column;
    }
    .sidebar {
        width: 100%;
        height: auto;
        border-right: none;
        border-bottom: 1px solid #dee2e6;
    }
    
    .sidebar-nav {
        padding: 0.5rem 0;
    }
    
    .nav-list {
        display: flex;
        justify-content: space-around;
        flex-wrap: wrap;
    }
    
    .nav-item {
        margin-bottom: 0;
    }
    
    .nav-link {
        flex-direction: column;
        padding: 0.5rem;
        margin-right: 0;
        border-radius: 0;
        min-width: 60px;
    }
    
    .nav-link span {
        display: block;
        font-size: 0.75rem;
        margin-top: 0.25rem;
    }
    
    .nav-icon {
        margin-right: 0;
        margin-bottom: 0.25rem;
    }
}

/* Loading animation */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, .3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

.flag-line {
    width: 3px !important;
    height: 100px;
    background: linear-gradient(to bottom,
            red 33.33%,
            lightblue 33.33%,
            lightblue 66.66%,
            #2a2f6b 66.66%);
    margin: 0 20px;
    padding: 1.5px;
    margin-left: 60px;
}



