/* =========================================================
   FAST CAMBIOS — KYC Registration Page
   Modern, responsive, premium design
   ========================================================= */

/* ── Reset & Base ────────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Poppins', system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    min-height: 100dvh;
    background: #020d1f url('../background.jpg') center center / cover no-repeat fixed;
    color: #ffffff;
    overflow-x: hidden;
    position: relative;
}

/* Background overlay for depth */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(2, 13, 31, 0.55) 0%,
            rgba(0, 40, 100, 0.35) 50%,
            rgba(2, 13, 31, 0.60) 100%);
    pointer-events: none;
    z-index: 0;
}

/* ── Page Wrapper ────────────────────────────────────────── */
.page-wrapper {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1.5rem, 5vw, 3rem);
}

/* ── Coin Decorations ────────────────────────────────────── */
.coin {
    position: fixed;
    z-index: 1;
    pointer-events: none;
    user-select: none;
}

.coin img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.5));
    animation: floatCoin 6s ease-in-out infinite;
}

/* Top-right coins */
.coin-tr-1 {
    width: clamp(90px, 12vw, 180px);
    top: -20px;
    right: clamp(60px, 8vw, 140px);
    animation-delay: 0s;
}

.coin-tr-2 {
    width: clamp(60px, 8vw, 120px);
    top: clamp(80px, 10vh, 160px);
    right: -10px;
    animation-delay: -2s;
}

/* Bottom-left coins */
.coin-bl-1 {
    width: clamp(80px, 11vw, 160px);
    bottom: clamp(60px, 8vh, 120px);
    left: -10px;
    animation-delay: -1s;
}

.coin-bl-2 {
    width: clamp(60px, 8vw, 110px);
    bottom: -15px;
    left: clamp(60px, 8vw, 130px);
    animation-delay: -3s;
}

@keyframes floatCoin {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    33% {
        transform: translateY(-14px) rotate(3deg);
    }

    66% {
        transform: translateY(-6px) rotate(-2deg);
    }
}

/* ── Main Grid Layout ────────────────────────────────────── */
.main-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    width: 100%;
    max-width: 1200px;
    align-items: start;
}

/* ── Info Section (Left) ─────────────────────────────────── */
.info-section {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Logo */
.logo-wrap {
    display: flex;
    align-items: flex-start;
}

.logo-img {
    width: 100%;
    max-width: clamp(180px, 30vw, 280px);
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 20px rgba(0, 180, 255, 0.3));
    transition: transform 0.3s ease, filter 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.03);
    filter: drop-shadow(0 6px 28px rgba(0, 200, 255, 0.45));
}

/* Info Text */
.info-text {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.info-text p {
    font-size: clamp(0.875rem, 1.5vw, 1rem);
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.92);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

.info-text p strong {
    color: #ffffff;
    font-weight: 700;
}

.info-text h2 {
    font-size: clamp(1rem, 1.8vw, 1.1rem);
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    line-height: 1.4;
}

/* ── Form Section (Right) ────────────────────────────────── */
.form-section {
    display: flex;
    flex-direction: column;
}

/* Form Card */
.form-card {
    background: linear-gradient(145deg, #29c4d0, #1fb0bc, #17939e);
    border-radius: 24px;
    padding: clamp(1.75rem, 4vw, 2.75rem);
    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(255, 255, 255, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: relative;
    overflow: hidden;
}

.form-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.12) 0%, transparent 60%);
    pointer-events: none;
}

/* Form Title */
.form-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin-bottom: 1.75rem;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
    letter-spacing: -0.02em;
}

/* Form Groups */
.form-group {
    margin-bottom: 1.25rem;
    position: relative;
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 0.4rem;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* Text Inputs */
.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.92);
    border: 2px solid transparent;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    color: #1a2a3a;
    outline: none;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.form-input::placeholder {
    color: #9aabb8;
    font-size: 0.85rem;
}

.form-input:focus {
    background: #ffffff;
    border-color: #005f8e;
    box-shadow: 0 0 0 4px rgba(0, 95, 142, 0.2), 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.form-input.error {
    border-color: #e53e3e;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.2);
}

/* Upload Zone */
.upload-hint {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
    font-style: italic;
}

.upload-zone {
    position: relative;
    background: rgba(255, 255, 255, 0.92);
    border: 2px dashed rgba(0, 95, 142, 0.4);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.25s ease;
    min-height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.upload-zone:hover,
.upload-zone:focus {
    background: #ffffff;
    border-color: #005f8e;
    box-shadow: 0 0 0 4px rgba(0, 95, 142, 0.2);
    transform: translateY(-1px);
    outline: none;
}

.upload-zone.drag-over {
    background: #e8f8ff;
    border-color: #0096c7;
    border-style: solid;
    box-shadow: 0 0 0 4px rgba(0, 150, 199, 0.25);
}

.upload-zone.has-file {
    border-style: solid;
    border-color: #00897b;
}

.file-input {
    display: none;
    /* Hidden — triggered programmatically by zone click */
}

.upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 1rem;
    text-align: center;
    pointer-events: none;
    z-index: 1;
}

.upload-icon {
    width: 40px;
    height: 40px;
    color: #47a3b5;
    transition: color 0.2s, transform 0.2s;
}

.upload-zone:hover .upload-icon,
.upload-zone:focus .upload-icon {
    color: #005f8e;
    transform: scale(1.1);
}

.upload-icon svg {
    width: 100%;
    height: 100%;
}

.upload-text {
    font-size: 0.82rem;
    font-weight: 600;
    color: #2d6a7a;
}

.upload-subtext {
    font-size: 0.72rem;
    color: #7aabb5;
}

/* Upload Preview */
.upload-preview {
    position: relative;
    width: 100%;
    min-height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-preview img {
    max-width: 100%;
    max-height: 160px;
    object-fit: contain;
    border-radius: 8px;
    padding: 8px;
}

.remove-preview {
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(229, 62, 62, 0.85);
    color: white;
    border: none;
    border-radius: 50%;
    width: 26px;
    height: 26px;
    cursor: pointer;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.2s, transform 0.2s;
    pointer-events: all;
}

.remove-preview:hover {
    background: #c53030;
    transform: scale(1.1);
}

/* Error messages */
.error-msg {
    display: block;
    font-size: 0.75rem;
    color: #ffe0e0;
    font-weight: 500;
    margin-top: 0.3rem;
    min-height: 1rem;
    padding-left: 0.25rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Submit Button */
.btn-submit {
    width: 100%;
    padding: 1rem 2rem;
    margin-top: 0.75rem;
    background: linear-gradient(135deg, #0a3d62, #1565c0, #0d47a1);
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(10, 61, 98, 0.5);
}

.btn-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.4s ease;
}

.btn-submit:hover::before {
    left: 100%;
}

.btn-submit:hover {
    background: linear-gradient(135deg, #1565c0, #1976d2, #1e88e5);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(10, 61, 98, 0.6);
}

.btn-submit:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(10, 61, 98, 0.4);
}

.btn-submit:disabled {
    opacity: 0.75;
    cursor: not-allowed;
    transform: none;
}

.btn-text,
.btn-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.spinner {
    width: 20px;
    height: 20px;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ── Success Message ─────────────────────────────────────── */
.success-message {
    text-align: center;
    padding: 2rem 1rem;
    animation: fadeInUp 0.5s ease;
}

.success-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #00c853, #69f0ae);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    margin: 0 auto 1.25rem;
    box-shadow: 0 8px 24px rgba(0, 200, 83, 0.4);
    animation: popIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.2s both;
}

.success-message h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.75rem;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.success-message p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    max-width: 380px;
    margin: 0 auto;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ── Responsive: Tablet ──────────────────────────────────── */
@media (max-width: 900px) {
    .main-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        max-width: 600px;
    }

    .info-section {
        gap: 1.5rem;
    }

    .logo-img {
        max-width: 200px;
    }

    .coin-tr-1 {
        width: 80px;
        top: -10px;
        right: 10px;
    }

    .coin-tr-2 {
        width: 55px;
        top: 60px;
        right: -5px;
    }

    .coin-bl-1 {
        width: 70px;
        bottom: 40px;
        left: -5px;
    }

    .coin-bl-2 {
        width: 52px;
        bottom: -10px;
        left: 55px;
    }
}

/* ── Responsive: Mobile ──────────────────────────────────── */
@media (max-width: 600px) {
    .page-wrapper {
        padding: 1.25rem;
        align-items: flex-start;
    }

    .form-card {
        padding: 1.5rem 1.25rem;
        border-radius: 18px;
    }

    .form-title {
        font-size: 1.75rem;
    }

    .info-text p,
    .info-text h2 {
        font-size: 0.875rem;
    }

    .coin-tr-1 {
        width: 65px;
        top: -5px;
        right: 5px;
    }

    .coin-tr-2 {
        width: 45px;
        top: 50px;
        right: -3px;
    }

    .coin-bl-1 {
        width: 60px;
        bottom: 30px;
        left: -3px;
    }

    .coin-bl-2 {
        width: 42px;
        bottom: -8px;
        left: 45px;
    }

    .upload-zone {
        min-height: 90px;
    }

    .logo-img {
        max-width: 170px;
    }
}

/* ── Very small screens ──────────────────────────────────── */
@media (max-width: 380px) {
    .page-wrapper {
        padding: 1rem 0.875rem;
    }

    .form-card {
        padding: 1.25rem 1rem;
    }

    .form-input {
        font-size: 0.85rem;
        padding: 0.7rem 0.875rem;
    }

    .btn-submit {
        font-size: 0.9rem;
        padding: 0.875rem 1.5rem;
    }
}

/* ── Accessibility: Reduce Motion ────────────────────────── */
@media (prefers-reduced-motion: reduce) {

    .coin img,
    .spinner {
        animation: none;
    }

    .btn-submit::before {
        display: none;
    }

    .form-input:focus,
    .upload-zone:hover,
    .upload-zone:focus {
        transform: none;
    }
}