:root {
    --primary: #002b6c;
    --primary-dark: #001b46;
    --primary-soft: #eaf1fb;
    --accent: #00a9e0;
    --accent-hover: #008fc0;
    --background: #f5f8fc;
    --white: #ffffff;
    --text: #152033;
    --muted: #667085;
    --border: #dce5f0;
    --danger: #dc2626;
    --success: #16a34a;

    --radius-lg: 28px;
    --radius-md: 16px;
    --radius-sm: 12px;

    --shadow-card: 0 24px 70px rgba(15, 36, 64, 0.13);
}

body {
    margin: 0;
    background:
            radial-gradient(circle at top right, rgba(0, 169, 224, 0.10), transparent 30%),
            linear-gradient(180deg, #ffffff 0%, var(--background) 100%);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
}

.pre-page {
    position: relative;
    min-height: 100vh;
    padding: 36px 20px 56px;
    overflow: hidden;
}

.pre-watermark {
    position: fixed;
    right: -140px;
    bottom: -160px;
    width: min(680px, 70vw);
    opacity: 0.035;
    pointer-events: none;
    user-select: none;
    z-index: 0;
}

.pre-header,
.pre-card,
.pre-note {
    position: relative;
    z-index: 1;
}

.pre-header {
    max-width: 1160px;
    margin: 0 auto 28px;
    text-align: center;
}

.pre-logo {
    width: 230px;
    max-width: 80%;
    height: auto;
    margin-bottom: 14px;
}

.pre-title span {
    display: block;
    color: var(--text);
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.035em;
}

.pre-title h1 {
    margin: 6px 0 0;
    color: var(--primary);
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.pre-title p {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 15px;
}

.pre-card {
    max-width: 1160px;
    margin: 0 auto;
    padding: 34px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(220, 229, 240, 0.95);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(18px);
}

.pre-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 24px;
    margin-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.pre-eyebrow {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--primary-soft);
    color: var(--primary);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.pre-card-header h2 {
    margin: 0;
    color: var(--text);
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.035em;
}

.pre-required {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 999px;
    background: #fff1f2;
    color: #9f1239;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.pre-required span,
.required {
    color: var(--danger);
    font-weight: 900;
}

.form-section {
    padding: 26px 0;
    border-bottom: 1px solid var(--border);
}

.form-section:first-of-type {
    padding-top: 0;
}

.form-section:last-of-type {
    border-bottom: 0;
}

.section-title {
    margin-bottom: 20px;
    text-align: left;
}

.section-title h3 {
    margin: 0;
    color: var(--primary);
    font-size: 25px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.section-title p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.form-group label {
    color: var(--text);
    font-size: 14px;
    font-weight: 700;
}

.form-group label small {
    display: inline;
    color: var(--muted);
    font-weight: 400;
}

.form-group label a {
    color: var(--primary);
    font-weight: 800;
}

.form-control {
    min-height: 44px;
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 14px;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    border-color: rgba(0, 169, 224, 0.72);
    box-shadow: 0 0 0 4px rgba(0, 169, 224, 0.14);
}

.form-control.is-invalid {
    border-color: var(--danger);
}

.form-control.is-valid {
    border-color: var(--success);
}

.field-error {
    display: block;
    margin-top: 6px;
    color: var(--danger);
    font-size: 12px;
    font-weight: 600;
}

.captcha-wrapper {
    display: flex;
    justify-content: center;
    padding: 12px 0 0;
}

.form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 28px;
}

.btn-primary-action,
.btn-secondary-action {
    min-height: 46px;
    padding: 0 24px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary-action {
    border: 0;
    background: linear-gradient(135deg, var(--accent), #007fc4);
    color: var(--white);
    box-shadow: 0 14px 28px rgba(0, 169, 224, 0.24);
}

.btn-primary-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(0, 169, 224, 0.30);
}

.btn-secondary-action {
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--primary);
}

.btn-secondary-action:hover {
    background: var(--primary-soft);
}

.submit-loader {
    margin-top: 18px;
    padding: 14px;
    border-radius: 14px;
    background: #eff6ff;
    color: var(--primary);
    font-weight: 700;
    text-align: center;
}

.submit-loader img {
    width: 20px;
    height: 20px;
    margin-left: 8px;
}

.pre-note {
    max-width: 1160px;
    margin: 22px auto 0;
    padding: 18px 22px;
    border: 1px solid #bfdbfe;
    border-radius: var(--radius-md);
    background: #eff6ff;
    color: #1e3a8a;
}

.pre-note strong {
    display: block;
    margin-bottom: 6px;
    color: var(--primary);
}

.pre-note p {
    margin: 0;
    color: #344054;
    line-height: 1.65;
}

.pre-card-message {
    max-width: 760px;
    text-align: center;
}

.pre-card-message h2 {
    margin: 0 0 14px;
    color: var(--primary);
    font-weight: 800;
}

.pre-card-message p {
    color: var(--muted);
    line-height: 1.7;
}

.institution-signature {
    display: grid;
    gap: 4px;
    margin-top: 24px;
    color: var(--text);
}

.institution-signature a {
    color: var(--primary);
    font-weight: 700;
}

.browser-list {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-top: 22px;
}

.browser-list img {
    width: 44px;
    height: auto;
}

@media (max-width: 768px) {
    .pre-page {
        padding: 24px 14px 40px;
    }

    .pre-card {
        padding: 24px 18px;
        border-radius: 22px;
    }

    .pre-card-header {
        flex-direction: column;
    }

    .pre-title span {
        font-size: 23px;
    }

    .pre-title h1 {
        font-size: 21px;
    }

    .form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .btn-primary-action,
    .btn-secondary-action {
        width: 100%;
    }

    .captcha-wrapper {
        transform: scale(0.88);
        transform-origin: center;
    }
}