* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #f4f6f8;
    color: #1e293b;
    font-family: Arial, sans-serif;
}

.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 28px;
    background: #111827;
}

.brand {
    color: white;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
}

.container {
    width: min(1180px, calc(100% - 32px));
    margin: 32px auto;
}

.cards {
    display: grid;
    grid-template-columns:
        repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.card,
.record,
.login-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgb(0 0 0 / 6%);
}

.card {
    padding: 22px;
    color: inherit;
    text-decoration: none;
}

.card:hover {
    border-color: #64748b;
}

.card h2 {
    margin-top: 0;
}

.card span {
    color: #64748b;
    font-size: 14px;
}

.login-wrapper {
    min-height: 80vh;
    display: grid;
    place-items: center;
}

.login-card {
    width: min(420px, 100%);
    padding: 32px;
}

.login-card h1 {
    margin-bottom: 6px;
}

.login-card p {
    margin-top: 0;
    color: #64748b;
}

.record {
    margin: 18px 0;
    padding: 22px;
    display: grid;
    grid-template-columns:
        repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.field label {
    font-size: 13px;
    font-weight: 700;
    color: #475569;
}

.readonly div {
    padding: 11px;
    background: #f1f5f9;
    border-radius: 7px;
}

input,
select,
textarea {
    width: 100%;
    padding: 11px;
    border: 1px solid #cbd5e1;
    border-radius: 7px;
    background: white;
    font: inherit;
}

textarea {
    resize: vertical;
}

button {
    padding: 11px 18px;
    border: 0;
    border-radius: 7px;
    background: #1d4ed8;
    color: white;
    cursor: pointer;
    font-weight: 700;
}

.record > button {
    align-self: end;
}

.logout {
    background: #374151;
}

.back {
    color: #1d4ed8;
    text-decoration: none;
}

.flash {
    margin-bottom: 18px;
    padding: 14px;
    border-radius: 8px;
}

.flash.success {
    background: #dcfce7;
}

.flash.error {
    background: #fee2e2;
}

.switch {
    min-height: 42px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.switch input {
    width: auto;
}
