:root {
    --sg-red: #E8892C;
    --sg-red-dark: #c96f1a;
    --sg-navy: #5c3a15;
    --bg-soft: #fff8ec;
    --input-bg: #fef3df;
}

* {
    font-family: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
}

body {
    margin: 0;
    background: var(--bg-soft);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

.bg-shapes {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
}

.shape {
    position: absolute;
    border-radius: 50%;
    opacity: .12;
}

.shape-1 {
    width: 500px;
    height: 500px;
    background: var(--sg-red);
    top: -180px;
    right: -150px;
}

.shape-2 {
    width: 400px;
    height: 400px;
    background: var(--sg-navy);
    bottom: -150px;
    left: -120px;
}

.brand-title {
    font-weight: 800;
    color: var(--sg-navy);
    letter-spacing: -.5px;
    margin-bottom: 2px;
}

.brand-subtitle {
    color: #8a6a3f;
    font-size: .9rem;
}

.top-slider {
    display: block;
    width: 100%;
    margin: 0;
    box-shadow: 0 6px 24px rgba(20, 30, 60, .12);
}

.top-slider .carousel-inner,
.top-slider .carousel-item {
    width: 100%;
}

.top-slider .carousel-item img {
    display: block;
    width: 100%;
    height: auto;
}

.top-slider .carousel-indicators {
    margin-bottom: 10px;
}

.top-slider .carousel-indicators button {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .6);
}

.top-slider .carousel-indicators button.active {
    background: var(--sg-red);
}

.top-slider .carousel-control-prev,
.top-slider .carousel-control-next {
    width: 10%;
    opacity: 0;
    transition: opacity .2s;
}

.top-slider:hover .carousel-control-prev,
.top-slider:hover .carousel-control-next {
    opacity: .8;
}


.reg-card {
    border: none;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(20, 30, 60, .12);
}

.reg-card.top-slider-gap {
    margin-top: 1.5rem;
}

/* Step indicator */
.step-indicator {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    opacity: .4;
    transition: opacity .3s;
}

.step.active,
.step.done {
    opacity: 1;
}

.step-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #f3dfb8;
    color: #b58a4f;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all .3s;
}

.step.active .step-circle {
    background: var(--sg-red);
    color: #fff;
    box-shadow: 0 4px 12px rgba(232, 137, 44, .4);
}

.step.done .step-circle {
    background: #22c55e;
    color: #fff;
}

.step-label {
    font-size: .68rem;
    color: #b58a4f;
    font-weight: 600;
    white-space: nowrap;
}

.step.active .step-label {
    color: var(--sg-navy);
}

.step-line {
    flex: 1;
    height: 2px;
    background: #f3dfb8;
    margin: 0 4px;
    margin-bottom: 20px;
}

/* Form steps */
.form-step {
    display: none;
    animation: fadeSlide .35s ease;
}

.form-step.active {
    display: block;
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateX(12px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.step-title {
    font-weight: 700;
    color: var(--sg-navy);
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.step-title ion-icon {
    color: var(--sg-red);
    font-size: 22px;
}

.step-desc {
    color: #8a6a3f;
    font-size: .88rem;
    margin-bottom: 20px;
}

.form-label {
    font-weight: 600;
    color: var(--sg-navy);
    font-size: .88rem;
}

.input-group-text {
    background: #fdf1dc;
    border-right: none;
    color: #b58a4f;
}

.form-control,
.form-select {
    border-left: none;
}

.input-group .form-control:not(:first-child) {
    border-left: none;
}

.form-control:focus,
.form-select:focus {
    box-shadow: none;
    border-color: var(--sg-red);
}

.input-group:focus-within .input-group-text {
    border-color: var(--sg-red);
}

.country-flag-select {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    color: var(--sg-navy) !important;
}

.flag-icon {
    width: 22px;
    height: 16px;
    object-fit: cover;
    border-radius: 2px;
}

.btn-primary {
    background: var(--sg-red);
    border-color: var(--sg-red);
    font-weight: 700;
    border-radius: 10px;
    padding: 12px;
}

.btn-primary:hover,
.btn-primary:active {
    background: var(--sg-red-dark) !important;
    border-color: var(--sg-red-dark) !important;
}

.btn-link {
    color: #b58a4f;
    text-decoration: none;
    font-size: .88rem;
}

.btn-link:hover {
    color: var(--sg-red);
}

.invalid-feedback-custom {
    display: none;
    color: var(--sg-red);
    font-size: .78rem;
    margin-top: 6px;
}

.is-invalid~.invalid-feedback-custom,
.invalid-feedback-custom.show {
    display: block;
}

/* OTP boxes */
.otp-input-group {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.otp-box {
    width: 52px;
    height: 58px;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    border: 2px solid #f3dfb8;
    border-radius: 12px;
    color: var(--sg-navy);
    transition: border-color .2s;
}

.otp-box:focus {
    outline: none;
    border-color: var(--sg-red);
}

.resend-link {
    color: var(--sg-red);
    font-weight: 600;
    text-decoration: none;
}

.resend-link.disabled {
    color: #b58a4f;
    pointer-events: none;
}

.toggle-pw {
    cursor: pointer;
}

.declare-check {
    background: #fdf1dc;
    border-radius: 10px;
    padding: 12px 14px;
}

.form-check-input:checked {
    background-color: var(--sg-red);
    border-color: var(--sg-red);
}

/* Step 5 processing */
.spinner-ring {
    width: 110px;
    height: 110px;
    margin: 0 auto;
    position: relative;
}

.spinner-ring-track {
    width: 100%;
    height: 100%;
    border: 6px solid #f3dfb8;
    border-top-color: var(--sg-red);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.spinner-center-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px;
    color: var(--sg-red);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.countdown-box {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--sg-navy);
    color: #fff;
    font-weight: 700;
    font-size: 1.4rem;
    padding: 8px 22px;
    border-radius: 12px;
    font-variant-numeric: tabular-nums;
}

.countdown-box ion-icon {
    font-size: 20px;
}

.process-progress {
    height: 8px;
    border-radius: 6px;
}

.process-progress .progress-bar {
    background: var(--sg-red);
    transition: width 1s linear;
}

.process-checklist {
    list-style: none;
    padding: 0;
    max-width: 320px;
}

.process-checklist li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    color: #b58a4f;
    font-size: .88rem;
    transition: color .3s;
}

.process-checklist li ion-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.process-checklist li.done {
    color: var(--sg-navy);
    font-weight: 600;
}

.process-checklist li.done ion-icon {
    color: #22c55e;
}

.process-checklist li.done ion-icon::before {
    content: "";
}

.success-check ion-icon {
    font-size: 72px;
    color: #22c55e;
}

/* Live toast bottom-left */
.live-toast-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1080;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.live-toast {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(20, 30, 60, .18);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 270px;
    max-width: 300px;
    animation: toastIn .4s ease, toastOut .4s ease 4.6s forwards;
    border-left: 4px solid #22c55e;
}

.live-toast .toast-flag {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid #fdf1dc;
}

.live-toast .toast-flag img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.live-toast .toast-body {
    flex: 1;
    min-width: 0;
}

.live-toast .toast-name {
    font-weight: 700;
    font-size: .85rem;
    color: var(--sg-navy);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.live-toast .toast-status {
    font-size: .76rem;
    color: #22c55e;
    display: flex;
    align-items: center;
    gap: 4px;
}

.live-toast .toast-time {
    font-size: .72rem;
    color: #d8b98a;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toastOut {
    to {
        opacity: 0;
        transform: translateY(-10px) scale(.95);
    }
}

@media (max-width: 480px) {
    .otp-box {
        width: 44px;
        height: 52px;
        font-size: 20px;
    }

    .step-label {
        display: none;
    }

    .live-toast-container {
        left: 10px;
        right: 10px;
        bottom: 10px;
    }

    .live-toast {
        max-width: none;
    }
}