@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body { 
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, #667eea, #764ba2);
} 

.conatiner {
    width: 90%;
    max-width: 450px; 
}

h1 {
    color: #f9fafb;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* PASSWORD DISPLAY */
.display-container {
    position: relative;
    background-color: #374151;
    border-radius: 12px; 
    border-bottom: 4px solid #4f46e5;
    margin: 1rem 0; 
    padding-top: 0.35rem;
}

.display { 
    width: 100%;
    color: #f9fafb;
    background-color: transparent;
    padding: 10px;
    font-weight: 600;
    border: none;
}

.display::placeholder {
    color: #9ca3af;
    text-transform: uppercase;
}

.display-container button {
    position: absolute;
    top: 50%;
    right: 1.5rem;
    transform: translateY(-50%);
}

/* TOOLTIP */
.toolTip {
    position: absolute;
    background-color: #4f46e5;
    color: white;
    padding: 5px 10px;
    border-radius: 8px;
    transform: scale(0);
    transform-origin: bottom;
    transition: all 250ms ease-in-out;
    top: -34px;
}

.toolTip.active {
    transform: scale(1);
}
 
/* MAIN CARD */
.input-container {
    width: 100%;
    background-color: #1f2937;
    border-radius: 12px;
    padding: 1.5rem;
    border-bottom: 4px solid #4f46e5;
}

/* LENGTH */
.length-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #f9fafb;
    margin-bottom: 10px;
}

/* STRENGTH */
.strength-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #f9fafb;
    margin-top: 10px;
}

.indicator {
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background-color: #ef4444; /* default weak */
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

/* BUTTON */
.generateButton {
    background-color: #4f46e5;
    color: white;
    padding: 0.7rem;
    border: none;
    border-radius: 10px;
    text-transform: uppercase;
    font-weight: 600;
    width: 100%;
    cursor: pointer;
    letter-spacing: 0.1rem;
    margin-top: 1rem;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    transition: 0.3s;
}

.generateButton:hover {
    background-color: #4338ca;
}

/* CHECKBOX */
.check {
    display: flex;
    align-items: center;
    margin: 0.2rem 0;
    gap: 0 0.4rem;
    color: #e5e7eb;
}

.check input {
    appearance: none;
    width: 18px;
    height: 18px;
    border: 1px solid #9ca3af;
    cursor: pointer;
    position: relative;
    border-radius: 4px;
}

.check input:checked {
    background-color: #22c55e;
}

.check input:checked::before {
    content: '\2713';
    position: absolute;
    color: white;
    font-size: 12px;
    left: 3px;
}

/* SLIDER */
.slider {
    appearance: none;
    width: 100%;
    height: 0.6rem;
    cursor: pointer;
    border-radius: 1rem;
    margin: 10px 0;
    background: linear-gradient(to right, #4f46e5, #22c55e);
}

/* SLIDER THUMB */
.slider::-webkit-slider-thumb {
    appearance: none;
    height: 22px;
    width: 22px;
    border-radius: 50%;
    background-color: #f9fafb;
    cursor: pointer;
    box-shadow: 0 0 15px rgba(79, 70, 229, 0.6);
    transition: 0.2s;
}

.slider::-webkit-slider-thumb:hover {
    background-color: #22c55e;
}

/* FOCUS */
.slider:focus {
    outline: none;
}