:root {
    /* Theme-aware color variables */
    --color-primary: #3598dc;
    --color-success: #26a69a;
    --color-info: #32c5d2;
    --color-warning: #f29a12;
    --color-danger: #e7505a;
    --color-dark: #2f353b;
    --color-light: #f3f6f9;
    --color-border: #ebedf3;

    /* Teacher status colors */
    --color-active: #26C281;
    --color-inactive: #E87E04;
    --color-onleave: #8E44AD;
}

/* Teacher portlet styling */
.student-portlet {
    position: relative;
    overflow: hidden;
    border-radius: 6px;
    border: 1px solid var(--color-border);
    background: #fff;
    transition: all .25s ease-in-out;
    margin-bottom: 30px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.1);
    min-height: 610px;
}


.student-portlet:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, .15);
}

/* Left border color indicator based on status */
.student-portlet.status-active {
    border-left: 4px solid var(--color-active);
}

.student-portlet.status-inactive {
    border-left: 4px solid var(--color-inactive);
}

.student-portlet.status-onleave {
    border-left: 4px solid var(--color-onleave);
}

/* Header styling */
.student-portlet .portlet-title {
    padding: 12px 15px !important;
    background: var(--color-light);
    border-bottom: 1px solid var(--color-border);
    /*display: flex;*/
    /*align-items: center;*/
    /*justify-content: space-between;*/
}

.student-portlet .portlet-title .caption {
    display: flex;
    align-items: center;
}

.student-portlet .portlet-title .caption-subject {
    font-size: 18px;
    font-weight: 600;
    margin-left: 10px;
}

.student-portlet .teacher-id {
    font-size: 12px;
    padding: 3px 8px;
    background: #e4e8ef;
    border-radius: 20px;
    color: #555;
    margin-left: 10px;
}


/* Tab panel styling */
.student-portlet .tabbable-line {
    margin-top: 0;
}

.student-portlet .tabbable-line > .nav-tabs {
    border-bottom: 1px solid #eee;
}

.student-portlet .tabbable-line > .nav-tabs > li {
    margin-right: 2px;
}

.student-portlet .tabbable-line > .nav-tabs > li > a {
    border: 0;
    margin-right: 0;
    color: #737373;
    font-size: 14px;
    padding: 15px 20px;
}

.student-portlet .tabbable-line > .nav-tabs > li > a > i {
    margin-right: 5px;
}

.student-portlet .tabbable-line > .nav-tabs > li.active > a {
    border-bottom: 3px solid var(--color-primary);
    color: var(--color-primary);
}

/* Tab content styling */
.student-portlet .tab-content {
    padding: 20px;
}

.institute-subject-info {
    margin-top: 10px;
    padding: 8px;
    background: #f9f9f9;
    border-radius: 4px;
    border-left: 3px solid var(--color-info);
    font-size: 11px;
}

.phone-corp .contact-icon-compact {
    background: #e74c3c;
}

.phone-pers .contact-icon-compact {
    background: #9b59b6;
}

.email-pers .contact-icon-compact {
    background: #f39c12;
}

.email-corp .contact-icon-compact {
    background: #27ae60;
}


/* Compact Employment Section */
.student-compact {
    border-radius: 5px;
    padding: 8px;
    margin-bottom: 10px;
    position: relative;
    transition: all 0.3s ease;
}

/* Active Employment */
.student-compact.student-register-date-active {
    background: #f4f6f8;
    border-left: 3px solid #27ae60;
}

/* Terminated Employment */
.student-compact.employment-terminated {
    background: linear-gradient(135deg, #fff5f5 0%, #ffe8e8 100%);
    border-left: 3px solid #e74c3c;
    border: 1px solid #f8d7da;
}

.employment-status-badge i {
    margin-right: 4px;
    font-size: 11px;
}

@keyframes terminated-pulse {
    0%, 100% {
        box-shadow: 0 2px 4px rgba(231, 76, 60, 0.3);
    }
    50% {
        box-shadow: 0 4px 8px rgba(231, 76, 60, 0.5);
    }
}

.student-register-date-label {
    margin-right: 4px;
    font-weight: 500;
}

.student-register-date {
    font-weight: 600;
}

.student-register-date-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.student-register-date-compact {
    display: flex;
    align-items: center;
    font-size: 11px;
    flex: 1;
    min-width: 120px;
}

.student-register-date-compact i {
    margin-right: 4px;
    width: 12px;
}

/* Active employment icons */
.student-register-date-active .student-register-date-compact i {
    color: #27ae60;
}


@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notes-section {
    margin: 10px 0;
    padding: 8px 10px;
    background: #f8f9fa;
    border-radius: 4px;
    border-left: 3px solid #3598dc;
}

.note-content {
    padding-top: 5px;
}

.note-timestamp {
    font-size: 11px;
    color: #666;
    margin-bottom: 5px;
}

.note-text {
    margin-bottom: 8px;
}

.note-empty, .note-restricted {
    padding: 5px 0;
    color: #999;
}

/* Compact CRM Tab Styles */
.tab-pane {
    padding: 10px 0;
    font-size: 12px;
}

.status-dashboard {
    background: #f8f9fa;
    border: 1px solid #e7ecf1;
    border-radius: 4px;
    padding: 10px;
    margin-bottom: 15px;
}

.status-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding: 5px 0;
    border-bottom: 1px solid #eee;
}

.status-row:last-child {
    margin-bottom: 0;
    border-bottom: none;
}

.status-label-inline {
    font-weight: 600;
    color: #555;
    font-size: 11px;
    min-width: 120px;
}

.status-pills {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.status-pill {
    background: #f1f3f4;
    border: 1px solid #e1e5e9;
    border-radius: 10px;
    padding: 3px 8px;
    font-size: 10px;
    color: #666;
    white-space: nowrap;
}

.status-pill.urgent {
    background: #fff5f5;
    border-color: #fed7d7;
    color: #e53e3e;
}

.status-pill.success {
    background: #f0fff4;
    border-color: #9ae6b4;
    color: #38a169;
}

.progress-mini {
    height: 4px;
    background: #e7ecf1;
    border-radius: 2px;
    margin: 8px 0;
    overflow: hidden;
}

.progress-bar-mini {
    height: 100%;
    background: #3598dc;
    transition: width 0.3s ease;
}

.action-bar {
    background: #fff;
    border: 1px solid #e7ecf1;
    border-radius: 4px;
    padding: 8px;
    margin-bottom: 15px;
}

.action-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-xs-compact {
    padding: 3px 8px;
    font-size: 10px;
    line-height: 1.2;
    border-radius: 2px;
}

@media (max-width: 1920px) {
    .btn-xs-compact {
        padding: 3px 5px;
        font-size: 8px;
        line-height: 1.2;
        border-radius: 2px;
    }

    .contact-tips {
        line-height: 20px !important;
    }
}

.reminder-inline {
    background: #f8f9fa;
    border: 1px solid #e7ecf1;
    border-radius: 4px;
    padding: 8px;
}

.reminder-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.reminder-row:last-child {
    margin-bottom: 0;
}

.reminder-label {
    font-size: 10px;
    color: #666;
    min-width: 60px;
    font-weight: 600;
}

.form-control-xs {
    height: 24px;
    padding: 2px 6px;
    font-size: 10px;
    border-radius: 2px;
}

.toggle-mini {
    width: 32px;
    height: 16px;
    background: #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: inline-block;
}

.toggle-mini.active {
    background: #32c5d2;
}

.toggle-mini:before {
    content: '';
    position: absolute;
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.toggle-mini.active:before {
    transform: translateX(16px);
}

/* Custom styling for editable elements */
.editable-click {
    border-bottom: 1px dashed #3598dc;
    cursor: pointer;
}

.editable-click:hover {
    background-color: #f0f8ff;
}

/* Site Registration Indicator Banner */
.sreg-banner-wrapper {
    position: relative;
    margin: -12px -15px 15px -15px;
    overflow: hidden;
}

.sreg-warning-banner {
    background: linear-gradient(135deg, #fff9e6 0%, #ffeaa7 100%);
    border-left: 4px solid #f39c12;
    border-bottom: 1px solid #f8d49d;
    padding: 8px 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #856404;
    font-weight: 600;
    animation: sreg-subtle-pulse 2s ease-in-out infinite;
    box-shadow: 0 2px 4px rgba(243, 156, 18, 0.1);
}

.sreg-warning-banner i {
    font-size: 14px;
    color: #f39c12;
    animation: sreg-icon-rotate 3s ease-in-out infinite;
}

.sreg-warning-banner span {
    flex: 1;
    letter-spacing: 0.3px;
}

/* Subtle animations */
@keyframes sreg-subtle-pulse {
    0%, 100% {
        background: linear-gradient(135deg, #fff9e6 0%, #ffeaa7 100%);
    }
    50% {
        background: linear-gradient(135deg, #fffbf0 0%, #fff3c4 100%);
    }
}

@keyframes sreg-icon-rotate {
    0%, 100% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(-10deg);
    }
    75% {
        transform: rotate(10deg);
    }
}

/* Hover effect for interactive feel */
.sreg-warning-banner:hover {
    background: linear-gradient(135deg, #fffbf0 0%, #fff3c4 100%);
    border-left-width: 6px;
    transition: all 0.3s ease;
}

/* Compact version for table list view (index-1.php) */
.table .sreg-warning-banner {
    margin-top: 5px;
    padding: 5px 10px;
    font-size: 11px;
    border-radius: 3px;
}

.table .sreg-warning-banner i {
    font-size: 12px;
}

/* Compact version for smaller screens */
@media (max-width: 768px) {
    .sreg-warning-banner {
        font-size: 11px;
        padding: 6px 12px;
    }
    
    .sreg-warning-banner i {
        font-size: 12px;
    }

    .status-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .action-group {
        flex-wrap: wrap;
    }

    .reminder-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}