/* DNT Form Styles - Formular Cerințe și Necesități */
/* Instant Asig - ASF Compliance 2025 */

/* Modal Container */
.dnt-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
}

.dnt-modal-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 20px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    animation: dntSlideIn 0.4s ease-out;
}

@keyframes dntSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Close Button */
.dnt-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: #ef4444;
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.dnt-close:hover {
    background: #dc2626;
    transform: rotate(90deg);
}

/* Header */
.dnt-header {
    background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%);
    color: white;
    padding: 30px;
    border-radius: 20px 20px 0 0;
    text-align: center;
}

.dnt-header h2 {
    margin: 0 0 10px 0;
    font-size: 1.6rem;
    font-weight: 700;
}

.dnt-header p {
    margin: 0 0 20px 0;
    opacity: 0.9;
    font-size: 0.95rem;
}

/* Progress Bar */
.dnt-progress-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.dnt-progress-bar {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    overflow: hidden;
}

.dnt-progress {
    height: 100%;
    background: linear-gradient(90deg, #22c55e, #4ade80);
    border-radius: 10px;
    transition: width 0.4s ease;
}

#dntStepIndicator {
    font-size: 0.85rem;
    white-space: nowrap;
    font-weight: 600;
}

/* Error Message */
.dnt-error-msg {
    background: #fef2f2;
    color: #dc2626;
    padding: 12px 20px;
    margin: 0 20px;
    border-radius: 8px;
    border-left: 4px solid #dc2626;
    font-size: 0.9rem;
    animation: dntShake 0.5s ease;
}

@keyframes dntShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Form Steps */
.dnt-step {
    padding: 25px 30px;
}

.dnt-step h3 {
    color: #1e3a5f;
    font-size: 1.3rem;
    margin: 0 0 25px 0;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

/* Form Groups */
.dnt-form-group {
    margin-bottom: 20px;
}

.dnt-form-group label {
    display: block;
    color: #374151;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.dnt-form-group input[type="text"],
.dnt-form-group input[type="email"],
.dnt-form-group input[type="tel"],
.dnt-form-group input[type="number"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
    background: #fff;
}

.dnt-form-group input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.dnt-form-group input.dnt-error {
    border-color: #ef4444;
    background: #fef2f2;
}

.dnt-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .dnt-form-row {
        grid-template-columns: 1fr;
    }
}

/* Questions */
.dnt-question {
    margin-bottom: 25px;
    padding: 20px;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.dnt-question > label {
    display: block;
    color: #1e3a5f;
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Radio Groups */
.dnt-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.dnt-radio-group.dnt-error {
    background: #fef2f2;
    padding: 10px;
    border-radius: 8px;
    border: 2px solid #ef4444;
}

.dnt-radio {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.dnt-radio:hover {
    border-color: #2563eb;
    background: #eff6ff;
}

.dnt-radio input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #2563eb;
}

.dnt-radio:has(input:checked) {
    background: linear-gradient(135deg, #2563eb 0%, #1e3a5f 100%);
    color: white;
    border-color: #2563eb;
}

/* Checkbox Groups */
.dnt-checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.dnt-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.dnt-checkbox:hover {
    border-color: #2563eb;
}

.dnt-checkbox input[type="radio"],
.dnt-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #2563eb;
}

.dnt-checkbox:has(input:checked) {
    background: #eff6ff;
    border-color: #2563eb;
    color: #1e3a5f;
}

/* Info Boxes */
.dnt-info-box {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    padding: 18px;
    margin: 20px 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #1e40af;
}

.dnt-info-box.warning {
    background: #fef3c7;
    border-color: #fcd34d;
    color: #92400e;
}

.dnt-info-box.success {
    background: #dcfce7;
    border-color: #86efac;
    color: #166534;
}

.dnt-info-box p {
    margin: 0 0 10px 0;
}

.dnt-info-box p:last-child {
    margin-bottom: 0;
}

/* Confirm Box */
.dnt-confirm-box {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
}

.dnt-confirm-box h4 {
    color: #92400e;
    margin: 0 0 20px 0;
    font-size: 1.1rem;
}

.dnt-confirm-box .dnt-question {
    background: white;
    border: 1px solid #fcd34d;
}

/* Signature Section */
.dnt-signature-section {
    margin: 25px 0;
}

.dnt-signature-section > label {
    display: block;
    color: #1e3a5f;
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 0.95rem;
}

.dnt-signature-container {
    position: relative;
    background: white;
    border: 3px dashed #cbd5e1;
    border-radius: 15px;
    overflow: hidden;
}

#signatureCanvas {
    width: 100%;
    height: 180px;
    cursor: crosshair;
    display: block;
    touch-action: none;
}

.dnt-clear-sig {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: #ef4444;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dnt-clear-sig:hover {
    background: #dc2626;
    transform: scale(1.05);
}

/* Buttons */
.dnt-buttons {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    padding: 20px 30px 30px;
    background: #f8fafc;
    border-radius: 0 0 20px 20px;
    border-top: 1px solid #e2e8f0;
}

.dnt-btn {
    padding: 14px 28px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.dnt-btn-primary {
    background: linear-gradient(135deg, #2563eb 0%, #1e3a5f 100%);
    color: white;
    margin-left: auto;
}

.dnt-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4);
}

.dnt-btn-secondary {
    background: #e2e8f0;
    color: #475569;
}

.dnt-btn-secondary:hover {
    background: #cbd5e1;
}

.dnt-btn-success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    margin-left: auto;
}

.dnt-btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(34, 197, 94, 0.4);
}

/* Success Screen */
.dnt-success {
    text-align: center;
    padding: 60px 40px;
}

.dnt-success-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    margin: 0 auto 30px;
    animation: dntPulse 1s ease infinite;
}

@keyframes dntPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.dnt-success h2 {
    color: #22c55e;
    margin: 0 0 15px;
    font-size: 1.6rem;
}

.dnt-success p {
    color: #475569;
    margin: 10px 0;
    font-size: 1.1rem;
}

.dnt-loader {
    width: 50px;
    height: 50px;
    border: 4px solid #e2e8f0;
    border-top-color: #2563eb;
    border-radius: 50%;
    margin: 30px auto 0;
    animation: dntSpin 1s linear infinite;
}

@keyframes dntSpin {
    to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .dnt-modal {
        padding: 10px;
    }
    
    .dnt-modal-content {
        max-height: 95vh;
        border-radius: 15px;
    }
    
    .dnt-header {
        padding: 20px;
        border-radius: 15px 15px 0 0;
    }
    
    .dnt-header h2 {
        font-size: 1.3rem;
    }
    
    .dnt-step {
        padding: 20px;
    }
    
    .dnt-step h3 {
        font-size: 1.1rem;
    }
    
    .dnt-radio-group {
        flex-direction: column;
    }
    
    .dnt-radio {
        width: 100%;
        justify-content: flex-start;
    }
    
    .dnt-checkbox-group {
        flex-direction: column;
    }
    
    .dnt-checkbox {
        width: 100%;
    }
    
    .dnt-buttons {
        flex-direction: column;
        padding: 20px;
    }
    
    .dnt-btn {
        width: 100%;
        justify-content: center;
    }
    
    .dnt-btn-primary,
    .dnt-btn-success {
        margin-left: 0;
        order: -1;
    }
    
    #signatureCanvas {
        height: 150px;
    }
}

/* Print styles - hide modal */
@media print {
    .dnt-modal {
        display: none !important;
    }
}


