:root {
    --primary: #0419dc;
    --dark: #012444;
    --accent: #1e90ff;
    --bg: #f0f4f8;
    --white: #ffffff;
    --border: #e1e8f0;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }

body { background: var(--bg); padding: 50px 20px; }

.enrollment-wrapper { max-width: 1100px; margin: 0 auto; }

.form-container {
    display: flex;
    background: var(--white);
    border-radius: 25px;
    box-shadow: 0 25px 50px rgba(1, 36, 68, 0.1);
    min-height: 650px;
    overflow: hidden;
}

/* Sidebar Styling */
.form-sidebar {
    width: 320px;
    background: var(--dark);
    padding: 40px;
    display: flex;
    flex-direction: column;
    color: var(--white);
}

.sidebar-brand img { width: 150px; border-radius: 8px; margin-bottom: 50px; }

.step-list { list-style: none; flex-grow: 1; }

.step-item {
    display: flex;
    align-items: center;
    margin-bottom: 35px;
    cursor: pointer;
    opacity: 0.5;
    transition: 0.3s;
}

.step-item.active { opacity: 1; transform: translateX(10px); }

.step-num {
    width: 35px; height: 35px;
    border: 2px solid var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-weight: 600;
}

.step-item.active .step-num { background: var(--accent); color: white; }

.step-txt small { display: block; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px; color: var(--accent); }
.step-txt span { font-size: 0.95rem; font-weight: 500; }

.sidebar-info { font-size: 0.8rem; opacity: 0.6; line-height: 1.5; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 20px; }
.sidebar-info i { margin-bottom: 10px; font-size: 1.2rem; display: block; color: var(--accent); }

/* Main Content Styling */
.form-content { flex: 1; padding: 60px; position: relative; }

.form-step-section { display: none; animation: fadeIn 0.4s ease-in-out; }
.form-step-section.active { display: block; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.section-title { color: var(--dark); font-size: 1.8rem; margin-bottom: 8px; }
.section-subtitle { color: #666; font-size: 0.95rem; margin-bottom: 40px; }

/* Input Styles */
.input-row { display: flex; gap: 20px; margin-bottom: 25px; }
.input-group { flex: 1; margin-bottom: 25px; display: flex; flex-direction: column; }
.input-group label { font-size: 0.85rem; font-weight: 600; color: var(--dark); margin-bottom: 8px; }

input[type="text"], input[type="email"], select, textarea {
    padding: 15px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    background: #f9fbff;
    outline: none;
    font-size: 0.95rem;
    transition: 0.3s;
}

input:focus, textarea:focus { border-color: var(--primary); background: #fff; box-shadow: 0 0 0 4px rgba(4, 25, 220, 0.05); }

/* Navigation Buttons */
.form-nav { margin-top: 40px; display: flex; gap: 15px; }

.btn-next, .btn-submit {
    background: var(--primary);
    color: white;
    padding: 15px 35px;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.btn-prev {
    background: #eef2f7;
    color: var(--dark);
    padding: 15px 30px;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
}

.btn-next:hover, .btn-submit:hover { background: var(--dark); transform: translateY(-2px); }

/* Upload Area */
.upload-container { display: flex; gap: 20px; }
.upload-box { flex: 1; }
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    position: relative;
    cursor: pointer;
}
.drop-zone i { font-size: 2rem; color: var(--primary); margin-bottom: 15px; }
.drop-zone input { position: absolute; width: 100%; height: 100%; top: 0; left: 0; opacity: 0; cursor: pointer; }
.drop-zone:hover { border-color: var(--primary); background: #f0f4ff; }

/* Responsive */
@media (max-width: 900px) {
    .form-container { flex-direction: column; }
    .form-sidebar { width: 100%; padding: 30px; }
    .form-content { padding: 30px 20px; }
    .input-row { flex-direction: column; gap: 0; }
}

/* Styling for completed steps in the sidebar */
.step-item.completed .step-num {
    background: #2ecc71;
    border-color: #2ecc71;
    color: white;
}

.step-item.completed .step-num::after {
    content: '\f00c'; /* FontAwesome Checkmark */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

/* Hide the number when completed */
.step-item.completed .step-num {
    font-size: 0;
}
.step-item.completed .step-num::after {
    font-size: 0.9rem;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(1, 36, 68, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: 0.4s ease;
    z-index: 9999;
}

.modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Modal Card */
.modal-card {
    background: white;
    padding: 50px;
    border-radius: 30px;
    text-align: center;
    max-width: 500px;
    width: 90%;
    transform: translateY(30px);
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-overlay.show .modal-card {
    transform: translateY(0);
}

.modal-icon {
    width: 80px; height: 80px;
    background: #2ecc71;
    color: white;
    font-size: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin: 0 auto 25px;
    box-shadow: 0 10px 20px rgba(46, 204, 113, 0.3);
}

.modal-card h2 { color: var(--dark); margin-bottom: 15px; font-size: 1.8rem; }
.modal-card p { color: #666; line-height: 1.6; margin-bottom: 30px; }

.modal-ref {
    background: #f0f4f8;
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 30px;
}
.modal-ref span { display: block; font-size: 0.75rem; text-transform: uppercase; color: #888; margin-bottom: 5px; }
.modal-ref strong { font-size: 1.2rem; color: var(--primary); letter-spacing: 1px; }

/* Close Icon Styling */
.modal-close-icon {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 28px;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.modal-close-icon:hover {
    color: #1e293b;
}

/* Modal Actions Layout */
.modal-footer-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-top: 25px;
}

/* Secondary Dismiss Button */
.btn-close-secondary {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: underline;
    transition: 0.2s;
}

.btn-close-secondary:hover {
    color: #2b67f6;
}

/* Ensure card is the reference for the X position */
.modal-card {
    position: relative;
}

/* Dismiss link styling */
.btn-close-text {
    background: none;
    border: none;
    color: #64748b;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: underline;
    transition: 0.3s;
}

.btn-close-text:hover {
    color: #0f172a;
}

/* The Pipeline Button */
.btn-pipeline {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 18px 35px;
    border-radius: 15px;
    text-decoration: none;
    font-weight: 700;
    transition: 0.3s;
    box-shadow: 0 10px 25px rgba(4, 25, 220, 0.3);
}

.btn-pipeline:hover {
    background: var(--dark);
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(4, 25, 220, 0.4);
}