/* === 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: 100%; }

body {
    background: var(--bg-page);
    color: var(--text-dark);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    /* Override Bootstrap Reboot's `-webkit-text-size-adjust: 100%`/`text-size-adjust: 100%` so iOS Dynamic Type and Android font-size are respected */
    -webkit-text-size-adjust: auto;
    text-size-adjust: auto;
}

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;
    min-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;
}

.marketing-story-grid,
.organiser-steps {
    display: grid;
    gap: 1.5rem;
}

.marketing-story-grid {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    align-items: center;
}

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

.marketing-story-copy p {
    color: var(--text-muted);
    line-height: 1.75;
    margin: 0;
}

.marketing-story-figure {
    margin: 0;
}

.marketing-shot-kicker {
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

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

.marketing-callout-card {
    position: relative;
    overflow: hidden;
}

.marketing-callout-card::after {
    content: "";
    position: absolute;
    inset: auto -40px -40px auto;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(139, 44, 59, 0.06);
}

.marketing-cta-row-left {
    justify-content: flex-start;
}

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

.organiser-step {
    position: relative;
    overflow: hidden;
}

.organiser-step-media {
    margin: -1.5rem -1.5rem 1.25rem;
    border-bottom: 1px solid var(--border);
    background: #f4f1ee;
}

.organiser-step-media img {
    display: block;
    width: 100%;
    height: auto;
}

.organiser-step .marketing-step-number {
    margin-bottom: 0.9rem;
}

@media (max-width: 980px) {
    .marketing-story-grid,
    .organiser-steps,
    .marketing-coming-soon .marketing-card-grid {
        grid-template-columns: 1fr;
    }
}

/* === 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 {
    display: block;
    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;
    color: inherit;
    text-decoration: none;
}
.event-card-public:hover {
    border-color: var(--primary);
    box-shadow: 0 12px 24px rgba(0,0,0,0.12);
    transform: translateY(-4px);
}
.event-card-public:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}
.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%);
}

.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-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-line;
    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: flex-start;
    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 listing wrapper — keeps intro + cards as one flex child inside .chat-bubble.bot */
.event-listing-wrapper {
    flex: 1;
    min-width: 0;
}

/* Plain text wrapper — prevents <br>-separated text nodes becoming separate flex items */
.chat-text-wrapper {
    flex: 1;
    min-width: 0;
}

/* Wider bubble for event listings on all screen sizes */
.chat-bubble:has(.event-listing-wrapper) {
    max-width: 96%;
}

/* 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;
    }
}

/* Mobile: tighter padding so event cards have more room */
@media (max-width: 480px) {
    .home-chat-messages {
        padding: 1rem 0.75rem;
    }

    .chat-bubble:has(.event-listing-wrapper) {
        max-width: 100%;
        padding: 0.6rem 0.75rem;
    }
}

.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: min(0.95rem, 16px);
    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-disclaimer {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    text-align: left;
    margin-bottom: 0;
}

.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);
    }
}

/* Feedback buttons for chat responses */
.chat-feedback-buttons {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    align-items: center;
}

.chat-feedback-btn {
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.chat-feedback-btn:hover:not(:disabled) {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(139, 44, 59, 0.05);
}

.chat-feedback-btn:disabled {
    cursor: default;
    opacity: 0.6;
}

.chat-feedback-btn.selected {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(139, 44, 59, 0.1);
}


/* === COMMON DETAIL PAGE STYLES === */
.common-detail-page {
    padding: 2rem 1.5rem 4rem;
}

.common-detail-breadcrumb {
    margin-bottom: 1.25rem;
}

.breadcrumb-home {
    font-size: 0.88rem;
    color: var(--text-muted);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: color 0.15s;
}

.breadcrumb-home:hover {
    color: var(--primary);
}

.common-detail-badge {
    display: inline-block;
    background: var(--primary-border-light);
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.75rem;
}

.detail-translated-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-left: 0.35rem;
    vertical-align: middle;
}

.common-detail-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
    line-height: 1.2;
}

@media (max-width: 820px) {
    .common-detail-title {
        font-size: 1.5rem;
    }
}

.common-detail-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
    white-space: pre-line;
}

.common-detail-meta {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 1.75rem;
    padding: 1.25rem;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
}

.common-detail-meta-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
    color: var(--text-dark);
}

.common-detail-meta-icon {
    color: var(--primary);
    width: 1.1rem;
    text-align: center;
    flex-shrink: 0;
}

.common-detail-section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.common-detail-map-section,
.common-detail-more-section {
    margin-top: 1.5rem;
    margin-bottom: 2rem;
}

.common-detail-map {
    height: 280px;
    border-radius: var(--card-radius);
    border: 1px solid var(--border);
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.common-detail-directions-link {
    font-size: 0.9rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.common-detail-directions-link:hover {
    text-decoration: underline;
}

.common-detail-more-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.common-detail-more-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    text-decoration: none;
    color: var(--text-dark);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.common-detail-more-card:hover {
    border-color: var(--primary);
    box-shadow: 0 2px 8px rgba(139, 44, 59, 0.1);
}

.common-detail-more-thumb,
.common-detail-more-thumb-placeholder {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.common-detail-more-thumb-placeholder {
    background: var(--primary-border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.25rem;
}

.common-detail-more-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.common-detail-more-title {
    font-weight: 600;
    font-size: 0.92rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.common-detail-more-date {
    font-size: 0.82rem;
    color: var(--text-muted);
}

/* === EVENT DETAIL PAGE (event-specific) === */
.event-detail-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 2.5rem;
    align-items: start;
}

@media (max-width: 820px) {
    .event-detail-container {
        grid-template-columns: 1fr;
    }

    .event-detail-sidebar {
        order: -1;
    }
}

.event-detail-container > * {
    min-width: 0;
}


/* Flyer sidebar */
.event-detail-flyer-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    overflow: hidden;
    position: sticky;
    top: 80px;
}

.event-detail-flyer-img {
    width: 100%;
    display: block;
    cursor: zoom-in;
    transition: opacity 0.15s;
}

.event-detail-flyer-img:hover {
    opacity: 0.9;
}

.event-detail-flyer-hint {
    text-align: center;
    font-size: 0.78rem;
    color: var(--text-muted);
    padding: 0.5rem;
    margin: 0;
    border-top: 1px solid var(--border);
}

/* Flyer lightbox */
.flyer-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.flyer-lightbox.active {
    display: flex;
}

.flyer-lightbox-img {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 8px;
    object-fit: contain;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

.flyer-lightbox-close {
    position: fixed;
    top: 1rem;
    right: 1.25rem;
    background: rgba(255,255,255,0.15);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background 0.15s;
}

.flyer-lightbox-close:hover {
    background: rgba(255,255,255,0.3);
}


/* === BUSINESS DETAIL PAGE === */

.business-detail-container {
    max-width: 760px;
    margin: 0 auto;
}

.business-detail-contact-link {
    color: var(--primary);
    text-decoration: none;
    word-break: break-all;
}

.business-detail-contact-link:hover {
    text-decoration: underline;
}

.business-detail-hours {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    overflow: hidden;
}

.business-detail-hours-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.55rem 1.1rem;
    font-size: 0.93rem;
    border-bottom: 1px solid var(--border);
}

.business-detail-hours-row:last-child {
    border-bottom: none;
}

.business-detail-hours-day {
    font-weight: 600;
    color: var(--text-dark);
    min-width: 7rem;
}

.business-detail-hours-times {
    color: var(--text-dark);
}

.business-detail-hours-closed {
    color: var(--text-muted);
    font-style: italic;
}

/* === EVENT CARD LINK STYLES === */
.event-item-link {
    display: flex;
    text-decoration: none;
    color: inherit;
    transition: background 0.15s, border-color 0.15s;
}

.event-item-link:hover {
    background: #fdf7f7;
    border-color: var(--primary);
}

.event-flyer-thumb {
    margin-left: auto;
    flex-shrink: 0;
    align-self: center;
}

.event-flyer-thumb img {
    width: 52px;
    height: 52px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--border);
}

/* === CHAT ACTION BUTTONS (inside message thread, mobile only) === */
/* Hidden on desktop — desktop keeps the .chat-quick-replies chips */
.chat-actions-row {
    display: none;
}

.chat-action-btn {
    padding: 0.55rem 1rem;
    background: white;
    border: 1.5px solid rgba(139, 44, 59, 0.3);
    border-radius: 999px;
    font-size: min(0.85rem, 14px);
    font-weight: 600;
    color: var(--primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
    white-space: normal;
    transition: background 0.15s, border-color 0.15s;
    font-family: inherit;
}

.chat-action-btn:hover {
    background: rgba(139, 44, 59, 0.06);
    border-color: rgba(139, 44, 59, 0.5);
}

.chat-action-btn i {
    font-size: 0.9rem;
    opacity: 0.85;
}

/* ================================================================
   MOBILE CHAT FULL-SCREEN LAYOUT — Issue #96
   ≤640px phones only. Desktop/tablet layout is untouched.
   ================================================================ */
@media (max-width: 640px) {
    /* 1. Clear competing sections */
    .hero-home {
        display: none;
    }

    .digest-section {
        display: none;
    }

    /* 2. Chat section fills the remaining viewport below the 64px sticky nav */
    .home-chat-section {
        height: calc(100vh - 64px);
        height: calc(100dvh - 64px);
        padding: 0;
        background: white;
        margin: 0;
    }

    .home-chat-section .container {
        height: 100%;
        max-width: 100%;
        padding: 0;
    }

    /* 3. Inner wrapper — flex column, fills available height */
    .home-chat-inner {
        height: 100%;
        border-radius: 0;
        border: none;
        box-shadow: none;
        overflow: visible;
        display: flex;
        flex-direction: column;
    }

    /* 4. Re-show the chat header (hidden at 820px) in compact form for branding */
    .home-chat-header {
        display: block;
        padding: 0.65rem 1rem;
        flex-shrink: 0;
    }

    .home-chat-subtitle {
        font-size: 0.75rem;
    }

    /* 5. Interface and widget fill remaining height as flex column */
    .home-chat-interface {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    .home-chat-widget {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    /* 6. Messages scroll, input stays pinned naturally at the flex bottom */
    .home-chat-messages {
        flex: 1;
        min-height: 0;
        max-height: none;
    }

    /* 7. Neutralise chat-engaged overrides that conflict with flex layout.
       Use min-height: 0 (NOT unset — unset resolves to the initial value of
       'auto', which lets the flex item grow to fit content and breaks the
       inner messages scroll). */
    .home-chat-interface.chat-engaged .home-chat-widget {
        min-height: 0;
    }

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

    /* 8. Desktop chips hidden, action buttons shown */
    .chat-quick-replies {
        display: none;
    }

    .chat-actions-row {
        display: flex;
        flex-direction: column;
        gap: 0.4rem;
        margin-top: 0.25rem;
        margin-bottom: 0.25rem;
        align-items: flex-start;
    }

    /* 9. Footer hidden — fullscreen chat owns the viewport on phones */
    .site-footer {
        display: none;
    }
}

/* ================================================================
   SEO DETAIL PAGE ELEMENTS — past-event notice, LLM reply, chat CTA
   ================================================================ */

.seo-past-event-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    background: #fef9ec;
    border: 1px solid var(--accent);
    border-radius: var(--card-radius);
    padding: 1rem 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.seo-past-event-notice i {
    color: var(--accent);
    font-size: 1.1rem;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.seo-past-event-reply {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    padding: 1.25rem 1.5rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.seo-past-event-reply-body {
    font-size: 0.95rem;
    color: var(--text-body);
    line-height: 1.6;
}

.seo-past-event-reply-body p:last-child {
    margin-bottom: 0;
}

.seo-past-event-loading {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.seo-past-event-loading i {
    color: var(--primary);
}

.seo-chat-cta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    background: var(--primary-border-light, rgba(139,44,59,0.06));
    border: 1px solid rgba(139,44,59,0.18);
    border-radius: var(--card-radius);
    padding: 1.5rem 1.75rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.seo-chat-cta-heading {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0;
    line-height: 1.4;
}

.seo-chat-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: var(--primary);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.55rem 1.25rem;
    border-radius: 999px;
    text-decoration: none;
    transition: background 0.15s ease;
    white-space: nowrap;
}

.seo-chat-cta-btn:hover {
    background: #6f2230;
    color: #fff;
    text-decoration: none;
}

/* === TEASER PAGE === */

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

.teaser-events-section {
    max-width: 1140px;
    margin: 0 auto;
    padding: 3rem 1.5rem 2rem;
}

.teaser-events-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.75rem;
}

.teaser-events-header h2 {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 700;
    margin: 0;
}

.teaser-more-count {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
}

.teaser-event-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
}

@media (max-width: 820px) {
    .teaser-event-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 540px) {
    .teaser-event-grid {
        grid-template-columns: 1fr;
    }
}

.teaser-event-card {
    position: relative;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.teaser-event-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.teaser-event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(5px) brightness(0.85);
    transform: scale(1.05);
}

.teaser-event-body {
    padding: 1rem 1.25rem 1.25rem;
}

.teaser-event-date {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.4rem;
}

.teaser-event-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 0.4rem;
    line-height: 1.3;
}

.teaser-event-location {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.teaser-lock-overlay {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    background: var(--primary);
    color: white;
    border-radius: 999px;
    width: 1.75rem;
    height: 1.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.teaser-lock-overlay i {
    font-size: 0.75rem;
    color: white;
    opacity: 1;
    filter: none;
}

.teaser-events-empty {
    color: var(--text-muted);
    font-size: 0.95rem;
    padding-top: 2rem;
    padding-bottom: 1rem;
}

.teaser-cta-section {
    max-width: 1140px;
    margin: 0 auto;
    padding: 3rem 1.5rem 4rem;
    border-top: 1px solid var(--border);
}

/* === TEASER DEMO SECTION === */

.teaser-demo-section {
    background: linear-gradient(135deg, #f0f4ff 0%, #f8f4ff 100%);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    padding: 3rem 1.5rem;
}

.teaser-demo-inner {
    max-width: 680px;
    margin: 0 auto;
}

.teaser-demo-eyebrow {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--primary);
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.teaser-demo-widget {
    border-radius: 1rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    background: white;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    max-width: 100%;
    width: 100%;
}

.teaser-demo-messages {
    flex: 1;
    padding: 1.25rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    overflow-y: auto;
    max-height: 340px;
}

.teaser-demo-input-locked {
    border-top: 1px solid var(--border);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.teaser-demo-input-fake {
    flex: 1;
    min-width: 160px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.5rem 1rem;
    background: var(--bg-light);
    color: var(--text-muted);
    font-size: 0.85rem;
    gap: 0.5rem;
    cursor: not-allowed;
    user-select: none;
}

.teaser-demo-input-fake i {
    font-size: 0.75rem;
    opacity: 0.6;
}

/* Thinking dots animation */

.chat-thinking {
    display: flex;
    gap: 4px;
    align-items: center;
    padding: 0.6rem 0.9rem !important;
    min-width: 48px;
}

.chat-thinking span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--primary);
    opacity: 0.4;
    animation: thinking-bounce 1.2s infinite ease-in-out;
    display: inline-block;
}

.chat-thinking span:nth-child(1) { animation-delay: 0s; }
.chat-thinking span:nth-child(2) { animation-delay: 0.2s; }
.chat-thinking span:nth-child(3) { animation-delay: 0.4s; }

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

.teaser-demo-close {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    margin-bottom: 0;
}

/* Entrance animation for each revealed event card */
.teaser-demo-card {
    animation: card-slide-in 0.25s ease-out both;
}

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


/* ── Apex homepage (loquare.fr) ─────────────────────────── */

.apex-towns-section,
.apex-teaser-section {
    padding: 3rem 0;
}

.apex-cta-section {
    padding: 2.5rem 0 4rem;
}

.apex-cta-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    text-align: center;
}

.apex-cta-text {
    margin: 0;
    font-size: 1.05rem;
    color: var(--text-muted);
}

.apex-towns-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.apex-towns-grid-teaser {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.apex-town-card {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 1.1rem 1.25rem;
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    background: #fff;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
    position: relative;
}

.apex-town-card:not(.apex-town-card-teaser):hover {
    border-color: var(--primary);
    box-shadow: 0 4px 16px rgba(139, 44, 59, 0.10);
    transform: translateY(-2px);
    color: inherit;
    text-decoration: none;
}

.apex-town-card-teaser {
    opacity: 0.6;
    cursor: default;
}

.apex-town-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--primary);
}

.apex-town-card-teaser .apex-town-name {
    color: inherit;
}

.apex-town-postal {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.apex-town-arrow {
    position: absolute;
    right: 1.1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--primary);
    font-size: 0.85rem;
    opacity: 0;
    transition: opacity 0.15s;
}

.apex-town-card:not(.apex-town-card-teaser):hover .apex-town-arrow {
    opacity: 1;
}

.apex-teaser-badge {
    display: inline-block;
    margin-top: 0.3rem;
    padding: 0.15rem 0.5rem;
    background: var(--bg-light);
    border-radius: 4px;
    font-size: 0.75rem;
    color: var(--text-muted);
    width: fit-content;
}

@media (max-width: 900px) {
    .apex-towns-grid,
    .apex-towns-grid-teaser {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .apex-towns-grid,
    .apex-towns-grid-teaser {
        grid-template-columns: 1fr;
    }
}
