/* LF Drive unified public layout */
:root{
    --lf-public-ink:#13201a;
    --lf-public-muted:#718077;
    --lf-public-line:#e3eae5;
    --lf-public-green:#13935a;
    --lf-public-bright:#2fd17e;
    --lf-public-wash:#e8f7ef;
    --lf-public-display:
        "Space Grotesk",-apple-system,
        BlinkMacSystemFont,"Segoe UI",sans-serif;
    --lf-public-body:
        "Inter",-apple-system,
        BlinkMacSystemFont,"Segoe UI",sans-serif
}
html{
    scroll-padding-top:78px
}
body{
    font-family:var(--lf-public-body)
}
body h1,
body h2,
body h3,
body h4{
    font-family:var(--lf-public-display)
}
.lfh,
.lfh *,
.lff,
.lff *{
    box-sizing:border-box
}
.lfh{
    position:sticky;
    z-index:10000;
    top:0;
    width:100%;
    border-bottom:1px solid var(--lf-public-line);
    background:rgba(255,255,255,.96);
    color:var(--lf-public-ink);
    font-family:var(--lf-public-body);
    backdrop-filter:blur(14px)
}
.lfh__inner{
    width:min(100% - 44px,1120px);
    min-height:66px;
    margin:0 auto;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:28px
}
.lfh__logo{
    display:flex;
    flex:none;
    align-items:center;
    gap:9px;
    color:var(--lf-public-ink)!important;
    font-family:var(--lf-public-display);
    font-size:19px;
    font-weight:700;
    line-height:1;
    text-decoration:none!important
}
.lfh__ring,
.lff__ring{
    width:13px;
    height:13px;
    flex:none;
    border:3px solid var(--lf-public-bright);
    border-radius:50%
}
.lfh__nav{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:22px;
    margin-left:auto
}
.lfh__nav a{
    color:#46554c!important;
    font-size:14px;
    font-weight:500;
    line-height:1;
    text-decoration:none!important;
    white-space:nowrap
}
.lfh__nav a:hover{
    color:var(--lf-public-ink)!important
}
.lfh__actions{
    display:flex;
    flex:none;
    align-items:center;
    gap:10px
}
.lfh__login{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:40px;
    padding:9px 18px;
    border-radius:100px;
    background:var(--lf-public-green);
    color:#fff!important;
    font-size:14px;
    font-weight:700;
    line-height:1;
    text-decoration:none!important
}
.lfh__login:hover{
    background:#0e7245
}
.lfh__burger{
    display:none;
    width:42px;
    height:42px;
    padding:10px;
    border:1px solid var(--lf-public-line);
    border-radius:11px;
    background:#fff;
    cursor:pointer
}
.lfh__burger span{
    display:block;
    width:100%;
    height:2px;
    margin:4px 0;
    border-radius:2px;
    background:var(--lf-public-ink);
    transition:.18s ease
}
.lfh__burger.open span:nth-child(1){
    transform:translateY(6px) rotate(45deg)
}
.lfh__burger.open span:nth-child(2){
    opacity:0
}
.lfh__burger.open span:nth-child(3){
    transform:translateY(-6px) rotate(-45deg)
}
.lfh__mobile{
    display:none;
    padding:6px 22px 18px;
    border-top:1px solid var(--lf-public-line);
    background:#fff
}
.lfh__mobile.open{
    display:block
}
.lfh__mobile a{
    display:block;
    padding:12px 2px;
    border-bottom:1px solid #edf1ed;
    color:#46554c!important;
    font-size:15px;
    font-weight:550;
    text-decoration:none!important
}
.lfh__mobile-login{
    margin-top:12px;
    border:0!important;
    border-radius:100px;
    background:var(--lf-public-green);
    color:#fff!important;
    text-align:center
}
.lff{
    width:100%;
    margin:0;
    padding:0;
    border:0;
    background:#0f1a14;
    color:#c4d2c9;
    font-family:var(--lf-public-body);
    font-size:14px;
    line-height:1.6
}
.lff__inner{
    width:min(100% - 44px,1120px);
    margin:0 auto;
    padding-top:48px
}
.lff__top{
    display:grid;
    grid-template-columns:1.5fr 1fr 1fr 1fr;
    gap:32px;
    padding-bottom:34px
}
.lff__logo{
    display:flex;
    align-items:center;
    gap:9px;
    margin-bottom:12px;
    color:#fff!important;
    font-family:var(--lf-public-display);
    font-size:19px;
    font-weight:700;
    text-decoration:none!important
}
.lff__brand p{
    max-width:300px;
    margin:0 0 14px;
    color:#8ea89a;
    font-size:14px;
    line-height:1.6
}
.lff__mail{
    color:var(--lf-public-bright)!important;
    font-weight:650;
    text-decoration:none!important
}
.lff__column h2{
    margin:0 0 14px;
    color:#7e988a;
    font-family:var(--lf-public-display);
    font-size:12px;
    font-weight:650;
    letter-spacing:.07em;
    line-height:1.2;
    text-transform:uppercase
}
.lff__column a{
    display:block;
    margin-bottom:9px;
    color:#c4d2c9!important;
    font-size:14px;
    text-decoration:none!important
}
.lff__column a:hover{
    color:#fff!important
}
.lff__bottom{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px 24px;
    padding:18px 0 26px;
    border-top:1px solid rgba(255,255,255,.08);
    color:#7e988a;
    font-size:13px
}
.lff__bottom strong{
    color:#c4d2c9
}
@media(max-width:1040px){
    .lfh__nav{gap:14px}
    .lfh__nav a{font-size:13px}
}
@media(max-width:900px){
    .lfh__nav{display:none}
    .lfh__burger{display:block}
    .lfh__login{display:none}
}
@media(max-width:760px){
    .lff__top{
        grid-template-columns:1fr 1fr;
        gap:27px
    }
    .lff__bottom{
        align-items:flex-start;
        flex-direction:column
    }
}
@media(max-width:480px){
    .lfh__inner,
    .lff__inner{
        width:min(100% - 28px,1120px)
    }
    .lff__top{
        grid-template-columns:1fr;
        gap:23px
    }
}


/* LFDRIVE_PUBLIC_DRAWER_FIX_V2 */
.lfh__backdrop{
    position:fixed;
    z-index:10001;
    inset:0;
    opacity:0;
    visibility:hidden;
    background:rgba(10,22,15,.52);
    transition:
        opacity .22s ease,
        visibility .22s ease
}
.lfh__backdrop.open{
    opacity:1;
    visibility:visible
}
@media(max-width:900px){
    .lfh__inner{
        position:relative;
        z-index:10004
    }
    .lfh__burger{
        position:relative;
        z-index:10005
    }
    .lfh__mobile{
        position:fixed;
        z-index:10003;
        top:0;
        right:0;
        bottom:0;
        display:block;
        width:min(86vw,380px);
        height:100vh;
        height:100dvh;
        padding:82px 22px 28px;
        overflow-y:auto;
        border:0;
        border-left:1px solid var(--lf-public-line);
        background:#fff;
        box-shadow:-20px 0 60px rgba(19,32,26,.18);
        visibility:hidden;
        transform:translateX(105%);
        transition:
            transform .24s ease,
            visibility .24s ease
    }
    .lfh__mobile.open{
        display:block;
        visibility:visible;
        transform:translateX(0)
    }
    .lfh__mobile a{
        padding:14px 4px;
        font-size:16px
    }
    .lfh__mobile .lfh__mobile-login,
    .lfh__mobile a.lfh__mobile-login{
        margin-top:18px;
        padding:14px 18px;
        border:0!important;
        background:var(--lf-public-green)!important;
        color:#fff!important;
        -webkit-text-fill-color:#fff!important;
        font-weight:700;
        text-align:center
    }
    body.lfh-menu-open{
        overflow:hidden
    }
}

/*
 * Когда общий footer уже загружен, старые футеры
 * должны быть полностью скрыты даже до удаления JS.
 */
body:has(#lfPublicFooter) .lft:not(#lfPublicFooter),
body:has(#lfPublicFooter) footer:not(#lfPublicFooter),
body:has(#lfPublicFooter) .footer:not(#lfPublicFooter){
    display:none!important
}


/* LFDRIVE_PUBLIC_LAYOUT_FIX_V3 */
:root {
    --lf-public-bg: #f4f7f2;
    --lf-public-surface: #fff;
    --lf-public-ink: #13201a;
    --lf-public-soft: #4a5b52;
    --lf-public-line: #e2e8de;
    --lf-public-green: #13935a;
    --lf-public-green-deep: #0e7245;
    --lf-public-bright: #2fd17e;
}

.lf-public-header {
    position: sticky;
    top: 0;
    z-index: 900;
    width: 100%;
    background: rgba(244, 247, 242, .94);
    border-bottom: 1px solid var(--lf-public-line);
    backdrop-filter: blur(12px);
}

.lf-public-nav {
    width: min(1120px, calc(100% - 48px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 28px;
}

.lf-public-logo {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--lf-public-ink);
    font-family: "Space Grotesk", sans-serif;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: -.02em;
    line-height: 1;
    text-decoration: none;
}

.lf-public-logo-mark {
    position: relative;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: var(--lf-public-ink);
}

.lf-public-logo-mark::before,
.lf-public-logo-mark::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 11px;
    height: 11px;
    border: 2.5px solid var(--lf-public-bright);
    border-radius: 50%;
    transform: translate(-73%, -50%);
}

.lf-public-logo-mark::after {
    transform: translate(-8%, -50%);
    opacity: .55;
}

.lf-public-desktop-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 22px;
}

.lf-public-desktop-nav a {
    color: var(--lf-public-soft);
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
}

.lf-public-desktop-nav a:hover {
    color: var(--lf-public-ink);
}

.lf-public-nav-actions {
    display: flex;
    align-items: center;
}

.lf-public-login,
.lf-public-mobile-login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 9px 20px;
    border-radius: 999px;
    background: var(--lf-public-green);
    color: #fff !important;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
}

.lf-public-login:hover,
.lf-public-mobile-login:hover {
    background: var(--lf-public-green-deep);
    color: #fff !important;
}

.lf-public-burger {
    display: none;
}

.lf-public-mobile-menu,
.lf-public-menu-backdrop {
    display: none;
}

/* Отступ на главной странице инструментов и во всех генераторах. */
html.lf-tools-page body > main,
html.lf-tools-page body > .wrap,
html.lf-tools-page body > .container {
    padding-top: 36px;
}

body.lf-public-menu-open {
    overflow: hidden !important;
}

@media (max-width: 900px) {
    .lf-public-nav {
        width: calc(100% - 32px);
        height: 64px;
    }

    .lf-public-desktop-nav,
    .lf-public-desktop-login {
        display: none !important;
    }

    .lf-public-nav-actions {
        margin-left: auto;
    }

    .lf-public-burger {
        width: 42px;
        height: 42px;
        padding: 10px;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        justify-content: center;
        gap: 5px;
        border: 1px solid var(--lf-public-line);
        border-radius: 11px;
        background: #fff;
        cursor: pointer;
    }

    .lf-public-burger span {
        display: block;
        height: 2px;
        border-radius: 2px;
        background: var(--lf-public-ink);
    }

    .lf-public-menu-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1998;
        display: block;
        visibility: hidden;
        background: rgba(19, 32, 26, .58);
        opacity: 0;
        pointer-events: none;
        transition: opacity .22s ease, visibility .22s ease;
    }

    .lf-public-menu-backdrop.open {
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
    }

    .lf-public-mobile-menu {
        position: fixed;
        z-index: 2000;
        top: 0;
        right: 0;
        bottom: 0;
        width: min(340px, calc(100vw - 18px));
        height: 100dvh;
        padding: 18px 17px max(22px, env(safe-area-inset-bottom));
        display: flex;
        flex-direction: column;
        overflow-y: auto;
        background: var(--lf-public-bg);
        box-shadow: -18px 0 50px rgba(19, 32, 26, .18);
        visibility: hidden;
        transform: translateX(105%);
        pointer-events: none;
        transition: transform .24s ease, visibility .24s ease;
    }

    .lf-public-mobile-menu.open {
        visibility: visible;
        transform: translateX(0);
        pointer-events: auto;
    }

    .lf-public-mobile-head {
        flex: 0 0 auto;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding-bottom: 18px;
    }

    .lf-public-menu-close {
        width: 42px;
        height: 42px;
        border: 1px solid var(--lf-public-line);
        border-radius: 11px;
        background: #fff;
        color: var(--lf-public-ink);
        font: 400 30px/36px Inter, sans-serif;
        cursor: pointer;
    }

    .lf-public-mobile-links {
        display: flex;
        flex-direction: column;
    }

    .lf-public-mobile-links a {
        display: block;
        padding: 14px 4px;
        border-bottom: 1px solid var(--lf-public-line);
        color: var(--lf-public-ink);
        font-family: Inter, sans-serif;
        font-size: 15px;
        font-weight: 500;
        text-decoration: none;
    }

    .lf-public-mobile-login {
        flex: 0 0 auto;
        width: 100%;
        min-height: 48px;
        margin-top: auto;
        color: #fff !important;
    }

    html.lf-tools-page body > main,
    html.lf-tools-page body > .wrap,
    html.lf-tools-page body > .container {
        padding-top: 24px;
    }
}

/* LFDRIVE_LEGAL_TOOLS_FIX_V5 */

/*
 * Юридические страницы раньше задавали padding всему body,
 * из-за чего сдвигались header и footer.
 */
html body.lf-legal-page {
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden;
}

/* Шапка и подвал занимают обычные 100% без появления скролла. */
body.lf-legal-page #lfPublicHeader,
body.lf-legal-page #lfPublicFooter {
    width: 100% !important;
    max-width: none !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    border-radius: 0 !important;
}

/* Сохраняем нормальные отступы вокруг юридического документа. */
body.lf-legal-page > .wrap {
    width: calc(100% - 40px);
    margin: 40px auto !important;
}

/* Отступ между инструментами и подвалом. */
html.lf-tools-page #lfPublicFooter {
    width: 100% !important;
    margin: 56px 0 0 !important;
}

/* Страховка от горизонтального скролла общего шаблона. */
html:not(.lf-auth-page),
html:not(.lf-auth-page) body {
    max-width: 100%;
    overflow-x: hidden;
}

@media (max-width: 700px) {
    body.lf-legal-page > .wrap {
        width: calc(100% - 28px);
        margin: 22px auto !important;
    }

    html.lf-tools-page #lfPublicFooter {
        margin-top: 38px !important;
    }
}


/* LFDRIVE_STICKY_HEADER_FIX_V6 */

/*
 * overflow:hidden ломает position:sticky.
 * clip убирает горизонтальный выход без создания
 * дополнительного контейнера прокрутки.
 */
html,
body,
html:not(.lf-auth-page),
html:not(.lf-auth-page) body,
html body.lf-legal-page {
    overflow-x: clip !important;
}

/* Шапка снова закрепляется сверху при прокрутке. */
#lfPublicHeader {
    position: sticky !important;
    top: 0 !important;
    right: auto !important;
    left: auto !important;
    z-index: 1900 !important;
    width: 100% !important;
    margin: 0 !important;
}

/* Мобильное меню должно находиться выше закреплённой шапки. */
.lf-public-menu-backdrop {
    z-index: 1998 !important;
}

.lf-public-mobile-menu {
    z-index: 2000 !important;
}
