:root {
    --primary: #4361ee;
    --secondary: #3f37c9;
    --dark: #212529;
    --light: #f8f9fa;
    --success: #33ec0e;
    --danger: rgb(247, 37, 37);
    --gray: #6c757d;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    background-color: #f5f7fa;
    color: var(--dark);
    padding: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.container {
    max-width: 500px;
    width: 100%;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

h1 {
    text-align: center;
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 1.8rem;
}

.password-display {
    position: relative;
    margin-bottom: 25px;
}

#passwordOutput {
    width: 100%;
    padding: 15px;
    font-size: 1.2rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    background-color: var(--light);
    text-align: center;
    font-family: 'Courier New', monospace;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.copy-btn {
    position: absolute;
    right: 10px;
    top: 10px;
    background: none;
    border: none;
    color: var(--gray);
    cursor: pointer;
    font-size: 1.2rem;
    transition: color 0.3s;
}

.copy-btn:hover {
    color: var(--primary);
}

.copy-notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--success);
    color: white;
    padding: 10px 20px;
    border-radius: 50px;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 100;
}

.copy-notification.show {
    opacity: 1;
}

.controls {
    margin-bottom: 20px;
}

.control-group {
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.length-control {
    display: flex;
    align-items: center;
}

#lengthSlider {
    flex: 1;
    margin-right: 15px;
}

#lengthValue {
    width: 40px;
    text-align: center;
    font-weight: bold;
}

.options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.option-item {
    display: flex;
    align-items: center;
}

.option-item input {
    margin-right: 10px;
}

.strength-meter {
    height: 10px;
    background-color: #eee;
    border-radius: 5px;
    margin-bottom: 20px;
    overflow: hidden;
}

.strength-bar {
    height: 100%;
    width: 0%;
    background-color: var(--danger);
    transition: width 0.3s, background-color 0.3s;
}

.generate-btn {
    width: 100%;
    padding: 15px;
    background-color: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.generate-btn:hover {
    background-color: var(--secondary);
}

@media (max-width: 500px) {
    .options {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 20px;
    }
}