body.lf-modern-template {
    --lf-accent: var(--color-black, #2d3748);
    --lf-accent-soft: color-mix(in srgb, var(--lf-accent) 6%, #ffffff);
    --lf-accent-border: #e5e7eb;
    --lf-accent-strong: #0f172a;
    background: #f6f7f9 !important;
    background-repeat: no-repeat !important;
    background-attachment: scroll !important;
}

body.lf-modern-template {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    height: auto !important;
}

body.lf-modern-template nav,
body.lf-modern-template .content-left,
body.lf-modern-template .content-left-wrapper {
    display: none !important;
}

body.lf-modern-template .container-fluid,
body.lf-modern-template .container-fluid .row.row-height {
    max-width: 1220px;
    margin: 0 auto !important;
    min-height: auto !important;
    height: auto !important;
}

body.lf-modern-template .content-right#start {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    width: 100% !important;
    padding: 22px 14px 30px !important;
    overflow: visible !important;
    max-height: none !important;
}

body.lf-modern-template.lf-iframe-mode {
    background: #ffffff !important;
}

html:has(body.lf-modern-template.lf-iframe-mode),
body.lf-modern-template.lf-iframe-mode {
    margin: 0 !important;
    padding: 0 !important;
}

body.lf-modern-template.lf-iframe-mode .container-fluid,
body.lf-modern-template.lf-iframe-mode .container-fluid .row.row-height {
    max-width: 100% !important;
    margin: 0 !important;
    width: 100% !important;
}

body.lf-modern-template.lf-iframe-mode .container-fluid .row.row-height {
    display: block !important;
    padding: 0 !important;
}

body.lf-modern-template.lf-iframe-mode .content-right#start {
    padding: 6px !important;
    margin: 0 !important;
}

body.lf-modern-template.lf-iframe-mode #wizard_container {
    border-radius: 0 !important;
    border: 0 !important;
    box-shadow: none !important;
}

body.lf-modern-template.lf-iframe-mode #middle-wizard {
    padding: 8px 10px 4px !important;
}

body.lf-modern-template.lf-iframe-mode .form-builder-item {
    margin-bottom: 6px !important;
    padding: 8px 8px 6px !important;
    border-radius: 8px !important;
}

body.lf-modern-template.lf-iframe-mode .modern-flow-container {
    padding: 0 !important;
}

body.lf-modern-template.lf-iframe-mode .modern-flow-container.modern-flow-process {
    box-shadow: none !important;
    border: none !important;
}

body.lf-modern-template .lf-modern-brandbar {
    margin: 0 0 12px;
    padding: 0 2px;
}

body.lf-modern-template .lf-modern-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: 0;
    border-radius: 0;
    background: transparent;
    padding: 0;
    box-shadow: none;
}

body.lf-modern-template .lf-modern-brand img {
    width: auto;
    height: 46px;
    max-width: 220px;
    object-fit: contain;
    border-radius: 0;
    background: transparent;
    border: 0;
    padding: 0;
}

body.lf-modern-template .lf-modern-brand-meta {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

body.lf-modern-template .lf-modern-brand-chip {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--lf-accent-strong);
}

body.lf-modern-template .lf-modern-brand-meta strong {
    font-size: 15px;
    color: #111827;
}

body.lf-modern-template #wizard_container {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 14px !important;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06) !important;
    overflow: visible !important;
}

body.lf-modern-template #top-wizard {
    background: #f8fafc !important;
    padding: 12px 16px !important;
    border-bottom: 1px solid #e5e7eb !important;
}

body.lf-modern-template #location {
    color: #475569 !important;
    font-weight: 600 !important;
}

body.lf-modern-template #progressbar {
    background: #e5e7eb !important;
    border-radius: 999px !important;
    overflow: hidden !important;
}

body.lf-modern-template #progressbar div {
    background: #94a3b8 !important;
}

body.lf-modern-template #middle-wizard {
    padding: 10px 14px 6px !important;
}

body.lf-modern-template .step.row.allhere {
    margin: 0 !important;
    row-gap: 8px !important;
}

body.lf-modern-template .section_title,
body.lf-modern-template .section_title.wizard-header,
body.lf-modern-template h3.main_question {
    color: #0f172a !important;
    letter-spacing: -0.02em;
    font-weight: 800 !important;
}

body.lf-modern-template .form-builder-item {
    margin: 0 0 8px 0 !important;
    padding: 10px 10px 8px !important;
    border: 1px solid #eceff3 !important;
    border-radius: 10px !important;
    background: #fff !important;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
    transition: transform .2s ease, box-shadow .2s ease;
    animation: lfModernSlideIn .35s ease both;
}

body.lf-modern-template .modern-section-group {
    position: relative;
    border: 0;
    border-radius: 0;
    padding: 4px 0 2px 18px;
    margin: 4px 0 10px;
    background: transparent;
    box-shadow: none;
    animation: lfSectionReveal .35s ease both;
    animation-delay: var(--section-stagger, 0s);
}

body.lf-modern-template .modern-section-group::before {
    content: "";
    position: absolute;
    top: 38px;
    bottom: 8px;
    left: 3px;
    width: 2px;
    border-radius: 999px;
    background: #d1d5db;
}

body.lf-modern-template .modern-section-anchor {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 6px;
    font-size: 13px;
    font-weight: 800;
    color: var(--lf-accent-strong);
}

body.lf-modern-template .modern-section-title {
    flex: 1;
    font-size: 20px;
    line-height: 1.25;
}

body.lf-modern-template .modern-section-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 78px;
    height: 22px;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
    color: #64748b;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .03em;
    text-transform: uppercase;
    padding: 0 8px;
}

body.lf-modern-template .modern-section-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #9ca3af;
    box-shadow: 0 0 0 3px rgba(156, 163, 175, 0.2);
}

body.lf-modern-template .modern-section-group > .form-builder-item[type="section"] {
    margin-bottom: 6px !important;
    border-style: dashed !important;
    background: #ffffff !important;
}

body.lf-modern-template .modern-section-group > .form-builder-item[type="section"] .main_question,
body.lf-modern-template .modern-section-group > .form-builder-item[type="section"] [name="input_title"] {
    display: none !important;
}

body.lf-modern-template .modern-section-group > .form-builder-item:not([type="section"]) {
    margin-left: 4px !important;
}

body.lf-modern-template .modern-section-group > .form-builder-item.modern-section-linked-item {
    border-left: 2px solid #e5e7eb !important;
    border-top-left-radius: 10px !important;
    border-bottom-left-radius: 10px !important;
}

body.lf-modern-template .modern-field-status {
    float: right;
    margin: -2px 0 6px 8px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 2px 8px;
    border: 1px solid #e5e7eb;
    background: #f8fafc;
    color: #64748b;
}

body.lf-modern-template .modern-field-status.done {
    color: #065f46;
    border-color: #a7f3d0;
    background: #ecfdf5;
}

body.lf-modern-template .form-builder-item.modern-required-missing {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12), 0 6px 14px rgba(15, 23, 42, 0.08) !important;
}

body.lf-modern-template .form-builder-item.modern-required-missing .modern-field-status {
    border-color: #fca5a5;
    color: #991b1b;
    background: #fef2f2;
}

body.lf-modern-template .form-builder-item.modern-required-done {
    border-color: #86efac !important;
}

body.lf-modern-template .modern-flow-container {
    margin-top: 12px;
}

body.lf-modern-template .modern-flow-header {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
}

body.lf-modern-template .modern-flow-bullet {
    border: 1px solid #dbe4ee;
    background: #fff;
    color: #64748b;
    border-radius: 12px;
    padding: 7px 12px;
    font-size: 12px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all .22s ease;
}

body.lf-modern-template .modern-flow-bullet .n {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    font-weight: 900;
    font-size: 12px;
}

body.lf-modern-template .modern-flow-bullet.active {
    border-color: #94a3b8;
    color: #0f172a;
    transform: translateY(-1px);
}

body.lf-modern-template .modern-flow-bullet.done .n {
    background: #dcfce7;
    color: #166534;
}

body.lf-modern-template .modern-flow-step {
    display: none;
}

body.lf-modern-template .modern-flow-step.active {
    display: block;
}

body.lf-modern-template .modern-flow-step-title {
    font-size: 24px;
    margin: 2px 0 10px;
    color: #0f172a;
    font-weight: 800;
}

body.lf-modern-template .modern-flow-validation-hint {
    margin: 0 0 12px;
    border-radius: 10px;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

body.lf-modern-template .modern-flow-validation-hint.is-warning {
    border: 1px solid #fecaca;
    background: #fff1f2;
    color: #991b1b;
}

body.lf-modern-template .modern-flow-validation-hint.is-success {
    border: 1px solid #bbf7d0;
    background: #ecfdf5;
    color: #166534;
}

body.lf-modern-template .modern-flow-pager {
    margin-top: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

body.lf-modern-template .modern-flow-pager button {
    border: 1px solid #d1d5db;
    background: #fff;
    border-radius: 12px;
    padding: 7px 14px;
    font-weight: 800;
}

body.lf-modern-template .modern-flow-pager button:disabled {
    opacity: .45;
    cursor: not-allowed;
}

body.lf-modern-template .modern-flow-progress {
    color: #64748b;
    font-weight: 700;
    font-size: 13px;
}

body.lf-modern-template .modern-flow-process {
    max-width: 980px;
    margin: 0 auto;
    padding: 18px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.12);
}

body.lf-modern-template .modern-flow-process .modern-flow-header {
    margin-bottom: 18px;
}

body.lf-modern-template .modern-flow-process .modern-flow-bullet {
    padding: 10px 14px;
    border-radius: 14px;
}

body.lf-modern-template .modern-flow-process .modern-flow-bullet .n {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    font-size: 20px;
    font-weight: 900;
    background: linear-gradient(145deg, #e2e8f0, #f8fafc);
    color: #334155;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.75);
}

body.lf-modern-template .modern-flow-process .modern-flow-bullet.active {
    border-color: #64748b;
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
}

body.lf-modern-template .modern-flow-process .modern-flow-bullet.active .n {
    background: linear-gradient(145deg, #334155, #0f172a);
    color: #fff;
}

body.lf-modern-template .modern-flow-process .modern-flow-step-title {
    font-size: 30px;
    font-weight: 900;
    letter-spacing: -0.02em;
    margin: 4px 0 14px;
}

body.lf-modern-template .modern-flow-process .modern-flow-pager button {
    background: #0f172a;
    color: #fff;
    border-color: #0f172a;
}

body.lf-modern-template .modern-flow-process .modern-flow-pager button:disabled {
    background: #cbd5e1;
    border-color: #cbd5e1;
    color: #fff;
}

body.lf-modern-template .modern-flow-multipage {
    max-width: none;
    margin: 0;
    padding: 0 2px;
    border: 0;
    background: transparent;
    box-shadow: none;
}

body.lf-modern-template .modern-flow-multipage .modern-flow-header {
    display: none;
}

body.lf-modern-template .modern-multipage-progress {
    margin: 0 0 12px;
}

body.lf-modern-template .modern-multipage-progress-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 6px;
}

body.lf-modern-template .modern-multipage-current-title {
    font-size: 15px;
    color: #0f172a;
    font-weight: 800;
}

body.lf-modern-template .modern-multipage-progress-text {
    font-size: 12px;
    font-weight: 800;
    color: #64748b;
}

body.lf-modern-template .modern-multipage-progress-track {
    height: 9px;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
}

body.lf-modern-template .modern-multipage-progress-fill {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #334155, #64748b);
    transition: width .28s ease;
}

body.lf-modern-template .modern-flow-multipage .modern-flow-step-title {
    font-size: 22px;
    margin: 2px 0 10px;
}

body.lf-modern-template .modern-flow-multipage .modern-flow-pager {
    border-top: 1px solid #e5e7eb;
    padding-top: 12px;
}

body.lf-modern-template .modern-flow-multipage .modern-flow-pager button {
    background: #fff;
    color: #334155;
    border-color: #cbd5e1;
}

body.lf-modern-template .modern-section-group,
body.lf-modern-template .modern-section-group .form-builder-item:not([type="section"]) {
    opacity: 0;
    transform: translateY(8px);
}

body.lf-modern-template .modern-section-group.is-visible,
body.lf-modern-template .modern-section-group .form-builder-item.is-visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity .4s ease, transform .4s ease;
}

body.lf-modern-template .form-builder-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08) !important;
}

body.lf-modern-template input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
body.lf-modern-template select,
body.lf-modern-template textarea {
    border-radius: 10px !important;
    border: 1px solid #d3e0fb !important;
    background: #fff !important;
    box-shadow: 0 2px 7px rgba(15, 23, 42, 0.05) !important;
}

body.lf-modern-template input:focus,
body.lf-modern-template select:focus,
body.lf-modern-template textarea:focus {
    border-color: #9ca3af !important;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.18) !important;
}

body.lf-modern-template #bottom-wizard {
    border-top: 1px solid #e2e8f0 !important;
    background: linear-gradient(180deg, #ffffff, #f7fbff) !important;
    padding: 14px 16px !important;
}

body.lf-modern-template #bottom-wizard .btn_1,
body.lf-modern-template #bottom-wizard button,
body.lf-modern-template #bottom-wizard input[type="submit"] {
    border: 0 !important;
    border-radius: 12px !important;
    background: #334155 !important;
    color: #fff !important;
    font-weight: 800 !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.22) !important;
}

body.lf-modern-template #bottom-wizard .btn_1:hover,
body.lf-modern-template #bottom-wizard button:hover,
body.lf-modern-template #bottom-wizard input[type="submit"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.28) !important;
}

@keyframes lfModernSlideIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes lfSectionReveal {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
