/* ==========================================================================
   Registration — two-column sign-up

   Colours, ambient light, brand, language picker and buttons live in
   auth-theme.css, which follows the Theme mode chosen in Business Settings.
   This file only lays the registration page out, using those tokens.

   Left is a sticky rail carrying the headline and the step list; right is the
   form. register-split.js steps through the numbered sections and sets
   --reg-pct / --reg-frac on <html> for the progress lines.

   Class names inside the two partials (reg-section, reg-nature-*) and the
   Bootstrap markup they emit are unchanged; this file restyles them.
   ========================================================================== */

:root {
    --rg-rail-w: clamp(320px, 25vw, 420px);
    --reg-pct:   25%;
}

/* --------------------------------------------------------------------------
   Shell
   -------------------------------------------------------------------------- */
.reg-shell {
    position: relative;
    display: flex;
    align-items: stretch;
    min-height: 100vh;
    font-family: var(--rg-font);
    font-size: 15px;
    line-height: 1.55;
    color: var(--rg-ink-2);
    isolation: isolate;
}

/* ==========================================================================
   Left rail
   ========================================================================== */
.reg-aside {
    position: relative;
    flex: 0 0 var(--rg-rail-w);
    width: var(--rg-rail-w);
    color: var(--rg-ink);
    background: linear-gradient(180deg, var(--rg-rail-a), var(--rg-rail-b));
    box-shadow: inset -1px 0 0 var(--rg-line);
}

/* A fine grid that fades out, like the landing hero. */
.reg-aside::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(var(--rg-grid) 1px, transparent 1px),
        linear-gradient(90deg, var(--rg-grid) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 30% 10%, #000 10%, transparent 70%);
    mask-image: radial-gradient(ellipse 80% 60% at 30% 10%, #000 10%, transparent 70%);
}

.reg-aside-inner {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 36px clamp(28px, 2.6vw, 40px);
    min-height: 100vh;
}

/* --- headline ------------------------------------------------------------- */
.reg-aside-copy h1 {
    margin: 0 0 16px;
    font-family: var(--rg-font);
    font-size: clamp(34px, 3.1vw, 48px);
    line-height: 1.02;
    font-weight: 700;
    letter-spacing: -.045em;
    background: var(--rg-headline);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.reg-aside-copy p {
    margin: 0;
    max-width: 36ch;
    font-size: 15.5px;
    line-height: 1.6;
    color: var(--rg-muted);
}

/* --- step list, on glass -------------------------------------------------- */
.reg-steps-wrap {
    position: relative;
    padding: 22px 22px 18px;
    border-radius: var(--rg-r);
    background: var(--rg-glass);
    box-shadow: inset 0 0 0 1px var(--rg-line), 0 20px 40px -30px var(--rg-shadow);
}

@supports (backdrop-filter: blur(1px)) {
    .reg-steps-wrap { backdrop-filter: blur(12px); }
}

.reg-steps-label {
    display: block;
    margin-bottom: 14px;
    font-family: var(--rg-mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--rg-accent);
}

.reg-steps {
    position: relative;
    margin: 0;
    padding: 0;
    list-style: none;
}

/* The track the markers sit on, and the part of it already covered. */
.reg-steps::before,
.reg-steps::after {
    content: "";
    position: absolute;
    left: 15px;
    top: 22px;
    width: 2px;
    border-radius: 2px;
}

.reg-steps::before {
    bottom: 22px;
    background: var(--rg-line);
}

.reg-steps::after {
    height: calc((100% - 44px) * var(--reg-frac, 0));
    background: linear-gradient(180deg, var(--rg-accent), var(--rg-accent-2));
    box-shadow: 0 0 12px var(--rg-accent-glow);
    transition: height .5s var(--rg-ease);
}

.reg-step {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 9px 10px 9px 0;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: -.01em;
    color: var(--rg-muted);
    transition: color .25s var(--rg-ease);
}

/* Only ground already covered can be jumped back to. */
.reg-step.is-reachable { cursor: pointer; }
.reg-step.is-reachable:hover { color: var(--rg-heading); }

.reg-step-num {
    position: relative;
    flex: none;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--rg-bg);
    box-shadow: inset 0 0 0 1px var(--rg-line-2);
    font-family: var(--rg-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--rg-muted);
    transition: background .3s var(--rg-ease), box-shadow .3s var(--rg-ease), color .3s var(--rg-ease), transform .3s var(--rg-ease);
}

.reg-step.is-on { color: var(--rg-heading); font-weight: 600; }

.reg-step.is-on .reg-step-num {
    background: var(--rg-grad);
    box-shadow: 0 0 0 5px var(--rg-accent-soft), 0 6px 18px -4px var(--rg-accent-glow);
    color: var(--rg-on-accent);
    transform: scale(1.06);
}

.reg-step.is-done { color: var(--rg-ink-2); }

.reg-step.is-done .reg-step-num {
    background: var(--rg-accent-soft);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
    color: var(--rg-accent);
}

/* --- trust list ----------------------------------------------------------- */
.reg-trust {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 11px;
}

.reg-trust li {
    position: relative;
    padding-left: 30px;
    font-size: 14px;
    letter-spacing: -.005em;
    color: var(--rg-ink-2);
}

.reg-trust li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 1px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--rg-accent-soft);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
}

.reg-trust li::after {
    content: "";
    position: absolute;
    left: 6.5px;
    top: 7px;
    width: 8px;
    height: 4.5px;
    border-left: 1.8px solid var(--rg-accent);
    border-bottom: 1.8px solid var(--rg-accent);
    transform: rotate(-45deg);
}

/* --- decorative dashboard ------------------------------------------------- */
.reg-figure {
    position: relative;
    margin-top: auto;
    padding: 18px 26px 10px 0;
    perspective: 1200px;
}

.reg-figure::before {
    content: "";
    position: absolute;
    inset: 10% 10% 0 0;
    z-index: -1;
    background: radial-gradient(ellipse at center, color-mix(in srgb, var(--rg-accent-2) 35%, transparent), color-mix(in srgb, var(--rg-accent) 12%, transparent) 45%, transparent 70%);
    filter: blur(40px);
}

.reg-figure-card {
    display: grid;
    gap: 12px;
    max-width: 330px;
    padding: 14px 16px 16px;
    border-radius: 16px;
    background: linear-gradient(180deg, var(--rg-mock-a), var(--rg-mock-b));
    box-shadow: inset 0 0 0 1px var(--rg-line-2), 0 40px 70px -30px var(--rg-shadow);
    transform: rotateX(10deg) rotateY(-14deg) rotateZ(1deg);
    transform-origin: 30% 60%;
    animation: rg-hover 7s ease-in-out infinite;
}

@keyframes rg-hover {
    0%, 100% { transform: rotateX(10deg) rotateY(-14deg) rotateZ(1deg) translateY(0); }
    50%      { transform: rotateX(8deg) rotateY(-10deg) rotateZ(1deg) translateY(-8px); }
}

.reg-fig-top { display: flex; align-items: center; gap: 5px; }
.reg-fig-dot { width: 7px; height: 7px; border-radius: 50%; }
.reg-fig-dot:nth-child(1) { background: #ff5f57; }
.reg-fig-dot:nth-child(2) { background: #febc2e; }
.reg-fig-dot:nth-child(3) { background: #28c840; }
.reg-fig-url { flex: 1; height: 8px; margin-left: 10px; border-radius: 4px; background: var(--rg-line); }

.reg-fig-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }

.reg-fig-kpi {
    display: grid;
    gap: 7px;
    padding: 10px;
    border-radius: 10px;
    background: var(--rg-glass);
    box-shadow: inset 0 0 0 1px var(--rg-line);
}

.reg-fig-kpi i { display: block; width: 55%; height: 5px; border-radius: 3px; background: var(--rg-line-2); }
.reg-fig-kpi b { display: block; width: 80%; height: 9px; border-radius: 4px; }
.reg-fig-kpi:nth-child(1) b { background: linear-gradient(90deg, var(--rg-accent), color-mix(in srgb, var(--rg-accent) 30%, transparent)); }
.reg-fig-kpi:nth-child(2) b { background: linear-gradient(90deg, var(--rg-accent-2), color-mix(in srgb, var(--rg-accent-2) 30%, transparent)); }
.reg-fig-kpi:nth-child(3) b { background: linear-gradient(90deg, var(--rg-muted), color-mix(in srgb, var(--rg-muted) 30%, transparent)); }

.reg-fig-chart {
    display: block;
    width: 100%;
    height: 86px;
    border-radius: 10px;
    background: var(--rg-glass);
    box-shadow: inset 0 0 0 1px var(--rg-line);
}

.reg-fig-stop-a { stop-color: var(--rg-accent); stop-opacity: .35; }
.reg-fig-stop-b { stop-color: var(--rg-accent); stop-opacity: 0; }
.reg-fig-line   { stroke: var(--rg-accent); }
.reg-fig-line-2 { stroke: var(--rg-accent-2); stroke-opacity: .8; }

.reg-fig-line {
    stroke-dasharray: 420;
    stroke-dashoffset: 420;
    animation: rg-draw 2.4s var(--rg-ease) .4s forwards;
}

@keyframes rg-draw { to { stroke-dashoffset: 0; } }

.reg-fig-rows { display: grid; gap: 7px; }
.reg-fig-rows span { display: block; height: 7px; border-radius: 4px; background: var(--rg-line); }
.reg-fig-rows span:nth-child(2) { width: 82%; }
.reg-fig-rows span:nth-child(3) { width: 64%; }

.reg-fig-float {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 12px 9px 9px;
    border-radius: 12px;
    background: var(--rg-mock);
    box-shadow: inset 0 0 0 1px var(--rg-line-2), 0 20px 40px -16px var(--rg-shadow);
    animation: rg-float 6s ease-in-out infinite;
}

@supports (backdrop-filter: blur(1px)) {
    .reg-fig-float { backdrop-filter: blur(14px); }
}

.reg-fig-float i { width: 24px; height: 24px; border-radius: 8px; background: var(--rg-accent-soft); box-shadow: inset 0 0 0 1px var(--rg-accent-line); }
.reg-fig-float b { display: block; width: 64px; height: 7px; border-radius: 4px; background: var(--rg-line-2); }
.reg-fig-float--a { top: 0; right: 0; }
.reg-fig-float--b { bottom: 0; left: 46%; animation-delay: -3s; }
.reg-fig-float--b i { background: color-mix(in srgb, var(--rg-accent-2) 16%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--rg-accent-2) 45%, transparent); }

@keyframes rg-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ==========================================================================
   Right column
   ========================================================================== */
.reg-main {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.reg-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 44px;
    background: var(--rg-bar);
    box-shadow: inset 0 -1px 0 var(--rg-line);
}

@supports (backdrop-filter: blur(1px)) {
    .reg-topbar { backdrop-filter: saturate(170%) blur(18px); }
}

.reg-topbar-progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    overflow: hidden;
}

.reg-topbar-progress i {
    display: block;
    width: var(--reg-pct);
    height: 100%;
    background: var(--rg-grad);
    box-shadow: 0 0 14px var(--rg-accent-glow);
    transition: width .5s var(--rg-ease);
}

.reg-topbar-hint {
    margin-right: auto;
    font-size: 14px;
    letter-spacing: -.005em;
    color: var(--rg-muted);
}

.reg-topbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* The form takes the whole column; no centred measure leaving gutters empty. */
.reg-main-inner {
    width: 100%;
    margin: 0;
    padding: 40px clamp(24px, 3.4vw, 64px) 96px;
}

/* ==========================================================================
   Sections
   ========================================================================== */
.reg-section {
    position: relative;
    margin-bottom: 18px;
    padding: 34px 36px 16px;
    border-radius: var(--rg-r);
    background: linear-gradient(180deg, var(--rg-card-a), var(--rg-card-b));
    box-shadow: inset 0 0 0 1px var(--rg-line), 0 40px 80px -44px var(--rg-shadow);
    scroll-margin-top: 96px;
    animation: rg-rise .6s var(--rg-ease) both;
}

@supports (backdrop-filter: blur(1px)) {
    .reg-section { backdrop-filter: blur(14px); }
}

/* A lit edge along the top of the card. */
.reg-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 36px;
    right: 36px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--rg-accent-line), color-mix(in srgb, var(--rg-accent-2) 45%, transparent), transparent);
}

/* One section at a time once the wizard is running. */
.reg-section[hidden] { display: none !important; }

@keyframes rg-rise {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: none; }
}

.reg-section-head {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 28px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--rg-line);
}

.reg-section-num {
    flex: none;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(180deg, var(--rg-accent-soft), color-mix(in srgb, var(--rg-accent-2) 8%, transparent));
    box-shadow: inset 0 0 0 1px var(--rg-accent-line), 0 10px 24px -14px var(--rg-accent-glow);
    font-family: var(--rg-mono);
    font-size: 13px;
    font-weight: 600;
    color: var(--rg-accent);
}

.reg-section-head h2 {
    margin: 2px 0 6px;
    font-family: var(--rg-font);
    font-size: 26px;
    line-height: 1.15;
    font-weight: 700;
    letter-spacing: -.035em;
    color: var(--rg-heading);
}

.reg-section-head p {
    margin: 0;
    max-width: 62ch;
    font-size: 14.5px;
    line-height: 1.6;
    color: var(--rg-muted);
}

/* ==========================================================================
   Nature cards
   ========================================================================== */
.reg-nature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.reg-nature-card {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 0;
    padding: 18px;
    /* It is a `label`, so it must not inherit field-label styling. */
    text-transform: none;
    letter-spacing: normal;
    border-radius: var(--rg-r-sm);
    background: var(--rg-glass);
    box-shadow: inset 0 0 0 1px var(--rg-line);
    font-weight: 400;
    cursor: pointer;
    overflow: hidden;
    isolation: isolate;
    transition: box-shadow .3s var(--rg-ease), transform .3s var(--rg-ease), background .3s ease;
}

.reg-nature-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: 0;
    background: radial-gradient(120% 90% at 0% 0%, var(--rg-accent-soft), transparent 60%),
                radial-gradient(90% 90% at 100% 100%, color-mix(in srgb, var(--rg-accent-2) 12%, transparent), transparent 60%);
    transition: opacity .35s ease;
}

.reg-nature-card:hover {
    background: var(--rg-glass-2);
    box-shadow: inset 0 0 0 1px var(--rg-line-2);
    transform: translateY(-2px);
}

.reg-nature-card:active { transform: translateY(0); }

/* The radio still carries the value and the required rule; it just is not
   what the reader clicks. */
.reg-nature-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}

.reg-nature-card.is-on {
    box-shadow: inset 0 0 0 1.5px var(--rg-accent-line), 0 18px 40px -22px var(--rg-accent-glow);
}

.reg-nature-card.is-on::before { opacity: 1; }

/* Keyboard users get the same ring the mouse users see. */
.reg-nature-card input[type="radio"]:focus-visible + .reg-nature-text {
    outline: 2px solid var(--rg-accent);
    outline-offset: 4px;
    border-radius: 5px;
}

.reg-nature-text {
    flex: 1 1 auto;
    min-width: 0;
    display: block;
}

.reg-nature-name {
    display: flex;
    align-items: center;
    gap: 11px;
    font-size: 15.5px;
    font-weight: 600;
    letter-spacing: -.015em;
    color: var(--rg-heading);
}

.reg-nature-ico {
    flex: none;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: var(--rg-accent-soft);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
    font-size: 14px;
    color: var(--rg-accent);
    transition: background .3s ease, color .3s ease, box-shadow .3s ease;
}

.reg-nature-card.is-on .reg-nature-ico {
    background: var(--rg-grad);
    box-shadow: 0 8px 20px -8px var(--rg-accent-glow);
    color: var(--rg-on-accent);
}

.reg-nature-blurb {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.5;
    color: var(--rg-muted);
}

.reg-nature-tick {
    flex: none;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--rg-accent);
    color: var(--rg-on-accent);
    font-size: 10px;
    opacity: 0;
    transform: scale(.5);
    box-shadow: 0 0 16px var(--rg-accent-glow);
    transition: opacity .2s ease, transform .3s cubic-bezier(.3, 1.5, .5, 1);
}

.reg-nature-card.is-on .reg-nature-tick { opacity: 1; transform: scale(1); }

/* --- what gets configured -------------------------------------------------- */
.reg-nature-side {
    margin-bottom: 22px;
    padding: 18px 20px;
    border-radius: var(--rg-r-sm);
    background: color-mix(in srgb, var(--rg-bg) 60%, transparent);
    box-shadow: inset 0 0 0 1px var(--rg-line);
}

.reg-nature-side h5 {
    margin: 0 0 14px;
    font-family: var(--rg-mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--rg-accent);
}

.reg-nature-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.reg-nature-list.is-hidden { display: none; }

.reg-nature-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--rg-accent-soft);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--rg-accent) 25%, transparent);
    font-size: 13px;
    color: var(--rg-ink-2);
    animation: rg-chip .45s var(--rg-ease) both;
}

.reg-nature-list li:nth-child(2) { animation-delay: .05s; }
.reg-nature-list li:nth-child(3) { animation-delay: .1s; }
.reg-nature-list li:nth-child(4) { animation-delay: .15s; }
.reg-nature-list li:nth-child(5) { animation-delay: .2s; }

@keyframes rg-chip { from { opacity: 0; transform: translateY(6px); } }

.reg-nature-list li .fa-check {
    font-size: 9px;
    color: var(--rg-accent);
}

.reg-nature-note {
    margin: 14px 0 0;
    font-size: 13px;
    color: var(--rg-faint);
}

/* ==========================================================================
   Fields

   The partial emits Bootstrap input-groups; the addon is lifted out of the
   flow and floated inside the field as a plain icon.
   ========================================================================== */
.reg-section .row { margin-left: -9px; margin-right: -9px; }
.reg-section [class*="col-md-"] { padding-left: 9px; padding-right: 9px; }

.reg-section .form-group { margin-bottom: 22px; }

/* Scoped to the field label specifically; a nature card is itself a `label`. */
.reg-section .form-group > label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: -.004em;
    color: var(--rg-ink-2);
}

.reg-section .form-group .fa-info-circle { color: var(--rg-faint) !important; }

/* Bootstrap floats `.input-group .form-control`; flex gives the wrapper a real
   height so the absolute icon has a box to centre against. */
.reg-section .input-group {
    position: relative;
    display: flex;
    align-items: stretch;
    width: 100%;
}

.reg-section .input-group > .form-control,
.reg-section .input-group > .select2-container {
    float: none;
    flex: 1 1 auto;
    min-width: 0;
}

.reg-section .input-group-addon {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 3;
    width: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: none;
    border: 0;
    border-radius: 0;
    font-size: 13px;
    color: var(--rg-faint);
    pointer-events: none;
    transition: color .2s ease;
}

.reg-section .form-control {
    display: block;
    width: 100%;
    height: 52px;
    padding: 8px 16px;
    background: var(--rg-field);
    border: 0;
    border-radius: var(--rg-r-xs);
    box-shadow: inset 0 0 0 1px var(--rg-line-2);
    font-family: var(--rg-font);
    font-size: 15px;
    font-weight: 500;
    letter-spacing: -.008em;
    color: var(--rg-ink);
    transition: box-shadow .2s ease, background .2s ease;
}

/* Bootstrap squares off the side of a control that meets its addon, with
   more specificity than a plain class rule. */
.reg-section .input-group > .form-control:first-child,
.reg-section .input-group > .form-control:last-child {
    padding-left: 46px;
    border-radius: var(--rg-r-xs);
}

.reg-section .form-control::placeholder {
    color: var(--rg-faint);
    font-weight: 400;
}

.reg-section .form-control:hover {
    background: var(--rg-field-hover);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
}

.reg-section .form-control:focus {
    background: var(--rg-field-hover);
    box-shadow: inset 0 0 0 1px var(--rg-accent), var(--rg-ring);
    outline: none;
}

/* Bootstrap greys readonly fields; the start date is readonly only so the
   picker owns it. */
.reg-section .form-control[readonly] {
    background: var(--rg-field);
    cursor: pointer;
}

/* The icon lights up with the field it belongs to. */
.reg-section .input-group:focus-within .input-group-addon { color: var(--rg-accent); }

/* File input: a drop-zone rather than a bare browser control. */
.reg-section input[type="file"] {
    display: block;
    width: 100%;
    padding: 12px 14px;
    background: var(--rg-glass);
    border: 1.5px dashed var(--rg-line-2);
    border-radius: var(--rg-r-xs);
    font-size: 13px;
    color: var(--rg-muted);
    cursor: pointer;
    transition: border-color .2s ease, background .2s ease;
}

.reg-section input[type="file"]::file-selector-button {
    margin-right: 12px;
    padding: 7px 14px;
    border: 0;
    border-radius: 999px;
    background: var(--rg-accent-soft);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
    font-family: var(--rg-font);
    font-size: 13px;
    font-weight: 600;
    color: var(--rg-heading);
    cursor: pointer;
}

.reg-section input[type="file"]:hover {
    border-color: var(--rg-accent-line);
    background: var(--rg-accent-soft);
}

.reg-section .text-danger { font-size: 12.5px; color: var(--rg-danger); }
.reg-section .help-block { font-size: 12.5px; color: var(--rg-muted); }

/* Checkbox rows read as one line, not a stack. */
.reg-section .input-check-box {
    width: 17px;
    height: 17px;
    margin-right: 10px;
    vertical-align: -3px;
    accent-color: var(--rg-accent);
}

.reg-section .form-group > label:has(> .input-check-box) {
    font-size: 14px;
    font-weight: 500;
    color: var(--rg-ink-2);
}

.reg-shell .reg-section a.terms_condition,
.reg-shell .reg-section a.terms_condition:hover {
    font-size: 14px;
    font-weight: 600;
    color: var(--rg-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1.5px;
}

/* --- Select2, on currency / timezone / month / method ---------------------- */
.reg-section .select2-container { width: 100% !important; }

.reg-section .select2-container .select2-selection--single {
    height: 52px;
    background: var(--rg-field);
    border: 0;
    border-radius: var(--rg-r-xs);
    box-shadow: inset 0 0 0 1px var(--rg-line-2);
    transition: box-shadow .2s ease, background .2s ease;
}

.reg-section .select2-container .select2-selection--single:hover {
    background: var(--rg-field-hover);
    box-shadow: inset 0 0 0 1px var(--rg-accent-line);
}

.reg-section .input-group .select2-container .select2-selection--single .select2-selection__rendered {
    padding-left: 46px;
}

.reg-section .select2-container .select2-selection--single .select2-selection__rendered {
    line-height: 52px;
    padding-left: 16px;
    padding-right: 32px;
    font-size: 15px;
    font-weight: 500;
    color: var(--rg-ink);
}

.reg-section .select2-container .select2-selection--single .select2-selection__placeholder { color: var(--rg-faint); }
.reg-section .select2-container .select2-selection--single .select2-selection__arrow { height: 50px; right: 10px; }
.reg-section .select2-container .select2-selection--single .select2-selection__arrow b { border-top-color: var(--rg-muted); }
.reg-section .select2-container--open .select2-selection--single .select2-selection__arrow b { border-bottom-color: var(--rg-accent); }

.reg-section .select2-container--focus .select2-selection--single,
.reg-section .select2-container--open .select2-selection--single {
    background: var(--rg-field-hover);
    box-shadow: inset 0 0 0 1px var(--rg-accent), var(--rg-ring);
}

/* The dropdown is appended to <body>, outside the section. */
body.reg-page .select2-dropdown {
    background: var(--rg-pop);
    border: 0;
    border-radius: 14px !important;
    box-shadow: inset 0 0 0 1px var(--rg-line-2), 0 30px 60px -20px var(--rg-shadow);
    overflow: hidden;
    color: var(--rg-ink-2);
    font-family: var(--rg-font);
}

body.reg-page .select2-container--open .select2-dropdown--below { margin-top: 6px; }
body.reg-page .select2-container--open .select2-dropdown--above { margin-top: -6px; }

body.reg-page .select2-search--dropdown { padding: 10px; }

body.reg-page .select2-search--dropdown .select2-search__field {
    height: 40px;
    padding: 6px 12px;
    background: var(--rg-field);
    border: 0;
    border-radius: 10px;
    box-shadow: inset 0 0 0 1px var(--rg-line-2);
    color: var(--rg-ink);
    outline: none;
}

body.reg-page .select2-search--dropdown .select2-search__field:focus {
    box-shadow: inset 0 0 0 1px var(--rg-accent);
}

body.reg-page .select2-results__options { padding: 0 6px 6px; }

body.reg-page .select2-results__option {
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--rg-ink-2);
}

body.reg-page .select2-container--default .select2-results__option[aria-selected="true"] {
    background: var(--rg-glass-2);
    color: var(--rg-heading);
}

body.reg-page .select2-container--default .select2-results__option--highlighted[aria-selected] {
    background: var(--rg-accent-soft);
    color: var(--rg-heading);
}

/* --- Date picker, also appended to <body> ---------------------------------- */
body.reg-page .datepicker.dropdown-menu {
    padding: 10px;
    background: var(--rg-pop);
    border: 0;
    border-radius: 14px;
    box-shadow: inset 0 0 0 1px var(--rg-line-2), 0 30px 60px -20px var(--rg-shadow);
    color: var(--rg-ink-2);
    font-family: var(--rg-font);
}

body.reg-page .datepicker.dropdown-menu::before,
body.reg-page .datepicker.dropdown-menu::after { display: none; }

body.reg-page .datepicker table tr td,
body.reg-page .datepicker table tr th { border-radius: 8px; color: var(--rg-ink-2); }

body.reg-page .datepicker table tr td.old,
body.reg-page .datepicker table tr td.new { color: var(--rg-faint); }

body.reg-page .datepicker table tr td.day:hover,
body.reg-page .datepicker table tr td.focused,
body.reg-page .datepicker table tr td span:hover,
body.reg-page .datepicker .datepicker-switch:hover,
body.reg-page .datepicker .prev:hover,
body.reg-page .datepicker .next:hover,
body.reg-page .datepicker tfoot tr th:hover { background: var(--rg-glass-2); color: var(--rg-heading); }

body.reg-page .datepicker table tr td.today { background: color-mix(in srgb, var(--rg-accent-2) 20%, transparent); color: var(--rg-heading); }

body.reg-page .datepicker table tr td.active,
body.reg-page .datepicker table tr td.active:hover,
body.reg-page .datepicker table tr td span.active,
body.reg-page .datepicker table tr td span.active:hover {
    background: var(--rg-accent) !important;
    background-image: none !important;
    color: var(--rg-on-accent) !important;
    text-shadow: none;
}

/* --- jQuery validate ------------------------------------------------------- */
.reg-section .form-control.error,
.reg-section input.error {
    box-shadow: inset 0 0 0 1px var(--rg-danger), 0 0 0 4px color-mix(in srgb, var(--rg-danger) 14%, transparent);
}

.reg-section label.error {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 7px;
    font-size: 12.5px;
    font-weight: 500;
    letter-spacing: -.005em;
    text-transform: none;
    color: var(--rg-danger);
}

/* ==========================================================================
   Submit bar
   ========================================================================== */
.reg-submit {
    position: sticky;
    bottom: 16px;
    z-index: 15;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 18px;
    margin-top: 6px;
    padding: 16px 18px;
    border-radius: 999px;
    background: var(--rg-mock);
    box-shadow: inset 0 0 0 1px var(--rg-line-2), 0 30px 60px -28px var(--rg-shadow);
    animation: rg-rise .6s var(--rg-ease) .2s both;
}

@supports (backdrop-filter: blur(1px)) {
    .reg-submit { backdrop-filter: saturate(170%) blur(18px); }
}

.reg-submit [hidden] { display: none !important; }

.reg-btn-go#reg_finish:hover svg { transform: none; }

.reg-progress {
    font-family: var(--rg-mono);
    font-size: 12.5px;
    font-weight: 500;
    letter-spacing: .02em;
    color: var(--rg-muted);
    font-variant-numeric: tabular-nums;
}

.reg-submit-note {
    margin-left: auto;
    padding-right: 10px;
    font-size: 14px;
    letter-spacing: -.005em;
    color: var(--rg-muted);
}

.reg-shell .reg-submit-note a,
.reg-shell .reg-submit-note a:hover {
    font-size: 14px;
    font-weight: 600;
    color: var(--rg-accent);
    text-decoration: none;
}

/* ==========================================================================
   Wide screens — use the width

   From 1440px each section splits in two: its heading sits in a column on the
   left and the fields fill the right. From 1860px the half-width fields go
   three across. Only the sections' own children are placed, so the
   partials' markup is untouched.

   Three across waits until 1860px: below that the field column is under
   ~900px and a select with its icon gets too cramped at a third of it.
   ========================================================================== */
@media (min-width: 1440px) {
    .reg-section {
        display: grid;
        grid-template-columns: clamp(240px, 19vw, 320px) minmax(0, 1fr);
        grid-auto-rows: min-content;
        column-gap: clamp(36px, 3.4vw, 64px);
        padding: 40px 44px 20px;
    }

    .reg-section::before { left: 44px; right: 44px; }

    .reg-section > .reg-section-head {
        grid-column: 1;
        grid-row: 1 / span 3;
        align-self: stretch;
        flex-direction: column;
        gap: 18px;
        margin: 0 0 20px;
        padding: 0 clamp(36px, 3.4vw, 64px) 0 0;
        border-bottom: 0;
        box-shadow: 1px 0 0 var(--rg-line);
    }

    .reg-section > .reg-section-head h2 { font-size: clamp(26px, 1.9vw, 32px); }

    .reg-section > :not(.reg-section-head) { grid-column: 2; }

    .reg-nature-grid { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}

@media (min-width: 1860px) {
    .reg-section .row > .col-md-6 { width: 33.33333%; }
}

/* ==========================================================================
   Narrow screens — the rail becomes a header
   ========================================================================== */
@media (max-width: 1100px) {
    .reg-submit-note { display: none; }
}

@media (max-width: 991px) {
    .reg-shell { display: block; min-height: 0; }

    .reg-aside { flex: none; width: auto; box-shadow: inset 0 -1px 0 var(--rg-line); }

    .reg-aside-inner {
        position: static;
        min-height: 0;
        gap: 18px;
        padding: 28px 22px 30px;
    }

    .reg-aside-copy h1 { font-size: 32px; }
    .reg-aside-copy p { max-width: none; font-size: 15px; }

    /* Both repeat what is about to be read anyway; on a phone that is a
       screenful of nothing before the first field. */
    .reg-steps-wrap,
    .reg-trust,
    .reg-figure { display: none; }

    .reg-topbar { padding: 12px 18px; }
    .reg-topbar-hint { display: none; }
    .reg-main-inner { padding: 22px 16px 60px; }
    .reg-section { padding: 26px 20px 8px; border-radius: 18px; }
    .reg-section::before { left: 20px; right: 20px; }
    .reg-section-head { gap: 12px; margin-bottom: 22px; padding-bottom: 18px; }
    .reg-section-head h2 { font-size: 21px; }
    .reg-section-num { width: 38px; height: 38px; border-radius: 12px; }
    .reg-nature-grid { grid-template-columns: 1fr; }
    .reg-submit { bottom: 10px; border-radius: 22px; }
}

@media (max-width: 560px) {
    .reg-submit { padding: 12px; }
    .reg-submit button { flex: 1 1 auto; justify-content: center; }
    .reg-progress { width: 100%; text-align: center; order: -1; }
    .reg-section .row { margin-left: 0; margin-right: 0; }
    .reg-section [class*="col-md-"] { padding-left: 0; padding-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .reg-figure-card,
    .reg-fig-float,
    .reg-nature-list li,
    .reg-section,
    .reg-submit { animation: none !important; }

    .reg-fig-line { stroke-dashoffset: 0; animation: none; }

    .reg-nature-card,
    .reg-nature-tick,
    .reg-nature-ico,
    .reg-step,
    .reg-step-num,
    .reg-steps::after,
    .reg-topbar-progress i { transition: none !important; }

    .reg-nature-card:hover { transform: none; }
}
