body {
    font-family: sans-serif;
    line-height: 1.6;
    margin: 24px;
    background-color: #f5f6f8;
    color: #222;
}

h1 {
    margin-bottom: 24px;
    font-size: 28px;
}

h2 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 20px;
    border-left: 5px solid #2f5fa7;
    padding-left: 10px;
}

.section-card {
    background: #fff;
    border: 1px solid #d9dde3;
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.intro-box {
    background: #f8fbff;
    border: 1px solid #cfdced;
    border-radius: 8px;
    padding: 20px 24px;
    margin-bottom: 24px;
}

.intro-box .intro-content {
    max-width: 760px;
}

.intro-box h2 {
    margin-bottom: 12px;
}

.intro-box p {
    line-height: 1.8;
    margin: 0 0 10px 0;
}

.form-grid {
    display: grid;
    grid-template-columns: 200px minmax(320px, 640px);
    gap: 14px 18px;
    align-items: start;
}

.form-grid label {
    text-align: right;
    white-space: nowrap;
    font-weight: 600;
    padding-top: 10px;
}

.required {
    color: #cc0000;
    margin-left: 4px;
    font-weight: 700;
}

.form-grid input[type="text"],
.form-grid input[type="email"],
.form-grid input[type="password"],
.form-grid input[type="file"] {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid #b8c0cc;
    border-radius: 6px;
    background: #fff;
}

.form-grid input[type="text"]:focus,
.form-grid input[type="email"]:focus,
.form-grid input[type="password"]:focus,
.form-grid input[type="file"]:focus {
    outline: none;
    border-color: #2f5fa7;
    box-shadow: 0 0 0 3px rgba(47, 95, 167, 0.15);
}

.admin-button-row {
    padding-left: 0;
}

.admin-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 16px;
}

.admin-upload-grid {
    margin-top: 20px;
}

.form-trap {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.note {
    font-size: 0.9em;
    color: #666;
    margin-top: 6px;
}

.button-row {
    margin-top: 20px;
    padding-left: 218px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn {
    min-width: 220px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    border: 1px solid #2f5fa7;
    border-radius: 6px;
    cursor: pointer;
    transition: opacity 0.15s ease, background-color 0.15s ease;
}

.btn:hover {
    opacity: 0.92;
}

.btn-primary {
    background: #2f5fa7;
    color: #fff;
}

.btn-secondary {
    background: #fff;
    color: #2f5fa7;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.btn-danger {
    background: #fff;
    border-color: #a62626;
    color: #a62626;
}

.btn-compact {
    min-width: 72px;
    padding: 7px 10px;
}

.table-scroll {
    overflow-x: auto;
}

.review-table {
    min-width: 1100px;
    max-width: none;
}

.review-table th {
    width: auto;
    white-space: nowrap;
}

.review-actions {
    display: flex;
    gap: 8px;
}

.message {
    margin-bottom: 20px;
    padding: 12px 16px;
    border-radius: 6px;
}

.message.error {
    background: #fdecec;
    border: 1px solid #f0b7b7;
    color: #9b1c1c;
}

.message.success {
    background: #edf8ed;
    border: 1px solid #b9dfb9;
    color: #1f6b1f;
}

table {
    border-collapse: collapse;
    width: 100%;
    max-width: 820px;
    background: #fff;
}

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

th {
    width: 220px;
    background: #f0f4fa;
}

@media (max-width: 760px) {
    body {
        margin: 16px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .form-grid label {
        text-align: left;
        padding-top: 0;
    }

    .button-row {
        padding-left: 0;
    }

    .btn {
        width: 100%;
    }

    .admin-actions {
        justify-content: stretch;
    }

    th,
    td {
        display: block;
        width: auto;
    }
}
