﻿:root {
    --bg-dark: #070913;
    --card-glass: rgba(18, 25, 43, 0.78);
    --border-glass: rgba(0, 242, 254, 0.18);
    --neon-cyan: #00f2fe;
    --neon-purple: #8a2be2;
    --text-main: #f1f5f9;
    --text-muted: #94a3b8;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    margin: 0;
    padding: 0 0 95px 0;
    font-family: 'Poppins', sans-serif;
    background: var(--bg-dark);
    background-image: radial-gradient(circle at 10% 15%, rgba(0, 242, 254, 0.12) 0%, transparent 40%), radial-gradient(circle at 90% 80%, rgba(138, 43, 226, 0.15) 0%, transparent 40%);
    color: var(--text-main);
    overflow-x: hidden;
}

/* 2-Second Futuristic Noorify Splash Loader */
#noorify-loader {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: radial-gradient(circle at center, #111827 0%, #05070e 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.55s ease, visibility 0.55s ease;
}

    #noorify-loader.loader-hidden {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }

.loader-badge-wrap {
    position: relative;
    width: 155px;
    height: 155px;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .loader-badge-wrap::before {
        content: '';
        position: absolute;
        inset: -10px;
        border-radius: 50%;
        border: 2px solid transparent;
        border-top-color: var(--neon-cyan);
        border-bottom-color: var(--neon-purple);
        animation: spinRing 1.4s linear infinite;
        box-shadow: 0 0 25px rgba(0, 242, 254, 0.25);
    }

.loader-badge-img {
    width: 125px;
    height: 125px;
    object-fit: contain;
    filter: drop-shadow(0 0 18px rgba(0, 242, 254, 0.45));
    animation: pulseBadge 1.8s ease-in-out infinite;
}

.loader-bar-track {
    width: 150px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    margin-top: 26px;
    overflow: hidden;
}

.loader-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    animation: fillProgress 2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes spinRing {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulseBadge {
    0%, 100% {
        transform: scale(0.96);
    }

    50% {
        transform: scale(1.04);
    }
}

@keyframes fillProgress {
    0% {
        width: 0%;
    }

    100% {
        width: 100%;
    }
}

/* Sticky Header with Noorify Logo */
.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(7, 9, 19, 0.88);
    backdrop-filter: blur(16px);
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo-wrap {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.header-logo-img {
    height: 34px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 8px rgba(0, 242, 254, 0.3));
}

.header-nav-group {
    display: flex;
    gap: 6px;
}

.header-switch {
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--neon-cyan);
    padding: 8px 14px;
    border-radius: 20px;
    border: 1px solid rgba(0, 242, 254, 0.4);
    background: rgba(0, 242, 254, 0.08);
    white-space: nowrap;
}

.container {
    padding: 16px;
    max-width: 520px;
    margin: 0 auto;
}

/* Search & Multi-Filter Deck */
.search-filter-card {
    background: rgba(18, 25, 43, 0.82);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-glass);
    border-radius: 18px;
    padding: 15px;
    margin-bottom: 22px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
}

.search-row {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 7px;
    margin-bottom: 12px;
}

.filter-sub-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 10px;
}

.btn-search {
    padding: 0 15px;
    border: 1px solid var(--neon-cyan);
    background: linear-gradient(135deg, rgba(0, 242, 254, 0.22), rgba(138, 43, 226, 0.3));
    color: #fff;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
}

.btn-clear {
    padding: 0 11px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.78rem;
    cursor: pointer;
}

/* Active Member Workload Summary Table Section */
.summary-matrix-card {
    background: rgba(15, 22, 39, 0.85);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(0, 242, 254, 0.22);
    border-radius: 18px;
    padding: 14px;
    margin-bottom: 35px;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.42);
}

.matrix-title {
    font-size: 0.76rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--neon-cyan);
    margin: 0 0 10px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.workload-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.78rem;
    overflow: hidden;
    border-radius: 12px;
}

    .workload-table th {
        background: rgba(0, 242, 254, 0.12);
        color: #e2e8f0;
        font-weight: 600;
        padding: 8px 6px;
        text-align: center;
        border-bottom: 1px solid rgba(0, 242, 254, 0.25);
        font-size: 0.72rem;
        line-height: 1.25;
    }

        .workload-table th:first-child {
            text-align: left;
            padding-left: 10px;
        }

    .workload-table td {
        padding: 8px 6px;
        text-align: center;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        color: #f8fafc;
        font-weight: 600;
    }

    .workload-table tr:last-child td {
        border-bottom: none;
    }

    .workload-table td:first-child {
        text-align: left;
        padding-left: 10px;
        color: #cbd5e1;
        font-weight: 500;
    }

.count-pill {
    display: inline-block;
    min-width: 24px;
    padding: 2px 7px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
}

.pill-nys {
    background: rgba(148, 163, 184, 0.18);
    color: #e2e8f0;
    border: 1px solid rgba(148, 163, 184, 0.35);
}

.pill-wip {
    background: rgba(14, 165, 233, 0.22);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.45);
}

.pill-hold {
    background: rgba(245, 158, 11, 0.22);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.45);
}

.section-heading {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0 0 14px 0;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--neon-cyan);
}

.form-label {
    display: block;
    font-size: 0.73rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.futuristic-input {
    width: 100%;
    padding: 11px 12px;
    background: rgba(9, 13, 24, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 12px;
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 0.86rem;
    transition: all 0.25s ease;
}

    .futuristic-input:focus {
        outline: none;
        border-color: var(--neon-cyan);
        box-shadow: 0 0 12px rgba(0, 242, 254, 0.25);
    }

/* Task Card Base + 5 Conditional Color Themes */
.task-card {
    border-radius: 18px;
    padding: 16px;
    margin-bottom: 70px;
    backdrop-filter: blur(12px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
}

.bg-light-red {
    background: linear-gradient(145deg, rgba(239, 68, 68, 0.25), rgba(153, 27, 27, 0.18));
    border: 1px solid rgba(248, 113, 113, 0.55);
    border-left: 5px solid #ef4444;
}

.bg-light-amber {
    background: linear-gradient(145deg, rgba(245, 158, 11, 0.25), rgba(180, 83, 9, 0.18));
    border: 1px solid rgba(251, 191, 36, 0.55);
    border-left: 5px solid #f59e0b;
}

.bg-light-green {
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.24), rgba(6, 95, 70, 0.18));
    border: 1px solid rgba(52, 211, 153, 0.55);
    border-left: 5px solid #10b981;
}

.bg-light-blue {
    background: linear-gradient(145deg, rgba(14, 165, 233, 0.25), rgba(3, 105, 161, 0.18));
    border: 1px solid rgba(56, 189, 248, 0.55);
    border-left: 5px solid #0ea5e9;
}

.bg-light-neutral {
    background: rgba(20, 28, 48, 0.78);
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-left: 5px solid #64748b;
}

.task-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 10px;
}

.task-title {
    font-size: 1.02rem;
    font-weight: 600;
    color: #fff;
    margin: 0;
    flex: 1;
    line-height: 1.4;
}

.task-id-badge {
    display: inline-block;
    background: rgba(0, 242, 254, 0.16);
    border: 1px solid rgba(0, 242, 254, 0.45);
    color: var(--neon-cyan);
    font-size: 0.76rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 8px;
    margin-right: 7px;
    vertical-align: middle;
}

.header-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.badge-status {
    font-size: 0.68rem;
    font-weight: 600;
    padding: 4px 9px;
    border-radius: 20px;
    white-space: nowrap;
    background: rgba(0, 0, 0, 0.45);
    color: #e2e8f0;
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.badge-priority {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 20px;
    white-space: nowrap;
}

.prio-Critical {
    background: rgba(239, 68, 68, 0.28);
    color: #fca5a5;
    border: 1px solid #ef4444;
}

.prio-High {
    background: rgba(249, 115, 22, 0.28);
    color: #fdba74;
    border: 1px solid #f97316;
}

.prio-Medium {
    background: rgba(59, 130, 246, 0.28);
    color: #93c5fd;
    border: 1px solid #3b82f6;
}

.prio-Low {
    background: rgba(16, 185, 129, 0.28);
    color: #6ee7b7;
    border: 1px solid #10b981;
}

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.meta-chip {
    background: rgba(0, 0, 0, 0.32);
    padding: 4px 10px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #e2e8f0;
}

.meta-chip-eta {
    background: rgba(0, 242, 254, 0.14);
    border: 1px solid rgba(0, 242, 254, 0.35);
    color: #e0f2fe;
    font-weight: 600;
}

/* Structured Comment History with Thin <hr> */
.comment-history {
    background: rgba(5, 8, 17, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 11px 13px;
    font-size: 0.82rem;
    color: #cbd5e1;
    max-height: 165px;
    overflow-y: auto;
    margin-bottom: 12px;
    line-height: 1.5;
}

.comment-entry {
    margin: 0;
}

.comment-meta-line {
    color: #38bdf8;
    font-weight: 600;
    font-size: 0.76rem;
}

.comment-status-line {
    color: #c084fc;
    font-weight: 600;
    font-size: 0.76rem;
    margin-bottom: 3px;
}

.comment-body-line {
    color: #f1f5f9;
    font-size: 0.82rem;
}

.comment-hr {
    border: 0;
    border-top: 1px solid rgba(0, 242, 254, 0.22);
    margin: 10px 0;
}

/* Quick Update Grid + Original vs New ETA Calendar Picker */
.quick-update-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px dashed rgba(255, 255, 255, 0.18);
}

.update-here-title {
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--neon-cyan);
    margin-bottom: -2px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.eta-update-box {
    display: grid;
    grid-template-columns: 1fr 1.25fr;
    gap: 10px;
    background: rgba(7, 10, 20, 0.65);
    border: 1px solid rgba(0, 242, 254, 0.22);
    border-radius: 12px;
    padding: 10px;
    align-items: center;
}

.orig-eta-box {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.orig-eta-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--text-muted);
}

.orig-eta-val {
    font-size: 0.84rem;
    font-weight: 600;
    color: #cbd5e1;
    background: rgba(255, 255, 255, 0.05);
    padding: 9px 10px;
    border-radius: 9px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    text-align: center;
}

.new-eta-box {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.new-eta-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--neon-cyan);
    font-weight: 600;
}

.calendar-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.new-eta-input {
    padding: 9px 34px 9px 11px !important;
    font-size: 0.84rem !important;
    font-weight: 600;
    border-color: rgba(0, 242, 254, 0.5) !important;
    cursor: pointer;
    background: rgba(9, 13, 24, 0.95) !important;
}

    .new-eta-input.input-invalid {
        border-color: #ef4444 !important;
        box-shadow: 0 0 14px rgba(239, 68, 68, 0.45) !important;
    }

.calendar-trigger-icon {
    position: absolute;
    right: 11px;
    color: var(--neon-cyan);
    font-size: 0.95rem;
    pointer-events: none;
}

/* Floating Tooltip Bubble directly above New ETA selection */
.eta-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    right: 0;
    width: 240px;
    background: linear-gradient(135deg, #dc2626, #991b1b);
    color: #fff;
    font-size: 0.73rem;
    font-weight: 500;
    line-height: 1.35;
    padding: 9px 11px;
    border-radius: 10px;
    border: 1px solid #fca5a5;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.65);
    z-index: 500;
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: all 0.22s ease;
    pointer-events: none;
}

    .eta-tooltip::after {
        content: '';
        position: absolute;
        top: 100%;
        right: 28px;
        border-width: 6px;
        border-style: solid;
        border-color: #991b1b transparent transparent transparent;
    }

    .eta-tooltip.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

/* Centered Middle-of-Screen Glassmorphic Popup Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 99990;
    background: rgba(4, 7, 15, 0.78);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

    .modal-overlay.active {
        opacity: 1;
        visibility: visible;
    }

.modal-box {
    width: 100%;
    max-width: 350px;
    background: linear-gradient(155deg, rgba(18, 26, 46, 0.96), rgba(10, 14, 26, 0.98));
    border: 1px solid rgba(248, 113, 113, 0.55);
    border-radius: 22px;
    padding: 22px 20px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.75), 0 0 25px rgba(239, 68, 68, 0.25);
    transform: scale(0.9);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-box {
    transform: scale(1);
}

.modal-box.modal-success {
    border-color: rgba(16, 185, 129, 0.6);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.75), 0 0 25px rgba(16, 185, 129, 0.25);
}

.modal-icon {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    margin: 0 auto 12px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: rgba(239, 68, 68, 0.18);
    color: #f87171;
    border: 1px solid rgba(248, 113, 113, 0.45);
}

.modal-box.modal-success .modal-icon {
    background: rgba(16, 185, 129, 0.18);
    color: #34d399;
    border-color: rgba(52, 211, 153, 0.45);
}

.modal-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 8px 0;
}

.modal-text {
    font-size: 0.84rem;
    color: #cbd5e1;
    line-height: 1.5;
    margin: 0 0 18px 0;
}

.modal-btn {
    width: 100%;
    padding: 11px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #ef4444, #b91c1c);
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.35);
}

.modal-box.modal-success .modal-btn {
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

.btn-update-sm {
    width: 100%;
    padding: 11px;
    border: 1px solid var(--neon-cyan);
    background: rgba(0, 242, 254, 0.18);
    color: #fff;
    border-radius: 10px;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: 0.2s;
}

    .btn-update-sm:active {
        background: var(--neon-cyan);
        color: #000;
    }

/* Send WhatsApp Section */
.wa-bar-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    color: #4ade80;
    font-weight: 600;
    margin-top: 4px;
    display: block;
}

.wa-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.btn-wa-direct {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 12px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid #25D366;
    color: #4ade80;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s ease;
}

    .btn-wa-direct:active {
        transform: scale(0.95);
        background: #25D366;
        color: #070913;
    }

.btn-wa-group {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 12px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #e2e8f0;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 500;
    text-decoration: none;
}

.empty-state {
    text-align: center;
    padding: 30px 16px;
    background: rgba(15, 22, 38, 0.6);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* 3-Tab Bottom Mobile Navigation Dock */
.bottom-dock {
    position: fixed;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 24px);
    max-width: 480px;
    background: rgba(13, 18, 32, 0.94);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 242, 254, 0.25);
    border-radius: 24px;
    padding: 7px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
    z-index: 999;
}

.dock-link {
    text-decoration: none;
    text-align: center;
    padding: 10px 4px;
    border-radius: 18px;
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: 0.25s;
    white-space: nowrap;
}

    .dock-link.active {
        background: linear-gradient(135deg, rgba(0, 242, 254, 0.22), rgba(138, 43, 226, 0.32));
        color: #fff;
        border: 1px solid rgba(0, 242, 254, 0.45);
        box-shadow: 0 0 15px rgba(0, 242, 254, 0.25);
    }


/* Toggle Tab Buttons Row */
.matrix-toggle-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
}

.btn-matrix-tab {
    padding: 9px 10px;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.76rem;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(9, 13, 24, 0.75);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.22s ease;
}

    .btn-matrix-tab.active {
        background: linear-gradient(135deg, rgba(0, 242, 254, 0.22), rgba(138, 43, 226, 0.32));
        border-color: var(--neon-cyan);
        color: #fff;
        box-shadow: 0 0 12px rgba(0, 242, 254, 0.25);
    }

    .btn-matrix-tab.active-missed {
        background: linear-gradient(135deg, rgba(239, 68, 68, 0.28), rgba(153, 27, 27, 0.35));
        border-color: #ef4444;
        color: #fca5a5;
        box-shadow: 0 0 12px rgba(239, 68, 68, 0.25);
    }

.pill-missed {
    background: rgba(239, 68, 68, 0.24);
    color: #fca5a5;
    border: 1px solid rgba(248, 113, 113, 0.5);
    white-space: nowrap;
}

.missed-empty-cell {
    text-align: center !important;
    color: var(--text-muted) !important;
    padding: 14px 8px !important;
    font-weight: 400 !important;
}