* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #111827;
    background: #f8fafc;
}

main {
    width: min(720px, calc(100% - 32px));
    margin: 96px auto;
}

h1 {
    margin: 0 0 12px;
    font-size: 2rem;
    line-height: 1.2;
}

h2 {
    margin: 32px 0 12px;
    font-size: 1.25rem;
    line-height: 1.3;
}

p {
    margin: 0;
    color: #475569;
    line-height: 1.6;
}

.muted {
    margin-top: 12px;
    color: #64748b;
}

.status-line {
    margin-top: 16px;
}

.actions {
    margin-top: 20px;
}

.admin-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 20px 0;
}

.admin-nav a {
    color: #111827;
    font-weight: 600;
}

.error {
    margin: 16px 0;
    color: #b91c1c;
}

form {
    display: grid;
    gap: 12px;
    margin-top: 24px;
}

label {
    font-weight: 600;
}

input[type="text"],
input[type="url"],
input[type="email"],
input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font: inherit;
}

fieldset {
    display: grid;
    gap: 8px;
    margin: 4px 0;
    padding: 0;
    border: 0;
}

legend {
    margin-bottom: 4px;
    font-weight: 600;
}

.checkbox-label {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    font-weight: 400;
}

.radio-label {
    display: flex;
    gap: 8px;
    align-items: center;
    font-weight: 400;
}

button {
    width: fit-content;
    padding: 10px 14px;
    border: 0;
    border-radius: 6px;
    color: #ffffff;
    background: #111827;
    font: inherit;
    cursor: pointer;
}

.danger-button {
    background: #991b1b;
}

.button-link {
    display: inline-block;
    padding: 10px 14px;
    border-radius: 6px;
    color: #ffffff;
    background: #111827;
    text-decoration: none;
}

.inline-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
}

.inline-actions form {
    margin-top: 0;
}

.table-wrap {
    margin-top: 20px;
    overflow-x: auto;
}

table {
    width: 100%;
    min-width: 880px;
    border-collapse: collapse;
    background: #ffffff;
}

th,
td {
    padding: 10px 12px;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
    vertical-align: top;
}

th {
    color: #334155;
    font-size: 0.875rem;
    font-weight: 700;
}

td {
    color: #111827;
}

.detail-list {
    display: grid;
    grid-template-columns: minmax(140px, 220px) minmax(0, 1fr);
    gap: 10px 16px;
    margin: 24px 0;
}

.detail-list dt {
    color: #334155;
    font-weight: 700;
}

.detail-list dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
}

.metadata {
    overflow-x: auto;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #ffffff;
    color: #111827;
}
