/**
 * DOBGuard Branded Modal Styles
 * Mobile-first, responsive design
 */

.dob-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.dob-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.dob-modal-container {
    max-width: 420px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9) translateY(-20px);
    transition: transform 0.3s ease;
}

.dob-modal-overlay.active .dob-modal-container {
    transform: scale(1) translateY(0);
}

.dob-modal-content {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    position: relative;
}

/* Header with branding - Top Left Corner */
.dob-modal-header {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 10;
    pointer-events: none;
}

.dob-modal-shield {
    font-size: 1.25rem;
    color: #FACC15;
    opacity: 0.85;
}

/* Body */
.dob-modal-body {
    padding: 1.5rem;
    text-align: center;
}

.dob-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 1rem 0;
    line-height: 1.3;
}

.dob-modal-message {
    font-size: 1rem;
    color: #4b5563;
    line-height: 1.6;
    margin: 0;
}

.dob-modal-message p {
    margin: 0 0 1rem 0;
}

.dob-modal-message p:last-child {
    margin-bottom: 0;
}

/* Icons for success/error/warning */
.dob-modal-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 1rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dob-modal-icon i {
    font-size: 1.75rem;
}

.dob-modal-icon svg {
    width: 32px;
    height: 32px;
}

.dob-modal-icon-success {
    background: #ecfdf5;
    color: #10b981;
}

.dob-modal-icon-error {
    background: #fef2f2;
    color: #ef4444;
}

.dob-modal-icon-warning {
    background: #fef3c7;
    color: #f59e0b;
}

/* Input */
.dob-modal-input {
    width: 100%;
    padding: 0.75rem 1rem;
    margin-top: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dob-modal-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Footer */
.dob-modal-footer {
    display: flex;
    gap: 0.75rem;
    padding: 1rem 1.5rem 1.5rem 1.5rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

/* Buttons */
.dob-modal-btn {
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    min-width: 80px;
}

.dob-modal-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.dob-modal-btn:active {
    transform: translateY(0);
}

.dob-modal-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(250, 204, 21, 0.3);
}

.dob-modal-btn-primary {
    background: #FACC15;
    color: #000000;
    font-weight: 700;
}

.dob-modal-btn-primary:hover {
    background: #EAB308;
}

.dob-modal-btn-secondary {
    background: #f3f4f6;
    color: #374151;
}

.dob-modal-btn-secondary:hover {
    background: #e5e7eb;
}

.dob-modal-btn-danger {
    background: #ef4444;
    color: white;
}

.dob-modal-btn-danger:hover {
    background: #dc2626;
}

/* Mobile optimizations */
@media (max-width: 640px) {
    .dob-modal-overlay {
        padding: 0.5rem;
    }
    
    .dob-modal-header {
        top: 0.625rem;
        left: 0.625rem;
    }
    
    .dob-modal-shield {
        font-size: 1.125rem;
    }
    
    .dob-modal-body {
        padding: 1.25rem;
    }
    
    .dob-modal-title {
        font-size: 1.25rem;
    }
    
    .dob-modal-message {
        font-size: 0.9375rem;
    }
    
    .dob-modal-footer {
        padding: 0.875rem 1.25rem 1.25rem 1.25rem;
        flex-direction: column-reverse;
    }
    
    .dob-modal-btn {
        width: 100%;
        padding: 0.75rem 1.5rem;
    }
    
    .dob-modal-icon {
        width: 48px;
        height: 48px;
    }
    
    .dob-modal-icon i {
        font-size: 1.5rem;
    }
    
    .dob-modal-icon svg {
        width: 28px;
        height: 28px;
    }
}

/* Tablet */
@media (min-width: 641px) and (max-width: 1024px) {
    .dob-modal-container {
        max-width: 400px;
    }
    
    .dob-modal-shield {
        font-size: 1.125rem;
    }
}

/* Animation for modal entrance */
@keyframes dob-modal-fade-in {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Prevent body scroll when modal is open */
body.dob-modal-open {
    overflow: hidden;
}

/* Special styling for code/monospace content (API keys, etc) */
.dob-modal-code {
    background: #f3f4f6;
    padding: 1rem;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    color: #1f2937;
    word-break: break-all;
    margin: 1rem 0;
    border: 2px solid #e5e7eb;
}

/* Copy button for code blocks */
.dob-modal-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    margin-top: 0.75rem;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.dob-modal-copy-btn:hover {
    background: #2563eb;
}

.dob-modal-copy-btn:active {
    background: #1d4ed8;
}

/* Important warning styling */
.dob-modal-warning-text {
    background: #fef3c7;
    color: #92400e;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border-left: 4px solid #f59e0b;
    margin: 1rem 0;
    font-size: 0.9375rem;
    text-align: left;
}

.dob-modal-warning-text strong {
    color: #78350f;
}

