﻿/* ============================================================
   Email Banner (slide-in from left) — PsycheCenter
   ============================================================ */

#pc-email-banner {
    position: fixed !important;
    bottom: -500px !important;
    left: 50% !important;
    top: auto !important;
    right: auto !important;
    width: 360px !important;
    max-width: calc(100vw - 32px) !important;
    background: #ffffff !important;
    border-radius: 16px !important;
    box-shadow: 4px 8px 40px rgba(0, 0, 0, .18) !important;
    z-index: 2147483646 !important;
    transition: bottom .55s cubic-bezier(.22,.68,0,1.1) !important;
    padding: 28px 28px 22px !important;
    font-family: inherit;
    color: #1a1a1a;
    transform: translateX(-50%) !important;
    margin: 0 !important;
}

#pc-email-banner.pc-banner--visible {
    bottom: 36px !important;
}

#pc-banner-close {
    position: absolute;
    top: 10px;
    right: 12px;
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: #aaa;
    line-height: 1;
    padding: 4px;
    transition: color .2s;
}

#pc-banner-close:hover { color: #333; }

.pc-banner-inner { padding-top: 4px; }

.pc-banner-icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.pc-banner-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a6fd4;
    margin: 0 0 8px;
}

.pc-banner-text {
    font-size: .87rem;
    color: #555;
    line-height: 1.55;
    margin: 0 0 14px;
}

.pc-banner-field input[type="email"] {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #ccc;
    border-radius: 8px;
    font-size: .9rem;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    box-sizing: border-box;
    margin-bottom: 10px;
}

.pc-banner-field input[type="email"]:focus {
    border-color: #1a6fd4;
    box-shadow: 0 0 0 3px rgba(26,111,212,.15);
}

.pc-banner-consent {
    margin-bottom: 14px;
}

.pc-consent-label {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    font-size: .8rem;
    color: #666;
    line-height: 1.4;
    cursor: pointer;
}

.pc-consent-label input[type="checkbox"] {
    flex-shrink: 0;
    margin-top: 2px;
    width: 15px;
    height: 15px;
    accent-color: #1a6fd4;
}

.pc-consent-label a {
    color: #1a6fd4;
    text-decoration: none;
}

.pc-consent-label a:hover { text-decoration: underline; }

.pc-banner-submit {
    width: 100%;
    text-align: center;
    padding: 12px;
    margin-bottom: 0;
}

#pc-banner-message {
    margin-top: 10px;
    font-size: .85rem;
    font-weight: 600;
    color: #1a6fd4;
    min-height: 20px;
}

#pc-banner-message.pc-msg--error { color: #c0392b; }

/* Вспомогательный класс для скрин-ридеров */
.pc-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* На мобильных — та же логика, но немного выше в видимом состоянии */
@media (max-width: 520px) {
    #pc-email-banner {
        width: calc(100vw - 32px) !important;
        border-radius: 12px !important;
        padding: 20px 18px 16px !important;
    }
    #pc-email-banner.pc-banner--visible {
        bottom: 16px !important;
    }
}
