﻿/* =========================================
           MODAL STYLES
        ========================================== */
.modal {
    z-index: 1090;
    --bs-modal-margin: -3.25rem;
    --bs-modal-box-shadow: 0 0.25rem 0.75rem 0 rgba(34, 48, 62, 0.14);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 0px;
    border: 1px solid #888;
}

/* Duplicate Message */
#duplicateMsg {
    display: none;
    align-items: center;
    gap: .5rem;
    padding: .5rem .75rem;
    border: 1px solid rgba(220,53,69,.35);
    background: rgba(220,53,69,.08);
    border-radius: .5rem;
    line-height: 1.25;
}

#duplicateMsgtext {
    color: #dc3545;
    font-weight: 700;
    margin-right: .25rem;
    white-space: nowrap;
}

#detailDuplicate {
    color: #0d6efd;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
}

    #detailDuplicate:hover,
    #detailDuplicate:focus {
        text-decoration: underline;
        outline: none;
    }

:root[data-bs-theme="dark"] #duplicateMsg,
.dark #duplicateMsg {
    border-color: rgba(220,53,69,.4);
    background: rgba(220,53,69,.15);
}
/* ===============================
   MODAL RESPONSIVE (MOBILE)
   =============================== */
@media (max-width: 768px)   {

    .modal-attendance .modal-content {
        width: 80% !important;
        margin: 0.5rem;
    }
}

/* =========================================
           CARD & LAYOUT STYLES
        ========================================== */
.modern-card {
    border-radius: 24px;
    border: none;
}

.equal-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

    .equal-card .card-body {
        flex: 1 1 auto;
    }

.row.row-bordered > div:first-child {
    border-right: 1px solid rgba(226, 232, 240, 0.8);
}

.card-section-title {
    font-size: 1rem;
    font-weight: 600;
    color: black;
}

.progress-card {
    border-radius: 20px;
    border: none;
}

.progress-label {
    font-size: 12px;
    color: #9ca3af;
}

.progress-hours {
    font-size: 26px;
    font-weight: 600;
    line-height: 1;
    margin-top: 2px;
}

.progress-subtitle {
    font-size: 16px;
    color: black;
    margin-top: 3px;
}

.info-title {
    font-size: 15px;
    font-weight: 600;
    color: #4b4b4b;
}

.info-percent {
    font-size: 28px;
    font-weight: 700;
    color: #7367F0;
    margin-top: 3px;
}

.info-detail {
    font-size: 13px;
    color: #777;
    margin-top: -2px;
}

/* =========================================
           EMPLOYEE INFO STYLES
        ========================================== */
.employee-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 5px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px dashed rgba(0, 0, 0, 0.06);
}

    .info-row:last-child {
        border-bottom: none;
    }

    .info-row:hover {
        background-color: rgba(115, 103, 240, 0.04);
        border-radius: 6px;
        padding-left: 6px;
        transition: 0.2s ease;
    }

.info-label {
    display: flex;
    align-items: center;
    font-size: 13px;
    color: #4a5568;
    font-weight: 500;
    gap: 8px;
    width: 140px;
}

    .info-label i {
        font-size: 16px;
        opacity: .8;
    }

.info-value {
    font-size: 13px;
    font-weight: 500;
    color: #2d3748;
    text-align: left;
    flex: 1;
}

.info-badge {
    padding: 4px 10px;
    font-size: 11px;
    border-radius: 8px;
    font-weight: 600;
    display: inline-block;
}

.badge-dept {
    background: rgba(115, 103, 240, 0.12);
    color: #7367F0;
}

.badge-status {
    background: rgba(40, 199, 111, 0.15);
    color: #28C76F;
}

/* =========================================
           PROFILE HERO CARD STYLES
        ========================================== */
.profile-hero-card {
    max-height: 205px;
    aspect-ratio: 1 / 1.2;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    background: #ddd;
}

.profile-hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.profile-hero-gradient {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 45%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.75) 100%);
}

.profile-hero-footer {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #ffffff;
    z-index: 2;
}

.profile-hero-name {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 2px;
}

.profile-hero-job {
    font-size: 12px;
    opacity: 0.85;
}

/* =========================================
           ATTENDANCE COMPACT PILLS STYLES
        ========================================== */
.att-horizontal-wrapper {
    display: flex;
    gap: 4px;
    justify-content: space-between;
    width: 100%;
}

.att-pill {
    flex: 1;
    padding: 0.85rem 1rem;
    border-radius: 20px;
    height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    position: relative;
    cursor: pointer;
    transition: all .25s ease;
    color: #fff;
}

    .att-pill:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 24px rgba(0, 0, 0, 0.20);
    }

.att-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

.att-label {
    font-size: 0.82rem;
    font-weight: 600;
    margin-top: 4px;
}

.att-value {
    font-size: 0.75rem;
    opacity: .92;
}

.att-percent {
    position: absolute;
    bottom: 10px;
    right: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    opacity: .9;
}

/* Attendance Pill Types */
.att-accept {
    background: linear-gradient(135deg, #4e54c8, #8f94fb);
}

.att-leave {
    background: linear-gradient(135deg, #00c853, #1de9b6);
}

.att-absent {
    background: linear-gradient(135deg, #ff416c, #ff4b2b);
}

.att-abnormal {
    background: linear-gradient(135deg, #c471ed, #f64f59);
}

.att-delay {
    background: linear-gradient(135deg, #ffa726, #ffcc80);
}

/* Attendance Pills Responsive */
@media (max-width: 768px) {
    .att-horizontal-wrapper {
        flex-wrap: wrap;
        gap: 10px 12px;
    }

    .att-pill {
        flex: 0 0 calc(50% - 6px);
        height: 105px;
        padding: 0.75rem 0.8rem;
    }
}

@media (max-width: 480px) {
    .att-pill {
        height: 100px;
        padding: 0.7rem 0.75rem;
    }

    .att-icon {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }

    .att-label {
        font-size: 0.75rem;
    }

    .att-value {
        font-size: 0.7rem;
    }

    .att-percent {
        font-size: 0.72rem;
    }
}

/* =========================================
           WORK HOUR DETAIL CARD STYLES
        ========================================== */
.cardmounlyhourdetail {
    border-radius: 22px;
    padding: 24px 24px 20px;
    background: linear-gradient(135deg, #eef3ff 0%, #dde8ff 100%);
    border: none;
    position: relative;
}

    .cardmounlyhourdetail .info-title {
        font-size: 1rem;
        font-weight: 700;
        color: #1f2b54;
        margin-bottom: 2px;
    }

    .cardmounlyhourdetail .info-detail {
        font-size: 0.85rem;
        color: #6073a8;
        margin-bottom: 14px;
        display: block;
    }

.wh-info-line {
    display: flex;
    justify-content: space-between;
    padding: 6px 0 6px;
    font-size: 0.87rem;
    border-bottom: 1px dashed rgba(80, 96, 150, 0.20);
}

    .wh-info-line:last-child {
        border-bottom: none;
    }

.wh-label {
    color: #52639a;
    font-weight: 500;
}

.wh-value {
    font-weight: 700;
    color: #1f2b54;
}

.cardmounlyhourdetail::before {
    content: "";
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 24px;
    background: radial-gradient(circle at top left, rgba(255,255,255,0.6), transparent 60%);
    z-index: -1;
}

/* =========================================
           TABLE STYLES
        ========================================== */
.table-scroll,
.table-scroll2 {
    height: 240px;
    overflow-y: auto;
    position: relative;
    border-radius: 18px;
    box-shadow: 0 4px 12px rgba(148, 163, 184, 0.12);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

    .table-scroll .table-custom thead th {
        position: sticky;
        top: 0;
        z-index: 2;
        background: #4cd137;
        color: white;
        padding-block: 0.8rem !important;
        font-size: 12px;
    }

    .table-scroll2 .table-custom thead th {
        position: sticky;
        top: 0;
        z-index: 2;
        background: #9980FA;
        color: white;
        padding-block: 0.8rem !important;
        font-size: 12px;
    }

.table-custom thead tr th {
    border: 0;
    padding-top: 0.3rem;
    padding-bottom: 0.55rem;
    font-size: 11px;
    font-weight: 600;
    text-transform: capitalize;
    letter-spacing: 0.06em;
    color: #1f2933;
    border-bottom: 1px solid rgba(226, 232, 240, 1);
}

.table-custom tbody tr {
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    padding: 2px 6px;
    transition: background 0.2s ease, transform 0.15s ease;
}

    .table-custom tbody tr:last-child {
        border-bottom: none;
    }

    .table-custom tbody tr:hover {
        background: rgba(115, 103, 240, 0.06);
        transform: translateY(-1px);
    }

.table-custom {
    font-size: 11px;
    color: #4b4b61;
    cursor: pointer;
}

    .table-custom i.fa-briefcase {
        color: #7367F0;
    }

/* Scrollbar Styles */
.table-scroll::-webkit-scrollbar {
    height: 6px;
    width: 6px;
    display: none;
}

.table-scroll::-webkit-scrollbar-track {
    background: #eef0ff;
    border-radius: 999px;
}

.table-scroll::-webkit-scrollbar-thumb {
    background: #c9cdfa;
    border-radius: 999px;
}

    .table-scroll::-webkit-scrollbar-thumb:hover {
        background: #a7adff;
    }

/* =========================================
           CALENDAR STYLES
        ========================================== */
.apola-calendar-wrapper {
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #efefef;
}

.calendar-header {
    background: linear-gradient(90deg, #fafbff 0%, #ffffff 100%);
    border-bottom: 1px solid #eceef5;
}

    .calendar-header h6 {
        font-size: 0.95rem;
        color: #2f3349;
    }

/* FullCalendar Base Styles */
.apola-calendar .fc {
    font-family: "Plus Jakarta Sans", system-ui, sans-serif;
}

.apola-calendar .fc-toolbar.fc-header-toolbar {
    padding: 0.55rem 0.9rem;
    border-bottom: 1px solid #edf0f7;
}

.apola-calendar .fc-toolbar-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2f3349;
}

.apola-calendar .fc-button {
    border-radius: 14px;
    border: none;
    background-color: #f4f5fb;
    color: #4b4f68;
    padding: 0.2rem 0.8rem;
    font-size: 0.7rem;
    transition: all 0.2s ease;
}

.apola-calendar .fc-button-primary:not(:disabled):hover {
    background-color: #6366f1;
    color: #fff;
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.25);
}

.apola-calendar .fc-col-header-cell {
    padding: 0.35rem 0;
    background-color: transparent;
    color: #a1a5c1;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.apola-calendar .fc-daygrid-day {
    height: 3.1rem;
}

.apola-calendar .fc-daygrid-day-number {
    font-size: 0.75rem;
    font-weight: 500;
    color: #9a9fbf;
}

.apola-calendar .fc-day-today {
    background: #F8EFBA !important;
    border-radius: 8px;
}

    .apola-calendar .fc-day-today .fc-daygrid-day-number {
        color: #3b82f6;
        font-weight: 700;
    }

.apola-calendar .fc-day-weekend {
    background-color: #fdecef;
    border-radius: 10px;
}

html.dark-style .apola-calendar .fc-day-weekend,
html[data-theme="dark"] .apola-calendar .fc-day-weekend {
    background-color: #30334E;
}

html.dark-style .fc-toolbar-title,
html[data-theme="dark"] .fc-toolbar-title {
    color: #ffffff;
}

.apola-calendar .fc-daygrid-event {
    margin-top: 0.2rem;
    border-radius: 8px;
    font-size: 0.68rem;
    padding: 0.25rem 0.1rem;
    border: none;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.10);
    line-height: 1.1;
}

.apola-calendar .fc-event-title {
    font-weight: 600;
    font-size: 0.68rem;
    margin-bottom: 2px;
    color: #fff;
}

.apola-calendar .fc-event-worktime {
    font-size: 0.5rem;
    font-weight: 500;
    opacity: 0.95;
    color: #f8f8f8;
}

.apola-calendar .fc-event-ns07 {
    background: linear-gradient(135deg, #3b82f6, #60a5fa) !important;
    color: #fff !important;
    border: none !important;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.25);
}

.apola-calendar .fc-event-off {
    background: linear-gradient(135deg, #f87171, #ef4444) !important;
    color: #fff !important;
    border: none !important;
    padding: 2px 4px;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.25);
}

.apola-calendar .fc-theme-standard td,
.apola-calendar .fc-theme-standard th {
    border-color: #e5e7eb !important;
}

.apola-calendar .fc-daygrid-day:hover,
.apola-calendar .fc-day-weekend:hover {
    background: #f3f6fb;
    cursor: pointer;
}

.fc-theme-standard td,
.fc-theme-standard th {
    border: none;
}

.fc .fc-scrollgrid {
    border: none;
}

.apola-calendar .fc-toolbar.fc-header-toolbar {
    padding: 0.55rem 0.9rem;
    border-bottom: none;
}

.fc .fc-toolbar.fc-header-toolbar {
    margin-bottom: 0em;
}

.fc-col-header {
    background-color: transparent !important;
}

/* =========================================
           RESPONSIVE STYLES
        ========================================== */
@media (max-width: 767.98px) {
    .info-label {
        width: 140px;
    }

    .profile-hero-card {
        margin: 0 auto;
    }
}
