/* Floating consultation widget; all selectors scoped to avoid theme / Elementor conflicts. */
#mmc-tax-widget,
#mmc-tax-widget * { box-sizing: border-box; }
#mmc-tax-widget {
    --mmc-green: #04180F;
    --mmc-gold: #D1AD5D;
    --mmc-paper: #F8F6F0;
    position: fixed;
    bottom: 26px;
    bottom: calc(26px + env(safe-area-inset-bottom, 0px));
    left: 24px;
    z-index: 999990;
    font-family: "iranyekan-medium-fanum", Sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.9em;
    direction: rtl;
    text-align: right;
}
/* Reuse fonts already registered by the site (no extra font requests). */
#mmc-tax-widget *,
#mmc-tax-widget *::before,
#mmc-tax-widget *::after {
    font-family: "iranyekan-medium-fanum", Sans-serif;
    font-weight: 500;
    line-height: 1.9em;
}
#mmc-tax-widget [hidden] { display: none !important; }
#mmc-tax-widget button,
#mmc-tax-widget input { font: inherit; }
#mmc-tax-widget button { cursor: pointer; }
#mmc-tax-widget svg { display: block; width: 20px; height: 20px; flex-shrink: 0; }
#mmc-tax-widget .mmc-tax-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 54px;
    padding: 10px 21px;
    border: 1px solid #E6C780;
    border-radius: 99px;
    background: linear-gradient(135deg, #E4CA89, #D1AD5D 70%);
    box-shadow: 0 10px 28px rgba(0,0,0,.24), 0 2px 7px rgba(0,0,0,.12);
    color: var(--mmc-green);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.9em;
    white-space: nowrap;
    letter-spacing: 0;
    transition: transform .2s ease, box-shadow .2s ease;
    appearance: none;
}
#mmc-tax-widget .mmc-tax-toggle:hover,
#mmc-tax-widget .mmc-tax-toggle:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 13px 30px rgba(0,0,0,.27);
    background: linear-gradient(135deg, #EBD59B, #D1AD5D 70%);
    color: var(--mmc-green);
}
#mmc-tax-widget .mmc-tax-toggle:focus-visible,
#mmc-tax-widget .mmc-tax-close:focus-visible,
#mmc-tax-widget .mmc-tax-submit:focus-visible,
#mmc-tax-widget .mmc-tax-done:focus-visible {
    outline: 3px solid #D1AD5D;
    outline-offset: 3px;
}
#mmc-tax-widget .mmc-tax-toggle-icon { display: flex; align-items: center; justify-content: center; }
#mmc-tax-widget .mmc-tax-toggle-icon svg { width: 21px; height: 21px; }
#mmc-tax-widget .mmc-tax-panel {
    position: absolute;
    bottom: calc(100% + 13px);
    left: 0;
    width: 353px;
    max-width: calc(100vw - 32px);
    max-height: calc(100dvh - 112px);
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid rgba(209,173,93,.5);
    border-radius: 18px;
    background: var(--mmc-paper);
    box-shadow: 0 22px 65px rgba(0,0,0,.33), 0 5px 15px rgba(0,0,0,.12);
    color: var(--mmc-green);
    direction: rtl;
    text-align: right;
    animation: mmc-panel-in .22s ease both;
}
@keyframes mmc-panel-in {
    from { opacity: 0; transform: translateY(9px) scale(.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
#mmc-tax-widget .mmc-tax-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 76px;
    padding: 15px 17px;
    background: var(--mmc-green);
    color: #FFF9E9;
}
#mmc-tax-widget .mmc-tax-head-content { display: flex; align-items: center; gap: 11px; min-width: 0; }
#mmc-tax-widget .mmc-tax-head-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 37px;
    height: 37px;
    flex: 0 0 37px;
    border: 1px solid rgba(209,173,93,.6);
    border-radius: 12px;
    background: rgba(209,173,93,.12);
    color: var(--mmc-gold);
}
#mmc-tax-widget .mmc-tax-head h2 {
    margin: 0;
    padding: 0;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.9em;
    color: #F4D68D;
}
#mmc-tax-widget .mmc-tax-close {
    display: flex;
    justify-content: center;
    align-items: center;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 5px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 9px;
    background: rgba(255,255,255,.06);
    color: #F5F1E8;
    transition: background .2s ease;
    appearance: none;
}
#mmc-tax-widget .mmc-tax-close:hover { background: rgba(255,255,255,.18); color: #fff; }
#mmc-tax-widget .mmc-tax-close svg { height: 18px; width: 18px; }
#mmc-tax-widget .mmc-tax-content { padding: 20px 20px 16px; }
#mmc-tax-widget .mmc-tax-form { margin: 0; padding: 0; }
#mmc-tax-widget .mmc-tax-intro {
    margin: 0 0 18px;
    padding: 0;
    color: #4E5C52;
    font-size: 12.5px;
    font-weight: 500;
    line-height: 1.9em;
}
#mmc-tax-widget .mmc-tax-form > label {
    display: block;
    margin: 0 0 6px;
    padding: 0;
    color: #203D2D;
    font-size: 12.5px;
    font-weight: 500;
}
#mmc-tax-widget .mmc-tax-form > label span { color: #AE7F32; }
#mmc-tax-widget .mmc-tax-input-wrap { position: relative; margin-bottom: 15px; }
#mmc-tax-widget .mmc-tax-input-wrap svg {
    position: absolute;
    top: 50%;
    right: 13px;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    color: #9B947E;
    pointer-events: none;
}
#mmc-tax-widget .mmc-tax-input-wrap input {
    display: block;
    width: 100%;
    height: 46px;
    margin: 0;
    padding: 9px 40px 9px 12px;
    border: 1px solid #DDD8CB;
    border-radius: 11px;
    outline: 0;
    background: #fff;
    box-shadow: none;
    color: var(--mmc-green);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.9em;
    direction: rtl;
    text-align: right;
    transition: border-color .2s, box-shadow .2s;
    appearance: none;
}
#mmc-tax-widget .mmc-tax-input-wrap input::placeholder { color: #989B96; opacity: 1; }
#mmc-tax-widget .mmc-tax-input-wrap input:focus {
    border-color: #BD9650;
    box-shadow: 0 0 0 3px rgba(209,173,93,.16);
}
#mmc-tax-widget .mmc-tax-submit,
#mmc-tax-widget .mmc-tax-done {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 47px;
    margin: 5px 0 0;
    padding: 10px 14px;
    border: 0;
    border-radius: 11px;
    background: #D1AD5D;
    color: #04180F;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.9em;
    text-align: center;
    box-shadow: none;
    transition: background .2s ease, transform .2s ease;
    appearance: none;
}
#mmc-tax-widget .mmc-tax-submit:hover,
#mmc-tax-widget .mmc-tax-done:hover { background: #E0C17D; transform: translateY(-1px); color: #04180F; }
#mmc-tax-widget .mmc-tax-submit:disabled { opacity: .7; cursor: wait; transform: none; }
#mmc-tax-widget .mmc-tax-submit svg { height: 16px; width: 16px; }
#mmc-tax-widget .mmc-tax-privacy {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin: 13px 0 0;
    padding: 0;
    font-size: 10.5px;
    font-weight: 500;
    line-height: 1.9em;
    text-align: center;
    color: #69746B;
}
#mmc-tax-widget .mmc-tax-privacy svg { height: 14px; width: 14px; color: #32634A; }
#mmc-tax-widget .mmc-tax-error {
    margin: 0 0 8px;
    padding: 9px 11px;
    border: 1px solid #E8BAB5;
    border-radius: 9px;
    background: #FFF1EF;
    color: #9C3026;
    font-size: 12px;
}
#mmc-tax-widget .mmc-tax-honeypot {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}
#mmc-tax-widget .mmc-tax-success { padding: 10px 1px 9px; text-align: center; }
#mmc-tax-widget .mmc-tax-check {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 62px;
    height: 62px;
    margin: 0 auto 15px;
    border-radius: 50%;
    background: #E6F0E7;
    color: #1D6642;
}
#mmc-tax-widget .mmc-tax-check svg { width: 34px; height: 34px; }
#mmc-tax-widget .mmc-tax-success h3 { margin: 0 0 8px; padding: 0; font-size: 17px; font-weight: 500; color: #123C26; }
#mmc-tax-widget .mmc-tax-success p { margin: 0 0 22px; padding: 0; color: #55685C; font-size: 13px; line-height: 1.9em; }
#mmc-tax-widget .mmc-tax-done { margin-bottom: 5px; }
@media (max-width: 600px) {
    #mmc-tax-widget {
        bottom: 17px;
        bottom: calc(17px + env(safe-area-inset-bottom, 0px));
        left: 15px;
    }
    #mmc-tax-widget .mmc-tax-toggle {
        width: 56px;
        height: 56px;
        min-height: 56px;
        padding: 0;
        border-radius: 50%;
    }
    #mmc-tax-widget .mmc-tax-toggle-icon svg { width: 25px; height: 25px; }
    #mmc-tax-widget .mmc-tax-toggle-text { display: none; }
    #mmc-tax-widget .mmc-tax-panel {
        bottom: calc(100% + 13px);
        width: min(340px, calc(100vw - 30px));
        max-height: calc(100dvh - 105px - env(safe-area-inset-bottom, 0px));
        border-radius: 16px;
    }
    #mmc-tax-widget .mmc-tax-content { padding: 18px 18px 15px; }
}
@media (prefers-reduced-motion: reduce) {
    #mmc-tax-widget *, #mmc-tax-widget *::before, #mmc-tax-widget *::after { animation: none !important; transition: none !important; }
}

/* Deliberately lighter microcopy and placeholders for visual hierarchy. */
#mmc-tax-widget .mmc-tax-intro,
#mmc-tax-widget .mmc-tax-privacy,
#mmc-tax-widget .mmc-tax-error,
#mmc-tax-widget .mmc-tax-success p,
#mmc-tax-widget .mmc-tax-input-wrap input::placeholder {
    font-family: "iranyekan-light-fanum", Sans-serif;
    font-weight: 400;
    line-height: 1.9em;
}
