/* ======================
   RESET
====================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ======================
   BASE
====================== */
html,
body {
    height: 100%;
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: #f5f2eb;
    color: #333;
}

body {
    min-height: 100vh;
    padding-bottom: 80px;
    overscroll-behavior: none;
    -webkit-tap-highlight-color: transparent;
}

/* ======================
   LAYOUT
====================== */
.page-content {
    padding: 120px 20px 100px;
}

.container {
    width: 1100px;
    max-width: 95%;
    margin: 0 auto;
}

/* ======================
   HEADER
====================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(90deg, #8b0000, #b8860b);
    color: #fff;
    padding: 12px 24px;
    z-index: 5000;
}

.site-header-inner {
    position: relative;
    width: 100%;
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-left {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    z-index: 2;
}

.header-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.header-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-left: auto;
    z-index: 2;
}

.site-brand,
.site-brand:visited,
.site-brand:hover,
.site-brand:active {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
}

.site-logo {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: contain;
    background: #fff;
    flex-shrink: 0;
}

.site-title {
    text-align: left;
}

.site-title h1 {
    margin: 0;
    font-size: 20px;
    line-height: 1.1;
    color: #fff;
}

.site-title span {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #f3e6c9;
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 26px;
    flex-wrap: nowrap;
}

.site-nav a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.site-nav a:hover,
.site-nav a.active {
    text-decoration: underline;
}

.site-auth {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    text-align: right;
}

.site-auth a,
.site-auth span {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.site-auth a:hover {
    text-decoration: underline;
}

/* ======================
   USER DROPDOWN
====================== */
.user-menu {
    position: relative;
    display: inline-block;
}

.user-menu-btn {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
}

.user-menu-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}

.user-dropdown {
    display: none;
    position: absolute;
    top: 44px;
    right: 0;
    min-width: 230px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.14);
    overflow: hidden;
    z-index: 6000;
    padding: 6px 0;
}

.user-dropdown.show {
    display: block;
}

.user-dropdown a {
    display: block;
    padding: 11px 16px;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    border-bottom: 1px solid #f1ece2;
    transition: background 0.2s ease, color 0.2s ease;
}

.user-dropdown a:last-child {
    border-bottom: none;
}

.user-dropdown a:hover {
    background: #f7f4ee;
    color: #8b0000;
}

.user-dropdown-title {
    padding: 8px 16px 6px;
    font-size: 12px;
    font-weight: 700;
    color: #8b0000;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.user-dropdown-divider {
    height: 1px;
    background: #eee3d1;
    margin: 6px 0;
}

/* ======================
   MOBILE DRAWER
====================== */
.desktop-only {
    display: flex;
}

.mobile-only {
    display: none;
}

.mobile-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    visibility: hidden;
    transition: 0.25s ease;
    z-index: 7000;
}

.mobile-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    right: -320px;
    width: min(320px, 88vw);
    height: 100vh;
    background: #fff;
    box-shadow: -8px 0 24px rgba(0,0,0,0.16);
    transition: right 0.25s ease;
    z-index: 7001;
    display: flex;
    flex-direction: column;
}

.mobile-drawer.open {
    right: 0;
}

.mobile-drawer-header {
    background: linear-gradient(90deg, #8b0000, #b8860b);
    color: #fff;
    padding: 18px 16px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.mobile-drawer-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
}

.mobile-drawer-subtitle {
    font-size: 13px;
    opacity: 0.95;
}

.mobile-drawer-close {
    border: none;
    background: transparent;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
}

.mobile-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 10px 0 20px;
}

.mobile-drawer-section-title {
    padding: 12px 16px 8px;
    font-size: 12px;
    font-weight: 700;
    color: #8b0000;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.mobile-drawer-link {
    display: block;
    padding: 14px 16px;
    text-decoration: none;
    color: #333;
    font-size: 15px;
    font-weight: 600;
    border-bottom: 1px solid #f1ece2;
}

.mobile-drawer-link:hover {
    background: #f7f4ee;
    color: #8b0000;
}

body.drawer-open {
    overflow: hidden;
}

/* ======================
   HERO
====================== */
.hero {
    background: #fff;
    padding: 28px;
    border-radius: 16px;
    margin-bottom: 22px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

.hero h2 {
    color: #7a1f1f;
    margin-bottom: 10px;
}

.hero p {
    color: #555;
    line-height: 1.6;
}

/* ======================
   EMPTY STATE
====================== */
.empty-box {
    background: #fff;
    padding: 30px;
    border-radius: 18px;
    text-align: center;
    box-shadow: 0 10px 24px rgba(0,0,0,0.06);
    margin-top: 20px;
}

.empty-box h3 {
    color: #7a1f1f;
    margin-bottom: 10px;
}

.empty-box p {
    color: #555;
    margin-bottom: 15px;
}

/* ======================
   TABS
====================== */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.tabs a {
    display: inline-block;
    padding: 10px 18px;
    border-radius: 10px;
    background: #e8e0cf;
    text-decoration: none;
    color: #7a1f1f;
    font-weight: bold;
}

.tabs a.active {
    background: #b8860b;
    color: white;
}

/* ======================
   FILTER BOX
====================== */
.filter-box {
    background: #fff;
    padding: 18px;
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
    margin-bottom: 20px;
}

.filter-form {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    align-items: end;
}

.filter-group {
    min-width: 220px;
}

.filter-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: bold;
    color: #7a1f1f;
}

.filter-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
    background: #fff;
}

/* ======================
   BUTTONS
====================== */
.btn {
    display: inline-block;
    background: #b8860b;
    color: #fff;
    text-decoration: none;
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: #9f7609;
}

.btn.secondary {
    background: #ddd;
    color: #7a1f1f;
}

.btn.secondary:hover {
    background: #cfcfcf;
}

.btn-danger {
    background: #a32020;
    color: #fff !important;
}

.btn-danger:hover {
    background: #861919;
}

/* ======================
   HOME CARDS
====================== */
.cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.card {
    background: #fff;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

.card h3 {
    color: #7a1f1f;
    margin-bottom: 10px;
}

.card p {
    line-height: 1.6;
    color: #555;
}

.cards .card p {
    font-size: 28px;
    font-weight: 700;
    color: #7a1f1f;
    margin-top: 8px;
}

/* ======================
   CONTACT PAGE
====================== */
.wrap {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.form-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
}

.form-card h2 {
    margin-bottom: 14px;
    color: #7a1f1f;
}

.form-card p {
    margin-bottom: 10px;
    line-height: 1.6;
    color: #444;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.form-grid .full {
    grid-column: 1 / -1;
}

input,
textarea,
select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    background: #fff;
    outline: none;
}

input:focus,
textarea:focus,
select:focus {
    border-color: #b8860b;
}

/* ======================
   EVENTS
====================== */
.section-title {
    margin-bottom: 8px;
    color: #1f2430;
}

.result-count {
    margin-bottom: 18px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.event-card {
    background: #fff;
    padding: 22px;
    border-radius: 16px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
    border-top: 4px solid #b8860b;
}

.event-card h3 {
    color: #7a1f1f;
    margin-bottom: 10px;
}

.event-card p {
    margin-bottom: 8px;
    line-height: 1.6;
}

/* ======================
   AUTH
====================== */
.auth-wrap {
    min-height: calc(100vh - 220px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: 420px;
    max-width: 95%;
    background: #fff;
    border-radius: 18px;
    padding: 28px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
}

.success-message {
    background: #eaf8ea;
    color: #1f7a2e;
    border: 1px solid #bfe3c5;
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 14px;
    font-weight: 600;
}

.error-message {
    background: #fdeaea;
    color: #b00020;
    border: 1px solid #f3c2c2;
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 14px;
    font-weight: 600;
}

/* ======================
   FOOTER
====================== */
.site-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(90deg, #8b0000, #b8860b);
    color: #fff;
    padding: 14px 24px;
    z-index: 1000;
}

.site-footer-inner {
    position: relative;
    width: 100%;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-footer-left {
    display: flex;
    justify-content: flex-start;
    gap: 18px;
    flex-wrap: wrap;
}

.site-footer-left a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
}

.site-footer-left a:hover {
    text-decoration: underline;
}

.site-footer-center {
    text-align: center;
    font-size: 14px;
    white-space: nowrap;
}

.site-footer-right {
    display: flex;
    justify-content: flex-end;
}

/* ======================
   PAYMENT
====================== */
.payment-options {
    display: grid;
    gap: 10px;
    margin-top: 8px;
    margin-bottom: 8px;
}

.payment-option {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8f5ef;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 10px 12px;
    cursor: pointer;
}

.payment-option input[type="radio"] {
    width: auto;
    margin: 0;
}

.amount-box {
    background: #f8f5ef;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 18px;
    font-weight: 700;
    color: #7a1f1f;
}

.payment-element-box {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 14px;
}

/* ======================
   ADMIN
====================== */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
    background: #fff;
}

.admin-table th,
.admin-table td {
    border: 1px solid #e4ddd0;
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}

.admin-table th {
    background: #f4ead2;
    color: #7a1f1f;
    font-weight: 700;
}

.admin-table tr:nth-child(even) {
    background: #fcfaf6;
}

.admin-inline-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.admin-inline-form select {
    min-width: 130px;
}

.admin-pagination {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.admin-bookings-table {
    table-layout: fixed;
    width: 100%;
}

.admin-bookings-table th,
.admin-bookings-table td {
    word-wrap: break-word;
    overflow-wrap: anywhere;
}

.form-card canvas {
    width: 100% !important;
    max-height: 320px;
}

/* ======================
   MOBILE BOOKING CARDS
====================== */
.mobile-booking-list {
    display: none;
}

.mobile-booking-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
    padding: 16px;
    margin-bottom: 14px;
    border-top: 4px solid #b8860b;
}

.mobile-booking-card h3 {
    margin: 0 0 10px;
    color: #7a1f1f;
    font-size: 18px;
}

.mobile-booking-row {
    margin-bottom: 8px;
    line-height: 1.5;
    color: #333;
}

.mobile-booking-row strong {
    color: #7a1f1f;
}

.mobile-booking-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.mobile-booking-actions .btn,
.mobile-booking-actions .btn-danger {
    flex: 1;
    min-width: 110px;
    text-align: center;
}

.mobile-booking-inline-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}

.mobile-booking-inline-form select {
    width: 100%;
}

.mobile-booking-inline-form .btn {
    width: 100%;
}

.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.status-confirmed {
    background: #eaf8ea;
    color: #1f7a2e;
}

.status-pending {
    background: #fff4de;
    color: #9a6700;
}

.status-cancelled {
    background: #fdeaea;
    color: #b00020;
}

.install-app-btn {
    margin-left: 10px;
}

/* ======================
   POLISHED CHAT
====================== */
.site-chat-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #8b0000;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 999px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(0,0,0,0.10);
}

.site-chat-btn:hover {
    background: #f8f2ea;
}

.temple-chat-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.28);
    display: none;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 20px;
    z-index: 9999;
    backdrop-filter: blur(2px);
}

.temple-chat-modal.active {
    display: flex;
}

.temple-chat-box {
    width: 390px;
    max-width: 95vw;
    height: 560px;
    max-height: 85vh;
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 18px 50px rgba(0,0,0,0.18);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.temple-chat-header {
    background: linear-gradient(90deg, #8b0000, #b8860b);
    color: #fff;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    flex-shrink: 0;
}

.temple-chat-title-wrap {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.temple-chat-title {
    font-size: 18px;
    font-weight: 700;
}

.temple-chat-subtitle {
    font-size: 12px;
    opacity: 0.9;
    font-weight: 500;
}

.temple-chat-close {
    background: rgba(255,255,255,0.12);
    border: none;
    color: #fff;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    font-size: 22px;
    cursor: pointer;
    line-height: 1;
}

.temple-chat-close:hover {
    background: rgba(255,255,255,0.2);
}

.temple-chat-handle {
    display: none;
}

.temple-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 14px;
    background: #faf8f3;
    scroll-behavior: smooth;
}

.temple-chat-messages::-webkit-scrollbar {
    width: 6px;
}

.temple-chat-messages::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.18);
    border-radius: 999px;
}

.temple-chat-form {
    display: flex;
    gap: 10px;
    padding: 12px;
    border-top: 1px solid #eee;
    background: #fff;
    flex-shrink: 0;
}

.temple-chat-form input[type="text"] {
    flex: 1;
    margin-bottom: 0;
    border-radius: 14px;
    padding: 12px 14px;
    min-height: 46px;
}

.temple-chat-form .btn {
    min-width: 82px;
    border-radius: 14px;
    padding: 12px 14px;
}

.chat-bubble {
    max-width: 84%;
    padding: 12px 14px;
    border-radius: 16px;
    margin-bottom: 12px;
    line-height: 1.55;
    word-break: break-word;
    font-size: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04);
}

.chat-bubble.bot {
    background: #f3efe6;
    color: #333;
    border-top-left-radius: 6px;
    margin-right: auto;
}

.chat-bubble.user {
    background: #b8860b;
    color: #fff;
    border-top-right-radius: 6px;
    margin-left: auto;
}

.chat-bubble.bot ul {
    margin: 8px 0 0 18px;
}

.chat-bubble.bot li {
    margin-bottom: 4px;
}

.temple-chat-empty-tip {
    font-size: 13px;
    color: #666;
    margin-top: 4px;
}

/* ======================
   MOBILE NAV + FAB
====================== */
.mobile-bottom-nav {
    display: none;
}

.chat-fab {
    display: none;
}

/* ======================
   RESPONSIVE
====================== */
@media (max-width: 900px) {
    .site-header-inner,
    .site-footer-inner {
        position: static;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }

    .header-center,
    .header-right {
        position: static;
        transform: none;
        width: 100%;
        justify-content: flex-start;
    }

    .site-nav {
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .site-auth {
        justify-content: flex-start;
        text-align: left;
        flex-wrap: wrap;
    }

    .site-footer-center {
        text-align: left;
        white-space: normal;
    }

    .wrap {
        grid-template-columns: 1fr;
    }

    .cards {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    body {
        padding-bottom: calc(90px + env(safe-area-inset-bottom));
    }

    .site-header {
        position: sticky;
        top: 0;
        left: 0;
        width: 100%;
        padding: 10px 12px;
        z-index: 5000;
        background: linear-gradient(90deg, #8b0000, #b8860b);
    }

    .site-header-inner {
        position: static;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: flex-start;
        min-height: auto;
        gap: 0;
    }

    .header-left {
        width: 100%;
        display: flex;
        align-items: center;
    }

    .header-center,
    .header-right {
        display: none !important;
    }

    .desktop-only {
        display: none !important;
    }

    .mobile-only {
        display: none !important;
    }

    .site-brand,
    .site-brand:visited,
    .site-brand:hover,
    .site-brand:active {
        display: flex;
        align-items: center;
        gap: 10px;
        text-decoration: none;
        color: #fff;
        width: 100%;
    }

    .site-logo {
        width: 44px;
        height: 44px;
        min-width: 44px;
        border-radius: 50%;
        object-fit: contain;
        background: #fff;
    }

    .site-title {
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .site-title h1 {
        margin: 0;
        font-size: 16px;
        line-height: 1.1;
        color: #fff;
    }

    .site-title span {
        margin-top: 3px;
        font-size: 11px;
        color: #f3e6c9;
    }

    .page-content {
        padding: 14px 12px calc(110px + env(safe-area-inset-bottom));
    }

    .container,
    .wrap {
        width: 100%;
        max-width: 100%;
    }

    .hero,
    .form-card,
    .card,
    .auth-card,
    .event-card,
    .mobile-booking-card {
        padding: 16px;
        border-radius: 14px;
    }

    .cards,
    .grid,
    .wrap,
    .form-grid {
        grid-template-columns: 1fr !important;
        gap: 14px;
    }

    .tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
    }

    .tabs a {
        white-space: nowrap;
        flex: 0 0 auto;
        padding: 9px 14px;
        font-size: 14px;
    }

    .admin-table-wrapper {
        display: none;
    }

    .mobile-booking-list {
        display: block;
    }

    .admin-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .admin-table th,
    .admin-table td {
        white-space: nowrap;
    }

    .site-footer {
        display: none !important;
    }

    .mobile-bottom-nav {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        height: calc(72px + env(safe-area-inset-bottom));
        padding-bottom: env(safe-area-inset-bottom);
        background: linear-gradient(90deg, #8b0000, #b8860b);
        display: grid !important;
        grid-template-columns: repeat(4, 1fr);
        z-index: 6000;
        box-shadow: 0 -8px 18px rgba(0,0,0,0.18);
        border-top: 1px solid rgba(255,255,255,0.10);
    }

    .mobile-bottom-link {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        border: none;
        background: transparent;
        color: #fff;
        text-decoration: none;
        font-size: 11px;
        font-weight: 600;
        cursor: pointer;
        min-height: 72px;
    }

    .mobile-bottom-link i {
        font-size: 18px;
    }

    .mobile-bottom-link.active,
    .mobile-bottom-link:active {
        background: rgba(255,255,255,0.14);
    }

    .chat-fab {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        right: 14px;
        bottom: calc(88px + env(safe-area-inset-bottom));
        width: 56px;
        height: 56px;
        border-radius: 50%;
        border: none;
        background: linear-gradient(135deg, #b8860b, #8b0000);
        color: #fff;
        font-size: 22px;
        box-shadow: 0 12px 24px rgba(0,0,0,0.22);
        z-index: 7000;
        cursor: pointer;
    }

    .chat-fab:active {
        transform: scale(0.97);
    }

    .temple-chat-modal {
        align-items: flex-end;
        justify-content: center;
        padding: 0;
        background: rgba(0,0,0,0.30);
    }

    .temple-chat-box {
        width: 100%;
        max-width: 100%;
        height: 50vh !important;
        max-height: 50vh !important;
        border-radius: 18px 18px 0 0;
        box-shadow: 0 -10px 28px rgba(0,0,0,0.18);
    }

    .temple-chat-handle {
        display: block;
        width: 48px;
        height: 5px;
        border-radius: 999px;
        background: rgba(255,255,255,0.55);
        margin: 0 auto 10px;
    }

    .temple-chat-header {
        padding: 10px 14px 12px;
        align-items: flex-start;
    }

    .temple-chat-title {
        font-size: 17px;
    }

    .temple-chat-subtitle {
        font-size: 11px;
    }

    .temple-chat-messages {
        padding: 10px 12px;
    }

    .chat-bubble {
        max-width: 90%;
        font-size: 16px;
        padding: 12px 13px;
    }

    .temple-chat-form {
        padding: 8px 10px;
        gap: 8px;
    }

    .temple-chat-form input[type="text"] {
        min-height: 42px;
        font-size: 15px;
        border-radius: 12px;
    }

    .temple-chat-form .btn {
        min-width: 72px;
        padding: 11px 12px;
        border-radius: 12px;
    }
}