:root {
    --color-page-bg: #f4f6f8;
    color-scheme: light;
    font-family: Arial, Helvetica, sans-serif;
    color: #17212b;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--color-page-bg);
}

.page {
    width: min(760px, calc(100% - 32px));
    margin: 0 auto;
    padding: 56px 0;
}

.page--preview {
    width: max(760px, calc(var(--preview-banner-width, 760px) + 64px));
    max-width: none;
}

.panel {
    background: #ffffff;
    border: 1px solid #dce3ea;
    border-radius: 8px;
    padding: 28px;
    box-shadow: 0 16px 40px rgba(25, 38, 52, 0.08);
}

h1 {
    margin: 0 0 10px;
    font-size: 28px;
    line-height: 1.2;
    font-weight: 700;
}

.intro {
    margin: 0 0 26px;
    color: #536170;
    line-height: 1.5;
}

.upload-form {
    display: grid;
    gap: 18px;
}

.field {
    display: grid;
    gap: 8px;
}

label {
    font-weight: 700;
}

input[type="file"],
input[type="date"] {
    width: 100%;
    min-height: 44px;
    border: 1px solid #b8c4d0;
    border-radius: 6px;
    background: #ffffff;
    color: #17212b;
    font: inherit;
}

input[type="file"] {
    padding: 10px;
}

input[type="date"] {
    padding: 0 12px;
}

.note {
    margin: 0;
    color: #536170;
    font-size: 14px;
    line-height: 1.45;
}

.form-status {
    margin: -6px 0 0;
    color: #536170;
    font-size: 14px;
    line-height: 1.45;
}

.message-box {
    margin: 0 0 22px;
    border: 1px solid #dce3ea;
    border-radius: 8px;
    padding: 16px;
    background: #ffffff;
}

.message-box--error {
    border-color: #f1a7a1;
    background: #fff5f5;
}

.message-title {
    margin: 0 0 6px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 700;
}

.message-text {
    margin: 0 0 12px;
    color: #536170;
    line-height: 1.45;
}

.preview-note {
    margin: -12px 0 24px;
    border-left: 3px solid #d0a11f;
    padding: 8px 12px;
    background: #fff8e6;
    color: #5f4b13;
    font-size: 14px;
    line-height: 1.45;
}

.error-list {
    margin: 0 0 22px;
    padding-left: 22px;
    color: #b42318;
    line-height: 1.5;
}

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

.button-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: #1f6feb;
    font-weight: 700;
    text-decoration: none;
}

.copy-row {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.copy-row label {
    font-weight: 700;
}

.copy-controls {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.copy-controls input {
    width: 100%;
    min-height: 44px;
    border: 1px solid #b8c4d0;
    border-radius: 6px;
    padding: 0 12px;
    color: #17212b;
    font: inherit;
}

.preview-list {
    display: grid;
    gap: 34px;
    margin-top: 28px;
}

.banner-block {
    padding-top: 24px;
    border-top: 1px solid #dce3ea;
}

.banner-block:first-child {
    padding-top: 0;
    border-top: 0;
}

.banner-title {
    margin: 0 0 12px;
    font-size: 18px;
    line-height: 1.35;
}

.banner-frame {
    display: block;
    border: 1px solid #b8c4d0;
    overflow: hidden;
    background: #ffffff;
}

button {
    justify-self: start;
    min-height: 44px;
    border: 0;
    border-radius: 6px;
    padding: 0 18px;
    background: #1f6feb;
    color: #ffffff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

button:hover {
    background: #195fc9;
}

button:focus-visible,
input:focus-visible {
    outline: 3px solid rgba(31, 111, 235, 0.28);
    outline-offset: 2px;
}

@media (max-width: 520px) {
    .panel {
        padding: 22px;
    }

    .copy-controls {
        display: grid;
    }
}
