/* ==========================================================================
   🇰🇭 សិប្បកម្មកន្ទេលខ្មែរ (Kantel Khmer) - Design System & Stylesheet
   ========================================================================== */

/* 💡 ១. Google Fonts ខ្មែរស្តង់ដារ */
@import url('https://fonts.googleapis.com/css2?family=Battambang:wght@400;700;900&family=Kantumruy+Pro:ital,wght@0,100..900;1,100..900&family=Moul&display=swap');

:root {
    --navbar-bg: #d49a42;
    --hero-bg: #ebdcb9;
    --kantel-color: #ff5722;
    --kamplauk-color: #0088cc;
    --gold-text: #df9b35;
    --card-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* 💡 បង្ខំទប់ស្កាត់ការធ្លាយអេក្រង់ */
html, body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    font-family: 'Battambang', 'Khmer OS Battambang', 'Kantumruy Pro', sans-serif;
    background-color: #fdfbf7;
    color: #1e293b;
    scroll-behavior: smooth;
    line-height: 1.6;
}

*, *::before, *::after {
    box-sizing: inherit;
}

.moul {
    font-family: 'Moul', 'Battambang', cursive, serif;
}

button, input, select, textarea, optgroup {
    font-family: 'Kantumruy Pro', 'Battambang', 'Khmer OS Battambang', sans-serif !important;
}

/* ==========================================================================
   ២. របារម៉ឺនុយ (Navbar) - តាមគំរូរូបភាព ១០០%
   ========================================================================== */
.navbar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 52px !important;
    background-color: #d49a42 !important; /* ពណ៌លឿងឈើកន្ទេលដូចក្នុងរូបភាព */
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 0 25px !important;
    z-index: 99999 !important;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.12);
    box-sizing: border-box !important;
}

.left-section {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
}

.menu-btn {
    background: none !important;
    border: none !important;
    font-size: 22px !important;
    cursor: pointer !important;
    color: #1b120c !important;
    padding: 0 !important;
    margin-right: 4px !important;
    line-height: 1 !important;
    transition: transform 0.15s ease;
}

.menu-btn:hover {
    transform: scale(1.1);
}

.logo {
    font-size: 19px !important;
    font-weight: bold !important;
    color: #1b120c !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    letter-spacing: 0.2px;
}

.bell-container {
    cursor: pointer !important;
    padding: 2px 4px !important;
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
}

.msg-badge {
    position: absolute;
    top: -5px;
    right: -6px;
    background: #e53935;
    color: white;
    border-radius: 50%;
    padding: 1px 4px;
    font-size: 9px;
    font-weight: bold;
}

/* ម៉ឺនុយខាងស្ដាំ */
.nav-links {
    display: flex !important;
    align-items: center !important;
    gap: 22px !important;
    margin-left: auto !important;
}

.nav-links a {
    text-decoration: none !important;
    color: #1b120c !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
    white-space: nowrap !important;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-links a:hover {
    color: #000000 !important;
    opacity: 0.85;
}

/* ប៊ូតុងទិញឥឡូវរាងមូលពងក្រពើពណ៌លឿងដូចក្នុងរូបភាព */
.btn-buy-pill {
    background: #ffeb3b !important;
    color: #000000 !important;
    padding: 3px 12px !important;
    border-radius: 20px !important;
    font-size: 12px !important;
    font-weight: bold !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15) !important;
    border: 1px solid #fbc02d !important;
    animation: bounceAuto 1.5s infinite ease-in-out !important;
}

.btn-login {
    color: #1b120c !important;
    font-weight: bold !important;
    font-size: 14px !important;
}

/* ==========================================================================
   ២.១. Mobile Slide-out Drawer Menu (☰) & Overlay
   ========================================================================== */
.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 999998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.drawer-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 310px;
    max-width: 86vw;
    height: 100vh;
    height: 100dvh;
    background-color: #26160e;
    color: #fdfbf7;
    z-index: 999999;
    box-shadow: 6px 0 30px rgba(0, 0, 0, 0.55);
    transform: translateX(-100%);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mobile-drawer.open {
    transform: translateX(0);
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    background: #190e09;
    border-bottom: 2px solid #d49a42;
    flex-shrink: 0;
}

.drawer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.drawer-logo-icon {
    font-size: 26px;
    line-height: 1;
}

.drawer-title {
    font-size: 16px;
    margin: 0;
    font-weight: bold;
    color: #ffd54f;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif;
    line-height: 1.3;
}

.drawer-subtitle {
    font-size: 11px;
    color: #d49a42;
    display: block;
}

.drawer-close-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #ffd54f;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.drawer-close-btn:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: rotate(90deg);
}

.drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 14px 12px 40px;
    -webkit-overflow-scrolling: touch;
}

.drawer-body::-webkit-scrollbar {
    width: 4px;
}

.drawer-body::-webkit-scrollbar-thumb {
    background: rgba(212, 154, 66, 0.4);
    border-radius: 4px;
}

.drawer-section-label {
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #a88a6d;
    padding: 12px 10px 4px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    margin-top: 6px;
}

.drawer-section-label:first-of-type {
    border-top: none;
    margin-top: 0;
    padding-top: 2px;
}

.drawer-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    color: #ebdcb9;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    border-radius: 10px;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
    margin-bottom: 2px;
}

.drawer-link:hover, .drawer-link:active {
    background: rgba(212, 154, 66, 0.2);
    color: #ffd54f;
    transform: translateX(4px);
}

.drawer-icon {
    font-size: 16px;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
}

.drawer-badge {
    margin-left: auto;
    font-size: 10px;
    background: #ff5722;
    color: white;
    padding: 2px 7px;
    border-radius: 10px;
    font-weight: bold;
}

.drawer-buy-link {
    background: linear-gradient(135deg, #ffeb3b, #fbc02d) !important;
    color: #1b120c !important;
    font-weight: bold !important;
    margin-top: 6px;
    box-shadow: 0 3px 10px rgba(251, 192, 45, 0.35);
}

.drawer-buy-link:hover {
    background: #fff !important;
    transform: translateX(4px);
}

/* លាក់របាររំកិលរហ័សលើកុំព្យូទ័រ Desktop */
.mobile-subnav {
    display: none;
}

/* ==========================================================================
   ៣. ផ្នែកកណ្ដាល (Hero Section) - តាមគំរូរូបភាព ១០០%
   ========================================================================== */
.hero-section {
    width: 100% !important;
    max-width: 100% !important;
    padding-top: 75px !important; /* ឱ្យផុតពី Navbar 52px */
    padding-bottom: 25px !important;
    margin: 0 !important;
    background-color: #ebdcb9 !important; /* ពណ៌គ្រែមដូចក្នុងរូបភាព */
    box-sizing: border-box !important;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 15px;
}

.hero-title {
    font-size: 23px !important;
    margin-top: 0px !important;
    margin-bottom: 6px !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
    font-weight: bold;
    color: #1b120c !important;
    line-height: 1.4 !important;
    letter-spacing: 0.2px;
}

.hero-description {
    font-size: 13.5px !important;
    line-height: 1.6 !important;
    margin: 0 auto !important;
    color: #4a3b2b !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
}

/* ==========================================================================
   ៤. ផ្នែកបង្ហាញផលិតផល (Products Section)
   ========================================================================== */
.products-header, .kamplauk-header {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 30px 20px 8px 20px;
    text-align: left;
    box-sizing: border-box;
}

.section-title {
    font-size: 20px !important;
    color: #333;
    margin: 0 0 6px 0 !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
    font-weight: bold;
    display: block;
    line-height: 1.3 !important;
}

.section-desc {
    font-size: 14px;
    color: #444;
    line-height: 1.6 !important;
    margin: 0;
    max-width: 850px;
}

.product-container {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)) !important;
    gap: 20px !important;
    justify-content: center !important;
    padding: 15px 20px 25px 20px !important;
    width: 100% !important;
    max-width: 1240px !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
}

/* កាតផលិតផល */
.product-card {
    background: #ffffff !important;
    border: 5px solid #ff5722 !important; /* ស៊ុមពណ៌ទឹកក្រូច */
    border-radius: 16px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06) !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    box-sizing: border-box !important;
    position: relative !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.1) !important;
}

/* ស៊ុមសម្រាប់កំប្លោក */
.kamplauk-section .product-card {
    border-color: #0088cc !important;
}

/* រូបភាពផលិតផល */
.product-img-wrap {
    display: block;
    width: 100%;
    position: relative;
    overflow: hidden;
    background: #f8fafc;
}

.product-card img {
    width: 100% !important;
    height: 180px !important;
    object-fit: cover !important;
    display: block !important;
    border: none !important;
    cursor: pointer !important;
    transition: transform 0.3s ease;
}

.product-card:hover img {
    transform: scale(1.03);
}

.product-info {
    padding: 14px !important;
    flex-grow: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    box-sizing: border-box !important;
}

.product-info h3 {
    margin: 0 0 6px 0 !important;
    font-size: 15px !important;
    color: #1e293b !important;
    font-weight: bold !important;
    line-height: 1.4 !important;
    font-family: 'Battambang', 'Khmer OS Battambang', sans-serif !important;
}

.product-info p.size {
    margin: 0 0 4px 0 !important;
    font-size: 12px !important;
    color: #64748b !important;
}

.product-info p.desc {
    margin: 0 0 10px 0 !important;
    font-size: 12px !important;
    color: #718096 !important;
    line-height: 1.4 !important;
}

.product-footer {
    border-top: 1px solid #f1f5f9 !important;
    padding-top: 10px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 8px;
}

.product-price {
    font-size: 14px !important;
    font-weight: bold !important;
    color: #df9b35 !important;
}

.btn-telegram {
    background: #25D366 !important;
    color: white !important;
    padding: 6px 12px !important;
    text-decoration: none !important;
    border-radius: 6px !important;
    font-size: 11px !important;
    font-weight: bold !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px;
    white-space: nowrap;
}

.btn-telegram:hover {
    background: #1ebd54 !important;
}

.kamplauk-section .btn-telegram {
    background: #0088cc !important;
}

.kamplauk-section .btn-telegram:hover {
    background: #0070a6 !important;
}

/* ប៊ូតុង Like/Unlike/Save */
.reactions-bar {
    display: flex !important;
    flex-direction: row !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    margin-top: 10px !important;
    padding-top: 8px !important;
    border-top: 1px dashed #e2e8f0;
    width: 100% !important;
    box-sizing: border-box !important;
}

.reaction-btn {
    cursor: pointer;
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 5px !important;
    user-select: none;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.2s, box-shadow 0.2s;
    padding: 4px 10px !important;
    border-radius: 20px !important;
    border: 1px solid transparent !important;
    box-sizing: border-box !important;
}

.reaction-btn:hover {
    transform: scale(1.08);
    background-color: #f8fafc;
}

.reaction-btn .reaction-icon {
    font-size: 15px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    flex-shrink: 0 !important;
}

.reaction-btn .like-count {
    font-size: 11.5px !important;
    font-weight: bold !important;
    color: #333333 !important;
    line-height: 1 !important;
}

.reaction-btn .comment-text,
.reaction-btn .save-text {
    font-size: 11.5px !important;
    font-weight: bold !important;
    color: #475569 !important;
    line-height: 1 !important;
}

.reaction-btn.active-liked {
    background-color: #e0f2fe !important;
    border: 1px solid #7dd3fc !important;
    box-shadow: 0 1px 4px rgba(2, 132, 199, 0.25) !important;
}

.reaction-btn.active-liked .like-count {
    color: #0284c7 !important;
    font-weight: bold !important;
}

.reaction-btn.comment-btn {
    background-color: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    color: #475569 !important;
    cursor: pointer !important;
}

.reaction-btn.comment-btn:hover {
    background-color: #e0f2fe !important;
    border-color: #7dd3fc !important;
    color: #0284c7 !important;
    transform: scale(1.08) !important;
}

.comment-count-badge {
    font-size: 11px;
    font-weight: 700;
    color: #0284c7;
    background: #e0f2fe;
    padding: 1px 6px;
    border-radius: 10px;
    min-width: 17px;
    height: 17px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 2px;
    transition: all 0.2s ease;
    border: 1px solid rgba(2, 132, 199, 0.15);
    flex-shrink: 0;
}

.reaction-btn.comment-btn:hover .comment-count-badge {
    background: #0284c7;
    color: #ffffff;
    border-color: #0284c7;
}

.reaction-btn.save-btn {
    background-color: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    color: #475569 !important;
    cursor: pointer !important;
    text-decoration: none !important;
}

.reaction-btn.save-btn:hover {
    background-color: #fef3c7 !important;
    border-color: #fde047 !important;
    color: #b45309 !important;
    transform: scale(1.08) !important;
}

.reaction-btn.save-btn:active {
    transform: scale(0.95) !important;
}

.reaction-btn.save-btn.saved-success {
    background-color: #dcfce7 !important;
    border-color: #86efac !important;
    color: #15803d !important;
    animation: pulseSaved 0.35s ease;
}

.reaction-btn.save-btn.saved-success .save-text {
    color: #15803d !important;
}

@keyframes pulseSaved {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

@keyframes fadeInToast {
    from { opacity: 0; transform: translate(-50%, 15px); }
    to { opacity: 1; transform: translate(-50%, 0); }
}

#ios-photo-toast {
    position: fixed;
    bottom: 85px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.94);
    color: #ffffff;
    padding: 10px 18px;
    border-radius: 25px;
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.35);
    z-index: 999999;
    font-family: 'Battambang', sans-serif;
    text-align: center;
    max-width: 92%;
    width: max-content;
    animation: fadeInToast 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    pointer-events: none;
}

/* ស្លាកសញ្ញា "ថ្មី" */
.badge-new {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    width: 35px !important;
    height: 35px !important;
    line-height: 35px !important;
    text-align: center !important;
    background: #ff5722 !important;
    color: white !important;
    border-radius: 50% !important;
    font-size: 12px !important;
    font-weight: bold !important;
    z-index: 10 !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    animation: bounceAuto 1.5s infinite ease-in-out !important;
    pointer-events: none;
    display: block !important;
}

@keyframes bounceAuto {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* ផ្នែកកំប្លោក */
.kamplauk-section {
    width: 100%;
    overflow: hidden;
    background-color: #fffdf0;
    background-image: linear-gradient(90deg, rgba(31, 181, 99, 0.04) 50%, transparent 50%), linear-gradient(rgba(241, 196, 15, 0.05) 50%, transparent 50%);
    background-size: 8px 8px;
    border-top: 3px double #1fb563;
    border-bottom: 3px double #f1c40f;
    padding-bottom: 35px !important;
}

/* ==========================================================================
   ៥. ផ្នែកសកម្មភាព និងវីដេអូ (Activities Section)
   ========================================================================== */
.activity-section {
    width: 100%;
    overflow: hidden;
    padding: 25px 0 45px 0;
    background-color: #f9f9f9;
    border-top: 1px solid #eaeaea;
}

.activities-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.media-flex-container {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    width: 100%;
    margin-top: 15px;
}

.media-column {
    flex: 1 1 calc(50% - 15px);
    box-sizing: border-box;
}

.media-column h3 {
    font-size: 16px;
    font-weight: bold;
    margin-top: 0;
    margin-bottom: 18px;
    padding-bottom: 6px;
}

.sub-media-grid {
    display: flex;
    flex-direction: column;
    gap: 18px;
    width: 100%;
}

.index-activity-card {
    background: white;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
}

.video-box {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    background: #000;
    width: 100%;
}

.video-box iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.activity-caption {
    padding: 12px 15px;
    background: #ffffff;
}

.activity-caption h4 {
    margin: 0;
    font-size: 14px;
    color: #1e293b;
    font-weight: bold;
}

/* ==========================================================================
   ៦. ផ្នែកអំពីយើង (About Section)
   ========================================================================== */
.about-section {
    width: 100%;
    padding: 45px 20px;
    background: linear-gradient(135deg, #fffde7 0%, #ffe082 50%, #ffab91 100%) !important;
    text-align: center;
    box-sizing: border-box;
}

.about-box {
    max-width: 800px;
    margin: 0 auto;
}

.about-title {
    font-size: 24px !important;
    color: #000 !important;
    font-weight: bold;
    margin-bottom: 15px !important;
    line-height: 1.5 !important;
}

.about-text {
    font-size: 15px !important;
    line-height: 1.7 !important;
    color: #222 !important;
    margin: 0 auto;
}

/* ==========================================================================
   ៧. ផ្នែកមតិត្រឡប់ (Feedback Section)
   ========================================================================== */
.feedback-section {
    width: 100%;
    padding: 45px 20px;
    background-color: #f1f5f9;
    box-sizing: border-box;
}

.feedback-wrapper {
    max-width: 620px;
    margin: 0 auto;
    background: #ffffff;
    padding: 25px;
    border-radius: 14px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
    border-top: 4px solid #3498db;
    box-sizing: border-box;
}

.feedback-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-family: 'Kantumruy Pro', sans-serif;
    font-size: 14px;
    resize: none;
    outline: none;
    box-sizing: border-box;
}

.feedback-upload-row {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8fafc;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px dashed #cbd5e1;
    margin-top: 10px;
    flex-wrap: wrap;
}

.btn-camera {
    background-color: #3498db;
    color: white;
    padding: 8px 14px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    user-select: none;
}

.btn-submit-feedback {
    background: #fadb14;
    color: #006622;
    border: none;
    padding: 12px 35px;
    font-family: 'Moul', 'Battambang', sans-serif;
    font-size: 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(250, 219, 20, 0.3);
    width: 100%;
    max-width: 200px;
    margin-top: 12px;
}

/* ==========================================================================
   ៨. ផ្ទាំងមើលរូបភាពធំ (Image Lightbox Modal)
   ========================================================================== */
#imageLightbox {
    display: none;
    position: fixed;
    z-index: 9999999;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 20px;
    box-sizing: border-box;
}

#popupImage {
    max-width: 90%;
    max-height: 75vh;
    border-radius: 8px;
    object-fit: contain;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.lightbox-buttons {
    margin-top: 15px;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.btn-lb-download {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    background: #4CAF50;
    color: white;
    display: inline-block;
}

.btn-lb-close {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    background: #f44336;
    color: white;
}

/* ==========================================================================
   ៩. Footer & Visitor Stats
   ========================================================================== */
.visitor-dashboard {
    max-width: 400px;
    margin: 20px auto;
    padding: 15px;
    background: #ffffff;
    border: 1px solid #eaeaea;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    font-size: 13px;
    color: #333;
    text-align: center;
}

.stat-item {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    gap: 8px;
}

.stat-item:last-child {
    margin-bottom: 0;
}

.stat-item strong {
    color: #df9b35;
}

footer {
    background-color: #3e2723;
    color: #d4a04d;
    text-align: center;
    padding: 22px 20px;
    font-size: 13px;
}

footer a {
    color: #ffd700;
    text-decoration: none;
}

/* ==========================================================================
   📱 ១០. ផ្ទាំងកំណត់សម្រាប់ទូរស័ព្ទដៃ (Mobile Responsive @max-width: 768px)
   ========================================================================== */
@media (max-width: 768px) {
    /* Navbar លើទូរស័ព្ទ */
    .navbar {
        height: 50px !important;
        padding: 0 12px !important;
    }

    .logo {
        font-size: 16px !important;
    }

    .nav-links a:not(.btn-buy-pill) {
        display: none !important; /* លាក់ link វែងៗទុកតែប៊ូតុងទិញ និងម៉ឺនុយ */
    }

    .btn-buy-pill {
        font-size: 10px !important;
        padding: 3px 8px !important;
    }

    /* របាររំកិលប្រភេទរហ័សលើទូរស័ព្ទ (Category Tabs) */
    .mobile-subnav {
        display: flex !important;
        position: fixed !important;
        top: 50px !important;
        left: 0 !important;
        width: 100% !important;
        height: 44px !important;
        background: #bd8633 !important;
        border-top: 1px solid rgba(255, 255, 255, 0.15) !important;
        box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15) !important;
        z-index: 99998 !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        box-sizing: border-box !important;
    }

    .mobile-subnav::-webkit-scrollbar {
        display: none !important;
    }

    .subnav-container {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        padding: 0 12px !important;
        white-space: nowrap !important;
        width: max-content !important;
        min-width: 100% !important;
        box-sizing: border-box !important;
    }

    .subnav-pill {
        display: inline-flex !important;
        align-items: center !important;
        gap: 5px !important;
        padding: 5px 12px !important;
        background: rgba(0, 0, 0, 0.16) !important;
        color: #ffffff !important;
        text-decoration: none !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        border-radius: 20px !important;
        border: 1px solid rgba(255, 255, 255, 0.25) !important;
        transition: all 0.2s ease !important;
        flex-shrink: 0 !important;
    }

    .subnav-pill:active, .subnav-pill.active {
        background: #ffffff !important;
        color: #1b120c !important;
        font-weight: bold !important;
        border-color: #ffffff !important;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
    }

    .pill-icon {
        font-size: 13px !important;
    }

    /* Hero section លើទូរស័ព្ទ (ទុកចន្លោះសម្រាប់ Navbar 50px + Subnav 44px) */
    .hero-section {
        padding-top: 104px !important;
        padding-bottom: 20px !important;
    }

    .hero-title {
        font-size: 18px !important;
    }

    .hero-description {
        font-size: 12px !important;
    }

    /* ១. បង្ខំឱ្យប្លុកផលិតផលរត់ជា Grid ២ជួរឆ្វេងស្តាំស្មើគ្នា */
    .product-container {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        padding: 10px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* ២. កាតផលិតផលលើទូរស័ព្ទ */
    .product-card {
        width: 100% !important;
        margin: 0 !important;
        border-width: 4px !important;
        border-radius: 12px !important;
    }

    .product-card img {
        height: 130px !important;
    }

    .product-info {
        padding: 8px 6px !important;
    }

    .product-info h3 {
        font-size: 13px !important;
        margin-bottom: 3px !important;
    }

    .product-info p.size {
        font-size: 11px !important;
        margin-bottom: 2px !important;
    }

    .product-info p.desc {
        font-size: 11px !important;
        margin-bottom: 5px !important;
        line-height: 1.3 !important;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .product-footer {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 5px !important;
        padding-top: 5px !important;
    }

    .product-price {
        font-size: 13px !important;
        text-align: center;
    }

    .btn-telegram {
        font-size: 11px !important;
        padding: 6px 0 !important;
        width: 100% !important;
        text-align: center !important;
        justify-content: center !important;
    }

    .reactions-bar {
        margin-top: 6px !important;
        gap: 2.5px !important;
        justify-content: space-between !important;
        padding: 4px 0 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .reaction-btn {
        padding: 3px 4px !important;
        gap: 2.5px !important;
        border-radius: 10px !important;
        flex: 1 1 0 !important;
        min-width: 0 !important;
        justify-content: center !important;
        box-sizing: border-box !important;
    }

    .reaction-btn .reaction-icon {
        font-size: 12px !important;
    }

    .reaction-btn .like-count,
    .reaction-btn .save-text {
        font-size: 10px !important;
        white-space: nowrap !important;
    }

    .reaction-btn.comment-btn .comment-text {
        display: none !important;
    }

    .comment-count-badge {
        font-size: 9px !important;
        padding: 0 3px !important;
        min-width: 13px !important;
        height: 13px !important;
        margin-left: 0 !important;
    }

    .badge-new {
        top: 6px !important;
        right: 6px !important;
        width: 28px !important;
        height: 28px !important;
        line-height: 28px !important;
        font-size: 10px !important;
    }

    /* Activities លើទូរស័ព្ទ */
    .media-column {
        flex: 1 1 100% !important;
        width: 100% !important;
    }

    .media-flex-container {
        gap: 20px !important;
    }

    /* Feedback លើទូរស័ព្ទ */
    .feedback-wrapper {
        padding: 16px !important;
    }
}

/* ========================================================
   ផ្ទាំងបញ្ចេញមតិយោបល់ (Feedback & Comment Modal Dialog)
   ======================================================== */
.feedback-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 999999;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.feedback-modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.feedback-modal-container {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: 540px;
    max-height: 92vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.4);
    box-sizing: border-box;
    transform: scale(0.92) translateY(16px);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

.feedback-modal-backdrop.active .feedback-modal-container {
    transform: scale(1) translateY(0);
}

/* Modal Header */
.feedback-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 22px;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 40%, #f8fafc 100%);
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
}

.feedback-modal-title-box {
    display: flex;
    align-items: center;
    gap: 12px;
}

.feedback-modal-icon {
    font-size: 24px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(212, 160, 77, 0.25);
    border: 1px solid #fde68a;
    flex-shrink: 0;
}

.feedback-modal-title {
    margin: 0;
    font-family: 'Moul', 'Battambang', sans-serif;
    font-size: 16px;
    font-weight: normal;
    color: #003366;
    line-height: 1.3;
}

.feedback-modal-subtitle {
    margin: 3px 0 0 0;
    font-size: 12px;
    color: #64748b;
    font-family: 'Battambang', sans-serif;
}

.feedback-modal-close {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    font-size: 15px;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.feedback-modal-close:hover {
    background: #fee2e2;
    color: #ef4444;
    border-color: #fca5a5;
    transform: rotate(90deg);
}

/* Product Context Badge */
.modal-product-badge {
    margin: 14px 20px 0 20px;
    padding: 8px 12px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
    color: #166534;
    box-sizing: border-box;
}

.modal-product-badge .badge-icon {
    font-size: 15px;
}

.modal-product-badge .badge-label {
    font-weight: bold;
    color: #15803d;
}

.modal-product-badge .badge-title {
    color: #0f172a;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.modal-product-badge .badge-clear-btn {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    padding: 2px 6px;
    border-radius: 4px;
    transition: color 0.15s;
}

.modal-product-badge .badge-clear-btn:hover {
    color: #dc2626;
}

/* Quick Suggestion Tags */
.feedback-quick-tags {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 20px 0 20px;
    flex-wrap: wrap;
}

.quick-tag-label {
    font-size: 11.5px;
    font-weight: bold;
    color: #64748b;
}

.quick-tag {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    padding: 4px 10px;
    font-size: 11px;
    font-family: 'Battambang', sans-serif;
    color: #334155;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.quick-tag:hover {
    background: #fef3c7;
    border-color: #d4a04d;
    color: #92400e;
    transform: translateY(-1px);
}

/* Form Body */
.feedback-modal-body {
    padding: 14px 20px 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feedback-modal-textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    border: 1.5px solid #cbd5e1;
    border-radius: 12px;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
    font-size: 13.5px;
    line-height: 1.6;
    color: #1e293b;
    resize: vertical;
    min-height: 100px;
    background: #f8fafc;
    outline: none;
    transition: all 0.2s ease;
}

.feedback-modal-textarea:focus {
    background: #ffffff;
    border-color: #d4a04d;
    box-shadow: 0 0 0 3px rgba(212, 160, 77, 0.2);
}

/* Image Upload Row */
.modal-upload-section {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-modal-upload {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    padding: 7px 14px;
    border-radius: 10px;
    font-size: 12px;
    color: #334155;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    transition: all 0.2s ease;
}

.btn-modal-upload:hover {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #94a3b8;
}

.modal-img-status {
    font-size: 11.5px;
    color: #64748b;
    flex: 1;
}

/* Image Preview Container */
.modal-img-preview-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 10px;
    box-sizing: border-box;
}

.modal-img-preview-container img {
    width: 52px;
    height: 52px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
}

.modal-img-preview-info {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.modal-img-name {
    font-size: 12px;
    color: #334155;
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-remove-preview {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fca5a5;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-remove-preview:hover {
    background: #fecaca;
}

/* Telegram Callout */
.modal-telegram-callout {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 12px;
    color: #166534;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.modal-tg-link {
    color: #0284c7;
    font-weight: bold;
    text-decoration: none;
    transition: text-decoration 0.15s;
}

.modal-tg-link:hover {
    text-decoration: underline;
}

/* Status Message Box */
.modal-submit-msg {
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 12.5px;
    font-weight: bold;
    text-align: center;
    border: 1px solid transparent;
}

/* Modal Footer Actions */
.feedback-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

.btn-modal-cancel {
    background: #ffffff;
    color: #475569;
    border: 1px solid #cbd5e1;
    padding: 9px 18px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    font-family: 'Battambang', sans-serif;
    transition: all 0.15s ease;
}

.btn-modal-cancel:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.btn-modal-submit {
    background: linear-gradient(135deg, #d4a04d 0%, #b8860b 100%);
    color: #ffffff;
    border: none;
    padding: 9px 22px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(184, 134, 11, 0.3);
    transition: all 0.2s ease;
}

.btn-modal-submit:hover:not(:disabled) {
    box-shadow: 0 6px 16px rgba(184, 134, 11, 0.45);
    transform: translateY(-1px);
}

.btn-modal-submit:active:not(:disabled) {
    transform: translateY(0);
}

.btn-modal-submit:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

/* Responsive on Mobile */
@media (max-width: 600px) {
    .feedback-modal-container {
        max-height: 94vh;
        border-radius: 16px;
    }

    .feedback-modal-header {
        padding: 12px 16px;
        border-top-left-radius: 16px;
        border-top-right-radius: 16px;
    }

    .feedback-modal-title {
        font-size: 15px;
    }

    .modal-product-badge {
        margin: 10px 14px 0 14px;
        padding: 6px 10px;
        font-size: 11.5px;
    }

    .feedback-quick-tags {
        padding: 10px 14px 0 14px;
    }

    .feedback-modal-body {
        padding: 12px 14px;
    }

    .feedback-modal-footer {
        padding: 10px 14px;
        border-bottom-left-radius: 16px;
        border-bottom-right-radius: 16px;
    }
}

/* ========================================================
   ប្រអប់សារ (Message Box / Inbox Modal & Buttons)
   ======================================================== */
.inbox-box-trigger {
    cursor: pointer !important;
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 4px 7px !important;
    border-radius: 8px !important;
    transition: background 0.2s ease, transform 0.15s ease !important;
}

.inbox-box-trigger:hover {
    background: rgba(212, 160, 77, 0.18) !important;
    transform: scale(1.05);
}

.nav-inbox-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    text-decoration: none !important;
    color: #1b120c !important;
    font-size: 13px !important;
    font-weight: bold !important;
    font-family: 'Battambang', sans-serif !important;
    padding: 4px 12px !important;
    border-radius: 20px !important;
    background: #fffbeb !important;
    border: 1px solid #fde68a !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08) !important;
    transition: all 0.2s ease !important;
}

.nav-inbox-btn:hover {
    background: #fef3c7 !important;
    border-color: #d4a04d !important;
    transform: translateY(-1px);
}

.nav-inbox-pill {
    background: #dc2626;
    color: #ffffff;
    font-size: 10px;
    font-weight: bold;
    border-radius: 12px;
    padding: 1px 6px;
    line-height: 1.2;
}

.subnav-badge {
    background: #dc2626;
    color: #ffffff;
    font-size: 9px;
    font-weight: bold;
    border-radius: 10px;
    padding: 1px 5px;
    margin-left: 3px;
    line-height: 1;
}

/* Inbox Modal Overlay */
.inbox-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 999998;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.inbox-modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.inbox-modal-container {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: 580px;
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.4);
    box-sizing: border-box;
    transform: scale(0.92) translateY(16px);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.inbox-modal-backdrop.active .inbox-modal-container {
    transform: scale(1) translateY(0);
}

/* Inbox Header */
.inbox-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 40%, #f8fafc 100%);
}

.inbox-modal-title-box {
    display: flex;
    align-items: center;
    gap: 12px;
}

.inbox-modal-icon {
    font-size: 24px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(212, 160, 77, 0.25);
    border: 1px solid #fde68a;
    flex-shrink: 0;
}

.inbox-modal-title {
    margin: 0;
    font-family: 'Moul', 'Battambang', sans-serif;
    font-size: 16.5px;
    font-weight: normal;
    color: #003366;
    line-height: 1.3;
}

.inbox-count-badge {
    background: #0284c7;
    color: #ffffff;
    font-size: 10.5px;
    font-weight: bold;
    padding: 2px 8px;
    border-radius: 12px;
    font-family: 'Battambang', sans-serif;
}

.inbox-modal-subtitle {
    margin: 3px 0 0 0;
    font-size: 12px;
    color: #64748b;
    font-family: 'Battambang', sans-serif;
}

.inbox-modal-close {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    font-size: 15px;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.inbox-modal-close:hover {
    background: #fee2e2;
    color: #ef4444;
    border-color: #fca5a5;
    transform: rotate(90deg);
}

/* Tabs & Action Bar */
.inbox-tabs-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 18px 0 18px;
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    gap: 8px;
    flex-wrap: wrap;
}

.inbox-tabs-group {
    display: flex;
    gap: 4px;
}

.inbox-tab-btn {
    background: none;
    border: none;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    color: #64748b;
    cursor: pointer;
    border-bottom: 2.5px solid transparent;
    transition: all 0.15s ease;
}

.inbox-tab-btn:hover {
    color: #0f172a;
}

.inbox-tab-btn.active {
    color: #b45309;
    border-bottom-color: #d4a04d;
}

.inbox-tab-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
}

.btn-inbox-refresh {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 5px 10px;
    font-size: 11.5px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    color: #334155;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.15s ease;
}

.btn-inbox-refresh:hover {
    background: #e2e8f0;
}

.btn-inbox-write {
    background: linear-gradient(135deg, #d4a04d 0%, #b8860b 100%);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 5px 12px;
    font-size: 11.5px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 6px rgba(184, 134, 11, 0.25);
    transition: all 0.15s ease;
}

.btn-inbox-write:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(184, 134, 11, 0.35);
}

/* Messages Body Area */
.inbox-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 280px;
    max-height: 56vh;
    box-sizing: border-box;
}

.inbox-state-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
}

.inbox-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #e2e8f0;
    border-top-color: #d4a04d;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.inbox-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
}

/* Feedback Cards */
.inbox-item-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: all 0.2s ease;
}

.inbox-item-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    border-color: #cbd5e1;
}

.inbox-item-card.unread-item {
    border-left: 4px solid #d4a04d;
    background: #fffdfa;
}

.inbox-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.inbox-item-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.inbox-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #fef3c7;
    border: 1px solid #fde68a;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

.inbox-author-name {
    font-size: 13px;
    font-weight: bold;
    color: #1e293b;
    font-family: 'Battambang', sans-serif;
}

.inbox-time {
    font-size: 11px;
    color: #94a3b8;
}

.inbox-unread-pill {
    background: #fee2e2;
    color: #dc2626;
    font-size: 10px;
    font-weight: bold;
    padding: 1px 7px;
    border-radius: 10px;
}

.inbox-item-comment {
    font-size: 13.5px;
    line-height: 1.6;
    color: #334155;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
    word-break: break-word;
    white-space: pre-wrap;
}

.inbox-item-img-box {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.inbox-item-img-box img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.inbox-item-img-box img:hover {
    transform: scale(1.05);
}

.inbox-item-img-box .img-hint {
    font-size: 11px;
    color: #0284c7;
    cursor: pointer;
    text-decoration: underline;
}

.inbox-item-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding-top: 6px;
    border-top: 1px solid #f1f5f9;
}

.inbox-tg-btn {
    font-size: 11.5px;
    color: #0284c7;
    font-weight: bold;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    background: #f0f9ff;
    transition: background 0.15s ease;
}

.inbox-tg-btn:hover {
    background: #e0f2fe;
}

/* Chat Cards */
.inbox-chat-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.inbox-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.inbox-chat-author {
    font-size: 12.5px;
    color: #003366;
    font-family: 'Battambang', sans-serif;
}

.inbox-chat-time {
    font-size: 11px;
    color: #94a3b8;
}

.inbox-chat-reply {
    font-size: 11.5px;
    background: #f1f5f9;
    padding: 4px 8px;
    border-radius: 6px;
    border-left: 3px solid #0284c7;
    margin: 2px 0;
}

.inbox-chat-msg {
    font-size: 13px;
    color: #1e293b;
    line-height: 1.5;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
}

/* Chat Input Row */
.inbox-chat-input-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
}

.inbox-name-input {
    width: 90px;
    padding: 8px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 12px;
    outline: none;
    font-family: 'Battambang', sans-serif;
}

.inbox-msg-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 12.5px;
    outline: none;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
}

.inbox-msg-input:focus, .inbox-name-input:focus {
    border-color: #d4a04d;
}

.btn-quick-send {
    background: #d4a04d;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.15s;
}

.btn-quick-send:hover {
    background: #b8860b;
}

/* Inbox Footer */
.inbox-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
}

/* Mobile Adjustments */
@media (max-width: 600px) {
    .inbox-modal-container {
        max-height: 94vh;
        border-radius: 16px;
    }

    .inbox-modal-header {
        padding: 12px 16px;
    }

    .inbox-tabs-bar {
        padding: 8px 14px 0 14px;
    }

    .inbox-modal-body {
        padding: 12px 14px;
    }

    .action-btn-text {
        display: none;
    }

    .inbox-name-input {
        width: 75px;
    }
}

/* ========================================================
   ប្រអប់មតិយោបល់ និងការឆ្លើយឆ្លង (Live Community Comments & Replies)
   ======================================================== */
.comment-thread-container {
    max-width: 620px !important;
    height: 90vh !important;
    max-height: 740px !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    border-radius: 20px !important;
}

.comment-context-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 16px;
    background: #fefce8;
    border-bottom: 1px solid #fef08a;
    font-size: 12px;
    color: #854d0e;
    gap: 8px;
    flex-wrap: wrap;
}

.context-info {
    display: flex;
    align-items: center;
    gap: 6px;
}

.context-filter-btns {
    display: flex;
    gap: 4px;
}

.btn-filter-pill {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 2px 10px;
    font-size: 11px;
    cursor: pointer;
    color: #475569;
    font-family: 'Battambang', sans-serif;
    transition: all 0.15s ease;
}

.btn-filter-pill.active {
    background: #d4a04d;
    color: #ffffff;
    border-color: #b8860b;
    font-weight: bold;
}

.comments-thread-feed {
    flex: 1;
    overflow-y: auto;
    padding: 14px 16px;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    gap: 12px;
    box-sizing: border-box;
}

.comments-list-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Individual Comment Card */
.comment-bubble {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: all 0.2s ease;
}

.comment-bubble:hover {
    border-color: #cbd5e1;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.comment-bubble.reply-item {
    margin-left: 20px;
    border-left: 3px solid #0284c7;
    background: #fafcff;
}

.comment-bubble-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comment-author-box {
    display: flex;
    align-items: center;
    gap: 8px;
}

.comment-author-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #fef3c7;
    border: 1px solid #fde68a;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.comment-author-name {
    font-size: 13px;
    font-weight: bold;
    color: #0f172a;
    font-family: 'Battambang', sans-serif;
}

.comment-prod-tag {
    background: #f1f5f9;
    color: #475569;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 6px;
    margin-left: 4px;
    display: inline-block;
    max-width: 130px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.comment-time {
    font-size: 10.5px;
    color: #94a3b8;
}

/* Quoted Parent Reply Block */
.comment-quoted-box {
    background: #f1f5f9;
    border-left: 3px solid #0284c7;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 11.5px;
    color: #475569;
    margin: 2px 0;
}

.comment-quoted-box strong {
    color: #0369a1;
}

.comment-text-body {
    font-size: 13.5px;
    line-height: 1.6;
    color: #334155;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
    word-break: break-word;
    white-space: pre-wrap;
}

.comment-bubble-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 6px;
    border-top: 1px solid #f8fafc;
}

.btn-comment-reply {
    background: none;
    border: none;
    color: #0284c7;
    font-size: 11.5px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 6px;
    transition: background 0.15s ease;
}

.btn-comment-reply:hover {
    background: #e0f2fe;
}

.btn-comment-delete {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    font-size: 11px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px;
    border-radius: 6px;
    transition: all 0.2s ease;
    margin-left: auto;
}

.btn-comment-delete:hover {
    background: #dc2626;
    color: #ffffff;
    border-color: #dc2626;
    transform: scale(1.05);
}

/* Active Reply Banner Above Composer */
.active-reply-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 7px 16px;
    background: #e0f2fe;
    border-top: 1px solid #bae6fd;
    font-size: 12px;
    color: #0369a1;
    font-family: 'Battambang', sans-serif;
    animation: fadeIn 0.2s ease;
}

.reply-bar-content {
    display: flex;
    align-items: center;
    gap: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.reply-bar-content em {
    opacity: 0.85;
    font-style: normal;
    color: #0284c7;
}

.btn-cancel-reply {
    background: none;
    border: none;
    color: #0369a1;
    font-size: 15px;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    transition: color 0.15s;
}

.btn-cancel-reply:hover {
    color: #dc2626;
}

/* Compact Tags */
.comment-tags-compact {
    padding: 6px 16px 0 16px !important;
    background: #ffffff;
    border-top: 1px solid #f1f5f9;
}

/* Composer Form */
.comment-composer-form {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 10px 16px 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.composer-inputs-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.composer-name-input {
    width: 140px;
    padding: 6px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 12px;
    font-family: 'Battambang', sans-serif;
    outline: none;
    transition: border-color 0.15s;
}

.composer-name-input:focus {
    border-color: #d4a04d;
}

.btn-composer-camera {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 5px 10px;
    font-size: 11.5px;
    font-weight: bold;
    font-family: 'Battambang', sans-serif;
    color: #475569;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.15s ease;
}

.btn-composer-camera:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.btn-composer-tg {
    margin-left: auto;
    font-size: 11.5px;
    color: #0284c7;
    text-decoration: none;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 8px;
    border-radius: 6px;
    background: #f0f9ff;
    transition: background 0.15s;
}

.btn-composer-tg:hover {
    background: #e0f2fe;
}

.composer-textarea-row {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.composer-textarea {
    flex: 1;
    padding: 8px 12px;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    font-size: 13px;
    font-family: 'Kantumruy Pro', 'Battambang', sans-serif;
    line-height: 1.5;
    color: #1e293b;
    resize: none;
    min-height: 42px;
    max-height: 90px;
    outline: none;
    transition: all 0.2s ease;
}

.composer-textarea:focus {
    border-color: #d4a04d;
    box-shadow: 0 0 0 3px rgba(212, 160, 77, 0.2);
}

.btn-composer-send {
    background: linear-gradient(135deg, #d4a04d 0%, #b8860b 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    width: 44px;
    height: 42px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 8px rgba(184, 134, 11, 0.3);
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.btn-composer-send:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 5px 12px rgba(184, 134, 11, 0.4);
}

.btn-composer-send:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Mobile Adjustments for Comment Thread */
@media (max-width: 600px) {
    .comment-thread-container {
        height: 95vh !important;
        max-height: 95vh !important;
        border-radius: 16px !important;
    }

    .comment-bubble.reply-item {
        margin-left: 10px;
    }

    .composer-name-input {
        width: 105px;
    }

    .comment-tags-compact {
        padding: 4px 12px 0 12px !important;
    }

    .comment-composer-form {
        padding: 8px 12px 10px 12px;
    }
}



