
/* ========================================
   Registration pages
   Palette: Deep navy, royal blue, orange
======================================== */

.register-page {
    --form-bg: #111144;
    --form-bg-secondary: #171B59;
    --form-card: #1B245F;
    --form-card-light: #223382;
    --form-blue: #9BACD8;
    --form-orange: #F98513;
    --form-white: #F4F1EC;
    --form-muted: rgba(244, 241, 236, 0.65);

    position: relative;
    min-height: 100vh;
    min-height: 100svh;

    padding: 40px 20px;

    overflow-x: hidden;
    isolation: isolate;

    background:
        radial-gradient(
            ellipse at 15% 15%,
            rgba(249, 133, 19, 0.08),
            transparent 35%
        ),
        radial-gradient(
            ellipse at 85% 80%,
            rgba(34, 51, 130, 0.35),
            transparent 40%
        ),
        linear-gradient(
            145deg,
            #111144,
            #171B59 55%,
            #111144
        );

    color: var(--form-white);
}

/* Animated background layers */

.register-page::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;

    pointer-events: none;

    background-image:
        linear-gradient(
            rgba(155, 172, 216, 0.025) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(155, 172, 216, 0.025) 1px,
            transparent 1px
        );

    background-size: 76px 76px;

    mask-image: linear-gradient(
        to bottom,
        black,
        transparent 90%
    );
}

.register-page::after {
    content: "";
    position: fixed;
    z-index: -2;

    width: 440px;
    height: 440px;

    top: -160px;
    right: -140px;

    border-radius: 50%;

    background: radial-gradient(circle, rgba(249, 133, 19, 0.12) 0%, transparent 70%);

    pointer-events: none;
}

/* Background decoration */

.register-container {
    position: relative;
    z-index: 1;

    width: 100%;
    max-width: 720px;

    margin: 0 auto;
}

.register-container::before,
.register-container::after {
    content: "";
    position: fixed;
    z-index: -1;

    border-radius: 50%;
    pointer-events: none;

    border: 1px solid rgba(155, 172, 216, 0.10);
}

.register-container::before {
    width: 420px;
    height: 420px;

    top: 12%;
    left: -220px;

    animation: register-shape-one 32s ease-in-out infinite alternate;
}

.register-container::after {
    width: 560px;
    height: 560px;

    bottom: -280px;
    right: -250px;

    border-color: rgba(249, 133, 19, 0.10);

    animation: register-shape-two 36s ease-in-out infinite alternate;
}

/* Back link */

.register-back {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    margin-bottom: 24px;

    color: var(--form-blue);
    text-decoration: none;
    font-size: 14px;

    opacity: 0.8;

    transition:
        opacity 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.register-back::before {
    content: "→";
    font-size: 18px;
}

.register-back:hover {
    opacity: 1;
    color: var(--form-white);
    transform: translateX(3px);
}

/* Main form card */

.register-card {
    position: relative;
    overflow: hidden;

    padding: 40px;

    border: 1px solid rgba(155, 172, 216, 0.15);
    border-radius: 24px;

    background: linear-gradient(
        145deg,
        rgba(27, 36, 95, 0.92),
        rgba(17, 17, 68, 0.94)
    );

    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.22),
        inset 0 1px 0 rgba(244, 241, 236, 0.035);

    animation: register-card-appear 0.65s ease both;
}

.register-card::before {
    content: "";
    position: absolute;

    top: 0;
    right: 40px;
    left: 40px;

    height: 1px;

    background: linear-gradient(
        90deg,
        transparent,
        rgba(249, 133, 19, 0.65),
        rgba(155, 172, 216, 0.35),
        transparent
    );

    pointer-events: none;
}

/* Heading */

.register-heading {
    margin-bottom: 34px;
}

.register-label {
    display: inline-flex;
    align-items: center;
    gap: 9px;

    margin-bottom: 16px;

    color: var(--form-orange);
    font-size: 13px;
    font-weight: 600;
}

.register-label::before {
    content: "";
    width: 6px;
    height: 6px;

    border-radius: 50%;
    background: var(--form-orange);

    box-shadow: 0 0 12px rgba(249, 133, 19, 0.45);
}

.register-heading h1 {
    margin-bottom: 12px;

    color: var(--form-white);

    font-size: 28px;
    font-weight: 800;
    line-height: 1.6;
}

.register-heading p {
    color: var(--form-muted);
    font-size: 14px;
    line-height: 2;
}

/* Progress */

.progress-section {
    margin-bottom: 34px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;

    margin-bottom: 14px;

    color: var(--form-muted);
    font-size: 13px;
}

.progress-info span:last-child {
    color: var(--form-blue);
}

.progress-track {
    position: relative;

    height: 5px;
    overflow: hidden;

    border-radius: 20px;

    background: rgba(155, 172, 216, 0.12);
}

.progress-fill {
    width: 100%;
    height: 100%;

    border-radius: inherit;

    background: linear-gradient(
        90deg,
        var(--form-orange),
        #ffb45d
    );

    box-shadow: 0 0 14px rgba(249, 133, 19, 0.25);

    transition: width 0.4s ease;
}

/* Form layout */

.register-form {
    display: flex;
    flex-direction: column;
    gap: 26px;
}

.form-step {
    animation: register-step-in 0.3s ease;
}

.form-step[hidden] {
    display: none !important;
}

.form-step label {
    display: block;

    margin-bottom: 12px;

    color: var(--form-white);
    font-size: 15px;
    font-weight: 600;
}

/* Inputs */

.form-step input,
.form-step select {
    width: 100%;
    min-height: 56px;

    padding: 14px 16px;

    border: 1px solid rgba(155, 172, 216, 0.18);
    border-radius: 12px;

    outline: none;

    background: rgba(17, 17, 68, 0.72);
    color: var(--form-white);

    font-family: inherit;
    font-size: 15px;

    transition:
        border-color 0.22s ease,
        box-shadow 0.22s ease,
        background 0.22s ease;
}

.form-step input::placeholder {
    color: rgba(244, 241, 236, 0.38);
}

.form-step input:hover,
.form-step select:hover {
    border-color: rgba(155, 172, 216, 0.35);
}

.form-step input:focus,
.form-step select:focus {
    border-color: var(--form-orange);

    background: rgba(17, 17, 68, 0.95);

    box-shadow:
        0 0 0 3px rgba(249, 133, 19, 0.09),
        0 8px 24px rgba(0, 0, 0, 0.08);
}

.form-step select option {
    background: #171B59;
    color: var(--form-white);
}

/* File input */

.form-step input[type="file"] {
    padding: 10px;

    cursor: pointer;

    color: var(--form-muted);
    font-size: 13px;
}

.form-step input[type="file"]::file-selector-button {
    margin-left: 12px;

    padding: 9px 14px;

    border: 1px solid rgba(155, 172, 216, 0.2);
    border-radius: 8px;

    background: var(--form-card-light);
    color: var(--form-white);

    font-family: inherit;
    font-size: 13px;

    cursor: pointer;

    transition:
        background 0.2s ease,
        border-color 0.2s ease;
}

.form-step input[type="file"]::file-selector-button:hover {
    background: #2b408f;
    border-color: rgba(249, 133, 19, 0.4);
}

/* Hints and file name */

.form-hint {
    margin-top: 10px;

    color: var(--form-muted);
    font-size: 13px;
    line-height: 1.9;
}

.file-name {
    margin-top: 12px;

    color: var(--form-blue);
    font-size: 13px;

    overflow-wrap: anywhere;
}

/* Form actions */

.form-actions {
    display: flex;
    gap: 12px;

    width: 100%;
}

.form-actions button {
    flex: 1;

    min-height: 56px;

    border-radius: 12px;

    font-family: inherit;
    font-size: 15px;
    font-weight: 700;

    cursor: pointer;

    transition:
        transform 0.22s ease,
        background 0.22s ease,
        border-color 0.22s ease,
        box-shadow 0.22s ease,
        opacity 0.22s ease;
}

/* Next button */

.register-next {
    border: 1px solid rgba(244, 241, 236, 0.18);

    background: var(--form-orange);
    color: #111144;

    box-shadow:
        0 10px 28px rgba(249, 133, 19, 0.13),
        inset 0 1px 0 rgba(244, 241, 236, 0.22);
}

.register-next:hover {
    transform: translateY(-2px);

    background: #ff941f;

    box-shadow:
        0 14px 34px rgba(249, 133, 19, 0.2),
        inset 0 1px 0 rgba(244, 241, 236, 0.25);
}

.register-next:active {
    transform: translateY(0) scale(0.99);
}

.register-next:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Previous button */

.register-previous {
    padding: 12px 20px;

    border: 1px solid rgba(155, 172, 216, 0.2);

    background: rgba(34, 51, 130, 0.35);
    color: var(--form-blue);
}

.register-previous:hover {
    background: rgba(34, 51, 130, 0.65);
    border-color: rgba(155, 172, 216, 0.35);
}

/* Error and success messages */

.form-error {
    color: #ff9b9b;
    font-size: 14px;
    line-height: 1.9;
}

.form-success {
    color: #9fe0bb;
    font-size: 14px;
    line-height: 1.9;
}

/* Step animation */

@keyframes register-step-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes register-card-appear {
    from {
        opacity: 0;
        transform: translateY(16px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes register-glow-orange {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(-100px, 130px) scale(1.15);
    }
}

@keyframes register-shape-one {
    from {
        transform: translate(0, 0) rotate(0deg);
    }

    to {
        transform: translate(50px, 60px) rotate(10deg);
    }
}

@keyframes register-shape-two {
    from {
        transform: translate(0, 0) rotate(0deg);
    }

    to {
        transform: translate(-45px, -40px) rotate(-8deg);
    }
}

/* Success page */

.success-card {
    text-align: center;
}

.success-icon {
    width: 72px;
    height: 72px;

    display: grid;
    place-items: center;

    margin: 0 auto 24px;

    border-radius: 50%;

    background: rgba(155, 172, 216, 0.12);
    border: 1px solid rgba(155, 172, 216, 0.18);

    color: var(--form-blue);
    font-size: 36px;
}

.success-card h1 {
    margin: 16px 0;

    color: var(--form-white);
}

.success-card p {
    color: var(--form-muted);
    line-height: 1.9;
}

.success-home {
    display: flex;
    align-items: center;
    justify-content: center;

    margin-top: 28px;

    text-decoration: none;
}

/* QR ticket */

.ticket-qr {
    display: flex;
    justify-content: center;
    align-items: center;

    width: fit-content;

    margin: 28px auto;
    padding: 16px;

    border-radius: 16px;

    background: #ffffff;

    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.18);
}

.ticket-qr img {
    display: block;

    width: 240px;
    height: 240px;
    max-width: 100%;

    object-fit: contain;
}

.ticket-code {
    direction: ltr;

    font-family: monospace;
    font-size: 14px;
    letter-spacing: 1px;
}

.ticket-instruction {
    max-width: 420px;

    margin: 16px auto;

    line-height: 2;
}

.success-back {
    display: inline-block;

    margin-top: 20px;

    color: var(--form-blue);
    text-decoration: none;
}

/* Tablet */

@media (max-width: 600px) {
    .register-page {
        padding: 28px 16px;
    }

    .register-card {
        padding: 30px 22px;
        border-radius: 20px;
    }

    .register-heading h1 {
        font-size: 24px;
    }

    .progress-section {
        margin-bottom: 28px;
    }
}

/* Mobile */

@media (max-width: 480px) {
    .register-page {
        padding: 22px 12px;
    }

    .register-card {
        padding: 28px 18px;
        border-radius: 18px;
    }

    .register-heading h1 {
        font-size: 22px;
    }

    .register-heading p {
        font-size: 13px;
    }

    .progress-info {
        font-size: 12px;
    }

    .form-step input,
    .form-step select {
        min-height: 54px;
        font-size: 14px;
    }

    .form-actions {
        flex-direction: column-reverse;
    }

    .form-actions button {
        width: 100%;
        min-height: 54px;
    }

    .register-page::after {
        width: 300px;
        height: 300px;
    }

    .register-container::before {
        width: 280px;
        height: 280px;
    }

    .register-container::after {
        width: 360px;
        height: 360px;
    }
}

@media (max-width: 400px) {
    .ticket-qr {
        padding: 10px;
    }

    .ticket-qr img {
        width: 210px;
        height: 210px;
    }
}

/* Accessibility */

@media (prefers-reduced-motion: reduce) {
    .register-page *,
    .register-page *::before,
    .register-page *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}



/* Progress steps */
.progress-track {
    position: relative;
    height: 16px;
    width: 100%;
    overflow: visible;
    border-radius: 999px;
    background: #10143f;
    margin: 24px 0 34px;
    direction: rtl;
}

.progress-fill {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 0;
    border-radius: 999px;
    background: linear-gradient(
        90deg,
        #ff9b35,
        #f98513
    );
    transition: width 0.45s ease;
    z-index: 1;
}

/* Container of numbered circles */
.progress-steps {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    direction: rtl;
    z-index: 2;
}

/* Each numbered circle */
.progress-step {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;
    background: #171b59;
    border: 3px solid #394783;

    color: #b8c4e8;
    font-size: 15px;
    font-weight: 700;

    transition:
        background 0.3s ease,
        border-color 0.3s ease,
        color 0.3s ease,
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

/* Current step */
.progress-step.active {
    background: #f98513;
    border-color: #ffb15c;
    color: #111144;
    transform: scale(1.12);
    box-shadow: 0 0 0 5px rgba(249, 133, 19, 0.15);
}

/* Completed steps */
.progress-step.completed {
    background: #f98513;
    border-color: #f98513;
    color: #111144;
}

/* Mobile */
@media (max-width: 480px) {
    .progress-track {
        height: 12px;
        margin: 22px 0 30px;
    }

    .progress-step {
        width: 30px;
        height: 30px;
        border-width: 2px;
        font-size: 12px;
    }

    .progress-step.active {
        box-shadow: 0 0 0 4px rgba(249, 133, 19, 0.15);
    }
}




/* QR download button */
.success-home {
    display: block;
    width: 100%;
    max-width: 360px;
    margin: 16px auto 0;
    padding: 16px 24px;
    border-radius: 16px !important;
    overflow: hidden;
    text-align: center;
}



/* Smooth focus effect for form fields */
.form-step input,
.form-step select {
    transition:
        border-color 0.45s ease,
        box-shadow 0.45s ease,
        background-color 0.45s ease;
}

/* Focused input */
.form-step input:focus,
.form-step select:focus {
    border-color: rgba(249, 133, 19, 0.85);

    background-color: rgba(34, 51, 130, 0.55);

    box-shadow:
        0 0 0 3px rgba(249, 133, 19, 0.08),
        0 0 22px rgba(155, 172, 216, 0.10);
}

/* Keyboard focus */
.form-step input:focus-visible,
.form-step select:focus-visible {
    outline: 2px solid rgba(155, 172, 216, 0.65);
    outline-offset: 3px;
}

/* File input focus */
.form-step input[type="file"]:focus {
    box-shadow:
        0 0 0 3px rgba(249, 133, 19, 0.10),
        0 0 20px rgba(249, 133, 19, 0.12);
}



/* Smooth interaction for registration buttons */
.register-next,
.register-previous {
    position: relative;
    overflow: hidden;


    transition:
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.8s ease,
    background-color 0.8s ease,
    border-color 0.8s ease;    
}

/* Next button hover */
.register-next:hover:not(:disabled) {
    transform: translateY(-3px);

    box-shadow:
        0 10px 28px rgba(249, 133, 19, 0.22),
        0 0 18px rgba(249, 133, 19, 0.10);
}

/* Previous button hover */
.register-previous:hover:not(:disabled) {
    transform: translateY(-2px);

    box-shadow:
        0 8px 22px rgba(155, 172, 216, 0.12);
}

/* Press effect */
.register-next:active:not(:disabled),
.register-previous:active:not(:disabled) {
    transform: translateY(0) scale(0.99);
}

/* Disabled state */
.register-next:disabled {
    cursor: wait;
    opacity: 0.75;
}

/* Keyboard focus */
.register-next:focus-visible,
.register-previous:focus-visible {
    outline: 2px solid rgba(155, 172, 216, 0.75);
    outline-offset: 4px;
}



/* Hover effect for progress steps */
.progress-step {
    transition:
        transform 0.8s cubic-bezier(0.22, 1, 0.36, 1),
        box-shadow 0.8s ease,
        background-color 0.8s ease;
}

.progress-step:hover {
    transform: scale(1.06);
    box-shadow: 0 0 16px rgba(249, 133, 19, 0.18);
}

/* Keep the current step's glow subtle */
.progress-step.active:hover {
    box-shadow: 0 0 20px rgba(249, 133, 19, 0.28);
}

@media (prefers-reduced-motion: reduce) {
    .progress-step {
        transition: none;
    }

    .progress-step:hover {
        transform: none;
    }
}



/* Subtle registration card glow */
.register-container {
    position: relative;
    isolation: isolate;
}

.register-container::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: linear-gradient(
        135deg,
        rgba(249, 133, 19, 0.12),
        transparent 35%,
        rgba(155, 172, 216, 0.10) 70%,
        transparent
    );
    opacity: 0.6;
    pointer-events: none;
    z-index: -1;
    animation: register-card-glow 5s ease-in-out infinite alternate;
}

@keyframes register-card-glow {
    from {
        opacity: 0.35;
    }

    to {
        opacity: 0.75;
    }
}

@media (prefers-reduced-motion: reduce) {
    .register-container::before {
        animation: none;
    }
}



/* Floating background particles */
.background-particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.background-particles span {
    position: absolute;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #9BACD8;
    box-shadow: 0 0 8px rgba(155, 172, 216, 0.6);
    animation: particle-float 3s ease-in-out infinite alternate;
}

/* Particle positions and colors */
.background-particles span:nth-child(1) {
    left: 8%;
    top: 15%;
}

.background-particles span:nth-child(2) {
    left: 22%;
    top: 65%;
    background: #F98513;
    box-shadow: 0 0 8px rgba(249, 133, 19, 0.6);
    animation-delay: -3s;
}

.background-particles span:nth-child(3) {
    left: 38%;
    top: 30%;
    animation-delay: -6s;
}

.background-particles span:nth-child(4) {
    left: 55%;
    top: 80%;
    background: #F98513;
    box-shadow: 0 0 8px rgba(249, 133, 19, 0.6);
    animation-delay: -9s;
}

.background-particles span:nth-child(5) {
    left: 68%;
    top: 20%;
    animation-delay: -4s;
}

.background-particles span:nth-child(6) {
    left: 79%;
    top: 55%;
    background: #F98513;
    box-shadow: 0 0 8px rgba(249, 133, 19, 0.6);
    animation-delay: -7s;
}

.background-particles span:nth-child(7) {
    left: 91%;
    top: 35%;
    animation-delay: -2s;
}

.background-particles span:nth-child(8) {
    left: 96%;
    top: 85%;
    background: #F98513;
    box-shadow: 0 0 8px rgba(249, 133, 19, 0.6);
    animation-delay: -11s;
}


@keyframes particle-float {
    from {
        transform: translateY(-20px);
    }

    to {
        transform: translateY(20px);
    }
}


/* Keep the registration form above the particles */
.register-container {
    position: relative;
    z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
    .background-particles span {
        animation: none;
    }
}

/* Performance: drop decorative motion on touch & small screens */
@media (max-width: 600px), (prefers-reduced-motion: reduce) {
    .register-container::before,
    .register-container::after,
    .background-particles span {
        animation: none !important;
    }
}



