:root {
    --reg-bg: #f5f7fb;
    --reg-surface: #ffffff;
    --reg-text: #192233;
    --reg-muted: #687386;
    --reg-line: #e3e8f0;
    --reg-primary: #243f8f;
    --reg-primary-dark: #172d6f;
    --reg-accent: #f1b632;
    --reg-success: #2f7d57;
    --reg-radius: 18px;
    --reg-shadow: 0 16px 42px rgba(19, 32, 61, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--reg-bg);
    color: var(--reg-text);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 12px;
    line-height: 1.7;
}

a {
    color: inherit;
}

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

.reg-document-head {
    padding-top: 30px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--reg-line);
}

.reg-back {
    display: inline-block;
    margin-bottom: 18px;
    color: var(--reg-muted);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.reg-back:hover {
    color: var(--reg-primary);
}

.reg-document-head h1 {
    max-width: 900px;
    margin: 0;
    color: var(--reg-text);
    font-size: 26px;
    line-height: 1.3;
    letter-spacing: -0.015em;
}

.reg-document-head small {
    display: block;
    margin-top: 8px;
    color: #8a93a2;
    font-size: 12px;
}

.reg-layout {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
    padding: 42px 0 72px;
}

.reg-sidebar {
    position: sticky;
    top: 24px;
}

.reg-sidebar-card {
    max-height: calc(100vh - 122px);
    overflow: auto;
    padding: 20px;
    background: var(--reg-surface);
    border: 1px solid var(--reg-line);
    border-radius: var(--reg-radius);
    box-shadow: var(--reg-shadow);
}

.reg-sidebar-card > strong {
    display: block;
    margin-bottom: 12px;
    color: var(--reg-primary-dark);
    font-size: 15px;
}

.reg-sidebar nav {
    display: grid;
}

.reg-sidebar a {
    padding: 8px 0;
    color: var(--reg-muted);
    text-decoration: none;
    border-bottom: 1px solid #eef1f5;
    font-size: 13px;
    line-height: 1.35;
}

.reg-sidebar a:last-child {
    border-bottom: 0;
}

.reg-sidebar a:hover {
    color: var(--reg-primary);
}

.reg-content {
    min-width: 0;
}

.reg-section {
    scroll-margin-top: 24px;
    margin-bottom: 20px;
    padding: 30px 32px;
    background: var(--reg-surface);
    border: 1px solid var(--reg-line);
    border-radius: var(--reg-radius);
    box-shadow: 0 8px 28px rgba(19, 32, 61, 0.045);
}

.reg-section h2 {
    margin: 0 0 18px;
    color: var(--reg-primary-dark);
    font-size: 15px;
    line-height: 1.25;
    letter-spacing: -.015em;
}

.reg-section p {
    margin: 0 0 14px;
}

.reg-section p:last-child {
    margin-bottom: 0;
}

.reg-section strong {
    color: #13214a;
}

.reg-checklist,
.reg-roman,
.reg-steps {
    margin: 16px 0 18px;
    padding: 0;
}

.reg-checklist {
    list-style: none;
    display: grid;
    gap: 9px;
}

.reg-checklist li {
    position: relative;
    padding-left: 28px;
}

.reg-checklist li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--reg-success);
    font-weight: 800;
}

.reg-roman,
.reg-steps {
    padding-left: 22px;
}

.reg-roman li,
.reg-steps li {
    margin-bottom: 10px;
    padding-left: 6px;
}

.reg-highlight {
    border-color: #efcf79;
    background: linear-gradient(180deg, #fffdf6, #fff);
}

.reg-highlight-success {
    border-color: #b7dac9;
    background: linear-gradient(180deg, #f7fcf9, #fff);
}

.reg-highlight-label {
    display: inline-block;
    margin-bottom: 10px;
    padding: 5px 9px;
    border-radius: 999px;
    background: #fff1c8;
    color: #765300;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.reg-highlight-success .reg-highlight-label {
    background: #def2e8;
    color: #225f43;
}

.reg-footer-note {
    display: grid;
    gap: 3px;
    margin-top: 28px;
    padding: 24px;
    border-radius: var(--reg-radius);
    background: #eaf0fb;
    color: #49566d;
    font-size: 14px;
}

.reg-footer-note strong {
    color: var(--reg-primary-dark);
}

.reg-footer {
    background: #111d43;
    color: rgba(255,255,255,.82);
}

.reg-footer-inner {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}

.reg-footer-inner > div:first-child {
    display: grid;
    gap: 2px;
}

.reg-footer-inner strong {
    color: #fff;
}

.reg-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}

.reg-footer-links a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
}

.reg-top {
    position: fixed;
    right: 22px;
    bottom: 22px;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--reg-primary);
    color: #fff;
    text-decoration: none;
    box-shadow: 0 10px 28px rgba(23,45,111,.24);
    font-weight: 800;
}

@media (max-width: 900px) {
    .reg-layout {
        grid-template-columns: 1fr;
    }

    .reg-sidebar {
        position: static;
    }

    .reg-sidebar-card {
        max-height: none;
    }

    .reg-sidebar nav {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0 18px;
    }
}

@media (max-width: 640px) {
    body {
        font-size: 13px;
    }

    .reg-container {
        width: min(100% - 28px, 1180px);
    }

    .reg-header-inner {
        min-height: 52px;
    }

    .reg-brand {
        font-size: 16px;
    }

    .reg-back {
        font-size: 12px;
    }

    .reg-document-head {
        padding-top: 24px;
        padding-bottom: 4px;
    }

    .reg-document-head h1 {
        font-size: 24px;
    }

    .reg-document-head p {
        font-size: 14px;
    }

    .reg-layout {
        gap: 20px;
        padding: 24px 0 48px;
    }

    .reg-sidebar-card {
        padding: 18px;
    }

    .reg-sidebar nav {
        grid-template-columns: 1fr;
    }

    .reg-section {
        scroll-margin-top: 82px;
        padding: 23px 20px;
        border-radius: 15px;
    }

    .reg-section h2 {
        font-size: 21px;
    }

    .reg-footer-inner {
        min-height: 160px;
        align-items: flex-start;
        justify-content: center;
        flex-direction: column;
        padding: 28px 0;
    }

    .reg-footer-links {
        display: grid;
        gap: 8px;
    }

    .reg-top {
        right: 14px;
        bottom: 14px;
    }
}
