* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0f0219 0%, #1a0a2e 50%, #16213e 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
}

body::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(2px 2px at 20% 30%, rgba(168, 85, 247, 0.5), rgba(0, 0, 0, 0)),
        radial-gradient(2px 2px at 60% 70%, rgba(139, 92, 246, 0.3), rgba(0, 0, 0, 0)),
        radial-gradient(1px 1px at 50% 50%, rgba(168, 85, 247, 0.4), rgba(0, 0, 0, 0)),
        radial-gradient(1px 1px at 80% 10%, rgba(139, 92, 246, 0.5), rgba(0, 0, 0, 0)),
        radial-gradient(2px 2px at 90% 60%, rgba(168, 85, 247, 0.3), rgba(0, 0, 0, 0)),
        radial-gradient(1px 1px at 30% 80%, rgba(139, 92, 246, 0.4), rgba(0, 0, 0, 0)),
        radial-gradient(1px 1px at 10% 40%, rgba(168, 85, 247, 0.3), rgba(0, 0, 0, 0));
    background-size: 200% 200%;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: -1;
    opacity: 0.6;
    animation: twinkle 8s ease-in-out infinite;
}

@keyframes twinkle {

    0%,
    100% {
        opacity: 0.3;
    }

    50% {
        opacity: 0.6;
    }
}

.page-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    min-height: 100vh;
}

.login-container {
    width: 100%;
    height: 100vh;
    max-width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.card-wrapper {
    background: rgba(30, 24, 74, 0.9);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), inset 0 0 40px rgba(168, 85, 247, 0.1);
    overflow: hidden;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(168, 85, 247, 0.2);
    animation: slideIn 0.5s ease-out;
    width: 100%;
    max-width: 650px;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-header {
    background: linear-gradient(135deg, #2d1b5e 0%, #3d2b7f 100%);
    padding: 40px 30px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid rgba(168, 85, 247, 0.3);
}

.card-header::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.15) 0%, transparent 70%);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(20px, 20px);
    }

    100% {
        transform: translate(0, 0);
    }
}

.card-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="20" fill="white" opacity="0.1"/><circle cx="80" cy="80" r="30" fill="white" opacity="0.05"/></svg>');
    opacity: 0.5;
}

.logo-section {
    position: relative;
    z-index: 1;
    margin-bottom: 15px;
}

.logo-section img {
    width: 100px;
    height: 100px;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.2);
    padding: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.header-title {
    font-size: 28px;
    font-weight: 700;
    margin: 15px 0 5px;
    position: relative;
    z-index: 1;
    color: #ffffff;
}

.header-subtitle {
    font-size: 14px;
    opacity: 0.9;
    position: relative;
    z-index: 1;
    color: #e0e7ff;
}

.card-body {
    padding: 45px 50px;
    background: rgba(30, 24, 74, 0.5);
    color: #e0e7ff;
}

.form-section {
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(180deg, #7c3aed 0%, #5b21b6 100%);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(124, 58, 237, 0.6);
}

.alert-custom {
    background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 100%);
    color: white;
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(239, 68, 68, 0.3);
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

.alert-custom i {
    font-size: 18px;
}

.close-alert {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    color: white;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 18px;
    margin-left: auto;
    transition: all 0.3s;
}

.close-alert:hover {
    background: rgba(255, 255, 255, 0.5);
}

.wallet-button {
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
    color: white;
    border: 1px solid rgba(168, 85, 247, 0.5);
    padding: 16px 30px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(168, 85, 247, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.wallet-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.wallet-button:hover::before {
    left: 100%;
}

.wallet-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(168, 85, 247, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    background: linear-gradient(135deg, #a855f7 0%, #d946ef 100%);
}

.wallet-button:active {
    transform: translateY(-1px);
}

.wallet-button i {
    font-size: 20px;
}

.wallet-option {
    background: rgba(100, 50, 150, 0.4);
    border: 2px solid rgba(168, 85, 247, 0.4);
    padding: 10px 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    width: 100%;
}

.wallet-option:hover {
    border-color: #d946ef;
    background: rgba(168, 85, 247, 0.3);
    transform: translateX(5px);
    box-shadow: 0 8px 20px rgba(217, 70, 239, 0.4);
}

.wallet-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(168, 85, 247, 0.2);
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.2);
    flex-shrink: 0;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.wallet-icon img {
    width: 35px;
    height: 35px;
    object-fit: contain;
}

.wallet-info {
    flex: 1;
}

.modal .wallet-name {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    display: block;
}

.modal .wallet-desc {
    font-size: 12px;
    color: #c5b0e0;
    display: block;
    margin-top: 3px;
}

.modal .wallet-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(168, 85, 247, 0.3);
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.3);
    flex-shrink: 0;
    border: 1px solid rgba(217, 70, 239, 0.4);
}

.modal .wallet-arrow {
    color: #d946ef;
    font-size: 18px;
    transition: transform 0.3s;
    text-shadow: 0 0 10px rgba(217, 70, 239, 0.5);
}

.wallet-arrow {
    color: #7c3aed;
    font-size: 18px;
    transition: transform 0.3s;
    text-shadow: 0 0 8px rgba(124, 58, 237, 0.5);
}

.wallet-option:hover .wallet-arrow {
    transform: translateX(5px);
}

.footer-text {
    text-align: center;
    font-size: 13px;
    color: #b0b9d9;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid rgba(168, 85, 247, 0.2);
}

.footer-text a {
    color: #7c3aed;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
    text-shadow: 0 0 6px rgba(124, 58, 237, 0.3);
}

.footer-text a:hover {
    color: #a78bfa;
    text-shadow: 0 0 10px rgba(124, 58, 237, 0.6);
}

.info-box {
    background: rgba(168, 85, 247, 0.08);
    border-left: 4px solid #a855f7;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    gap: 12px;
    box-shadow: inset 0 0 20px rgba(168, 85, 247, 0.05);
    border: 1px solid rgba(168, 85, 247, 0.15);
}

.info-box i {
    color: #a855f7;
    font-size: 18px;
    flex-shrink: 0;
    margin-top: 2px;
    text-shadow: 0 0 8px rgba(168, 85, 247, 0.4);
}

.info-box-content {
    font-size: 13px;
    color: #d1d5db;
    line-height: 1.5;
}

.info-box-title {
    font-weight: 600;
    color: #e0e7ff;
    margin-bottom: 3px;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.3s ease-in;
}

.modal.show {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-dialog {
    position: relative;
    width: auto;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
}

.modal-dialog-centered {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
}

.modal-content-custom {
    background-color: rgba(40, 30, 100, 1);
    border-radius: 20px;
    border: 1px solid rgba(168, 85, 247, 0.4);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 50px rgba(168, 85, 247, 0.2);
    position: relative;
    display: flex;
    flex-direction: column;
    max-width: 450px;
    width: 90%;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header-custom {
    background: linear-gradient(135deg, #5d3fa3 0%, #7c4bc4 100%);
    color: white;
    border: none;
    border-radius: 20px 20px 0 0;
    padding: 25px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 8px 16px rgba(0, 0, 0, 0.3);
    position: relative;
    border-bottom: 1px solid rgba(168, 85, 247, 0.3);
}

.modal-header-custom::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
}

.modal-title-custom {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    flex: 1;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.btn-close {
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: white;
    padding: 0;
    margin: 0;
    line-height: 1;
}

.btn-close:hover {
    opacity: 0.8;
}

.modal-body-custom {
    padding: 30px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    background: rgba(40, 30, 90, 0.8);
}

/* Responsive Design */
@media (max-width: 768px) {
    .login-container {
        padding: 15px;
        height: auto;
        min-height: 100vh;
    }

    .card-wrapper {
        max-width: 100%;
        width: 100%;
        border-radius: 15px;
    }

    .card-header {
        padding: 30px 20px;
    }

    .logo-section img {
        width: 80px;
        height: 80px;
    }

    .header-title {
        font-size: 24px;
    }

    .card-body {
        padding: 30px 25px;
    }

    .section-title {
        font-size: 16px;
    }

    .wallet-button {
        padding: 12px 20px;
        font-size: 14px;
    }

    .wallet-option {
        padding: 14px;
    }

    .wallet-icon {
        width: 45px;
        height: 45px;
    }

    .wallet-icon img {
        width: 30px;
        height: 30px;
    }

    .footer-text {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 10px;
        height: auto;
        min-height: 100vh;
    }

    .card-header {
        padding: 25px 15px;
    }

    .card-body {
        padding: 20px 15px;
    }

    .logo-section img {
        width: 70px;
        height: 70px;
    }

    .header-title {
        font-size: 20px;
    }

    .header-subtitle {
        font-size: 12px;
    }

    .section-title {
        font-size: 14px;
    }

    .wallet-option {
        padding: 12px 10px;
        gap: 10px;
    }

    .wallet-name {
        font-size: 13px;
    }

    .wallet-desc {
        font-size: 11px;
    }

    .wallet-button {
        padding: 10px 15px;
        font-size: 13px;
    }
}

.spinner-border-custom {
    border-color: rgba(255, 255, 255, 0.3) !important;
    border-right-color: white !important;
}

/* Form Group Custom Styles */
.form-group-custom {
    margin-bottom: 1rem;
    animation: fadeInUp 0.4s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-label-custom {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
}

.form-label-custom i {
    font-size: 16px;
    color: #a855f7;
    text-shadow: 0 0 8px rgba(168, 85, 247, 0.6);
    transition: all 0.3s ease;
}

.form-label-custom:hover i {
    color: #d946ef;
    text-shadow: 0 0 12px rgba(217, 70, 239, 0.8);
    transform: scale(1.1);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.form-control-custom {
    width: 100%;
    padding: 14px 45px 14px 16px;
    background: rgba(168, 85, 247, 0.08);
    border: 2px solid rgba(168, 85, 247, 0.3);
    border-radius: 10px;
    color: #e0e7ff;
    font-size: 14px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 0 0 rgba(168, 85, 247, 0.4);
    backdrop-filter: blur(10px);
}

.form-control-custom::placeholder {
    color: rgba(224, 231, 255, 0.5);
    font-weight: 500;
}

.form-control-custom:focus {
    outline: none;
    border-color: #a855f7;
    background: rgba(168, 85, 247, 0.12);
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 20px rgba(168, 85, 247, 0.4), inset 0 0 15px rgba(168, 85, 247, 0.05);
    transform: translateY(-1px);
}

.form-control-custom:hover {
    border-color: rgba(168, 85, 247, 0.5);
    background: rgba(168, 85, 247, 0.1);
}

.form-control-custom.error {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.08);
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 15px rgba(239, 68, 68, 0.3);
}

.input-icon-right {
    position: absolute;
    right: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a855f7;
    font-size: 14px;
    pointer-events: none;
    transition: all 0.3s ease;
}

.form-control-custom:focus ~ .input-icon-right {
    color: #d946ef;
    text-shadow: 0 0 10px rgba(217, 70, 239, 0.6);
    transform: scale(1.15);
}

.sponsor-feedback {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    color: #a78bfa;
    min-height: 18px;
    animation: slideInDown 0.3s ease-out;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sponsor-feedback.success {
    color: #34d399;
    text-shadow: 0 0 8px rgba(52, 211, 153, 0.5);
}

.sponsor-feedback.error {
    color: #f87171;
    text-shadow: 0 0 8px rgba(248, 113, 113, 0.5);
}

.form-error-custom {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    color: #ef4444;
    text-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
    font-weight: 500;
    animation: shake 0.3s ease-in-out;
}

/* Responsive Form Styles */
@media (max-width: 768px) {
    .form-label-custom {
        font-size: 13px;
    }

    .form-control-custom {
        padding: 12px 40px 12px 14px;
        font-size: 13px;
    }

    .input-icon-right {
        font-size: 13px;
    }

    .sponsor-feedback {
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .form-label-custom {
        font-size: 12px;
        gap: 6px;
    }

    .form-label-custom i {
        font-size: 14px;
    }

    .form-control-custom {
        padding: 10px 35px 10px 12px;
        font-size: 12px;
    }

    .input-icon-right {
        right: 10px;
        font-size: 12px;
    }
}