/* src/main/resources/static/css/pages/register.css */

/* ===== REGISTER PAGE - SOFT & STYLISH COMPACT ===== */

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    justify-content: center;
    padding: 32px 24px;
    background: #ffffff;
}

.onboarding-wrapper {
    width: 100%;
    max-width: 900px;
}

/* Card */
.onboarding-card {
    background: #ffffff;
    border-radius: 32px;
    padding: 32px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.02);
}

/* Header */
.card-header {
    text-align: center;
    margin-bottom: 30px;
}

.card-header h2 {
    font-size: 28px;
    font-weight: 600;
    color: #18181b;
    margin-bottom: 6px;
    letter-spacing: -0.02em;
}

.card-header p {
    font-size: 14px;
    color: #71717a;
}

.highlight {
    color: #18181b;
    font-weight: 600;
    background: #f4f4f5;
    padding: 2px 8px;
    border-radius: 20px;
}

/* Progress Steps */
.progress-steps {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 36px;
}

.step {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 32px;
    top: 12px;
    width: 50px;
    height: 2px;
    background: #e4e4e7;
}

.step-number {
    width: 26px;
    height: 26px;
    border-radius: 26px;
    background: #f4f4f5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    font-size: 12px;
    color: #71717a;
    z-index: 2;
}

.step.active .step-number {
    background: #18181b;
    color: white;
}

.step-text {
    font-size: 12px;
    font-weight: 500;
    color: #a1a1aa;
}

.step.active .step-text {
    color: #18181b;
}

/* Messages */
.message {
    padding: 14px 18px;
    border-radius: 16px;
    font-size: 13px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.message.success {
    background: #f6f6f7;
    color: #18181b;
    border: 1px solid #e4e4e7;
}

.message.error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fee2e2;
}

/* 2-Column Grid */
.registration-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.section-title {
    font-size: 12px;
    font-weight: 600;
    color: #71717a;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Form Groups */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #52525b;
    margin-bottom: 4px;
}

.input-wrapper {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #a1a1aa;
    font-size: 14px;
}

/* Input Fields */
.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 14px 10px 42px;
    border: 1.5px solid #e4e4e7;
    border-radius: 14px;
    font-size: 13px;
    background: #ffffff;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    color: #18181b;
}

.form-group input:focus {
    border-color: #18181b;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.02);
}

.error-message {
    color: #ef4444;
    font-size: 11px;
    margin-top: 2px;
    display: block;
}

/* Plan Selector */
.plan-selector {
    background: #f8fafc;
    border: 1.5px solid #e4e4e7;
    border-radius: 16px;
    padding: 14px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
    margin-bottom: 16px;
}

.plan-selector:hover {
    border-color: #18181b;
    background: #f1f5f9;
}

.plan-selector-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.plan-selector-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.plan-selector-text {
    display: flex;
    flex-direction: column;
}

.plan-selector-title {
    font-weight: 600;
    font-size: 15px;
    color: #18181b;
}

.plan-selector-subtitle {
    font-size: 11px;
    color: #71717a;
}

.plan-selector-price {
    font-weight: 700;
    font-size: 16px;
    color: #2563eb;
}

.selected-plan-badge {
    background: #10b981;
    color: white;
    padding: 3px 10px;
    border-radius: 30px;
    font-size: 11px;
    font-weight: 600;
    display: inline-block;
}

/* ===== BUTTON - SOFT & STYLISH (FIXED) ===== */
.btn-register {
    width: 50%;
    padding: 12px 20px;
    background: #18181b;
    color: white;
    border: none;
    border-radius: 40px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 24px auto 0;
    position: relative;
    overflow: hidden;
    transition: all 0.2s;
}

/* Shine effect */
.btn-register::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-register:hover {
    background: #27272a;
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.btn-register:hover::before {
    left: 100%;
}

.btn-register:active {
    transform: translateY(0);
}

.btn-register i {
    transition: transform 0.2s;
}

.btn-register:hover i {
    transform: translateX(3px);
}

.btn-register:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #94a3b8;
}

.btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Back Link */
.back-link {
    text-align: center;
    margin-top: 20px;
}

.back-link a {
    text-decoration: none;
    color: #71717a;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 40px;
    transition: all 0.2s;
}

.back-link a:hover {
    background: #f4f4f5;
    color: #18181b;
}


@keyframes modalSlideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

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

/* Plan Grid */
.plan-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

.plan-card {
    border: 2px solid #e4e4e7;
    border-radius: 20px;
    padding: 20px 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.plan-card:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.1);
}

.plan-card.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, #f5f7ff 0%, #ffffff 100%);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.2);
}

.plan-card.popular::before {
    content: '🔥 POPULAR';
    position: absolute;
    top: -10px;
    right: 20px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 30px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.plan-card.best-value::before {
    content: '⭐ BEST VALUE';
    position: absolute;
    top: -10px;
    right: 20px;
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 30px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1px;
}

.plan-name {
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 6px;
    color: #18181b;
    text-align: center;
}

.plan-price {
    font-size: 20px;
    font-weight: 800;
    color: #2563eb;
    margin-bottom: 8px;
    text-align: center;
}

.plan-price.free {
    color: #10b981;
}

.plan-price small {
    font-size: 11px;
    font-weight: 400;
    color: #71717a;
}

.plan-features {
    list-style: none;
    margin-top: 12px;
}

.plan-features li {
    font-size: 11px;
    color: #71717a;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.plan-features i {
    color: #10b981;
    font-size: 10px;
}

/* Modal Buttons */
.plan-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.modal-btn {
    padding: 10px 24px;
    border: none;
    border-radius: 40px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-btn.primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.modal-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.4);
}

.modal-btn.secondary {
    background: #f1f5f9;
    color: #475569;
}

.modal-btn.secondary:hover {
    background: #e2e8f0;
}

/* Success Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.success-modal-content {
    background: white;
    border-radius: 24px;
    padding: 28px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2);
    animation: modalSlideUp 0.3s ease;
    width: 90%;
    max-width: 380px;
}

.success-icon {
    width: 70px;
    height: 70px;
    background: #10b981;
    border-radius: 50%;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.success-icon i {
    color: white;
    font-size: 36px;
}

/* Responsive */
@media (max-width: 768px) {
    .registration-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .onboarding-card {
        padding: 24px 20px;
    }

    .plan-grid {
        grid-template-columns: 1fr;
    }

    .btn-register {
        width: 100%;
    }
}


/* ===== PLAN MODAL - FIXED BADGES ===== */
.plan-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.plan-modal.active {
    display: flex;
}

.plan-modal-content {
    background: white;
    max-width: 550px;
    width: 90%;
    border-radius: 32px;
    padding: 30px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2);
    animation: modalSlideUp 0.3s ease;
}

@keyframes modalSlideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.plan-modal-header {
    text-align: center;
    margin-bottom: 24px;
}

.plan-modal-header h3 {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 6px;
}

.plan-modal-header p {
    color: #71717a;
    font-size: 13px;
}

/* Plan Grid */
.plan-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

/* Plan Card - with proper badge positioning */
.plan-card {
    border: 2px solid #e4e4e7;
    border-radius: 20px;
    padding: 20px 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    background: white;
    overflow: visible; /* Important for badges */
}

.plan-card:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.1);
}

.plan-card.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, #f5f7ff 0%, #ffffff 100%);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.2);
}

/* POPULAR Badge - Fixed */
.plan-card.popular {
    position: relative;
}

.plan-card.popular::before {
    content: '🔥 POPULAR';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: white;
    padding: 4px 16px;
    border-radius: 30px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    white-space: nowrap;
    z-index: 10;
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.3);
    border: 2px solid white;
}

/* BEST VALUE Badge - Fixed */
.plan-card.best-value {
    position: relative;
}

.plan-card.best-value::before {
    content: '⭐ BEST VALUE';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #48bb78, #38a169);
    color: white;
    padding: 4px 16px;
    border-radius: 30px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    white-space: nowrap;
    z-index: 10;
    box-shadow: 0 4px 8px rgba(72, 187, 120, 0.3);
    border: 2px solid white;
}

/* Plan Icon */
.plan-icon {
    font-size: 28px;
    margin-bottom: 8px;
    text-align: center;
    margin-top: 8px; /* Add space for badge */
}

.plan-name {
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 6px;
    color: #18181b;
    text-align: center;
}

/* Plan Price */
.plan-price {
    font-size: 20px;
    font-weight: 800;
    color: #2563eb;
    margin-bottom: 8px;
    text-align: center;
}

.plan-price.free {
    color: #10b981;
}

.plan-price small {
    font-size: 11px;
    font-weight: 400;
    color: #71717a;
}

/* Plan Features */
.plan-features {
    list-style: none;
    margin-top: 12px;
    padding: 0;
}

.plan-features li {
    font-size: 11px;
    color: #71717a;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.plan-features i {
    color: #10b981;
    font-size: 10px;
    width: 14px;
}

/* Modal Actions */
.plan-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px;
}

.modal-btn {
    padding: 10px 24px;
    border: none;
    border-radius: 40px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-btn.primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.modal-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.4);
}

.modal-btn.secondary {
    background: #f1f5f9;
    color: #475569;
}

.modal-btn.secondary:hover {
    background: #e2e8f0;
}

/* Responsive */
@media (max-width: 768px) {
    .plan-grid {
        grid-template-columns: 1fr;
    }
    
    .plan-card.popular::before,
    .plan-card.best-value::before {
        font-size: 9px;
        padding: 3px 12px;
    }
}



/* ===== SUCCESS MODAL - COMPLETE FIX ===== */

/* Success Container - Full screen overlay */
#successContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    animation: fadeIn 0.3s ease;
}

.success-modal-content {
    background: white;
    border-radius: 28px;
    padding: 32px 36px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
    position: relative;
}

/* Success Icon Animation */
.success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    animation: scaleIn 0.5s ease;
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
}

.success-icon i {
    font-size: 40px;
    color: white;
}

/* Progress Bar Container */
.progress-bar-container {
    width: 100%;
    height: 6px;
    background: #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    margin: 24px 0 20px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #10b981, #059669);
    width: 100%;
    border-radius: 10px;
    transition: width 0.3s linear;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin: 24px 0 16px;
}

.action-btn {
    padding: 12px 24px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
}

.action-btn.primary {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.action-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

.action-btn.secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #e5e7eb;
}

.action-btn.secondary:hover {
    background: #e5e7eb;
    transform: translateY(-1px);
}

.info-text {
    font-size: 13px;
    color: #6b7280;
    margin-top: 12px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.7);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Mobile Responsive */
@media (max-width: 640px) {
    .success-modal-content {
        padding: 24px 20px;
        width: 92%;
    }
    
    .success-icon {
        width: 64px;
        height: 64px;
    }
    
    .success-icon i {
        font-size: 32px;
    }
    
    .action-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .action-btn {
        justify-content: center;
        padding: 10px 20px;
    }
    
    .info-text {
        font-size: 12px;
    }
}





/* Plan Selection Status Container */
div[style*="margin-bottom: 40px"] {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

/* Badge - No plan selected */
.selected-plan-badge.warning {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fef2f2;
    color: #dc2626;
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 0.7rem;
    font-weight: 500;
    border: 1px solid #fee2e2;
}

/* Required Message - Shows on validation error */
.plan-required-message {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #fef2f2;
    color: #dc2626;
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 0.7rem;
    font-weight: 500;
    border: 1px solid #fee2e2;
    animation: fadeIn 0.3s ease;
}

.plan-required-message i {
    font-size: 0.65rem;
    color: #dc2626;
}

/* Animation for message */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-3px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Success badge (when plan selected) */
.selected-plan-badge.success {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f0fdf4;
    color: #10b981;
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 0.7rem;
    font-weight: 500;
    border: 1px solid #bbf7d0;
}

/* Responsive - stack on mobile */
@media (max-width: 640px) {
    div[style*="margin-bottom: 40px"] {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}