@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* --- Global Reset & Typography --- */
body {
    font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f3f4f6;
    color: #1f2937;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    line-height: 1.5;
}

a {
    text-decoration: none;
    transition: color 0.2s;
}

/* --- Wrappers & Layouts --- */
.activation-wrapper {
    width: 100%;
    padding: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* 1. Narrow Card (Used for Success Page & Simple Auth) */
.auth-card {
    width: 100%;
    max-width: 480px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
}

/* 2. Wide Split Card (Used for Activation Form) */
.activation-card {
    width: 100%;
    max-width: 1000px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    min-height: 600px;
}

/* --- Common Elements --- */
.brand-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
    margin-bottom: 1rem;
}

/* Form Controls */
.form-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    display: block;
}

.form-control, .form-select {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    font-weight: 400;
    line-height: 1.5;
    color: #1f2937;
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    transition: all 0.2s ease-in-out;
}

.form-control:focus {
    border-color: #6366f1;
    outline: 0;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-control::placeholder {
    color: #9ca3af;
}

/* Input Groups (Activation Form) */
.input-group-text {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: #6b7280;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-right: none;
    border-top-left-radius: 0.5rem;
    border-bottom-left-radius: 0.5rem;
}

.input-group .form-control {
    border-left: 0;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease-in-out;
    cursor: pointer;
    border: 1px solid transparent;
}

.btn-primary {
    color: #fff;
    background-color: #4f46e5;
    border-color: #4f46e5;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.btn-primary:hover {
    color: #fff;
    background-color: #4338ca;
    border-color: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.2);
}

/* Success Button (Return to Installer) */
.btn-success {
    color: #fff;
    background-color: #16a34a;
    border-color: #16a34a;
}

.btn-success:hover {
    color: #fff;
    background-color: #15803d;
    border-color: #15803d;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(22, 163, 74, 0.3);
}

/* --- Activation Form Specifics (Split Layout) --- */
.form-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: #ffffff;
}

.info-section {
    background-color: #f8fafc;
    border-left: 1px solid #e2e8f0;
}

.validation-message {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 0.35rem;
    display: block;
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding-left: 0.5rem;
}

.timeline-item {
    position: relative;
    padding-bottom: 2rem;
    padding-left: 2.5rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 32px;
    bottom: 0;
    width: 2px;
    background-color: #e5e7eb;
}

.timeline-item:last-child::before {
    display: none;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #e0e7ff;
    color: #4f46e5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    z-index: 1;
}

.premium-alert {
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
}

.alert-icon {
    flex-shrink: 0;
    margin-right: 1rem;
    color: #4f46e5;
    background-color: #e0e7ff;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- Activation Success Page Specifics --- */

/* 1. Success Ring with Font Awesome Icon */
.success-ring {
    width: 80px;
    height: 80px;
    background-color: #dcfce7; /* Light Green */
    color: #16a34a; /* Success Green */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 2.5rem;
    box-shadow: 0 0 0 8px rgba(220, 252, 231, 0.4);
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes popIn {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* 2. Purchase Code Container (Merged Input + Button) */
.tracking-wide {
    letter-spacing: 0.05em;
    font-size: 0.75rem;
}

.bg-success-subtle {
    background-color: #dcfce7 !important;
    color: #166534 !important;
}

.purchase-code-container {
    display: flex;
    align-items: center;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 0.5rem;
    transition: all 0.2s ease;
}

.purchase-code-container:focus-within {
    border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.1);
    background-color: #fff;
}

.purchase-code-container .form-control {
    box-shadow: none;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    letter-spacing: 0.5px;
    background-color: transparent;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* 3. Copy Button */
.btn-copy {
    display: flex;
    align-items: center;
    padding: 0.5rem 1.25rem;
    border-radius: 6px;
    border: 1px solid transparent;
    background-color: #fff;
    color: #374151;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    transition: all 0.2s;
    white-space: nowrap;
    cursor: pointer;
}

.btn-copy:hover {
    background-color: #f3f4f6;
    border-color: #e5e7eb;
}

.btn-copy:active {
    transform: translateY(1px);
}

/* --- Responsive Adjustments --- */
@media (max-width: 991px) {
    .activation-card {
        max-width: 500px;
    }
    
    .info-section {
        border-left: none;
        border-top: 1px solid #e2e8f0;
        background-color: #f8fafc;
        padding: 2rem !important;
    }

    .form-section {
        padding: 2rem !important;
    }

    .timeline-item::before {
        display: none;
    }
    
    .timeline-item {
        padding-bottom: 1.5rem;
    }
    
    .activation-wrapper {
        padding: 1rem;
    }
}