:root {
    --bg-primary: #1871f4;
    --white: #ffffff;
    --input-bg: #f8fafc;
    --text-dark: #0f172a;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #f1f5f9;
    color: var(--text-dark);
    display: flex;
    flex-direction: column;
}

.header-navbar {
    background-color: var(--bg-primary);
    width: 100%;
    height: 75px;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(24, 113, 244, 0.15);
    flex-shrink: 0;
}

.logo-side {
    display: flex;
    align-items: center;
}

.logo-img {
    width: 42px;
    height: 42px;
    margin-right: 14px;
    border-radius: 25%;
    background: var(--white);
    object-fit: contain;
}

.app-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--white);
    letter-spacing: -0.02em;
}

.tabs-side {
    display: flex;
    gap: 8px;
}

.tab-btn {
    background: rgba(255, 255, 255, 0);
    border: none;
    color: rgba(255, 255, 255, 0.75);
    font-size: 14px;
    font-weight: 600;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
}

.tab-btn.active {
    background: var(--white);
    color: var(--bg-primary);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}



.view-card {
    background-color: var(--white);
    width: 100%;
    max-width: 520px;
    border-radius: 24px;
    padding: 40px 45px;
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.04), 0 5px 15px rgba(15, 23, 42, 0.02);
    border: 1px solid var(--border-color);
    display: none;
}

.view-card.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.greeting {
    font-size: 16px;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 4px;
}

.user-heading {
    font-size: 30px;
    font-weight: 800;
    color: var(--text-dark);
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}

.view-description {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
}

.input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 18px;
    color: var(--bg-primary);
    font-size: 18px;
}

.form-control {
    width: 100%;
    height: 52px;
    background-color: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 0 52px;
    font-size: 15px;
    color: var(--text-dark);
    font-weight: 500;
    outline: none;
    transition: all 0.2s ease;
}

.form-control:focus {
    border-color: var(--bg-primary);
    background-color: var(--white);
    box-shadow: 0 0 0 4px rgba(24, 113, 244, 0.1);
}

.toggle-password {
    position: absolute;
    right: 18px;
    color: var(--bg-primary);
    cursor: pointer;
    font-size: 18px;
}

.character-counter {
    text-align: right;
    font-size: 12px;
    color: #22c55e;
    margin-top: 6px;
    font-weight: 600;
}

.utilities-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.custom-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    margin-right: 12px;
}

.custom-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    border-radius: 24px;
    transition: .2s;
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: var(--white);
    border-radius: 50%;
    transition: .2s;
}

input:checked+.switch-slider {
    background-color: var(--bg-primary);
}

input:checked+.switch-slider:before {
    transform: translateX(20px);
}

.remember-label {
    font-size: 14px;
    color: #475569;
    font-weight: 500;
}

.recovery-link {
    font-size: 14px;
    color: var(--bg-primary);
    text-decoration: none;
    font-weight: 600;
}

.recovery-link:hover {
    text-decoration: underline;
}

.btn-primary {
    width: 100%;
    height: 54px;
    background-color: var(--bg-primary);
    color: var(--white);
    border: none;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    margin-bottom: 25px;
}

.btn-primary:hover {
    background-color: #1260d1;
}

.alternative-action {
    text-align: center;
}

.alt-text {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.alt-link {
    font-size: 14px;
    color: var(--bg-primary);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
}

.alt-link:hover {
    text-decoration: underline;
}


.footer-brand {
    display: flex;
    align-items: center;
}

.footer-logo {
    width: 26px;
    height: 26px;
    margin-right: 10px;
}

.footer-title {
    font-size: 14px;
    font-weight: 700;
    color: #334155;
}

.footer-copy {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

@media (max-width: 768px) {

    html,
    body {
        overflow: auto;
        height: auto;
        min-height: 100vh;
    }

    .header-navbar {
        padding: 15px 20px;
        height: auto;
        flex-direction: column;
        gap: 15px;
    }

    .tabs-side {
        width: 100%;
        justify-content: space-between;
    }

    .tab-btn {
        flex: 1;
        text-align: center;
        padding: 10px 5px;
        font-size: 13px;
    }

    

    .view-card {
        padding: 35px 24px;
        border-radius: 20px;
    }


}


.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
}

.loading-card {
    width: 340px;
    padding: 30px 26px;
    background: #ffffff;
    border-radius: 18px;
    border: 2px solid #2563eb;
    text-align: center;
}

.loading-card .spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 4px;
    color: #2563eb;
}

.loading-card h5 {
    margin-top: 16px;
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
}

.loading-card p {
    margin-top: 6px;
    font-size: 14px;
    color: #64748b;
}

.d-none {
    display: none !important;
}


.custom-error {

    width: 100%;

    display: flex;
    align-items: center;
    gap: 16px;

    background: linear-gradient(135deg,
            #fff5f5,
            #ffecec);

    border: 1px solid #fecaca;

    border-left: 5px solid #ef4444;

    border-radius: 18px;

    padding: 18px;

    margin-bottom: 22px;

    box-shadow:
        0 10px 30px rgba(239, 68, 68, 0.10);

    animation:
        errorShow .35s ease;

    position: relative;

    overflow: hidden;
}


.custom-error::before {

    content: '';

    position: absolute;

    top: -30px;
    right: -30px;

    width: 100px;
    height: 100px;

    background: rgba(239, 68, 68, 0.05);

    border-radius: 50%;
}


.error-icon {

    min-width: 52px;
    height: 52px;

    border-radius: 14px;

    background: linear-gradient(135deg,
            #ef4444,
            #dc2626);

    display: flex;
    justify-content: center;
    align-items: center;

    color: white;

    font-size: 22px;

    box-shadow:
        0 8px 20px rgba(239, 68, 68, 0.25);
}



.error-content {

    display: flex;
    flex-direction: column;

    flex: 1;
}

.error-content strong {

    color: #991b1b;

    font-size: 15px;

    margin-bottom: 4px;
}

.error-content span {

    color: #7f1d1d;

    font-size: 14px;

    line-height: 1.5;
}




.close-error {

    border: none;

    background: transparent;

    color: #b91c1c;

    font-size: 16px;

    cursor: pointer;

    transition: .25s ease;
}

.close-error:hover {

    transform: rotate(90deg) scale(1.1);

    color: #7f1d1d;
}


@keyframes errorShow {

    from {

        opacity: 0;

        transform:
            translateY(-12px) scale(.98);

    }

    to {

        opacity: 1;

        transform:
            translateY(0) scale(1);

    }

}

.custom-error,
.custom-success {

    width: 100%;

    display: flex;
    align-items: center;
    gap: 14px;

    padding: 16px 18px;

    border-radius: 18px;

    margin-bottom: 20px;

    animation: fadeIn 0.25s ease;

    position: relative;

    overflow: hidden;
}

.custom-error {

    background: linear-gradient(135deg, #fff5f5, #ffecec);

    border: 1px solid #fecaca;

    box-shadow:
        0 8px 25px rgba(239, 68, 68, 0.12);
}

.custom-success {

    background: linear-gradient(135deg, #f0fdf4, #dcfce7);

    border: 1px solid #86efac;

    box-shadow:
        0 8px 25px rgba(34, 197, 94, 0.12);
}

.error-icon,
.success-icon {

    width: 45px;
    height: 45px;

    border-radius: 14px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    font-size: 20px;
}

.error-icon {

    background: #ef4444;
    color: white;
}

.success-icon {

    background: #22c55e;
    color: white;
}

.error-content,
.success-content {

    display: flex;
    flex-direction: column;
}

.error-content strong {

    color: #b91c1c;
    font-size: 15px;
    margin-bottom: 2px;
}

.success-content strong {

    color: #15803d;
    font-size: 15px;
    margin-bottom: 2px;
}

.error-content span {

    color: #7f1d1d;
    font-size: 14px;
}

.success-content span {

    color: #166534;
    font-size: 14px;
}

.close-error,
.close-success {

    margin-left: auto;

    border: none;
    background: transparent;

    font-size: 16px;

    cursor: pointer;

    opacity: 0.7;

    transition: 0.2s ease;
}

.close-error {
    color: #b91c1c;
}

.close-success {
    color: #15803d;
}

.close-error:hover,
.close-success:hover {

    opacity: 1;

    transform: scale(1.1);
}

@keyframes fadeIn {

    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}


.loading-overlay {

    position: fixed;

    inset: 0;

    width: 100%;
    height: 100%;

    background:
        rgba(15, 23, 42, 0.72);

    backdrop-filter: blur(10px);

    display: flex;
    align-items: center;
    justify-content: center;

    z-index: 99999;

    animation: overlayFade 0.3s ease;
}

.loading-card {

    width: 95%;
    max-width: 420px;

    background:
        rgba(255, 255, 255, 0.12);

    border:
        1px solid rgba(255, 255, 255, 0.18);

    border-radius: 30px;

    padding: 45px 35px;

    text-align: center;

    backdrop-filter: blur(18px);

    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.30);

    animation: scaleIn 0.35s ease;
}

.loading-logo {

    margin-bottom: 25px;
}

.loading-logo img {

    width: 90px;
    height: 90px;

    border-radius: 24px;

    object-fit: cover;

    background: white;

    padding: 8px;

    box-shadow:
        0 10px 30px rgba(255, 255, 255, 0.15);
}

.loading-spinner {

    display: flex;
    justify-content: center;

    margin-bottom: 25px;
}

.spinner-ring {

    width: 75px;
    height: 75px;

    border-radius: 50%;

    border:
        5px solid rgba(255, 255, 255, 0.18);

    border-top:
        5px solid #3b82f6;

    animation:
        spin 0.9s linear infinite;
}

.loading-title {

    color: white;

    font-size: 28px;
    font-weight: 700;

    margin-bottom: 10px;
}

.loading-subtitle {

    color: rgba(255, 255, 255, 0.82);

    font-size: 15px;

    line-height: 1.6;

    margin-bottom: 28px;
}

.loading-progress {

    width: 100%;
    height: 10px;

    background:
        rgba(255, 255, 255, 0.12);

    border-radius: 20px;

    overflow: hidden;
}

.loading-progress-bar {

    width: 40%;

    height: 100%;

    border-radius: 20px;

    background:
        linear-gradient(90deg,
            #3b82f6,
            #60a5fa);

    animation:
        progressMove 1.3s infinite ease-in-out;
}



@keyframes spin {

    to {
        transform: rotate(360deg);
    }

}

@keyframes progressMove {

    0% {
        transform: translateX(-120%);
    }

    100% {
        transform: translateX(320%);
    }

}

@keyframes overlayFade {

    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }

}

@keyframes scaleIn {

    from {

        opacity: 0;

        transform:
            scale(0.92) translateY(10px);

    }

    to {

        opacity: 1;

        transform:
            scale(1) translateY(0);

    }

}

.btn-primary.disabled,
.btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}


.btn-primary.disabled,
.btn-primary:disabled {

    opacity: 0.7;

    cursor: not-allowed;

    pointer-events: none;

}



.register-icon {
    width: 74px;
    height: 74px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #eaf2ff, #dbeafe);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2563eb;
    font-size: 30px;
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.16);
}

.register-title {
    margin-bottom: 8px;
    font-size: 42px;
    line-height: 1.05;
}






.register-input {
    height: 58px;
    border-radius: 15px;
}

.register-input .form-control {
    font-size: 16px;
}

.register-counter-row {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: #64748b;
    font-size: 13px;
}

.register-counter-row span {
    display: flex;
    align-items: center;
    gap: 8px;
    text-align: left;
}

.register-counter-row i {
    color: #2563eb;
}

.register-counter-row strong {
    color: #334155;
    font-size: 14px;
}

.register-btn {
    margin-top: 26px;
    height: 58px;
    border-radius: 15px;
    font-size: 15px;
    letter-spacing: .6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.register-btn i {
    font-size: 20px;
}

.register-login-box {
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid #e5e7eb;
}

.register-login-box .alt-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
}

.register-info {
    margin-top: 24px;
    padding: 13px 16px;
    border-radius: 14px;
    border: 1px solid #bfdbfe;
    background: #f8fbff;
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.register-info i {
    color: #2563eb;
}

@media (max-width: 480px) {
    .register-card {
        padding: 28px 22px 24px;
    }


    .register-counter-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .register-counter-row strong {
        align-self: flex-end;
    }
}



.view-card {
    margin-top: 0;
}


.custom-success,
.custom-error {
    margin-bottom: 18px;
}

.main-content {
    flex: 1;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 35px 20px 40px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    overflow: visible;
}

.view-card {
    background-color: var(--white);
    width: 100%;
    max-width: 430px;
    border-radius: 22px;
    padding: 30px 28px 24px;
    box-shadow:
        0 15px 35px rgba(15, 23, 42, 0.05),
        0 5px 15px rgba(15, 23, 42, 0.03);
    border: 1px solid var(--border-color);
    display: none;
}

.view-card.active {
    display: block;
    animation: fadeIn .3s ease;
}

.register-card {
    width: 100%;
    max-width: 390px;
    padding: 26px 26px 22px;
    border-radius: 18px;
    text-align: center;
    overflow: visible;
}

.register-icon {
    width: 68px;
    height: 68px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, #eaf2ff, #dbeafe);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2563eb;
    font-size: 28px;
}

.register-title {
    font-size: 30px;
    margin-top: 0;
    margin-bottom: 6px;
}

.register-description {
    margin-bottom: 18px;
    color: #64748b;
    font-size: 14px;
}

.register-timer {
    width: 100%;
    margin-bottom: 18px;
    padding: 12px 14px;
    border: 1px solid #bfdbfe;
    border-radius: 15px;
    background: linear-gradient(135deg, #f8fbff, #eef6ff);
    color: #334155;
    font-size: 13px;
    font-weight: 600;
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.register-timer[style*="display:none"],
.register-timer[style*="display: none"] {
    display: none !important;
}

.register-timer strong {
    padding: 5px 10px;
    border-radius: 9px;
    background: #2563eb;
    color: #fff;
    font-size: 15px;
}

.register-input {
    height: 52px;
}

.register-counter-row {
    margin-top: 10px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: #64748b;
    font-size: 12px;
}

.register-counter-row span {
    display: flex;
    align-items: center;
    gap: 6px;
    text-align: left;
}

.register-btn {
    margin-top: 22px;
    height: 52px;
    border-radius: 14px;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.register-login-box {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #e5e7eb;
}

.register-login-box .alt-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
}

.register-info {
    margin-top: 18px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid #bfdbfe;
    background: #f8fbff;
    color: #64748b;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.custom-error,
.custom-success {
    margin-bottom: 18px;
}

.footer-bar {
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
    padding: 0 30px;
    height: 58px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

@media (max-width: 768px) {

    .main-content {
        padding: 30px 14px;
    }

    .view-card {
        padding: 26px 20px 22px;
    }

    .register-title {
        font-size: 30px;
    }

    .register-counter-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-bar {
        padding: 15px;
        height: auto;
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

.otp-inputs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 24px 0;
}

.otp-box {
    width: 48px;
    height: 58px;
    border-radius: 14px;
    border: 1px solid var(--border-color);
    background: var(--input-bg);
    text-align: center;
    font-size: 24px;
    font-weight: 800;
    color: var(--text-dark);
    outline: none;
    transition: .2s ease;
}

.otp-box:focus {
    border-color: var(--bg-primary);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(24, 113, 244, 0.12);
}

@media (max-width: 480px) {
    .otp-inputs {
        gap: 6px;
    }

    .otp-box {
        width: 42px;
        height: 54px;
        font-size: 22px;
    }
}

.password-strength {
    width: 100%;
    height: 8px;
    margin-top: 10px;
    background: #e5e7eb;
    border-radius: 20px;
    overflow: hidden;
}

#passwordStrengthBar {
    width: 0%;
    height: 100%;
    border-radius: 20px;
    transition: .25s ease;
}

#passwordStrengthBar.weak {
    width: 35%;
    background: #ef4444;
}

#passwordStrengthBar.medium {
    width: 70%;
    background: #f59e0b;
}

#passwordStrengthBar.strong {
    width: 100%;
    background: #22c55e;
}

.password-strength-text {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
}

.password-strength-text.weak {
    color: #dc2626;
}

.password-strength-text.medium {
    color: #d97706;
}

.password-strength-text.strong {
    color: #16a34a;
}

.password-rules {
    margin-top: 10px;
    padding-left: 0;
    list-style: none;
    display: grid;
    gap: 6px;
}

.password-rules li {
    font-size: 12px;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 6px;
}

.password-rules li::before {
    content: "○";
    color: #94a3b8;
    font-weight: 800;
}

.password-rules li.valid {
    color: #16a34a;
    font-weight: 700;
}

.password-rules li.valid::before {
    content: "✓";
    color: #16a34a;
}

.toggle-password {
    position: absolute;
    right: 18px;
    color: var(--bg-primary);
    cursor: pointer;
    font-size: 17px;
}


.footer-bar {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 0 28px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-app {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #334155;
    font-size: 13px;
    font-weight: 500;
}

.footer-play {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #1871f4;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}

.footer-play:hover {
    text-decoration: underline;
}

.footer-play i {
    font-size: 18px;
}

.footer-copy {
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
}

@media (max-width: 600px) {
    .footer-bar {
        height: auto;
        padding: 14px 18px;
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}