/* CSS Custom Properties - Change these to update colors site-wide */
:root {
    --school-primary: rgb(135, 206, 235);
    --school-primary-dark: rgb(57, 167, 211);
    --school-primary-darker: rgb(19, 127, 170);
    --school-primary-light: rgb(142, 171, 182);
    --school-primary-rgb: rgb(151, 220, 248);
}

.SchoolPrimaryColor {
    background-color: var(--school-primary) !important;
    color: white !important;
}

.SchoolPrimaryFont {
    color: var(--school-primary) !important;
}

.SchoolPrimaryGradient {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%) !important;
    color: white !important;
}

.SchoolPrimaryBorder {
    border-color: var(--school-primary) !important;
}

.SchoolPrimaryBorderLeft {
    border-left: 4px solid var(--school-primary) !important;
}

  .teacher-photo img {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid var(--school-primary);
    padding: 5px;
    margin-bottom: 10px;
}

.teacher-details strong {
    color: var(--school-primary);
}



.btn-success{
    background-color: var(--school-primary) !important;
    border-color: var(--school-primary) !important;
    
}

.btn-success:hover{
    transition: ease-in 0.2s;
    background-color: var(--school-primary-dark) !important; 
    border-color: var(--school-primary-darker) !important;
}

thead{
    position: sticky;
    top: 0; 
    z-index: 2;
    background-color: var(--school-primary) !important;
  }

  .dropdown-menu .dropdown-item.SchoolPrimaryColor.NowHover:hover {
    background-color: var(--school-primary) !important;
    color: #ffffff !important;
}


.loadingCentermain {
    position: fixed;
    top: 50%;
    left: 50%;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 6px solid rgba(255, 255, 255, 0.3); /* Lighter border for a soft feel */
    border-top-color: var(--school-primary); /* Vibrant green */
    animation: spin3 1s ease-in-out infinite;
    transform: translate(-50%, -50%);
    z-index: 10000;
    box-shadow: 0 0 20px var(--school-primary); /* Glow effect */
}
@keyframes spin3 {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}


/* #b41f32  rgb(231, 102, 119);*/


/* ===========================
   MODERN DASHBOARD CARDS
   =========================== */

.invoice-card-row {
    margin-bottom: 2rem;
    margin-left: -0.75rem;
    margin-right: -0.75rem;
}

.invoice-card-row > [class*='col-'] {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
    margin-bottom: 1.5rem;
}

.invoice-card {
    position: relative;
    overflow: hidden;
    border: none !important;
    border-radius: 20px;
    padding: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
    height: 100%;
}

.invoice-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15) !important;
}

/* Card Background Gradients */
.invoice-card.bg-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

.invoice-card.bg-info:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%) !important;
}

.invoice-card.bg-success {
    background: linear-gradient(135deg, #00c896 0%, #00a67e 100%) !important;
}

.invoice-card.bg-success:hover {
    background: linear-gradient(135deg, #00a67e 0%, #00c896 100%) !important;
}

.invoice-card.bg-danger {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%) !important;
}

.invoice-card.bg-danger:hover {
    background: linear-gradient(135deg, #ee5a6f 0%, #ff6b6b 100%) !important;
}

.invoice-card.bg-primary,
.invoice-card.SchoolPrimaryColor {
    background: linear-gradient(135deg, #0070c0 0%, #005aa8 100%) !important;
}

.invoice-card.bg-primary:hover,
.invoice-card.SchoolPrimaryColor:hover {
    background: linear-gradient(135deg, #005aa8 0%, #0070c0 100%) !important;
}

/* Card Body Styling */
.invoice-card .card-body {
    padding: 1.8rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    position: relative;
    z-index: 2;
}

.invoice-card .icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.invoice-card:hover .icon {
    background: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.invoice-card .icon svg {
    width: 35px;
    height: 35px;
}

/* Text Styling */
.invoice-card h2.invoice-num,
.invoice-card h3.invoice-num,
.invoice-card h4.invoice-num {
    margin: 0;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.invoice-card h2.invoice-num {
    font-size: 1.8rem;
    margin-bottom: 0.3rem;
}

.invoice-card h3.invoice-num {
    font-size: 1.5rem;
    margin-bottom: 0.2rem;
}

.invoice-card h4.invoice-num {
    font-size: 1.3rem;
    margin-bottom: 0.2rem;
}

.invoice-card .text-white.fs-18 {
    font-size: 0.95rem;
    opacity: 0.95;
    font-weight: 500;
    line-height: 1.4;
}

/* Shine Effect on Hover */
.invoice-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
    z-index: 1;
}

.invoice-card:hover::before {
    left: 100%;
}

/* Attendance Stats Styling */
.invoice-card .fs-18[style*="color: green;"],
.invoice-card .fs-18[style*="color: red;"],
.invoice-card .fs-18[style*="color: black;"] {
    font-weight: 600;
    margin: 0 0.5rem 0 0;
    display: inline-block;
}

/* Responsive Design */
@media (max-width: 768px) {
    .invoice-card .card-body {
        padding: 1.2rem;
        flex-direction: column;
        text-align: center;
    }

    .invoice-card h2.invoice-num {
        font-size: 1.5rem;
    }

    .invoice-card h3.invoice-num {
        font-size: 1.2rem;
    }

    .invoice-card .text-white.fs-18 {
        font-size: 0.85rem;
    }

    .invoice-card .icon {
        width: 45px;
        height: 45px;
    }

    .invoice-card .icon svg {
        width: 35px;
        height: 35px;
    }
}

/* Animation for card appearance */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.invoice-card {
    animation: slideInUp 0.6s ease-out forwards;
}

/* Stagger animation for multiple cards */
.col-xl-6:nth-child(1) .invoice-card {
    animation-delay: 0.1s;
}

.col-xl-6:nth-child(2) .invoice-card {
    animation-delay: 0.2s;
}

.col-xl-6:nth-child(3) .invoice-card {
    animation-delay: 0.3s;
}

.col-xl-6:nth-child(4) .invoice-card {
    animation-delay: 0.4s;
}

.col-xl-6:nth-child(5) .invoice-card {
    animation-delay: 0.5s;
}



.table thead {
    font-weight: 600;
    letter-spacing: 0.5px;
}

.table tbody tr {
    transition: all 0.3s ease;
    border-bottom: 1px solid #e9ecef;
}

.table tbody tr:hover {
    background-color: #f8f9fa;
    color: black;
}

.table tbody tr:last-child {
    border-bottom: none;
}

/* Page Title Styling */
.page-titles {
    margin-bottom: 1.5rem;
}

.page-titles .breadcrumb {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 10px;
    padding: 1rem 1.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border: none;
}

.page-titles .breadcrumb-item {
    color: #6c757d;
}

.page-titles .breadcrumb-item.active a {
   
    font-weight: 600;
}





/* Smooth transitions */
* {
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ===========================
   MULTIPLE SELECT STYLING
   =========================== */



select[multiple] {
    width: 100% !important;
    height: auto !important;
    min-height: 180px !important;
    display: block !important;
}

select[multiple] option {
    padding: 8px 5px;
    line-height: 1.5;
}

/* ===========================
   MODERN TEACHER TABLE STYLING
   =========================== */

.teacher-assignment-row {
    transition: all 0.3s ease;
}

.teacher-assignment-row:hover {
    background-color: var(--school-primary-light) !important;
}

/* Teacher group borders for visual separation */
.teacher-group-start td {
    border-top: 2px solid var(--school-primary) !important;
    padding-top: 15px !important;
}

.teacher-group-end td {
    padding-bottom: 15px !important;
    border-bottom: 2px solid var(--school-primary) !important;
}

.teacher-info-cell {
    vertical-align: middle;
    padding: 12px !important;
    background: linear-gradient(90deg, var(--school-primary-light) 0%, rgba(255,255,255,0.3) 100%);
    border-left: 3px solid var(--school-primary) !important;
}

.teacher-avatar-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.teacher-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--school-primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.teacher-assignment-row:hover .teacher-avatar {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.teacher-name {
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
}

.class-cell {
    vertical-align: middle;
    padding: 10px !important;
}

.class-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(0, 112, 192, 0.3);
    transition: all 0.3s ease;
}

.teacher-assignment-row:hover .class-badge {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 112, 192, 0.4);
}

.subjects-cell {
    vertical-align: middle;
    padding: 10px !important;
    color: #555;
    font-size: 0.9rem;
    line-height: 1.5;
    word-wrap: break-word;
    white-space: normal;
}

/* Subject tags styling (if you want to split subjects into tags) */
.subject-tag {
    display: inline-block;
    background-color: var(--school-primary-light);
    color: var(--school-primary);
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    margin: 2px;
    border: 1px solid var(--school-primary);
}

/* Modern Table Styling */
.teacher-table-wrapper {
    border-radius: 8px;
    overflow-x: auto;
    overflow-y: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.table-modern {
    margin-bottom: 0;
    border-collapse: separate;
    border-spacing: 0;
}

.table-modern thead th {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    padding: 12px 15px;
    border: none;
    color: #fff;
}

.table-modern tbody td {
    padding: 12px 15px;
    vertical-align: middle;
    border-bottom: 1px solid #e9ecef;
}

.table-modern tbody tr:last-child td {
    border-bottom: none;
}

.table-modern.table-hover tbody tr:hover {
    background-color: var(--school-primary-light);
}

.table-modern th:first-child,
        .table-modern td:first-child {
            position: static;
            background-color: transparent;
            z-index: auto;
        }

/* ===========================
   MODERN REGISTRATION FORM STYLING
   =========================== */

.modern-registration-card {
    border: none !important;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.modern-registration-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    padding: 30px;
    position: relative;
    overflow: hidden;
    border-radius: 20px 20px 0 0;
}

.modern-registration-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.modern-registration-header h4 {
    color: #fff;
    font-weight: 700;
    font-size: 1.5rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modern-registration-header h4 i {
    font-size: 1.8rem;
    background: rgba(255,255,255,0.2);
    padding: 12px;
    border-radius: 12px;
}

.modern-registration-header p {
    color: rgba(255,255,255,0.85);
    margin: 10px 0 0 0;
    font-size: 0.95rem;
}

.modern-registration-body {
    padding: 30px;
    background: #fff;
}

.form-section {
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid #e9ecef;
}

.form-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.form-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--school-primary);
}

.form-section-title i {
    font-size: 1.3rem;
    color: var(--school-primary);
    background: var(--school-primary-light);
    padding: 8px;
    border-radius: 8px;
}

.form-section-title h5 {
    color: var(--school-primary);
    font-weight: 600;
    font-size: 1.1rem;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Modern Form Fields */
.modern-form-field {
    margin-bottom: 20px;
}

.modern-form-field label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.modern-form-field label .requireinput {
    color: #dc3545;
    font-style: normal;
}

.modern-form-field .form-control,
.modern-form-field .form-select {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 1rem;
    height: auto;
    min-height: 48px;
    line-height: 1.5;
    overflow: visible;
    transition: all 0.3s ease;
    background-color: #f8f9fa;
}

.modern-form-field .form-control:focus,
.modern-form-field .form-select:focus {
    border-color: var(--school-primary);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(var(--school-primary-rgb), 0.15);
    outline: none;
}

.modern-form-field .form-control::placeholder {
    color: #adb5bd;
}

/* Input with icon */
.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper .form-control {
    padding-left: 45px;
}

.input-icon-wrapper i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--school-primary);
    font-size: 1.1rem;
}

/* Generate Password Button */
.btn-generate-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    border: none;
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.btn-generate-password:hover {
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.password-field-wrapper {
    position: relative;
}

.password-field-wrapper .form-control {
    padding-right: 55px;
}

/* Modern Submit Buttons */
.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-modern-submit {
    flex: 1;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-modern-submit.btn-primary {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(var(--school-primary-rgb), 0.4);
}

.btn-modern-submit.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(var(--school-primary-rgb), 0.5);
}

.btn-modern-submit.btn-secondary {
    background: #f8f9fa;
    color: #6c757d;
    border: 2px solid #e9ecef;
}

.btn-modern-submit.btn-secondary:hover {
    background: #e9ecef;
    border-color: #dee2e6;
}

/* Two-column grid for form fields */
.form-row-modern {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.form-row-modern.three-cols {
    grid-template-columns: repeat(3, 1fr);
}

.form-row-modern.four-cols {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 992px) {
    .form-row-modern.three-cols,
    .form-row-modern.four-cols {
        grid-template-columns: repeat(2, 1fr);
    }

    .modern-form-field .form-control,
    .modern-form-field .form-select {
        font-size: 0.9rem;
        padding: 10px 14px;
        min-height: 44px;
    }

    .modern-form-field .input-icon-wrapper .form-control {
        padding-left: 40px;
    }
}

@media (max-width: 768px) {
    .form-row-modern,
    .form-row-modern.three-cols,
    .form-row-modern.four-cols {
        grid-template-columns: 1fr;
    }
    
    .modern-registration-header {
        padding: 20px;
    }
    
    .modern-registration-header h4 {
        font-size: 1.2rem;
    }
    
    .modern-registration-body {
        padding: 20px;
    }
    
    .form-actions {
        flex-direction: column;
    }
}

/* Progress indicator (optional enhancement) */
.form-progress {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.progress-step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #f8f9fa;
    border-radius: 20px;
    font-size: 0.85rem;
    color: #6c757d;
    margin: 0 5px;
}

.progress-step.active {
    background: var(--school-primary);
    color: #fff;
}

.progress-step i {
    font-size: 1rem;
}

/* ===========================
   PHOTO UPLOAD STYLING
   =========================== */

.photo-preview-container {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 10px;
}

.student-info-preview {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
}

.preview-details {
    flex: 1;
    min-width: 200px;
}

.preview-details h4 {
    margin: 0 0 8px 0;
    color: #333;
    font-weight: 600;
}

.student-preview-name {
    font-size: 1.3rem;
    color: var(--school-primary) !important;
}

.student-preview-grade {
    font-size: 1rem;
    color: #666 !important;
}

.student-preview-extra {
    font-size: 0.9rem;
    color: #888 !important;
}

.preview-image-wrapper {
    flex-shrink: 0;
}

.preview-image {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid var(--school-primary);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.preview-image:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

.preview-placeholder {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    border: 3px dashed #adb5bd;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #6c757d;
}

.preview-placeholder i {
    font-size: 3rem;
    margin-bottom: 8px;
    opacity: 0.5;
}

.preview-placeholder span {
    font-size: 0.8rem;
    text-align: center;
}

/* File Upload Wrapper */
.file-upload-wrapper {
    position: relative;
    border: 2px dashed #dee2e6;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    background: #f8f9fa;
    transition: all 0.3s ease;
    cursor: pointer;
}

.file-upload-wrapper:hover {
    border-color: var(--school-primary);
    background: rgba(var(--school-primary-rgb), 0.05);
}

.file-upload-wrapper .file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-upload-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #6c757d;
    pointer-events: none;
}

.file-upload-text i {
    font-size: 2.5rem;
    color: var(--school-primary);
}

.file-upload-text span {
    font-size: 0.95rem;
}

/* File drag active state */
.file-upload-wrapper.drag-active {
    border-color: var(--school-primary);
    background: rgba(var(--school-primary-rgb), 0.1);
}

.file-upload-wrapper.drag-active .file-upload-text i {
    animation: bounce 0.5s ease infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

@media (max-width: 768px) {
    .student-info-preview {
        flex-direction: column-reverse;
        text-align: center;
    }
    
    .preview-details {
        text-align: center;
    }
    
    .preview-image,
    .preview-placeholder {
        width: 120px;
        height: 120px;
    }
    
    .file-upload-wrapper {
        padding: 15px;
    }
    
    .file-upload-text i {
        font-size: 2rem;
    }
}

/* ===========================
   CALCULATE BUTTONS STYLING
   =========================== */

.calculate-buttons-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.btn-calculate {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: linear-gradient(135deg, #1a56db 0%, #1e40af 100%);
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    box-shadow: 0 4px 15px rgba(26, 86, 219, 0.3);
}

.btn-calculate:hover {
    background: linear-gradient(135deg, #1e40af 0%, #1a56db 100%);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(26, 86, 219, 0.4);
}

.btn-calculate:active {
    transform: translateY(-1px);
}

/* Secondary button (Second Semester) */
.btn-calculate.btn-calculate-secondary {
    background: linear-gradient(135deg, #4b5563 0%, #374151 100%);
    box-shadow: 0 4px 15px rgba(75, 85, 99, 0.3);
}

.btn-calculate.btn-calculate-secondary:hover {
    background: linear-gradient(135deg, #374151 0%, #4b5563 100%);
    box-shadow: 0 8px 25px rgba(75, 85, 99, 0.4);
}

/* Success button (Final Average) */
.btn-calculate.btn-calculate-success {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
}

.btn-calculate.btn-calculate-success:hover {
    background: linear-gradient(135deg, #047857 0%, #059669 100%);
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.4);
}

.btn-calculate-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    color: #fff;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.btn-calculate:hover .btn-calculate-icon {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.3);
}

.btn-calculate-icon.secondary {
    background: rgba(255, 255, 255, 0.2);
}

.btn-calculate-icon.success {
    background: rgba(255, 255, 255, 0.2);
}

.btn-calculate-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.btn-calculate-title {
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
}

.btn-calculate-desc {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

@media (max-width: 992px) {
    .calculate-buttons-grid {
        grid-template-columns: 1fr;
    }
    
    .btn-calculate {
        padding: 15px;
    }
    
    .btn-calculate-icon {
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }
}

/* Fix for single-item form rows to take full width */
.form-row-modern:has(.modern-form-field:only-child) {
    grid-template-columns: 1fr;
}

/* Modern form mobile improvements */
@media (max-width: 576px) {
    .modern-registration-header {
        padding: 15px;
    }
    
    .modern-registration-header h4 {
        font-size: 1rem;
        flex-wrap: wrap;
    }
    
    .modern-registration-header h4 i {
        font-size: 1.3rem;
        padding: 8px;
    }
    
    .modern-registration-header p {
        font-size: 0.85rem;
    }
    
    .modern-registration-body {
        padding: 15px;
    }
    
    .form-section {
        margin-bottom: 20px;
        padding-bottom: 15px;
    }
    
    .form-section-title {
        margin-bottom: 15px;
    }
    
    .form-section-title h5 {
        font-size: 0.95rem;
    }
    
    .modern-form-field .form-control,
    .modern-form-field .form-select,
    .modern-form-field select {
        padding: 10px 12px;
        font-size: 0.9rem;
        width: 100% !important;
        min-width: 0;
    }
    
    .calculate-buttons-grid {
        gap: 10px;
    }
    
    .btn-calculate {
        padding: 12px;
        gap: 10px;
    }
    
    .btn-calculate-icon {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
        flex-shrink: 0;
    }
    
    .btn-calculate-text {
        min-width: 0;
        overflow: hidden;
    }
    
    .btn-calculate-title {
        font-size: 0.9rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .btn-calculate-desc {
        font-size: 0.75rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .form-actions {
        gap: 10px;
    }
    
    .btn-modern-submit {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
}

/* ===========================
   TEACHER RATING CARDS
   =========================== */

.teacher-rating-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.teacher-rating-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 35px rgba(var(--school-primary-rgb), 0.18);
}

.teacher-rating-card .teacher-card-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: linear-gradient(135deg, var(--school-primary-light) 0%, #e9ecef 100%);
}

.teacher-rating-card .teacher-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.teacher-rating-card:hover .teacher-card-photo img {
    transform: scale(1.05);
}

.teacher-rating-card .teacher-card-photo::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to top, rgba(255,255,255,1) 0%, transparent 100%);
}

.teacher-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.teacher-card-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 14px 0;
    text-align: center;
}

.teacher-card-ratings {
    flex: 1;
}

.teacher-star-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid #f0f0f0;
}

.teacher-star-row:last-child {
    border-bottom: none;
}

.teacher-star-row.total-row {
    background: rgba(var(--school-primary-rgb), 0.05);
    border-radius: 8px;
    padding: 8px 10px;
    margin-bottom: 8px;
    border-bottom: none;
}

.teacher-star-label {
    font-size: 0.82rem;
    color: #666;
    font-weight: 500;
}

.teacher-star-row.total-row .teacher-star-label {
    font-weight: 700;
    color: var(--school-primary);
    font-size: 0.85rem;
}

.teacher-star-icons {
    display: flex;
    gap: 2px;
    color: #fbbf24;
    font-size: 1rem;
}

.teacher-star-row.total-row .teacher-star-icons {
    font-size: 1.2rem;
}

.teacher-star-icons .bx-star {
    color: #ddd;
}

.teacher-card-action {
    margin-top: 16px;
}

.btn-rate-teacher {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(var(--school-primary-rgb), 0.3);
}

.btn-rate-teacher:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(var(--school-primary-rgb), 0.4);
    background: linear-gradient(135deg, var(--school-primary-dark) 0%, var(--school-primary) 100%);
}

/* Teachers page card/tabs */
.teachers-page-card {
    border: none !important;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.teachers-page-card > .card-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    border: none;
    padding: 24px 30px;
    position: relative;
    overflow: hidden;
}

.teachers-page-card > .card-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 60%);
    pointer-events: none;
}

.teachers-page-card > .card-header h4 {
    color: #fff;
    font-weight: 700;
    font-size: 1.4rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.teachers-page-card > .card-header h4 i {
    font-size: 1.6rem;
    background: rgba(255,255,255,0.2);
    padding: 10px;
    border-radius: 12px;
}

.teachers-tabs .nav-tabs {
    border: none;
    background: #f8f9fa;
    padding: 12px 16px 0;
    gap: 4px;
}

.teachers-tabs .nav-tabs .nav-link {
    border: none;
    border-radius: 12px 12px 0 0;
    padding: 12px 24px;
    font-weight: 600;
    font-size: 0.9rem;
    color: #6c757d;
    background: transparent;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.teachers-tabs .nav-tabs .nav-link:hover {
    color: var(--school-primary);
    background: rgba(var(--school-primary-rgb), 0.08);
}

.teachers-tabs .nav-tabs .nav-link.active {
    color: var(--school-primary);
    background: #fff;
    box-shadow: 0 -3px 0 var(--school-primary) inset, 0 -2px 8px rgba(0,0,0,0.04);
}

.teachers-tabs .tab-content {
    background: #fff;
    padding: 30px;
}

.teachers-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--school-primary-light);
}

.teachers-section-title i {
    font-size: 1.5rem;
    color: var(--school-primary);
    background: rgba(var(--school-primary-rgb), 0.1);
    padding: 10px;
    border-radius: 12px;
}

.teachers-section-title h4 {
    color: #333;
    font-weight: 700;
    font-size: 1.15rem;
    margin: 0;
}

/* Teacher cards grid */
.teacher-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
}

@media (max-width: 768px) {
    .teacher-cards-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .teacher-card-body {
        padding: 16px;
    }
    .teachers-tabs .tab-content {
        padding: 20px 16px;
    }
}

@media (max-width: 576px) {
    .teacher-cards-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .teacher-card-name {
        font-size: 0.9rem;
    }
    .teacher-star-label {
        font-size: 0.75rem;
    }
    .teacher-star-icons {
        font-size: 0.85rem;
    }
    .btn-rate-teacher {
        padding: 10px 14px;
        font-size: 0.8rem;
    }
}

/* ===========================
   TYPED TEST FEATURE
   =========================== */

.typed-test-section-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: #fff;
    padding: 14px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.typed-test-section-header i {
    font-size: 1.5rem;
    background: rgba(255,255,255,0.2);
    padding: 8px;
    border-radius: 8px;
    flex-shrink: 0;
}
.typed-test-section-header h5 {
    margin: 0;
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
}

.typed-test-edit-banner {
    background: linear-gradient(90deg, rgba(var(--school-primary-rgb), 0.1) 0%, rgba(var(--school-primary-rgb), 0.04) 100%);
    border-left: 4px solid var(--school-primary);
    border-radius: 0 8px 8px 0;
    padding: 10px 16px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}
.typed-test-edit-banner .edit-banner-text {
    color: var(--school-primary);
    font-weight: 600;
    font-size: 0.9rem;
}
.typed-test-edit-banner i {
    color: var(--school-primary);
}

/* Form field focus using school primary */
.typed-test-form .form-control:focus,
.typed-test-form .form-select:focus,
.typed-test-form select.form-control:focus {
    border-color: var(--school-primary);
    box-shadow: 0 0 0 3px rgba(var(--school-primary-rgb), 0.15);
    outline: none;
}
.typed-test-form label.form-label {
    color: #333;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Primary save/submit button */
.btn-typed-save {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(var(--school-primary-rgb), 0.35);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-typed-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(var(--school-primary-rgb), 0.45);
    color: #fff;
}
.btn-typed-save:active { transform: translateY(0); }

/* Refresh outline button */
.btn-typed-refresh {
    border: 1.5px solid var(--school-primary);
    color: var(--school-primary);
    background: transparent;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.btn-typed-refresh:hover {
    background: var(--school-primary);
    color: #fff;
}

/* Approve / Reject / Edit / PDF action buttons */
.btn-typed-approve,
.btn-typed-reject,
.btn-typed-edit,
.btn-typed-pdf {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
    text-decoration: none;
    line-height: 1.5;
}
.btn-typed-approve {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: #fff;
    box-shadow: 0 2px 6px rgba(5,150,105,0.3);
}
.btn-typed-approve:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(5,150,105,0.4); color: #fff; }
.btn-typed-reject {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #fff;
    box-shadow: 0 2px 6px rgba(239,68,68,0.3);
}
.btn-typed-reject:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(239,68,68,0.4); color: #fff; }
.btn-typed-edit {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    color: #fff;
    box-shadow: 0 2px 6px rgba(var(--school-primary-rgb), 0.3);
}
.btn-typed-edit:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(var(--school-primary-rgb), 0.4); color: #fff; }
.btn-typed-pdf {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    color: #fff;
    box-shadow: 0 2px 6px rgba(124,58,237,0.3);
}
.btn-typed-pdf:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(124,58,237,0.4); color: #fff; }

/* Typed test list table */
.typed-test-table thead {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%) !important;
}
.typed-test-table thead th {
    color: #fff !important;
    font-weight: 600;
    font-size: 0.83rem;
    letter-spacing: 0.4px;
    padding: 10px 8px;
    border: none !important;
}
.typed-test-table tbody tr:hover {
    background-color: rgba(var(--school-primary-rgb), 0.05) !important;
}

/* ===========================
   Teacher Payment Interface Styling
   =========================== */

/* Teacher Payment Transaction Table */
.teacher-transaction-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.teacher-transaction-table thead {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark, #0d5a3d) 100%);
}

.teacher-transaction-table thead th {
    color: #fff;
    font-weight: 600;
    padding: 16px 12px;
    text-align: left;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
}

.teacher-transaction-table tbody td {
    padding: 14px 12px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 13px;
}

.teacher-transaction-table tbody tr {
    transition: all 0.3s ease;
    background: #fff;
}

.teacher-transaction-table tbody tr:hover {
    background: #f9fafb;
    box-shadow: inset 0 0 0 1px #f0f1f3;
}

.teacher-transaction-table tbody tr:last-child td {
    border-bottom: none;
}

/* Modern teacher payment card */
.teacher-payment-card {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
}

.teacher-payment-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.payment-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.payment-info-item {
    background: #fff;
    padding: 14px;
    border-radius: 8px;
    border-left: 4px solid var(--school-primary);
    display: flex;
    flex-direction: column;
}

.payment-info-item-label {
    font-size: 11px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    font-weight: 600;
}

.payment-info-item-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--school-primary);
}

/* Payment status badges */
.payment-status-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.payment-status-paid {
    background: #d1fae5;
    color: #047857;
}

.payment-status-pending {
    background: #fef3c7;
    color: #92400e;
}

.payment-status-partial {
    background: #dbeafe;
    color: #0369a1;
}

/* ========== Mobile Horizontal Scroll Tabs (Global) ========== */
@media (max-width: 768px) {
    .nav-tabs {
        flex-wrap: nowrap !important;
        -ms-flex-wrap: nowrap !important;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: var(--school-primary) #e9ecef;
        padding-bottom: 4px;
    }
    .nav-tabs::-webkit-scrollbar {
        height: 4px;
    }
    .nav-tabs::-webkit-scrollbar-track {
        background: #e9ecef;
        border-radius: 4px;
    }
    .nav-tabs::-webkit-scrollbar-thumb {
        background: var(--school-primary);
        border-radius: 4px;
    }
    .nav-tabs .nav-link {
        white-space: nowrap;
    }
}

/* ========== APPROVED GRADES CARD STYLING ========== */

.approved-grade-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.approved-grade-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
}

.approved-grade-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.approved-grade-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.approval-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    margin-bottom: 8px;
}

.approval-badge i {
    font-size: 1rem;
}

.approval-by {
    color: rgba(255, 255, 255, 0.95);
    margin: 0;
    font-size: 0.95rem;
}

.approval-by strong {
    color: #fff;
}

.approved-grade-card .card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Grade Change Section */
.grade-change-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(var(--school-primary-rgb), 0.08) 0%, rgba(var(--school-primary-rgb), 0.04) 100%);
    border-radius: 12px;
    border: 1px solid rgba(var(--school-primary-rgb), 0.2);
}

.grade-badge {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px;
    border-radius: 10px;
    background: white;
}

.grade-badge.old-grade {
    border: 2px solid #e0e0e0;
}

.grade-badge.new-grade {
    border: 2px solid var(--school-primary);
    background: linear-gradient(135deg, rgba(var(--school-primary-rgb), 0.05) 0%, rgba(var(--school-primary-rgb), 0.02) 100%);
}

.grade-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    color: #999;
}

.grade-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--school-primary);
}

.grade-arrow {
    color: var(--school-primary);
    font-size: 1.3rem;
}

/* Info Sections */
.info-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e9ecef;
}

.info-section:last-of-type {
    border-bottom: none;
}

.info-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--school-primary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-header i {
    font-size: 1.1rem;
    background: rgba(var(--school-primary-rgb), 0.1);
    padding: 6px;
    border-radius: 6px;
}

.person-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.person-photo {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--school-primary);
    flex-shrink: 0;
}

.person-details {
    min-width: 0;
}

.person-details h6 {
    margin: 0;
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.person-details small {
    display: block;
    color: #999;
    font-size: 0.8rem;
    margin-top: 2px;
}

/* Academic Details Grid */
.academic-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 10px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-item label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    color: #999;
}

.detail-item span {
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
}

/* Reason Section */
.reason-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.reason-section label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--school-primary);
    font-size: 0.9rem;
}

.reason-section label i {
    font-size: 1rem;
    background: rgba(var(--school-primary-rgb), 0.1);
    padding: 4px;
    border-radius: 4px;
}

.reason-section p {
    margin: 0;
    color: #555;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Footer */
.approved-grade-footer {
    background: #f8f9fa;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.date-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
    text-align: center;
}

.date-item small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #999;
    font-size: 0.8rem;
    font-weight: 600;
}

.date-item small i {
    color: var(--school-primary);
}

.date-item span {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .grade-change-section {
        flex-wrap: wrap;
    }

    .academic-details {
        grid-template-columns: 1fr;
    }

    .approved-grade-footer {
        flex-direction: column;
        gap: 12px;
    }
}

/* ========== DECLINED GRADES CARD STYLING ========== */

.declined-grade-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.declined-grade-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
}

.declined-grade-header {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.declined-grade-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.decline-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    margin-bottom: 8px;
}

.decline-badge i {
    font-size: 1rem;
}

.decline-by {
    color: rgba(255, 255, 255, 0.95);
    margin: 0;
    font-size: 0.95rem;
}

.decline-by strong {
    color: #fff;
}

.declined-grade-card .card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Decline Reason Section */
.decline-reason-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(220, 38, 38, 0.04) 100%);
    border-left: 4px solid #ef4444;
    border-radius: 8px;
}

.decline-reason-section label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #dc2626;
    font-size: 0.9rem;
}

.decline-reason-section label i {
    font-size: 1rem;
    background: rgba(239, 68, 68, 0.15);
    padding: 4px;
    border-radius: 4px;
}

.decline-reason-section p {
    margin: 0;
    color: #555;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Footer */
.declined-grade-footer {
    background: #f8f9fa;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.declined-grade-footer .date-item small i {
    color: #ef4444;
}

@media (max-width: 768px) {
    .declined-grade-footer {
        flex-direction: column;
        gap: 12px;
    }
}

/* ========== PENDING GRADES CARD STYLING ========== */

.pending-grade-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--school-primary);
}

.pending-grade-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
}

.pending-grade-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.pending-grade-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.teacher-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 2;
    flex: 1;
    min-width: 0;
}

.teacher-header-photo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid white;
    flex-shrink: 0;
}

.teacher-header-details {
    min-width: 0;
    color: white;
}

.teacher-header-details h5 {
    margin: 0;
    font-weight: 600;
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.teacher-header-details small {
    display: block;
    opacity: 0.9;
    font-size: 0.8rem;
}

.pending-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 2;
    flex-shrink: 0;
}

.pending-status-badge i {
    font-size: 0.95rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.pending-grade-card .card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Footer with date */
.pending-grade-footer {
    background: #f8f9fa;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.date-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.date-info small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #999;
    font-size: 0.8rem;
    font-weight: 600;
}

.date-info small i {
    color: var(--school-primary);
}

.date-info span {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
}

/* Action Buttons */
.pending-grade-actions {
    padding: 16px 24px;
    display: flex;
    gap: 12px;
    border-top: 1px solid #e9ecef;
}

.btn-action {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-action i {
    font-size: 1.1rem;
}

.btn-approve {
    background: linear-gradient(135deg, #22a745 0%, #1e7e34 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(34, 167, 69, 0.3);
}

.btn-approve:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 167, 69, 0.4);
    background: linear-gradient(135deg, #1e7e34 0%, #155724 100%);
}

.btn-approve:active {
    transform: translateY(0);
}

.btn-decline {
    background: linear-gradient(135deg, #e0e0e0 0%, #d0d0d0 100%);
    color: #333;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-decline:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background: linear-gradient(135deg, #d0d0d0 0%, #bbb 100%);
    color: #000;
}

.btn-decline:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .pending-grade-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .pending-status-badge {
        align-self: flex-end;
    }

    .pending-grade-actions {
        flex-direction: column;
    }

    .btn-action {
        width: 100%;
    }
}

/* ========== TEACHER REQUEST CARDS (STAFF VIEW) ========== */

.teacher-request-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.teacher-request-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
}

/* Pending Request Card */
.pending-request-card {
    border-top: 4px solid var(--school-primary);
}

.request-card-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.request-card-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.pending-header {
    background: linear-gradient(135deg, var(--school-primary) 0%, var(--school-primary-dark) 100%);
}

.approved-header {
    background: linear-gradient(135deg, #22a745 0%, #1e7e34 100%);
}

.declined-header {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    margin-bottom: 8px;
}

.status-badge i {
    font-size: 1rem;
}

.pending-header .status-badge i {
    animation: pulse 2s infinite;
}

.status-subtitle {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    font-size: 0.9rem;
}

.teacher-request-card .card-body {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Footer styles */
.request-card-footer {
    background: #f8f9fa;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.request-card-footer small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #999;
    font-size: 0.8rem;
    font-weight: 600;
}

.request-card-footer small i {
    color: var(--school-primary);
}

.request-card-footer span {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
}

.request-card-footer-dual {
    background: #f8f9fa;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.date-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
    text-align: center;
}

.date-item small {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #999;
    font-size: 0.8rem;
    font-weight: 600;
}

.approved-header ~ .card-body .date-item small i,
.request-card-footer-dual .date-item:nth-child(2) small i {
    color: #22a745;
}

.declined-header ~ .card-body .date-item small i,
.declined-request-card .request-card-footer-dual .date-item:nth-child(2) small i {
    color: #ef4444;
}

.date-item span {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .request-card-footer-dual {
        flex-direction: column;
        gap: 12px;
    }
}

/* ========== STUDENT PROBLEM & REQUEST CARDS ========== */

.student-problem-card,
.student-request-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.student-problem-card:hover,
.student-request-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.15);
}

/* Problem Card Variants */
.pending-problem-card {
    border-top: 4px solid var(--school-primary);
}

.approved-problem-card {
    border-top: 4px solid #22a745;
}

.declined-problem-card {
    border-top: 4px solid #ef4444;
}

/* Request Card Variants */
.pending-request-card {
    border-top: 4px solid var(--school-primary);
}

.approved-request-card {
    border-top: 4px solid #22a745;
}

.declined-request-card {
    border-top: 4px solid #ef4444;
}