/* VoteAssist - Vital Records Assistant */

/* ── Header Image ── */
.site-header { background: #f8f9fa; }
.header-image {
    max-width: 600px;
    width: 100%;
    height: 100px;
    object-fit: contain;
}

/* ── Theme: Default (Blue) ── */
.theme-default .va-navbar { background: #0d6efd; }
.theme-default .record-card .card-header { background: #0d6efd; color: #fff; }
.theme-default #us-map path { fill: #cfe2ff; }
.theme-default #us-map path:hover { fill: #0d6efd; }
.theme-default .chat-msg.user { background: #0d6efd; }
.theme-default .admin-stat { color: #0d6efd; }
.theme-default #chatbot-toggle { background: #0d6efd; border-color: #0d6efd; }
.theme-default #chatbot-panel .card-header { background: #0d6efd; }
.theme-default .va-btn { background: #0d6efd; color: #fff; }

/* ── Theme: Dark ── */
.theme-dark .va-navbar { background: #212529; }
.theme-dark .record-card .card-header { background: #212529; color: #fff; }
.theme-dark #us-map path { fill: #ced4da; }
.theme-dark #us-map path:hover { fill: #495057; }
.theme-dark .chat-msg.user { background: #495057; }
.theme-dark .admin-stat { color: #495057; }
.theme-dark .site-header { background: #343a40; }
.theme-dark #chatbot-toggle { background: #495057; border-color: #495057; }
.theme-dark #chatbot-panel .card-header { background: #495057; }
.theme-dark .va-btn { background: #495057; color: #fff; }

/* ── Theme: Red ── */
.theme-red .va-navbar { background: #b71c1c; }
.theme-red .record-card .card-header { background: #b71c1c; color: #fff; }
.theme-red #us-map path { fill: #ffcdd2; }
.theme-red #us-map path:hover { fill: #b71c1c; }
.theme-red .chat-msg.user { background: #b71c1c; }
.theme-red .admin-stat { color: #b71c1c; }
.theme-red #chatbot-toggle { background: #b71c1c; border-color: #b71c1c; }
.theme-red #chatbot-panel .card-header { background: #b71c1c; }
.theme-red .va-btn { background: #b71c1c; color: #fff; }

/* ── Theme: Green ── */
.theme-green .va-navbar { background: #2e7d32; }
.theme-green .record-card .card-header { background: #2e7d32; color: #fff; }
.theme-green #us-map path { fill: #c8e6c9; }
.theme-green #us-map path:hover { fill: #2e7d32; }
.theme-green .chat-msg.user { background: #2e7d32; }
.theme-green .admin-stat { color: #2e7d32; }
.theme-green #chatbot-toggle { background: #2e7d32; border-color: #2e7d32; }
.theme-green #chatbot-panel .card-header { background: #2e7d32; }
.theme-green .va-btn { background: #2e7d32; color: #fff; }

/* ── Theme: Gold ── */
.theme-gold .va-navbar { background: #bf8c00; }
.theme-gold .record-card .card-header { background: #bf8c00; color: #fff; }
.theme-gold #us-map path { fill: #fff3cd; }
.theme-gold #us-map path:hover { fill: #bf8c00; }
.theme-gold .chat-msg.user { background: #bf8c00; }
.theme-gold .admin-stat { color: #bf8c00; }
.theme-gold #chatbot-toggle { background: #bf8c00; border-color: #bf8c00; }
.theme-gold #chatbot-panel .card-header { background: #bf8c00; }
.theme-gold .va-btn { background: #bf8c00; color: #fff; }

/* ── Theme: Teal ── */
.theme-teal .va-navbar { background: #00796b; }
.theme-teal .record-card .card-header { background: #00796b; color: #fff; }
.theme-teal #us-map path { fill: #b2dfdb; }
.theme-teal #us-map path:hover { fill: #00796b; }
.theme-teal .chat-msg.user { background: #00796b; }
.theme-teal .admin-stat { color: #00796b; }
.theme-teal #chatbot-toggle { background: #00796b; border-color: #00796b; }
.theme-teal .va-btn { background: #00796b; color: #fff; }
.theme-teal #chatbot-panel .card-header { background: #00796b; }

/* ── SVG Map ── */
#us-map { max-width: 100%; height: auto; }
#us-map path {
    stroke: #fff;
    stroke-width: 1.5;
    cursor: pointer;
    transition: fill 0.2s;
}
#us-map path:active { filter: brightness(0.85); }

/* ── Record cards ── */
.record-card { margin-bottom: 1.5rem; }
.record-card .card-header { font-weight: 600; }

/* ── Feedback form ── */
.feedback-form { max-width: 600px; }

/* ── Admin ── */
.admin-stat {
    font-size: 2rem;
    font-weight: 700;
}

/* ── Chatbot ── */
#chatbot-container {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    z-index: 1050;
}
#chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 1.5rem;
    color: #fff;
}
#chatbot-panel {
    display: none;
    width: 360px;
    max-height: 500px;
    border-radius: 0.5rem;
    overflow: hidden;
}
#chatbot-panel .card-header { color: #fff; }
#chatbot-panel.open { display: flex; flex-direction: column; }
#chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    max-height: 350px;
}
.chat-msg { margin-bottom: 0.75rem; padding: 0.5rem 0.75rem; border-radius: 0.75rem; max-width: 85%; }
.chat-msg.user { color: #fff; margin-left: auto; }
.chat-msg.bot { background: #f0f0f0; color: #212529; }

/* ── Responsive ── */
@media (max-width: 576px) {
    #chatbot-panel { width: calc(100vw - 2rem); right: 0; }
    .header-image { height: auto; max-height: 80px; }
}
