@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    /* ZEN Group Palette - Sleek Dark Neutral to let the colorful logo shine */
    --primary: #0f172a; /* Slate Dark */
    --primary-hover: #1e293b;
    --primary-light: #f1f5f9;
    
    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    
    --text-main: #334155;
    --text-muted: #94a3b8;
    --text-light: #cbd5e1;
    
    --border-color: #e2e8f0;
    --border-focus: var(--primary);
    
    --input-bg: transparent;
    
    --error: #ef4444; /* Standard red for errors, kept separate from primary */
    --success: #10b981;

    /* Thinner, sleeker radius */
    --radius-xl: 12px;
    --radius-lg: 8px;
    --radius-md: 4px;
    --transition: all 0.25s ease;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.4;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    overflow-x: hidden;
    font-weight: 400;
    user-select: none;
    -webkit-user-select: none;
}

input, textarea {
    user-select: auto;
    -webkit-user-select: auto;
}

img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    pointer-events: none; /* also prevents drag */
}

/* Make images clickable if needed, but not draggable */
img.brand-logo {
    pointer-events: auto;
    -webkit-user-drag: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.container {
    width: 100%;
    max-width: 960px; /* Slightly narrower for a more elegant look */
    position: relative;
    z-index: 1;
}

.card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    display: flex;
    flex-direction: row;
    border: 1px solid rgba(0,0,0,0.03);
}

/* Left Panel */
.left-panel {
    flex: 0 0 340px;
    background: #ffffff;
    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    border-right: 1px solid var(--border-color);
}

.brand-logo {
    width: 130px;
    height: auto;
    margin-bottom: 30px;
    object-fit: contain;
}

.left-panel h1 {
    font-size: 28px;
    font-weight: 500;
    color: #0f172a;
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}

.left-panel h2 {
    font-size: 16px;
    font-weight: 400;
    color: var(--text-muted);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.left-panel p {
    color: var(--text-muted);
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
}

/* Right Panel */
.right-panel {
    flex: 1;
    padding: 50px 40px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
}

/* Stepper UI */
.stepper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
    padding: 0;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    position: relative;
    z-index: 2;
}

.step-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 400;
    font-size: 13px;
    color: var(--text-muted);
    transition: var(--transition);
}

.step-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 300;
    transition: var(--transition);
}

.step.active .step-circle {
    border-color: var(--primary);
    background: var(--primary);
    color: #ffffff;
}
.step.active .step-label {
    color: var(--primary);
    font-weight: 500;
}

.step.completed .step-circle {
    border-color: var(--primary);
    background: #ffffff;
    color: var(--primary);
}
.step.completed .step-label {
    color: var(--text-main);
}

.step-line {
    flex: 1;
    height: 1px;
    background: var(--border-color);
    margin: 0 12px;
    position: relative;
    top: -9px;
    z-index: 1;
    transition: var(--transition);
}

.step.completed + .step-line {
    background: var(--primary);
}

/* Form Steps */
form {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.step-content {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.step-content.active {
    display: block;
}

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

.step-title {
    font-size: 20px;
    font-weight: 400;
    margin-bottom: 24px;
    color: var(--text-main);
    letter-spacing: 0.01em;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 24px;
}

.full-width {
    grid-column: span 2;
}

.field {
    position: relative;
    margin-top: 12px; /* space for the floating label */
}

/* Thin material-like inputs */
.field input,
.field textarea,
.field select {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-color);
    border-radius: 0;
    padding: 10px 0;
    color: var(--text-main);
    font-family: inherit;
    font-size: 16px;
    font-weight: 400;
    transition: var(--transition);
    outline: none;
}

.field textarea {
    min-height: 80px;
    resize: vertical;
    padding-top: 12px;
}

.field select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
    background-size: 14px;
    color: transparent;
}
.field select:focus, .field select.has-value {
    color: var(--text-main);
}

.field label {
    position: absolute;
    left: 0;
    top: 10px;
    color: var(--text-muted);
    font-size: 16px;
    font-weight: 400;
    pointer-events: none;
    transition: var(--transition);
    transform-origin: left top;
}

.field input:focus~label,
.field input:not(:placeholder-shown)~label,
.field textarea:focus~label,
.field textarea:not(:placeholder-shown)~label,
.field select:focus~label,
.field select.has-value~label,
.field label.active-label {
    transform: translateY(-22px) scale(0.85);
    color: var(--primary);
    font-weight: 400;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
    border-color: var(--border-focus);
    box-shadow: 0 1px 0 0 var(--border-focus);
}

/* File input styling */
.file-field input[type="file"] {
    padding-top: 18px;
    padding-bottom: 8px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-muted);
}
.file-field input[type="file"]::file-selector-button {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    padding: 4px 12px;
    border-radius: var(--radius-md);
    margin-right: 12px;
    font-weight: 400;
    font-size: 12px;
    cursor: pointer;
    transition: var(--transition);
}
.file-field input[type="file"]::file-selector-button:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.error-msg {
    color: var(--error);
    font-size: 11px;
    margin-top: 4px;
    height: 14px;
    opacity: 0;
    transform: translateY(-2px);
    transition: var(--transition);
    font-weight: 400;
}

.error-msg.visible {
    opacity: 1;
    transform: translateY(0);
}

.field.has-error input,
.field.has-error textarea,
.field.has-error select {
    border-color: var(--error);
    box-shadow: 0 1px 0 0 var(--error);
}
.field.has-error label {
    color: var(--error) !important;
}

/* Stepper Actions */
.stepper-actions {
    margin-top: auto;
    padding-top: 40px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

button {
    padding: 10px 24px;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 400;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.02em;
}

.btn-primary {
    background: var(--primary);
    color: #ffffff;
    flex: 0 1 auto;
    min-width: 120px;
}

.btn-primary:hover {
    background: var(--primary-hover);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border-color: var(--border-color);
    flex: 0 1 auto;
    min-width: 100px;
}

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
}

button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

.helper-text {
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 24px;
    font-weight: 300;
}

.success-container {
    display: none;
    text-align: center;
    padding: 40px 20px;
}

.success-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 24px;
    animation: scale-up 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes scale-up {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

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

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

button.loading .spinner {
    display: block;
}

button.loading span {
    display: none;
}

/* Responsive */
@media (max-width: 900px) {
    .card {
        flex-direction: column;
    }
    
    .left-panel {
        flex: none;
        padding: 24px 20px;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        text-align: center;
    }

    .brand-logo {
        width: 100px;
        margin: 0 auto 12px;
    }
    
    .left-panel h2 {
        margin-bottom: 0;
    }
    
    .left-panel p {
        display: none;
    }

    .right-panel {
        padding: 30px 20px;
    }
}

@media (max-width: 640px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .full-width {
        grid-column: auto;
    }
    
    .stepper-actions {
        flex-direction: column-reverse;
    }
    
    .btn-primary, .btn-secondary {
        width: 100%;
    }
}