/* ============================================
   Signature Request Detail Page Styling
   ============================================ */

/* Progress Container */
.progress-container {
    padding: 1rem 0;
}

.progress-bar-large {
    height: 30px;
    background: #e9ecef;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #0d6efd, #0b5ed7);
    transition: width 0.5s ease;
    border-radius: 15px;
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    font-size: 1.1rem;
}

.stat-item strong {
    color: #0d6efd;
}

/* Signers List */
.signers-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.signer-card {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    background: white;
    transition: all 0.2s ease;
}

.signer-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.signer-card.signer-signed {
    border-color: #198754;
    background: rgba(25, 135, 84, 0.05);
}

.signer-card.signer-declined {
    border-color: #dc3545;
    background: rgba(220, 53, 69, 0.05);
}

.signer-card.signer-viewed {
    border-color: #0dcaf0;
    background: rgba(13, 202, 240, 0.05);
}

.signer-card.signer-pending {
    border-color: #ffc107;
    background: rgba(255, 193, 7, 0.05);
}

.signer-order {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #0d6efd;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.5rem;
    margin-right: 1.5rem;
    flex-shrink: 0;
}

.signer-info {
    flex: 1;
}

.signer-info h6 {
    margin: 0 0 0.25rem 0;
    font-size: 1.1rem;
}

.signer-status {
    text-align: center;
    margin: 0 1rem;
}

.status-icon {
    margin-bottom: 0.5rem;
}

.status-icon.status-signed {
    color: #198754;
}

.status-icon.status-declined {
    color: #dc3545;
}

.status-icon.status-viewed {
    color: #0dcaf0;
}

.status-icon.status-pending {
    color: #ffc107;
}

.signer-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

/* Documents List */
.documents-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.document-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #f8f9fa;
    transition: all 0.2s ease;
}

.document-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.document-icon {
    margin-right: 1rem;
}

.document-info {
    flex: 1;
}

.document-info h6 {
    margin: 0 0 0.25rem 0;
}

.document-actions {
    display: flex;
    gap: 0.5rem;
}

/* Activity Timeline */
.activity-timeline {
    position: relative;
    padding-left: 3rem;
}

.activity-timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 10px;
    bottom: 10px;
    width: 2px;
    background: #dee2e6;
}

.activity-item {
    position: relative;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.activity-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.activity-icon {
    position: absolute;
    left: -2.8rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    z-index: 1;
}

.activity-icon.activity-created {
    background: #0d6efd;
}

.activity-icon.activity-sent {
    background: #6c757d;
}

.activity-icon.activity-signed {
    background: #198754;
}

.activity-icon.activity-declined {
    background: #dc3545;
}

.activity-icon.activity-viewed {
    background: #0dcaf0;
}

.activity-icon.activity-cancelled {
    background: #6c757d;
}

.activity-icon.activity-default {
    background: #adb5bd;
}

.activity-content h6 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    font-weight: 600;
}

.activity-content p {
    margin: 0;
    color: #6c757d;
}

/* Details Card */
.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-row strong {
    color: #495057;
    font-weight: 600;
}

.detail-row span {
    text-align: right;
}

/* Sticky Sidebar */
.sticky-top {
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
}

/* Responsive */
@media (max-width: 992px) {
    .sticky-top {
        position: relative !important;
        top: 0 !important;
    }

    .signer-card {
        flex-wrap: wrap;
        padding: 1rem;
    }

    .signer-order {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .signer-status {
        margin: 1rem 0;
        width: 100%;
    }

    .signer-actions {
        width: 100%;
        flex-direction: row;
        justify-content: flex-end;
    }

    .document-item {
        flex-wrap: wrap;
    }

    .document-actions {
        width: 100%;
        margin-top: 1rem;
    }

    .activity-timeline {
        padding-left: 2.5rem;
    }

    .activity-icon {
        left: -2.3rem;
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.signer-card,
.document-item,
.activity-item {
    animation: fadeIn 0.3s ease;
}

/* Modal Overlay */
.modal-backdrop.show {
    opacity: 0.5;
}

.modal.show {
    display: flex !important;
    align-items: center;
    justify-content: center;
}
