/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Header Styles */
header {
    background: linear-gradient(135deg, #7e57c2 0%, #643da8 100%);
    box-shadow: 0 2px 20px rgba(126, 87, 194, 0.3);
}

.navbar {
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: translateY(-2px);
}

/* Card Styles */
.card {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.card-header {
    background: linear-gradient(135deg, #7e57c2 0%, #643da8 100%);
    color: white;
    border: none;
    padding: 1.5rem;
}

.card-header h4 {
    margin: 0;
    font-weight: 600;
    font-size: 1.5rem;
}

/* Button Styles */
.btn {
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.3px;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary {
    background: linear-gradient(135deg, #7e57c2 0%, #643da8 100%);
    box-shadow: 0 4px 15px rgba(126, 87, 194, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(126, 87, 194, 0.4);
    background: linear-gradient(135deg, #8e67d2 0%, #744db8 100%);
}

/* Form Styles */
.form-control {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: #fff;
}

.form-control:focus {
    border-color: #7e57c2;
    box-shadow: 0 0 0 0.2rem rgba(126, 87, 194, 0.15);
    outline: none;
}

/* Footer Styles */
footer {
    margin-top: 4rem;
    padding: 2rem 0;
    background-color: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

footer a {
    color: #7e57c2;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #643da8;
    text-decoration: underline;
}

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: 16px;
    overflow: hidden;
}

.modal-header {
    background: linear-gradient(135deg, #7e57c2 0%, #643da8 100%);
    color: white;
    border: none;
    padding: 1.5rem;
}

.modal-title {
    font-weight: 600;
}

/* Breadcrumb Styles */
.breadcrumb {
    background-color: transparent;
    padding: 1rem 0;
    margin-bottom: 2rem;
    border-radius: 0;
}

.breadcrumb-item {
    font-size: 0.875rem;
    font-weight: 500;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: #999;
    font-weight: 600;
    padding: 0 0.75rem;
}

.breadcrumb-item a {
    color: #7e57c2;
    text-decoration: none;
    transition: color 0.2s ease;
}

.breadcrumb-item a:hover {
    color: #643da8;
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #666;
}

/* Table Styles */
.table {
    font-size: 14px;
    background-color: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.table thead {
    background-color: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
}

.table thead th {
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    padding: 1rem;
    border: none;
    white-space: nowrap;
}

.table tbody tr {
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #f1f3f5;
}

.table tbody tr:last-child {
    border-bottom: none;
}

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

.table td, .table th {
    padding: 0.875rem 1rem;
    vertical-align: middle;
    border: none;
}

.table td a {
    color: #7e57c2;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.table td a:hover {
    color: #643da8;
    text-decoration: underline;
}

.table td b {
    font-weight: 600;
    color: #333;
}

/* Table Responsive */
.table-responsive {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.table-responsive .table {
    margin-bottom: 0;
    box-shadow: none;
}

/* Table Bordered Specific */
.table-bordered {
    border: 1px solid #e9ecef;
}

.table-bordered td, .table-bordered th {
    border: 1px solid #e9ecef;
}

/* Utility Classes */
.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out;
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease-out;
}

.animate-slideInLeft {
    animation: slideInLeft 0.6s ease-out;
}

/*------------------------------------
- COLOR primary
------------------------------------*/
.alert-primary {
    color: #452a74;
    background-color: #f0ecf8;
    border-color: #e5ddf2;
}

.alert-primary hr {
    border-top-color: #d7caec;
}

.alert-primary .alert-link {
    color: #2e1c4e;
}

.badge-primary {
    color: #fff;
    background-color: #7e57c2;
}

.badge-primary[href]:hover, .badge-primary[href]:focus {
    color: #fff;
    background-color: #643da8;
}

.bg-primary {
    background-color: #7e57c2 !important;
}

a.bg-primary:hover, a.bg-primary:focus,
button.bg-primary:hover,
button.bg-primary:focus {
    background-color: #643da8 !important;
}

.border-primary {
    border-color: #7e57c2 !important;
}

.btn-primary {
    color: #fff;
    background-color: #7e57c2;
    border-color: #7e57c2;
}

.btn-primary:hover {
    color: #fff;
    background-color: #6b41b3;
    border-color: #643da8;
}

.btn-primary:focus, .btn-primary.focus {
    box-shadow: 0 0 0 0.2rem rgba(126, 87, 194, 0.5);
}

.btn-primary.disabled, .btn-primary:disabled {
    color: #fff;
    background-color: #7e57c2;
    border-color: #7e57c2;
}

.btn-primary:not(:disabled):not(.disabled):active, .btn-primary:not(:disabled):not(.disabled).active, .show > .btn-primary.dropdown-toggle {
    color: #fff;
    background-color: #643da8;
    border-color: #5d399d;
}

.btn-primary:not(:disabled):not(.disabled):active:focus, .btn-primary:not(:disabled):not(.disabled).active:focus, .show > .btn-primary.dropdown-toggle:focus {
    box-shadow: 0 0 0 0.2rem rgba(126, 87, 194, 0.5);
}

.btn-outline-primary {
    color: #7e57c2;
    background-color: transparent;
    border-color: #7e57c2;
}

.btn-outline-primary:hover {
    color: #fff;
    background-color: #7e57c2;
    border-color: #7e57c2;
}

.btn-outline-primary:focus, .btn-outline-primary.focus {
    box-shadow: 0 0 0 0.2rem rgba(126, 87, 194, 0.5);
}

.btn-outline-primary.disabled, .btn-outline-primary:disabled {
    color: #7e57c2;
    background-color: transparent;
}

.btn-outline-primary:not(:disabled):not(.disabled):active, .btn-outline-primary:not(:disabled):not(.disabled).active, .show > .btn-outline-primary.dropdown-toggle {
    color: #fff;
    background-color: #7e57c2;
    border-color: #7e57c2;
}

.btn-outline-primary:not(:disabled):not(.disabled):active:focus, .btn-outline-primary:not(:disabled):not(.disabled).active:focus, .show > .btn-outline-primary.dropdown-toggle:focus {
    box-shadow: 0 0 0 0.2rem rgba(126, 87, 194, 0.5);
}

.list-group-item-primary {
    color: #452a74;
    background-color: #e5ddf2;
}

.list-group-item-primary.list-group-item-action:hover, .list-group-item-primary.list-group-item-action:focus {
    color: #452a74;
    background-color: #d7caec;
}

.list-group-item-primary.list-group-item-action.active {
    color: #fff;
    background-color: #452a74;
    border-color: #452a74;
}

.table-primary,
.table-primary > th,
.table-primary > td {
    background-color: #e5ddf2;
}

.table-hover .table-primary:hover {
    background-color: #d7caec;
}

.table-hover .table-primary:hover > td,
.table-hover .table-primary:hover > th {
    background-color: #d7caec;
}

.text-primary {
    color: #7e57c2 !important;
}

a.text-primary:hover, a.text-primary:focus {
    color: #643da8 !important;
}

.btn-primary.focus, .btn-primary:focus {
    color: #fff;
    background-color: #7e57c2;
    border-color: #7e57c2;
}

/* Search Input for Tables */
#searchInput {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.875rem 1.25rem;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

#searchInput:focus {
    border-color: #7e57c2;
    box-shadow: 0 0 0 3px rgba(126, 87, 194, 0.1);
    outline: none;
}

#searchInput::placeholder {
    color: #adb5bd;
}

/* Mobile Responsive Tables */
@media only screen and (max-width: 768px) {
    .table {
        font-size: 13px;
    }
    
    .table thead th {
        font-size: 0.7rem;
        padding: 0.75rem 0.5rem;
    }
    
    .table td, .table th {
        padding: 0.5rem;
    }
    
    .breadcrumb {
        padding: 0.75rem 0;
        margin-bottom: 1rem;
    }
    
    .breadcrumb-item {
        font-size: 0.8rem;
    }
    
    #searchInput {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
}

@media only screen and (max-width: 480px) {
    .table-responsive {
        border-radius: 8px;
    }
    
    .table {
        font-size: 12px;
    }
    
    .table thead th {
        font-size: 0.65rem;
        padding: 0.5rem 0.25rem;
    }
    
    .table td, .table th {
        padding: 0.375rem 0.25rem;
    }
}

/* Home Page Specific Styles */
.hero-section {
    background: #ffffff;
    color: #333333;
    padding: 4rem 0;
    margin-bottom: 3rem;
    position: relative;
    overflow: hidden;
    width: 100%;
    border-bottom: 1px solid #e9ecef;
}

.hero-section::before,
.hero-section::after {
    /* Decorative elements will be defined separately */
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -60px;
    left: -60px;
    width: 160px;
    height: 160px;
    background: rgba(126, 87, 194, 0.15);
    border-radius: 50%;
    animation: float1 25s ease-in-out infinite alternate;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -60px;
    right: -60px;
    width: 200px;
    height: 200px;
    background: rgba(100, 61, 168, 0.12);
    border-radius: 50%;
    animation: float2 30s ease-in-out infinite alternate-reverse;
}

@keyframes float1 {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    100% {
        transform: translate(40px, 30px) rotate(360deg);
    }
}

@keyframes float2 {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    100% {
        transform: translate(-40px, -30px) rotate(-360deg);
    }
}

.hero-title {
    font-size: 2.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease-out;
    color: #7e57c2;
    text-shadow: none;
    letter-spacing: -0.5px;
}

.hero-subtitle {
    font-size: 1.15rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: #495057;
    animation: fadeInUp 0.8s ease-out 0.2s both;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
    text-shadow: none;
}

.exam-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: -1rem;
}

.exam-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    animation: fadeInUp 0.6s ease-out;
    animation-fill-mode: both;
}

.exam-card:nth-child(1) {
    animation-delay: 0.1s;
}

.exam-card:nth-child(2) {
    animation-delay: 0.2s;
}

.exam-card:nth-child(3) {
    animation-delay: 0.3s;
}

.exam-card:nth-child(4) {
    animation-delay: 0.4s;
}

.exam-card:nth-child(5) {
    animation-delay: 0.5s;
}

.exam-card:nth-child(6) {
    animation-delay: 0.6s;
}

.exam-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.exam-card h3 {
    color: #7e57c2;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.exam-card .material-icons {
    font-size: 2rem;
    background: linear-gradient(135deg, #7e57c2 0%, #643da8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.exam-card p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.exam-links {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.exam-links .btn {
    width: 100%;
    text-align: center;
    background: #f8f9fa;
    color: #7e57c2;
    border: 2px solid transparent;
    font-weight: 500;
}

.exam-links .btn:hover {
    background: #7e57c2;
    color: white;
    border-color: #7e57c2;
    transform: translateX(5px);
}


/* Main Content Layout */
.main-content-wrapper {
    max-width: 1000px;
    margin: 0 auto;
}

/* Side Ads */
.side-ad-left,
.side-ad-right {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 160px;
    z-index: 100;
}

.side-ad-left {
    left: 10px;
}

.side-ad-right {
    right: 10px;
}

@media (max-width: 1400px) {
    .side-ad-left,
    .side-ad-right {
        display: none;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 1.75rem;
    }

    .hero-subtitle {
        font-size: 1rem;
        padding: 0 1rem;
    }

    .exam-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }

    .hero-section {
        padding: 2rem 0;
    }
}
