/* THEME COLORS */
:root {
    --bg: #0d0d0d;
    --text: #ffffff;
    --card: rgba(255,255,255,0.08);
    --accent: #4df0ff;
    --glow: 0 0 12px #4df0ff;
}

.light {
    --bg: #f2f2f2;
    --text: #000;
    --card: rgba(255,255,255,0.6);
    --accent: #0077ff;
    --glow: 0 0 12px #0077ff;
}

body {
    margin: 0;
    font-family: "Poppins", sans-serif;
    background: var(--bg);
    color: var(--text);
    transition: 0.3s;
}

/* TOP */
.top-bar {
    padding: 15px 20px;
    background: var(--card);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.menu-btn {
    background: none;
    border: none;
    color: var(--text);
    font-size: 26px;
}

/* CARD */
.container {
    display: flex;
    justify-content: center;
    margin-top: 50px;
}

.card {
    width: 90%;
    max-width: 380px;
    padding: 25px;
    border-radius: 20px;
}

.glass {
    background: var(--card);
    backdrop-filter: blur(14px);
    box-shadow: var(--glow);
}

.password-box {
    display: flex;
    gap: 10px;
}

.password-box input {
    flex: 1;
    padding: 10px;
    border-radius: 10px;
    border: none;
    background: #678F8A2B;
    color: var(--text);
    font-weight: bold;
}

.btn, .gen-btn {
    padding: 15px;
    margin-top: 20px;
    background: var(--accent);
    border: none;
    border-radius: 20px;
    color: black;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}

.gen-btn:hover {
    transform: scale(1.05);
}

/* SWITCH TOGGLES */
.switch {
    display: flex;
    justify-content: space-between;
    margin: 10px 0;
}

.switch input {
    display: none;
}

.slider {
    width: 45px;
    height: 22px;
    background: #444;
    border-radius: 20px;
    position: relative;
    transition: 0.3s;
}

.slider::before {
    content: "";
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 50%;
    position: absolute;
    left: 2px;
    top: 2px;
    transition: 0.3s;
}

.switch input:checked + .slider {
    background: var(--accent);
    box-shadow: var(--glow);
}

.switch input:checked + .slider::before {
    transform: translateX(23px);
}

/* PASSWORD STRENGTH */
.strength {
    margin-top: 20px;
}

.strength-bar {
    width: 100%;
    height: 15px;
    margin-top: 5px;
    background: #222;
    border-radius: 10px;
    overflow: hidden;
}

#strengthFill {
    height: 100%;
    width: 0%;
    background: var(--accent);
    box-shadow: var(--glow);
    transition: width 0.3s;
}

/* BOTTOM SHEET */
.sheet {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(4px);
    background: #00000050;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

.sheet-content {
    width: 100%;
    background: var(--card);
    padding: 20px;
    border-radius: 20px 20px 0 0;
    box-shadow: var(--glow);
}

.sheet-btn {
    width: 100%;
    padding: 12px;
    margin: 5px 0;
    background: none;
    border: 1px solid var(--accent);
    color: var(--text);
    border-radius: 10px;
}

.close-sheet {
    margin-top: 10px;
    background: var(--accent);
    border: none;
    padding: 12px;
    width: 100%;
    border-radius: 10px;
}

/* MODAL */
.modal {
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: #00000070;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-box {
    width: 80%;
    max-width: 340px;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
}

/* ANIMATION */
.hidden { display: none; }

@keyframes up {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.animate-up { animation: up 0.4s ease; }

@keyframes pop {
    from { transform: scale(0.7); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.animate-pop { animation: pop 0.3s ease; }