/* ============================================================
   PD Consent Banner — colombo.pro
   v4.14
   ============================================================ */

.pd-consent-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 99998;
}

.pd-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    background: #fff;
    box-shadow: 0 -2px 15px rgba(0,0,0,0.15);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    font-size: 14px;
    color: #333;
    max-height: 90vh;
    overflow-y: auto;
}

.pd-consent-banner.pd-consent-top {
    bottom: auto;
    top: 0;
    box-shadow: 0 2px 15px rgba(0,0,0,0.15);
}

.pd-consent-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px 50px 16px 20px;
    position: relative;
}

/* ── Header ─────────────────────────────────── */
.pd-consent-header h3 {
    margin: 0 0 6px 0;
    font-size: 16px;
    font-weight: 600;
    color: #222;
}
.pd-consent-header p {
    margin: 0 0 4px 0;
    color: #555;
    line-height: 1.5;
    font-size: 13px;
}

/* ── Section titles ──────────────────────────── */
.pd-consent-section-title {
    font-size: 11px;
    font-weight: 700;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 10px 0 5px 0;
}
.pd-hint {
    font-weight: 400;
    text-transform: none;
    color: #1a3a6b;
    letter-spacing: 0;
}

/* ── Grids ───────────────────────────────────── */
.pd-consent-categories {
    display: grid;
    gap: 8px;
    margin-bottom: 2px;
}
.pd-required-group { grid-template-columns: repeat(2, 1fr); }
.pd-optional-group { grid-template-columns: repeat(4, 1fr); }
.pd-docs-group     { grid-template-columns: repeat(3, 1fr); }

/* ── Cards ───────────────────────────────────── */
.pd-category {
    background: #f8f8f8;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    padding: 10px 12px;
    transition: border-color 0.2s, background 0.2s;
}
.pd-category-required {
    background: #f0f7ff;
    border-color: #c8dff8;
}
.pd-category-doc {
    background: #fffbf0;
    border-color: #e8d888;
}
.pd-category-doc.pd-doc-confirmed {
    background: #f0fff0;
    border-color: #7bc87b;
}

/* ── Category head (обязательные без чекбокса) ─ */
.pd-category-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.pd-category-name {
    font-size: 13px;
    font-weight: 600;
    color: #222;
}
.pd-category-desc {
    margin: 5px 0 0 0;
    font-size: 12px;
    color: #888;
    line-height: 1.4;
}

/* ── Badge ───────────────────────────────────── */
.pd-badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap;
    flex-shrink: 0;
}
.pd-badge-on {
    background: #e8f5e9;
    color: #2e7d32;
}

/* ── Label / Checkbox ────────────────────────── */
.pd-category-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    margin: 0;
}
.pd-category-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-top: 2px;
    cursor: pointer;
    accent-color: #1a3a6b;
}

/* ── Text inside label ───────────────────────── */
.pd-category-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.pd-category-text strong {
    font-size: 13px;
    font-weight: 600;
    color: #222;
    line-height: 1.3;
}
.pd-category-doc .pd-category-text strong a {
    color: #1a3a6b;
    text-decoration: underline;
}
.pd-category-doc .pd-category-text strong a:hover { text-decoration: none; }
.pd-category-text span {
    font-size: 12px;
    color: #777;
    line-height: 1.4;
}
.pd-required-mark {
    color: #c00;
    font-style: normal;
    font-size: 11px;
    font-weight: 600;
}

/* ── Operators footer ────────────────────────── */
.pd-operators {
    margin: 8px 0;
    font-size: 11px;
    color: #aaa;
    line-height: 1.6;
}

/* ── Buttons ─────────────────────────────────── */
.pd-consent-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 12px;
    flex-wrap: wrap;
}
.pd-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.2s;
    white-space: nowrap;
}
.pd-btn:hover:not(:disabled) { opacity: 0.85; }

.pd-btn-primary {
    background: #1a3a6b;
    color: #fff;
}
.pd-btn-primary:disabled {
    background: #aaa;
    cursor: not-allowed;
}
.pd-btn-secondary {
    background: #e8e8e8;
    color: #333;
}

/* ── Close button ────────────────────────────── */
.pd-consent-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
    line-height: 1;
    padding: 4px 8px;
    z-index: 1;
}
.pd-consent-close:hover { color: #333; }

/* ── Responsive ──────────────────────────────── */
@media (max-width: 1000px) {
    .pd-optional-group { grid-template-columns: repeat(2, 1fr); }
    .pd-docs-group     { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .pd-consent-container { padding: 15px 40px 15px 15px; }
    .pd-required-group,
    .pd-optional-group,
    .pd-docs-group { grid-template-columns: 1fr; }
    .pd-consent-buttons { flex-direction: column; }
    .pd-btn { width: 100%; text-align: center; }
}

/* ── Мини-полоска (свёрнутое состояние) ─────── */
.pd-consent-mini {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 50px 10px 0;
    flex-wrap: wrap;
}
.pd-mini-text {
    font-size: 13px;
    color: #555;
    font-weight: 500;
}
.pd-btn-expand-btn {
    background: #1a3a6b;
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
}
.pd-btn-expand-btn:hover { opacity: 0.85; }

/* ── Кнопка Свернуть ─────────────────────────── */
.pd-btn-secondary {
    background: #e8e8e8;
    color: #333;
    font-size: 13px;
    padding: 10px 18px;
}
