/**
 * MoveMaster Signing Page Styles
 */

.movemaster-signing-container {
    max-width: 700px;
    margin: 40px auto;
    padding: 30px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.movemaster-signing-error-container {
    text-align: center;
    padding: 60px 30px;
}

.signing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.signing-header h2 {
    margin: 0;
    color: #1d2327;
    font-size: 1.5em;
}

.signing-timer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.signing-timer .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

.signing-timer.timer-warning {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.signing-timer.timer-expired {
    background: #d63638;
}

.contract-summary {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.contract-summary h3 {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    color: #1d2327;
}

.summary-table {
    width: 100%;
    border-collapse: collapse;
}

.summary-table th,
.summary-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.summary-table th {
    width: 40%;
    color: #666;
    font-weight: 500;
}

.summary-table td {
    color: #1d2327;
}

.signing-form h3 {
    margin: 0 0 10px 0;
    font-size: 1.1em;
    color: #1d2327;
}

.signing-form .description {
    color: #666;
    margin-bottom: 15px;
}

.signature-container {
    position: relative;
    margin-bottom: 20px;
}

.signature-canvas {
    width: 100%;
    height: 200px;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: crosshair;
    background: #fff;
    touch-action: none;
}

.signature-canvas:hover {
    border-color: #0073aa;
}

#clear-signature {
    position: absolute;
    bottom: 10px;
    right: 10px;
    padding: 6px 12px;
    font-size: 12px;
}

.terms-acceptance {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.terms-acceptance label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: #444;
    cursor: pointer;
}

.terms-acceptance input[type="checkbox"] {
    margin-top: 3px;
    width: 18px;
    height: 18px;
}

.terms-acceptance a {
    color: #0073aa;
    text-decoration: none;
}

.terms-acceptance a:hover {
    text-decoration: underline;
}

#submit-signature {
    width: 100%;
    padding: 15px;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 8px;
    color: #fff;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

#submit-signature:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

#submit-signature:disabled {
    background: #ccc;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

#signing-message,
#renewal-message {
    padding: 15px;
    border-radius: 6px;
    text-align: center;
}

#signing-message.success,
#renewal-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#signing-message.error,
#renewal-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Expired/Error states */
.signing-expired,
.signing-completed,
.signing-not-found {
    padding: 40px 20px;
}

.signing-expired h2,
.signing-completed h2,
.signing-not-found h2 {
    margin: 20px 0 10px 0;
    color: #1d2327;
}

.signing-expired p,
.signing-completed p,
.signing-not-found p {
    color: #666;
    margin-bottom: 20px;
}

#request-renewal-btn {
    padding: 12px 24px;
    font-size: 14px;
    background: #0073aa;
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
}

#request-renewal-btn:hover {
    background: #005a87;
}

/* Success animation */
.success-animation {
    animation: successPulse 0.5s ease-out;
}

@keyframes successPulse {
    0% { transform: scale(0.8); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

/* Responsive */
@media (max-width: 768px) {
    .movemaster-signing-container {
        margin: 20px;
        padding: 20px;
    }
    
    .signing-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .summary-table th,
    .summary-table td {
        display: block;
        width: 100%;
    }
    
    .summary-table th {
        border-bottom: none;
        padding-bottom: 2px;
    }
    
    .summary-table td {
        padding-top: 2px;
    }
}
