/* Password Strength Enhancements */
.strength-details {
    margin-top: 0.75rem;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    border-radius: 6px;
    font-size: 0.85rem;
    display: none;
}

.strength-analysis {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.analysis-section {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.analysis-title {
    font-weight: 600;
    color: var(--accent-cyan, #00ffc8);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.analysis-item {
    padding: 0.25rem 0;
    color: var(--text-secondary, #a8a8b8);
    line-height: 1.4;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.analysis-item:last-child {
    border-bottom: none;
}

/* Enhanced strength text styling */
.strength-text.excellent {
    color: #4caf50 !important;
    font-weight: 600;
}

.strength-text.strong {
    color: #8bc34a !important;
    font-weight: 600;
}

.strength-text.good {
    color: #ffc107 !important;
    font-weight: 600;
}

.strength-text.fair {
    color: #ff9800 !important;
    font-weight: 600;
}

.strength-text.weak {
    color: #f44336 !important;
    font-weight: 600;
}

.strength-text.very-weak {
    color: #d32f2f !important;
    font-weight: 600;
}

/* Enhanced strength bars */
.strength-bar.active.excellent {
    background: linear-gradient(90deg, #4caf50, #66bb6a);
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.5);
}

.strength-bar.active.strong {
    background: linear-gradient(90deg, #8bc34a, #9ccc65);
    box-shadow: 0 0 8px rgba(139, 195, 74, 0.5);
}

.strength-bar.active.good {
    background: linear-gradient(90deg, #ffc107, #ffca28);
    box-shadow: 0 0 8px rgba(255, 193, 7, 0.5);
}

.strength-bar.active.fair {
    background: linear-gradient(90deg, #ff9800, #ffb74d);
    box-shadow: 0 0 6px rgba(255, 152, 0, 0.5);
}

.strength-bar.active.weak {
    background: linear-gradient(90deg, #f44336, #ef5350);
    box-shadow: 0 0 6px rgba(244, 67, 54, 0.5);
}

.strength-bar.active.very-weak {
    background: linear-gradient(90deg, #d32f2f, #e57373);
    box-shadow: 0 0 6px rgba(211, 47, 47, 0.5);
}

/* Password Generator Modal Styling */
.modal-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: rgba(0, 0, 0, 0.8) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    z-index: 10000 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.password-generator-modal {
    background: var(--surface-color, #1a1a2e);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    border-radius: 12px;
    padding: 1.5rem;
    min-width: 500px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    padding-bottom: 1rem;
}

.modal-header h3 {
    margin: 0;
    color: var(--accent-cyan, #00ffc8);
    font-size: 1.25rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary, #a8a8b8);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary, #ffffff);
}

.modal-body {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary, #ffffff);
    font-weight: 500;
    font-size: 0.9rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    border-radius: 6px;
    color: var(--text-primary, #ffffff);
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-cyan, #00ffc8);
    box-shadow: 0 0 0 2px rgba(0, 255, 200, 0.1);
}

.password-preview {
    margin: 1.5rem 0;
}

.password-display {
    display: flex;
    gap: 0.75rem;
}

.password-display input {
    flex: 1;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
    background: rgba(0, 0, 0, 0.3);
}

.password-analysis {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    border-radius: 6px;
    padding: 0.75rem;
    margin-top: 1rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    font-size: 0.85rem;
}

.entropy-info, .crack-time {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.entropy-label, .crack-label {
    color: var(--text-secondary, #a8a8b8);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.entropy-bits {
    color: var(--text-secondary, #a8a8b8);
    font-size: 0.8rem;
}

#password-entropy, #crack-time {
    color: var(--accent-cyan, #00ffc8);
    font-weight: 600;
    font-size: 0.9rem;
}

.modal-footer {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    border-top: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    padding-top: 1rem;
}

.btn {
    padding: 0.625rem 1.25rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--accent-cyan, #00ffc8);
    color: var(--dark-bg, #0f0f23);
}

.btn-primary:hover:not(:disabled) {
    background: rgba(0, 255, 200, 0.8);
    transform: translateY(-1px);
}

.btn-success {
    background: #4caf50;
    color: white;
}

.btn-success:hover:not(:disabled) {
    background: #45a049;
    transform: translateY(-1px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary, #ffffff);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
}

.btn-secondary:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.modal-content {
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Generator option styling */
.radio-group input[type="radio"] {
    margin-right: 0.5rem;
}

.radio-group label:hover {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    padding: 0.25rem;
}

/* Length slider styling */
#lengthSlider {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    height: 6px;
}

#lengthSlider::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    background: var(--accent, #00ffc8);
    border-radius: 50%;
    cursor: pointer;
}

#lengthSlider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--accent, #00ffc8);
    border-radius: 50%;
    border: none;
    cursor: pointer;
}

/* Generated password input styling */
#generatedPassword {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace !important;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
}

/* Button hover effects */
#copyGeneratedBtn:hover {
    background: rgba(0, 255, 200, 0.8) !important;
    transform: translateY(-1px);
}

#regenerateBtn:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    transform: translateY(-1px);
}

#usePasswordBtn:hover {
    background: rgba(0, 255, 200, 0.9) !important;
    transform: translateY(-1px);
}

/* Password tips section */
.password-tips h4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.password-tips ul li {
    margin-bottom: 0.25rem;
}

.password-tips ul li strong {
    color: var(--accent, #00ffc8);
}

/* Mobile responsiveness */
@media (max-width: 600px) {
    .modal-content {
        margin: 1rem;
        padding: 1.5rem !important;
        max-width: none !important;
    }
    
    .radio-group {
        flex-direction: column !important;
        gap: 0.5rem !important;
    }
    
    .modal-actions {
        flex-direction: column !important;
    }
    
    .modal-actions button {
        width: 100%;
    }
}

/* Password actions button styling */
.generate-password-btn:hover {
    background: rgba(0, 255, 200, 0.2) !important;
    border-color: rgba(0, 255, 200, 0.5) !important;
    transform: translateY(-1px);
}

.generate-password-btn:active {
    transform: translateY(0);
}