* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

header {
    text-align: center;
    margin-bottom: 40px;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 16px;
    color: #1a1a1a;
    font-weight: 600;
}

header p {
    font-size: 1.1rem;
    color: #666;
}

.password-display {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 32px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.password-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.password {
    font-family: 'Courier New', monospace;
    font-size: 2rem;
    letter-spacing: 0.1em;
    flex: 1;
    word-break: break-all;
}

.copy-btn,
.regenerate-btn {
    background: none;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: #666;
}

.copy-btn:hover,
.regenerate-btn:hover {
    background-color: #f0f0f0;
    border-color: #999;
    color: #333;
}

.progress-bar {
    height: 8px;
    background-color: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: #4caf50;
    width: 75%;
    transition: width 0.3s ease;
}

.settings-container {
    background: white;
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.settings-container h2 {
    font-size: 1.5rem;
    margin-bottom: 24px;
    font-weight: 600;
}

.length-control {
    margin-bottom: 32px;
}

.length-control label {
    display: block;
    margin-bottom: 12px;
    font-weight: 500;
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 16px;
}

#lengthValue {
    width: 80px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    text-align: center;
}

#lengthSlider {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    outline: none;
}

#lengthSlider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: #d32f2f;
    border-radius: 50%;
    cursor: pointer;
}

#lengthSlider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: #d32f2f;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: start;
}

.radio-group,
.checkbox-group {
    display: flex;
    align-items: center;
    padding: 12px 0;
    min-height: 44px;
}

.radio-group input[type="radio"],
.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    cursor: pointer;
}

.radio-group input[type="radio"] {
    accent-color: #666;
}

.checkbox-group input[type="checkbox"] {
    accent-color: #d32f2f;
}

.radio-group label,
.checkbox-group label {
    cursor: pointer;
    display: flex;
    align-items: center;
    font-weight: 500;
}

.info-icon {
    margin-left: 8px;
    color: #999;
    font-size: 0.9rem;
    cursor: help;
}

.empty-cell {
    display: block;
}

.copy-password-btn {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    padding: 16px 32px;
    background-color: #d32f2f;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}

.copy-password-btn:hover {
    background-color: #b71c1c;
}

.copy-password-btn:active {
    transform: translateY(1px);
}

@media (max-width: 640px) {
    header h1 {
        font-size: 1.5rem;
    }
    
    .password {
        font-size: 1.5rem;
    }
    
    .options-grid {
        grid-template-columns: 1fr;
    }
    
    .settings-container {
        padding: 24px;
    }
}