﻿/* نوار ثابت مشاوره رایگان بالای همه صفحات */
:root {
    --free-consult-h: 64px;
}

body.has-free-consult #header.fixed-top {
    top: var(--free-consult-h) !important;
}

body.has-free-consult #main {
    padding-top: calc(40px + var(--free-consult-h));
}

body.has-free-consult section#slider {
    margin-top: calc(120px + var(--free-consult-h));
}

body.has-free-consult #hero.login-hero {
    padding-top: calc(108px + var(--free-consult-h)) !important;
}

body.has-free-consult #content .container {
    padding-top: calc(80px + var(--free-consult-h));
}

.free-consult-bar {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1205;
    background: linear-gradient(100deg, #0c5a40 0%, #14865f 42%, #0f6b4c 100%);
    color: #fff;
    box-shadow: 0 4px 16px rgba(12, 70, 48, 0.28);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.free-consult-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
    gap: 10px 14px;
    min-height: 56px;
    padding-top: 8px;
    padding-bottom: 8px;
}

.free-consult-headline {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    overflow: hidden;
}

.free-consult-headline-icon {
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 209, 102, 0.22);
    color: #ffd166;
    font-size: 15px;
    box-shadow: inset 0 0 0 1px rgba(255, 209, 102, 0.35);
}

.free-consult-headline-text {
    margin: 0;
    min-width: 0;
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.45;
    color: #f3fff8;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.12);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.free-consult-headline-text strong {
    color: #ffd166;
    font-weight: 900;
    font-size: 13.5px;
    letter-spacing: -0.2px;
}

.free-consult-sep {
    display: inline-block;
    margin: 0 6px;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 400;
}

.free-consult-dot {
    display: inline-block;
    margin: 0 5px;
    color: #ffd166;
    font-size: 11px;
    vertical-align: middle;
}

.free-consult-toggle {
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    border: 0;
    background: transparent;
    color: #fff;
    font-weight: 800;
    font-size: 14px;
    padding: 4px 0;
    cursor: pointer;
}

.free-consult-toggle .free-consult-chevron {
    transition: transform 0.2s ease;
}

.free-consult-bar.is-open .free-consult-toggle .free-consult-chevron {
    transform: rotate(180deg);
}

.free-consult-form {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
    margin: 0;
    position: relative;
    z-index: 1;
}

.free-consult-field {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    width: 190px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 10px;
    padding: 0 10px;
    min-height: 38px;
}

.free-consult-field label {
    margin: 0;
    white-space: nowrap;
    font-size: 12px;
    font-weight: 700;
    color: #e8fff5;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.free-consult-field input {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    height: 36px;
    padding: 0;
}

.free-consult-field input::placeholder {
    color: rgba(255, 255, 255, 0.72);
    font-weight: 600;
}

.free-consult-submit {
    flex: 0 0 auto;
    border: 0;
    border-radius: 10px;
    min-height: 38px;
    padding: 0 14px;
    background: #ffd166;
    color: #1a3d2c;
    font-weight: 800;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    cursor: pointer;
    transition: filter 0.15s ease, transform 0.15s ease;
}

.free-consult-submit:hover,
.free-consult-submit:focus {
    filter: brightness(1.05);
    transform: translateY(-1px);
}

.free-consult-submit:disabled {
    opacity: 0.7;
    cursor: wait;
    transform: none;
}

.free-consult-msg {
    display: none;
    flex: 0 0 100%;
    width: 100%;
    margin: 0;
    padding: 2px 10px 4px;
    font-size: 12.5px;
    font-weight: 700;
    text-align: center;
    order: 5;
    border-radius: 8px;
}

.free-consult-msg.is-visible {
    display: block;
}

.free-consult-msg.is-ok {
    color: #123d2c;
    background: rgba(255, 209, 102, 0.92);
}

.free-consult-msg.is-err {
    color: #ffe0e0;
    background: rgba(120, 20, 20, 0.28);
}

@media (max-width: 1199px) {
    .free-consult-headline-text {
        font-size: 12px;
    }

    .free-consult-field {
        width: 170px;
    }
}

@media (max-width: 991px) {
    :root {
        --free-consult-h: 48px;
    }

    .free-consult-inner {
        flex-wrap: wrap;
        min-height: 46px;
        padding-top: 6px;
        padding-bottom: 6px;
        gap: 8px;
    }

    .free-consult-toggle {
        display: inline-flex;
    }

    .free-consult-headline,
    .free-consult-form {
        display: none;
        width: 100%;
    }

    .free-consult-bar.is-open .free-consult-headline {
        display: flex;
        flex: 0 0 100%;
        padding: 6px 10px;
        border-radius: 10px;
        background: rgba(0, 0, 0, 0.14);
        border: 1px solid rgba(255, 209, 102, 0.28);
        overflow: visible;
    }

    .free-consult-bar.is-open .free-consult-headline-text {
        white-space: normal;
    }

    .free-consult-bar.is-open .free-consult-form {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        flex: 0 0 100%;
        min-width: 0;
        gap: 8px;
        padding-bottom: 4px;
    }

    .free-consult-field {
        width: 100%;
        min-height: 42px;
    }

    .free-consult-field input {
        height: 40px;
        font-size: 14px;
    }

    .free-consult-submit {
        width: 100%;
        justify-content: center;
        min-height: 42px;
    }
}
