@import url("app.css");

.access-mode {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    border-left: 5px solid var(--good);
}

.access-mode h2 { margin: 4px 0; }
.access-mode p { margin: 6px 0; }
.access-mode form { display: flex; align-items: center; gap: 12px; }
.access-mode-open { border-left-color: var(--warn); background: #fffbf1; }

.switch {
    position: relative;
    display: inline-block;
    flex: 0 0 auto;
    width: 54px;
    height: 30px;
}

.switch input { width: 0; height: 0; opacity: 0; }
.switch span {
    position: absolute;
    inset: 0;
    cursor: pointer;
    border-radius: 999px;
    background: #b8c4ca;
    transition: .2s;
}

.switch span::before {
    content: "";
    position: absolute;
    width: 22px;
    height: 22px;
    left: 4px;
    top: 4px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, .22);
    transition: .2s;
}

.switch input:checked + span { background: var(--warn); }
.switch input:checked + span::before { transform: translateX(24px); }

@media (max-width: 760px) {
    .access-mode { align-items: flex-start; flex-direction: column; }
}
