/* Jacobs Home - contact channels, live chat and tour CTA styles */

.channel-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr;
}
@media (min-width: 768px) {
    .channel-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.channel-card {
    display: flex;
    flex-direction: column;
    gap: .75rem;
    background: #fff;
    border: 1px solid #fee2e2;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 10px 30px -12px rgba(74, 13, 13, .25);
}
.channel-card.is-disabled { opacity: .55; }
.channel-card h3 { font-size: 1.125rem; font-weight: 800; color: #0f172a; }
.channel-card p { font-size: .875rem; color: #64748b; line-height: 1.5; flex: 1; }

.channel-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fef2f2;
    color: #7f1d1d;
}
.channel-icon svg { width: 1.5rem; height: 1.5rem; }
.channel-icon.is-green { background: #dcfce7; color: #15803d; }
.channel-icon.is-whatsapp { background: #dcfce7; color: #16a34a; }

.channel-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    width: 100%;
    padding: .75rem 1rem;
    border-radius: .75rem;
    font-weight: 600;
    font-size: .875rem;
    background: #7f1d1d;
    color: #fff;
    transition: background-color .15s ease;
    text-align: center;
}
.channel-btn:hover { background: #641010; }
.channel-btn.is-outline {
    background: #fff;
    color: #7f1d1d;
    border: 1px solid #fecaca;
}
.channel-btn.is-outline:hover { background: #fef2f2; }
.channel-btn.is-whatsapp { background: #16a34a; }
.channel-btn.is-whatsapp:hover { background: #15803d; }

.channel-note {
    font-size: .75rem;
    color: #94a3b8;
    text-align: center;
}

.tour-property {
    display: flex;
    gap: 1rem;
    align-items: center;
    background: #fff;
    border: 1px solid #fee2e2;
    border-radius: 1rem;
    padding: 1rem;
    box-shadow: 0 10px 30px -12px rgba(74, 13, 13, .25);
}
.tour-property img { width: 7rem; height: 5rem; object-fit: cover; border-radius: .75rem; }
.tour-property h2 { font-weight: 800; color: #0f172a; font-size: 1rem; line-height: 1.35; }
.tour-property p { font-size: .8rem; color: #64748b; }

/* Live chat */
.chat-shell {
    background: #fff;
    border: 1px solid #fee2e2;
    border-radius: 1rem;
    box-shadow: 0 10px 30px -12px rgba(74, 13, 13, .25);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.chat-head {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: 1rem 1.25rem;
    background: #4a0d0d;
    color: #fff;
}
.chat-head strong { font-size: .95rem; }
.chat-head small { display: block; font-size: .72rem; color: #fecaca; }
.chat-dot {
    width: .6rem; height: .6rem; border-radius: 9999px; background: #4ade80;
    box-shadow: 0 0 0 3px rgba(74, 222, 128, .25);
}
.chat-thread {
    flex: 1;
    min-height: 18rem;
    max-height: 26rem;
    overflow-y: auto;
    padding: 1.25rem;
    background: #fdf7f7;
    display: flex;
    flex-direction: column;
    gap: .6rem;
}
.chat-msg {
    max-width: 82%;
    padding: .6rem .85rem;
    border-radius: .9rem;
    font-size: .875rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-wrap: break-word;
}
.chat-msg.visitor { align-self: flex-end; background: #7f1d1d; color: #fff; border-bottom-right-radius: .3rem; }
.chat-msg.admin { align-self: flex-start; background: #fff; color: #334155; border: 1px solid #fee2e2; border-bottom-left-radius: .3rem; }
.chat-meta { font-size: .65rem; opacity: .7; margin-top: .25rem; }
.chat-empty { font-size: .8rem; color: #94a3b8; text-align: center; margin: auto; }
.chat-composer {
    display: flex;
    gap: .5rem;
    padding: .875rem;
    border-top: 1px solid #f1f5f9;
    background: #fff;
}
.chat-input {
    flex: 1;
    border: 1px solid #cbd5e1;
    border-radius: .75rem;
    padding: .65rem .85rem;
    font-size: .875rem;
    color: #1e293b;
    outline: none;
    resize: none;
    min-height: 2.75rem;
    max-height: 8rem;
}
.chat-input:focus { border-color: #991b1b; box-shadow: 0 0 0 2px rgba(153, 27, 27, .18); }
.chat-send {
    border: 0;
    border-radius: .75rem;
    background: #7f1d1d;
    color: #fff;
    font-weight: 600;
    font-size: .875rem;
    padding: 0 1.1rem;
    transition: background-color .15s ease;
}
.chat-send:hover { background: #641010; }
.chat-send:disabled { opacity: .6; cursor: default; }

/* Admin inbox */
.chat-inbox { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 1024px) { .chat-inbox { grid-template-columns: 20rem 1fr; } }
.chat-list { background: #fff; border: 1px solid #e2e8f0; border-radius: 1rem; overflow: hidden; }
.chat-list a { display: block; padding: .85rem 1rem; border-bottom: 1px solid #f1f5f9; color: #334155; }
.chat-list a:last-child { border-bottom: 0; }
.chat-list a:hover { background: #f8fafc; }
.chat-list a.is-active { background: #fef2f2; border-left: 4px solid #7f1d1d; }
.chat-list .who { font-weight: 700; font-size: .85rem; display: flex; justify-content: space-between; gap: .5rem; }
.chat-list .snippet { font-size: .72rem; color: #94a3b8; margin-top: .15rem; }
.chat-badge {
    background: #dc2626; color: #fff; border-radius: 9999px;
    font-size: .65rem; font-weight: 700; padding: .1rem .45rem; min-width: 1.1rem; text-align: center;
}
.chat-badge.is-closed { background: #94a3b8; }

/* Floating chat launcher */
.chat-fab {
    position: fixed;
    right: 1.1rem;
    bottom: 1.1rem;
    z-index: 90;
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    background: #7f1d1d;
    color: #fff;
    font-weight: 600;
    font-size: .875rem;
    padding: .8rem 1.1rem;
    border-radius: 9999px;
    box-shadow: 0 14px 30px -10px rgba(74, 13, 13, .6);
    transition: transform .15s ease, background-color .15s ease;
}
.chat-fab:hover { background: #641010; transform: translateY(-2px); }
.chat-fab svg { width: 1.25rem; height: 1.25rem; }

/* Dark mode */
.dark .channel-card,
.dark .tour-property,
.dark .chat-shell,
.dark .chat-list { background: #1e293b; border-color: #334155; }
.dark .channel-card h3,
.dark .tour-property h2 { color: #f1f5f9; }
.dark .channel-card p,
.dark .tour-property p { color: #94a3b8; }
.dark .channel-icon { background: #4a0d0d; color: #fca5a5; }
.dark .channel-btn.is-outline { background: #1e293b; color: #fca5a5; border-color: #475569; }
.dark .channel-btn.is-outline:hover { background: #334155; }
.dark .chat-thread { background: #0f172a; }
.dark .chat-msg.admin { background: #1e293b; border-color: #334155; color: #e2e8f0; }
.dark .chat-composer { background: #1e293b; border-top-color: #334155; }
.dark .chat-input { background: #0f172a; border-color: #475569; color: #e2e8f0; }
.dark .chat-list a { color: #cbd5e1; border-bottom-color: #334155; }
.dark .chat-list a:hover { background: #334155; }
.dark .chat-list a.is-active { background: rgba(74, 13, 13, .5); }
