/* === DESIGN TOKENS === */
:root {
    --primary:   #8B2C3B;
    --secondary: #4A5F3C;
    --accent:    #E6A817;
    --success:   #52796F;
    --error:     #C25B3B;
    --text-dark: #1F1F1F;
    --text-muted:#666;
    --border:    #E0E0E0;
    --bg-page:   #FAFAFA;
    --primary-border-light: rgba(139, 44, 59, 0.12);
    --card-radius: 12px;
    --bubble-radius: 16px;
}

/* === BASE === */
html { font-size: 16px; }

body {
    background: var(--bg-page);
    color: var(--text-dark);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

@supports (overflow-x: clip) {
    html,
    body {
        overflow-x: clip;
    }
}

.btn:focus, .btn:active:focus, .form-control:focus, .form-select:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem var(--primary);
}

/* === PUBLIC NAVIGATION === */
.site-nav {
    background: white;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.brand {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.brand:hover { color: var(--primary); }

.nav-links { display: flex; align-items: center; gap: 1.5rem; }

.nav-link-item {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.45rem 0.8rem;
    border-radius: 0.5rem;
    transition: color 0.15s, background 0.15s;
}
.nav-link-item:hover { color: var(--primary); background: rgba(139, 44, 59, 0.06); }

.nav-right { display: flex; align-items: center; gap: 1rem; }

.lang-switcher {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
}
.lang-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px 4px;
    line-height: 1;
    font-size: inherit;
    font-weight: inherit;
    font-family: inherit;
}
.lang-btn.active   { color: var(--primary); }
.lang-btn.inactive { color: var(--text-muted); }
.lang-sep          { color: var(--border); }

/* === PAGE WRAPPER === */
.page-content { padding: 0; }
.page-content > main {
    display: flex;
    flex-direction: column;
}
.page-content > main > :not(.hero-home):not(.digest-section):not(.home-chat-section) {
    max-width: 1140px;
    margin: 0 auto;
    padding: 2rem 1.5rem 0;
}

@media (max-width: 820px) {
    .page-content > main {
        flex-direction: column;
    }
    
    .page-content > main > .home-chat-section {
        order: 2;
    }
    
    .page-content > main > .hero-home {
        order: 1;
    }
    
    .page-content > main > .digest-section {
        order: 3;
    }
}

/* === HERO === */
.hero-home {
    margin-inline: calc(50% - 50vw);
    padding: 5rem 1.5rem 4rem;
    background: linear-gradient(135deg, #f8f4f0 0%, var(--bg-page) 100%);
    position: relative;
    overflow: hidden;
}

.hero-home-minimal {
    padding: 2rem 1.5rem 1.5rem;
}

.hero-home-minimal .lead {
    display: none;
}

@media (max-width: 640px) {
    .hero-home {
        padding: 1.25rem 1.5rem 1rem;
    }
    
    .hero-home h1 {
        font-size: clamp(1.5rem, 4vw, 2rem);
        margin-bottom: 0.25rem;
    }
    
    .hero-home .lead {
        font-size: 0.9rem;
        margin-bottom: 0;
    }
}
.hero-home::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(139, 44, 59, 0.08) 0%, transparent 48%);
}
.hero-content {
    position: relative;
    max-width: 820px;
    margin: 0 auto;
    text-align: center;
}
.hero-home h1 {
    font-size: clamp(2.75rem, 5vw, 3.5rem);
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
}
.hero-home .lead {
    font-size: clamp(1.1rem, 2vw, 1.375rem);
    color: var(--text-muted);
    margin: 0 auto;
    margin-bottom: 1.25rem;
    max-width: 640px;
    line-height: 1.55;
}

@media (max-width: 820px) {
    .hero-home .lead {
        display: none;
    }
}
.hero-host {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(139, 44, 59, 0.12);
    color: var(--text-muted);
}
.hero-host code {
    color: var(--primary);
    background: transparent;
    padding: 0;
}

.cta-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1.75rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 8px 18px rgba(139, 44, 59, 0.18);
    transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
}
.cta-btn:hover {
    background: #6f2230;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(139, 44, 59, 0.24);
}

.secondary-btn {
    border: 1px solid rgba(139, 44, 59, 0.18);
    background: white;
    color: var(--text-dark);
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: border-color 0.15s, color 0.15s, transform 0.15s, box-shadow 0.15s;
}
.secondary-btn:hover {
    color: var(--primary);
    border-color: rgba(139, 44, 59, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}

.marketing-hero {
    padding-bottom: 4rem;
}

.marketing-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    background: rgba(139, 44, 59, 0.08);
    color: var(--primary);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
}

.marketing-cta-row {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.marketing-note {
    max-width: 720px;
    margin: 1.25rem auto 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.marketing-section-header {
    max-width: 720px;
    margin-bottom: 2rem;
}

.marketing-section-header h2 {
    font-size: clamp(1.9rem, 3vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 0.9rem;
}

.marketing-section-header p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.65;
    margin: 0;
}

.marketing-card-grid,
.marketing-shot-grid,
.marketing-steps,
.marketing-admin-grid {
    display: grid;
    gap: 1.5rem;
}

.marketing-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.marketing-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 1.5rem;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

.marketing-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(139, 44, 59, 0.08);
    color: var(--primary);
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.marketing-card h3,
.marketing-step h3,
.marketing-admin-callout h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.marketing-card p,
.marketing-step p,
.marketing-admin-callout p {
    color: var(--text-muted);
    line-height: 1.65;
    margin: 0;
}

.marketing-shot-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.marketing-shot-card {
    margin: 0;
    background: white;
    border: 1px solid var(--border);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.marketing-shot-card img {
    display: block;
    width: 100%;
    height: auto;
    background: #f4f1ee;
}

.marketing-shot-card figcaption {
    padding: 1.2rem 1.25rem 1.35rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.marketing-shot-card strong {
    font-size: 1.05rem;
}

.marketing-shot-card span {
    color: var(--text-muted);
    line-height: 1.55;
}

.marketing-admin-grid {
    grid-template-columns: 1.5fr 1fr;
}

.marketing-admin-panel,
.marketing-admin-callout,
.marketing-step {
    background: white;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 1.5rem;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

.marketing-checklist {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1rem;
}

.marketing-checklist li {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
    line-height: 1.55;
}

.marketing-checklist i {
    color: var(--success);
    margin-top: 0.2rem;
}

.marketing-steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.marketing-step-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(139, 44, 59, 0.1);
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 1rem;
}

/* === DIGEST === */
.digest-section {
    padding: 4rem 1.5rem 0;
    background: white;
    margin-inline: calc(50% - 50vw);
}
.digest-section .container {
    max-width: 1200px;
    margin: 0 auto;
}
.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 2rem;
}
.section-title i {
    color: var(--primary);
    font-size: 1rem;
}
.home-digest-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
}
.home-digest-column h2 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}
.home-digest-column h2 i {
    font-size: 1.35rem;
    color: var(--primary);
}
@media (max-width: 900px) {
    .home-digest-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* Event card — public */
.event-card-public {
    background: white;
    border: 1px solid transparent;
    border-radius: var(--card-radius);
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.event-card-public:hover {
    border-color: var(--primary);
    box-shadow: 0 12px 24px rgba(0,0,0,0.12);
    transform: translateY(-4px);
}
.event-header-public {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
}
.event-card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.35;
    flex: 1;
}
.event-badge {
    display: inline-block;
    background: var(--accent);
    color: white;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}
.event-meta-row {
    font-size: 0.9rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.35rem;
}
.event-meta-row i { color: var(--primary); width: 16px; text-align: center; }
.empty-state {
    color: var(--text-muted);
    font-size: 0.92rem;
    padding: 2rem 1.25rem;
    text-align: center;
    background: white;
    border-radius: var(--card-radius);
    border: 2px dashed var(--border);
}

/* === HOME CHAT SECTION === */
.home-chat-section {
    margin-inline: calc(50% - 50vw);
    padding: 2rem 1.5rem 3rem;
    background: linear-gradient(180deg, var(--bg-page) 0%, #f0ece8 100%);
}

@media (max-width: 820px) {
    .home-chat-section {
        padding: 2rem 1.5rem 2rem;
    }
}

.home-chat-section .container {
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 820px) {
    .home-chat-section {
        padding: 1.5rem 1rem 2rem;
        order: 2;
    }
    
    .home-chat-header {
        display: none;
    }
    
    .home-chat-interface {
        grid-template-columns: 1fr;
    }
    
    .home-chat-intro {
        display: none;
    }
}

.home-chat-inner {
    background: white;
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.home-chat-header {
    background: linear-gradient(135deg, #f8f4f0 0%, white 100%);
    padding: 2rem 2.5rem;
    border-bottom: 1px solid var(--border);
    text-align: center;
}

@media (max-width: 820px) {
    .home-chat-header {
        padding: 1.25rem 1.5rem;
    }
}

.home-chat-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.4rem;
}

.home-chat-subtitle {
    font-size: 1rem;
    color: var(--text-muted);
}

.home-chat-interface {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 0;
    overflow: hidden;
}

.home-chat-intro {
    padding: 2.5rem 2rem;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #fafafa;
    transition: opacity 0.25s ease, transform 0.25s ease, max-height 0.25s ease, padding 0.25s ease;
    overflow: hidden;
}

.home-chat-intro h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
}

.home-chat-intro ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.home-chat-intro li {
    padding: 0.85rem 0;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    color: var(--text-muted);
    font-size: 0.95rem;
    border-bottom: 1px solid var(--border);
}

.home-chat-intro li:last-child {
    border-bottom: none;
}

.home-chat-intro li i {
    color: var(--primary);
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.home-chat-widget {
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: linear-gradient(180deg, #fff 0%, #fcf9f7 100%);
}

.home-chat-messages {
    flex: 1;
    min-height: 240px;
    max-height: 360px;
    overflow-y: auto;
    padding: 1.5rem 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overscroll-behavior: contain;
}

@media (max-width: 820px) {
    .home-chat-interface {
        grid-template-columns: 1fr;
    }

    .home-chat-intro {
        order: 2;
        border-right: none;
        border-top: 1px solid var(--border);
        max-height: 0;
        padding: 0;
        margin: 0;
        overflow: hidden;
        border-top: none;
    }

    .home-chat-widget {
        order: 1;
    }

    .home-chat-messages {
        max-height: 300px;
    }

    .home-chat-interface.chat-engaged .home-chat-intro {
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        border-top: 0;
        opacity: 0;
        transform: translateY(8px);
    }

    .home-chat-interface.chat-engaged .home-chat-widget {
        min-height: 420px;
    }

    .home-chat-interface.chat-engaged .home-chat-messages {
        max-height: 52vh;
    }
}

/* === SITE FOOTER === */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 2.5rem 1.5rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 5rem;
}
.site-footer a { color: var(--text-muted); text-decoration: none; }
.site-footer a:hover { color: var(--primary); }
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}
.footer-left {
    text-align: left;
}
.footer-right {
    text-align: right;
}

@media (max-width: 980px) {
    .marketing-card-grid,
    .marketing-shot-grid,
    .marketing-steps,
    .marketing-admin-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .marketing-hero {
        padding-top: 5rem;
    }

    .marketing-section-header h2 {
        font-size: 1.8rem;
    }
}

/* === CHAT PAGE === */
.chat-page-body {
    display: flex;
    flex-direction: column;
    height: 100vh;
    max-width: 480px;
    margin: 0 auto;
    background: var(--bg-page);
    overflow: hidden;
}

.chat-header {
    background: white;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    flex-shrink: 0;
}
.chat-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
.chat-back-btn { color: var(--primary); text-decoration: none; font-size: 1.1rem; padding: 0.25rem; }
.chat-title    { font-size: 1.2rem; font-weight: 600; color: var(--text-dark); margin-bottom: 0.25rem; }
.chat-subtitle { font-size: 0.88rem; color: var(--text-muted); }

.chat-digest {
    background: white;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.chat-digest-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    font-weight: 700;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.chat-digest-scroll {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
}
.chat-digest-scroll::-webkit-scrollbar { display: none; }

.chat-event-mini {
    min-width: 240px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.9rem;
    flex-shrink: 0;
    font-size: 0.82rem;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.chat-event-mini:hover {
    border-color: var(--primary);
    box-shadow: 0 6px 14px rgba(139, 44, 59, 0.12);
}
.chat-event-mini-title { font-weight: 600; color: var(--text-dark); margin-bottom: 0.45rem; font-size: 0.95rem; }
.chat-event-mini-meta {
    color: var(--text-muted);
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    margin-bottom: 0.25rem;
}
.chat-event-mini-meta i { color: var(--primary); width: 12px; }
.chat-event-mini-badge {
    display: inline-block;
    margin-top: 0.35rem;
    padding: 0.24rem 0.55rem;
    border-radius: 0.45rem;
    background: var(--accent);
    color: white;
    font-size: 0.68rem;
    font-weight: 600;
}

.chat-messages { flex: 1; overflow-y: auto; padding: 1rem 1.25rem; display: flex; flex-direction: column; gap: 0.5rem; }

.chat-message-row        { display: flex; flex-direction: column; margin-bottom: 0.75rem; animation: chat-row-in 0.2s ease-out; }
.chat-message-row.user   { align-items: flex-end; }
.chat-message-row.bot    { align-items: flex-start; }

/* Time when placed at row level (for event listings) */
.chat-message-row > .chat-message-time {
    display: block;
    font-size: 0.66rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    text-align: inherit;
}

.chat-message-row.user > .chat-message-time {
    text-align: right;
}

.chat-bubble {
    padding: 0.75rem 0.95rem;
    border-radius: var(--bubble-radius);
    max-width: 82%;
    font-size: 0.94rem;
    line-height: 1.45;
    white-space: pre-wrap;
    overflow-wrap: break-word;
}
.chat-bubble.user {
    background: var(--primary);
    color: white;
    border-bottom-right-radius: 4px;
}
.chat-bubble.bot {
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    color: var(--text-dark);
    border-bottom-left-radius: 4px;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-bubble.bot::before {
    content: "🤖";
    font-size: 1rem;
    flex-shrink: 0;
}

.chat-message-time {
    display: block;
    margin-top: 0.3rem;
    font-size: 0.66rem;
    color: var(--text-muted);
}

.chat-bubble.user .chat-message-time {
    color: rgba(255,255,255,0.72);
    text-align: right;
}

.chat-quick-replies {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: white;
    border-top: 1px solid var(--border);
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

.chat-quick-replies::-webkit-scrollbar {
    display: none;
}

.chat-quick-reply {
    padding: 0.62rem 0.95rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: white;
    color: var(--text-dark);
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    text-align: center;
    line-height: 1.2;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-width: max-content;
}

.chat-quick-reply:hover {
    background: rgba(139, 44, 59, 0.06);
    border-color: rgba(139, 44, 59, 0.2);
    color: var(--primary);
}

/* Event formatting (Option 3) */
.formatted-events {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 0.5rem 0;
}

.event-intro {
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.event-item {
    display: flex;
    gap: 0.6rem;
    padding: 0.6rem 0.75rem;
    border-left: 3px solid var(--primary);
    background: rgba(139, 44, 59, 0.04);
    border-radius: 4px;
    margin-bottom: 0.4rem;
}

.event-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.event-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.event-name {
    font-weight: 600;
    color: var(--primary);
    font-size: 0.95rem;
}

.event-info {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.3;
}

@media (min-width: 768px) {
    .chat-quick-replies {
        flex-wrap: wrap;
        overflow-x: auto;
    }
    
    .chat-quick-reply {
        white-space: nowrap;
        min-height: auto;
    }
}

.chat-input-area {
    background: white;
    padding: 0.75rem 1.25rem;
    padding-bottom: max(0.75rem, env(safe-area-inset-bottom));
    border-top: 1px solid var(--border);
    flex-shrink: 0;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.05);
}
.chat-input-row { display: flex; gap: 0.5rem; align-items: flex-end; }
.chat-input-field {
    flex: 1;
    min-width: 0;
    padding: 0.7rem 1rem;
    border: 1px solid var(--border);
    border-radius: 24px;
    font-size: 0.95rem;
    font-family: inherit;
    resize: none;
    max-height: 120px;
    line-height: 1.4;
    background: white;
}
.chat-input-field:focus { outline: none; border-color: var(--primary); }

.chat-send-btn {
    width: 44px;
    height: 44px;
    background: var(--primary);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.15s;
}
.chat-send-btn:hover     { background: #6f2230; }
.chat-send-btn:disabled  { opacity: 0.5; cursor: not-allowed; }
.chat-error { font-size: 0.8rem; color: var(--error); margin-top: 0.5rem; }

.chat-thinking {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    min-width: 64px;
    min-height: 40px;
}

.chat-thinking-dot {
    width: 0.42rem;
    height: 0.42rem;
    border-radius: 50%;
    background: rgba(139, 44, 59, 0.7);
    animation: chat-thinking-bounce 1s infinite ease-in-out;
}

.chat-thinking-dot:nth-child(2) {
    animation-delay: 0.14s;
}

.chat-thinking-dot:nth-child(3) {
    animation-delay: 0.28s;
}

@keyframes chat-thinking-bounce {
    0%, 80%, 100% {
        opacity: 0.4;
        transform: translateY(0);
    }
    40% {
        opacity: 1;
        transform: translateY(-2px);
    }
}

@keyframes chat-row-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
