﻿/* ============================
   VARIABLES & GLOBAL STYLES
   ============================ */

:root {
    --primary: #fbbf24;
    --primary-dark: #f59e0b;
    --secondary: #f97316;
    --accent: #dc2626;
    --success: #10b981;
    --text-dark: #1a1a1a;
    --text-light: #666666;
    --text-lighter: #999999;
    --bg-light: #f9fafb;
    --bg-lighter: #f5f5f5;
    --border-light: #e5e7eb;
    --white: #ffffff;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
    --radius: 12px;
    --radius-sm: 8px;
    --spacing-xs: 8px;
    --spacing-sm: 12px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    padding-bottom: 80px;
}

body.auth-loading-active {
    overflow: hidden;
}

@media (min-width: 769px) {
    body {
        padding-bottom: 0;
    }
}

/* ============================
   HEADER (TOP NAVBAR)
   ============================ */

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    box-shadow: var(--shadow-md);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md) var(--spacing-lg);
    gap: var(--spacing-lg);
    max-width: 100%;
}

.header-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    flex-shrink: 0;
    font-weight: 700;
    color: var(--text-dark);
}

.logo-img {
    height: 40px;
    width: auto;
    background: white;
    padding: 6px 10px;
    border-radius: 8px;
}

.logo-text {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    display: none;
}

@media (min-width: 769px) {
    .logo-text {
        display: inline;
    }
}

.header-search {
    display: none;
    flex: 1;
    gap: var(--spacing-xs);
    max-width: 400px;
}

.back-button {
    position: absolute;
    top: 15px;
    left: 15px;
    margin: 15px;
    min-height: 44px;
    padding: 10px 16px;
    border-radius: 999px;
    border: 1px solid rgba(244, 162, 97, 0.2);
    background: rgba(255, 255, 255, 0.94);
    color: #c76c2a;
    text-decoration: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    z-index: 120;
}

.back-button:hover {
    color: #a8571f;
    background: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.12);
}

.back-button-icon {
    font-size: 18px;
    line-height: 1;
}

.back-button-label {
    line-height: 1;
}

.back-button-inline {
    position: static;
    margin: 0;
}

@media (max-width: 768px) {
    .back-button,
    .back-button-inline {
        position: fixed;
        top: 15px;
        left: 15px;
        margin: 0;
        padding: 10px 12px;
        border-radius: 50%;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
        z-index: 1000;
    }

    .back-button-label {
        display: none;
    }
}

@media (min-width: 769px) {
    .header-search {
        display: flex;
        align-items: center;
        background-color: rgba(255, 255, 255, 0.9);
        border-radius: var(--radius);
        padding: var(--spacing-xs) var(--spacing-md);
    }
}

.search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: var(--spacing-sm) 0;
    font-size: 14px;
    outline: none;
    color: var(--text-dark);
}

.search-input::placeholder {
    color: var(--text-lighter);
}

.search-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    color: var(--text-dark);
    padding: var(--spacing-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.search-btn:hover {
    color: var(--secondary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-left: auto;
    justify-content: flex-end;
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    font-size: 20px;
    color: var(--text-dark);
    padding: var(--spacing-xs);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.icon-btn:hover {
    background-color: rgba(0, 0, 0, 0.1);
    transform: scale(1.1);
}

.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--secondary);
    color: white;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    box-shadow: var(--shadow);
}

/* Auth buttons */
.auth-desktop,
.auth-buttons {
    display: flex;
    gap: 10px;
    align-items: center;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.auth-buttons.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.navbar-profile {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 6px 10px 6px 6px;
    min-height: 46px;
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.14);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease, visibility 0.2s ease;
}

.navbar-profile[hidden] {
    display: none !important;
}

.navbar-profile:hover {
    background: rgba(255, 255, 255, 0.26);
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.18);
}

.navbar-profile:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.18), 0 14px 30px rgba(15, 23, 42, 0.18);
}

.navbar-profile-avatar-wrap {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #ffffff;
    color: #b45309;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.navbar-profile-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.navbar-profile-initials {
    font-size: 0.86rem;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.navbar-profile-name {
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.95rem;
    font-weight: 700;
}
 
.btn-login {
    padding: 6px 12px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid #fff;
    color: white;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
}

.btn-login:hover {
    background: rgba(255, 255, 255, 0.1);
    text-decoration: none;
}

.btn-signup {
    padding: 6px 12px;
    border-radius: 8px;
    background: white;
    color: #f59e0b;
    border: none;
    font-size: 14px;
    font-weight: 700;
    transition: var(--transition);
    text-decoration: none;
}

.btn-signup:hover {
    opacity: 0.9;
    text-decoration: none;
}

/* Mobile responsive auth buttons */
@media (max-width: 768px) {
    .auth-desktop,
    .auth-buttons {
        display: none !important;
    }

    .navbar-profile {
        display: none !important;
    }
}

/* ============================
   BANNER SLIDER
   ============================ */

.banner-slider {
    width: 95%;
    position: relative;
    overflow: hidden;
    height: 300px;
    border-radius: 20px;
    margin: 10px auto;
    box-shadow: var(--shadow-lg);
    isolation: isolate;
    background: #d9a96b;
}

.banner-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transform: scale(1.02);
    transition: opacity 0.65s ease, transform 0.65s ease, visibility 0.65s ease;
}

.banner-slide.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.banner-slide img,
.banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
    position: absolute;
    inset: 0;
    border-radius: 20px;
}

.banner-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(12, 17, 29, 0.78) 0%, rgba(12, 17, 29, 0.42) 34%, rgba(12, 17, 29, 0.08) 64%, rgba(12, 17, 29, 0) 76%);
}

.banner-content {
    position: absolute;
    top: 50%;
    left: 5%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 12px;
    max-width: 40%;
    padding: 0;
    text-align: left;
    color: var(--white);
    z-index: 2;
}

.banner-kicker {
    letter-spacing: 0.22em;
    text-transform: uppercase;
    font-size: 12px;
    font-weight: 700;
    color: #fde68a;
}

.banner-title {
    max-width: 100%;
    font-size: clamp(1.8rem, 3vw, 2rem);
    line-height: 1.18;
    font-weight: 800;
    text-wrap: balance;
    text-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}

.banner-slide[data-page="promotions.html"] .banner-content {
    max-width: 42%;
}

.banner-slide[data-page="devenir-vendeur.html"] .banner-content {
    max-width: 40%;
}

.banner-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 170px;
    padding: 12px 25px;
    border-radius: 25px;
    background: #F4A261;
    color: var(--white);
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(244, 162, 97, 0.3);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.banner-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(232, 149, 74, 0.34);
    background: #e8954a;
}

.banner-dots {
    position: absolute;
    left: 50%;
    bottom: 14px;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 3;
}

.banner-dot {
    width: 12px;
    height: 12px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.18);
    transition: transform 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease;
}

.banner-dot:hover,
.banner-dot:focus-visible {
    transform: translateY(-1px) scale(1.1);
    background: rgba(244, 162, 97, 0.72);
    box-shadow: 0 10px 18px rgba(244, 162, 97, 0.28);
    outline: none;
}

.banner-dot.active,
.banner-dot.active-dot {
    background: #F4A261;
    transform: scale(1.15);
    box-shadow: 0 12px 20px rgba(244, 162, 97, 0.3);
}

/* Responsive banner heights */
@media (max-width: 768px) {
    .banner-slider {
        height: 180px;
        margin: 10px auto;
        border-radius: 12px;
    }

    .banner-content {
        left: 6%;
        max-width: 52%;
        gap: 8px;
    }

    .banner-slide[data-page="promotions.html"] .banner-content {
        max-width: 56%;
    }

    .banner-slide[data-page="devenir-vendeur.html"] .banner-content {
        max-width: 54%;
    }

    .banner-title {
        font-size: 1rem;
        line-height: 1.2;
    }

    .banner-btn {
        min-width: 128px;
        padding: 9px 16px;
        font-size: 13px;
    }

    .banner-slide img,
    .banner-img {
        border-radius: 12px;
        object-position: 72% center;
    }
}

.promo-landing,
.categories-landing,
.seller-landing {
    min-height: 100vh;
    background:
        radial-gradient(circle at top right, rgba(244, 162, 97, 0.16), transparent 28%),
        linear-gradient(180deg, #fff8ef 0%, #ffffff 42%, #fff5ec 100%);
}

.landing-shell {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 32px 0 72px;
}

.landing-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.landing-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.landing-brand img {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.landing-header-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.landing-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    border: 1px solid rgba(44, 62, 80, 0.12);
    background: rgba(255, 255, 255, 0.88);
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.landing-link:hover,
.landing-link:focus-visible {
    transform: translateY(-1px);
    border-color: rgba(244, 162, 97, 0.45);
    box-shadow: 0 10px 24px rgba(44, 62, 80, 0.08);
    outline: none;
}

.landing-link.primary {
    background: #F4A261;
    border-color: #F4A261;
    color: var(--white);
}

.landing-link.primary:hover,
.landing-link.primary:focus-visible {
    box-shadow: 0 12px 26px rgba(244, 162, 97, 0.28);
}

.landing-banner {
    margin-bottom: 28px;
}

.landing-intro {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.landing-card {
    padding: 22px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(228, 204, 180, 0.65);
    box-shadow: 0 18px 38px rgba(44, 62, 80, 0.08);
}

.landing-card h2,
.landing-card h3 {
    margin-bottom: 10px;
    color: var(--text-dark);
}

.landing-card p,
.landing-card li {
    color: #5c6470;
    line-height: 1.6;
}

.landing-card ul {
    margin: 0;
    padding-left: 18px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.category-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 72px;
    padding: 18px 20px;
    border-radius: 20px;
    text-decoration: none;
    color: var(--text-dark);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(228, 204, 180, 0.7);
    box-shadow: 0 18px 34px rgba(44, 62, 80, 0.07);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.category-pill:hover,
.category-pill:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(244, 162, 97, 0.5);
    box-shadow: 0 22px 40px rgba(244, 162, 97, 0.14);
    outline: none;
}

.category-pill i {
    color: #F4A261;
    font-size: 1.15rem;
}

.seller-benefits {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.seller-benefit {
    min-height: 100%;
}

.seller-benefit-icon {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    margin-bottom: 16px;
    background: rgba(244, 162, 97, 0.14);
    color: #F4A261;
    font-size: 1.2rem;
}

.seller-offer-list {
    list-style: none;
    padding: 0;
    display: grid;
    gap: 12px;
}

.seller-offer-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.seller-offer-list i {
    margin-top: 4px;
    color: #F4A261;
}

.seller-cta-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 18px;
}

@media (max-width: 900px) {
    .landing-intro,
    .category-grid,
    .seller-benefits {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .landing-shell {
        width: min(100% - 24px, 1120px);
        padding-top: 20px;
        padding-bottom: 56px;
    }

    .landing-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .landing-header-actions {
        width: 100%;
    }

    .landing-link {
        flex: 1 1 160px;
    }

    .landing-card,
    .category-pill {
        border-radius: 18px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .banner-slider {
        height: 300px;
    }

    .banner-title {
        font-size: 1.75rem;
    }

    .banner-content {
        max-width: 44%;
    }
}

@media (max-width: 1024px) {
    .auth-buttons {
        display: none;
    }
}

@media (min-width: 769px) {
    .auth-buttons {
        gap: var(--spacing-xs);
    }

    .login-btn .btn-text,
    .signup-btn .btn-text {
        display: none;
    }

    .login-btn {
        padding: var(--spacing-xs);
    }

    .signup-btn {
        padding: 6px 8px;
        font-size: 12px;
    }
}

/* Logged in state */
.logged-in .auth-buttons {
    display: none;
}

.logged-in .profile-btn {
    display: flex;
}

/* ============================
   MAIN LAYOUT
   ============================ */

.main-layout {
    display: flex;
    max-width: 100%;
    margin: 0 auto;
}

/* ============================
   SIDEBAR (Desktop only)
   ============================ */

.sidebar {
    display: none;
    width: 260px;
    background-color: var(--white);
    border-right: 1px solid var(--border-light);
    padding: var(--spacing-lg) 0;
    position: sticky;
    top: 60px;
    height: calc(100vh - 60px);
    overflow-y: auto;
}

@media (min-width: 1025px) {
    .sidebar {
        display: block;
    }
}

.sidebar-title {
    padding: 0 var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    font-size: 14px;
    font-weight: 700;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.categories-list {
    display: flex;
    flex-direction: column;
}

.category-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-light);
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.category-item:hover {
    background-color: var(--bg-light);
    color: var(--primary);
}

.category-item.active {
    background-color: rgba(251, 191, 36, 0.1);
    color: var(--primary);
    border-left-color: var(--primary);
}

.category-item i {
    width: 20px;
    font-size: 16px;
}

/* ============================
   MAIN CONTENT
   ============================ */

.main-content {
    flex: 1;
    min-width: 0;
}

/* ============================
   TOP NAVIGATION MENU
   ============================ */

.top-nav {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-light);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    position: sticky;
    top: 60px;
    z-index: 50;
}

.nav-container {
    display: flex;
    gap: var(--spacing-sm);
    padding: 0 var(--spacing-md);
    max-width: 100%;
    margin: 0 auto;
    justify-content: center;
}

@media (max-width: 768px) {
    .top-nav {
        display: none;
    }
}

.nav-link {
    flex-shrink: 0;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--spacing-md) var(--spacing-sm);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-light);
    transition: var(--transition);
    position: relative;
    white-space: nowrap;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link.active {
    color: var(--primary);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
}

/* ============================
   MOBILE CATEGORIES
   ============================ */

.mobile-categories {
    display: block;
    background-color: var(--white);
    border-bottom: 1px solid var(--border-light);
    padding: var(--spacing-md) 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 1025px) {
    .mobile-categories {
        display: none;
    }
}

.categories-scroll {
    display: flex;
    gap: var(--spacing-sm);
    padding: 0 var(--spacing-md);
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

.categories-scroll::-webkit-scrollbar {
    height: 4px;
}

.categories-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.categories-scroll::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 2px;
}

.category-chip {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-sm) var(--spacing-md);
    background-color: var(--bg-light);
    border: 2px solid transparent;
    border-radius: 24px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    transition: var(--transition);
    white-space: nowrap;
}

.category-chip:hover {
    background-color: var(--primary);
    color: var(--text-dark);
    border-color: var(--primary);
}

.category-chip.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--text-dark);
    border-color: var(--primary);
}

/* ============================
   PRODUCTS SECTION
   ============================ */

.products-section {
    padding: var(--spacing-xl) var(--spacing-lg);
    background-color: var(--white);
    margin: var(--spacing-lg);
    border-radius: var(--radius);
}

@media (min-width: 1025px) {
    .products-section {
        margin: var(--spacing-xl) var(--spacing-lg);
        padding: var(--spacing-xl);
    }
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-md);
    flex-wrap: wrap;
    margin-bottom: var(--spacing-lg);
}

.section-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    min-width: 0;
    overflow-wrap: anywhere;
}

@media (min-width: 769px) {
    .section-title {
        font-size: 20px;
    }
}

.section-title i {
    color: var(--secondary);
}

.view-more {
    color: var(--primary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
}

.view-more:hover {
    color: var(--secondary);
}

/* Product Grid - Mobile first */
.products-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        padding: 10px;
    }

    .product-card {
        width: 100%;
        height: auto;
    }

    .product-image {
        padding-bottom: 0;
        aspect-ratio: 1 / 1;
    }

    .product-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .product-info {
        padding: 10px;
    }

    .product-name {
        font-size: 13px;
        line-height: 1.3;
    }

    .product-price {
        font-size: 14px;
    }

    .product-seller {
        font-size: 11px;
    }

    .product-actions {
        padding: 0 10px 10px;
        gap: 8px;
    }

    .product-action-btn {
        width: 34px;
        height: 34px;
        font-size: 14px;
    }

    .product-btn {
        padding: 10px 8px;
        font-size: 11px;
        white-space: normal;
        line-height: 1.2;
    }
}

@media (min-width: 769px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
}

@media (min-width: 1025px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--spacing-lg);
    }
}

/* Enhanced product grid for fuller look */
@media (min-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: var(--spacing-md);
    }
}

/* ============================
   PRODUCT CARD
   ============================ */

.product-card {
    background-color: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-light);
    position: relative;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-8px) scale(1.02);
    border-color: var(--primary);
    z-index: 10;
}

.product-card.discount {
    position: relative;
}

.product-card.discount::before {
    content: attr(data-discount);
    position: absolute;
    top: 0;
    left: 0;
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    color: white;
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 12px;
    font-weight: 800;
    z-index: 5;
    border-radius: 0 0 var(--radius) 0;
    box-shadow: var(--shadow-md);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

.product-image {
    position: relative;
    width: 100%;
    padding-bottom: 100%;
    overflow: hidden;
    background-color: var(--bg-lighter);
}

.product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.favorite-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background-color: rgba(255, 255, 255, 0.95);
    border: 2px solid var(--border-light);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: var(--transition);
    z-index: 3;
    color: var(--text-light);
}

.favorite-btn:hover {
    background-color: var(--white);
    border-color: var(--secondary);
    color: var(--secondary);
    transform: scale(1.15);
}

.favorite-btn.active {
    color: var(--secondary);
    border-color: var(--secondary);
    background-color: rgba(249, 115, 22, 0.1);
}

.favorite-btn.active i {
    transform: scale(1.05);
}

.product-info {
    padding: var(--spacing-md);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.product-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-price {
    font-size: 16px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-seller {
    font-size: 12px;
    color: var(--text-lighter);
    margin-bottom: auto;
    overflow-wrap: anywhere;
}

.product-actions {
    padding: 0 var(--spacing-md) var(--spacing-md);
    display: flex;
    gap: var(--spacing-sm);
    align-items: stretch;
}

.product-actions-single {
    display: block;
}

.product-action-btn {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--border-light);
    background-color: var(--white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: var(--transition);
    color: var(--text-light);
}

.product-action-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background-color: rgba(251, 191, 36, 0.1);
    transform: scale(1.1);
}

.product-btn {
    flex: 1;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--text-dark);
    border: none;
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 12px;
    font-weight: 700;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    white-space: normal;
    line-height: 1.35;
    text-align: center;
    box-shadow: 0 2px 8px rgba(251, 191, 36, 0.2);
}

@media (min-width: 769px) {
    .product-btn {
        font-size: 13px;
        padding: var(--spacing-md);
    }
}

.product-btn:hover {
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.product-btn:active {
    transform: translateY(0);
}

#favorites-btn {
    color: #ffffff;
}

#favorites-btn:hover {
    background-color: rgba(251, 191, 36, 0.1);
    color: #ffffff;
}

#favorites-btn .badge {
    background-color: var(--accent);
}

.favorites-page {
    padding-bottom: 120px;
}

.favorites-shell {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 16px 0;
}

.favorites-hero {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.22), rgba(249, 115, 22, 0.12));
    border: 1px solid rgba(249, 115, 22, 0.14);
    border-radius: 24px;
    padding: 28px 24px;
    box-shadow: var(--shadow-lg);
    margin-bottom: 24px;
}

.favorites-kicker {
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #b45309;
    margin-bottom: 8px;
}

.favorites-title {
    font-size: clamp(2rem, 4vw, 2.8rem);
    line-height: 1.08;
    color: #111827;
    margin-bottom: 10px;
}

.favorites-copy {
    color: var(--text-light);
    max-width: 700px;
}

.favorites-empty {
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(229, 231, 235, 0.9);
    border-radius: 22px;
    padding: 28px 24px;
    text-align: center;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.favorites-empty h2 {
    color: #111827;
    margin-bottom: 8px;
}

.favorites-empty p {
    color: var(--text-light);
}

/* ============================
   FOOTER
   ============================ */

.footer {
    background-color: #111;
    color: white;
    padding: var(--spacing-xl) var(--spacing-lg);
    margin-top: var(--spacing-xl);
    margin-bottom: 100px; /* Extra margin for mobile bottom nav */
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

/* Footer Grid Layout */
.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
    margin-bottom: var(--spacing-xl);
}

/* Desktop: 4 columns */
@media (min-width: 1025px) {
    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Tablet: 2 columns */
@media (min-width: 769px) and (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile: 1 column (default) */

.footer-column {
    display: flex;
    flex-direction: column;
}

.footer-title {
    color: white;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: var(--spacing-lg);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: var(--spacing-sm);
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: var(--transition);
    display: inline-block;
}

.footer-link:hover {
    color: #f59e0b;
    text-decoration: none;
}

/* Newsletter Section */
.newsletter {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.newsletter-input {
    flex: 1;
    padding: var(--spacing-sm) var(--spacing-md);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 14px;
    outline: none;
}

.newsletter-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-input:focus {
    border-color: #f59e0b;
    background-color: rgba(255, 255, 255, 0.15);
}

.newsletter-btn {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    border: none;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
    white-space: nowrap;
}

.newsletter-btn:hover {
    background: linear-gradient(135deg, #f97316, #dc2626);
    transform: translateY(-2px);
}

/* Social Links */
.social-links {
    display: flex;
    gap: var(--spacing-md);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
}

.social-link:hover {
    background-color: #f59e0b;
    color: white;
    transform: translateY(-3px);
}

.social-link i {
    font-size: 18px;
}

/* Footer Bottom */
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-lg);
    text-align: center;
}

.footer-bottom-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    flex-wrap: wrap;
}

.footer-bottom-link {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 12px;
    font-weight: 400;
    transition: var(--transition);
}

.footer-bottom-link:hover {
    color: #f59e0b;
    text-decoration: underline;
}

.footer-separator {
    color: rgba(255, 255, 255, 0.4);
    font-size: 12px;
}

.footer-bottom p {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    margin: 0;
}

/* Mobile Responsive Footer */
@media (max-width: 768px) {
    .footer {
        display: none;
    }

    .newsletter {
        flex-direction: column;
        align-items: center;
    }

    .newsletter-input {
        width: 100%;
        max-width: 300px;
    }

    .social-links {
        justify-content: center;
    }

    .footer-bottom-links {
        flex-direction: column;
        gap: var(--spacing-xs);
    }

    .footer-separator {
        display: none;
    }
}

/* ============================
   MODAL
   ============================ */

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.profile-modal-content {
    max-width: 800px;
    max-height: 90vh;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--border-light);
    background-color: var(--bg-light);
}

.modal-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-light);
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.modal-close:hover {
    background-color: var(--border-light);
    color: var(--text-dark);
}

.modal-body {
    padding: var(--spacing-lg);
    max-height: 60vh;
    overflow-y: auto;
}

/* ============================
   PROFILE MODAL STYLES
   ============================ */

.profile-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-light);
    margin-bottom: var(--spacing-lg);
    overflow-x: auto;
}

.profile-tab {
    background: none;
    border: none;
    padding: var(--spacing-md) var(--spacing-lg);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-light);
    border-bottom: 2px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
}

.profile-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.profile-tab:hover {
    color: var(--primary-dark);
}

.profile-content {
    min-height: 300px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.tab-content h3 {
    color: var(--primary-dark);
    margin-bottom: var(--spacing-lg);
    font-size: 1.2rem;
}

.account-info p {
    margin-bottom: var(--spacing-sm);
    color: var(--text-dark);
}

.profile-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
    margin-top: var(--spacing-md);
}

.profile-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.profile-btn.danger {
    background: var(--accent);
}

.profile-btn.danger:hover {
    background: #dc2626;
}

/* Policies tabs within profile */
.policies-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-lg);
}

.policy-tab-btn {
    background: var(--bg-lighter);
    border: 1px solid var(--border-light);
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-dark);
    transition: var(--transition);
}

.policy-tab-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.policy-tab-btn:hover {
    background: var(--primary-dark);
    color: white;
}

.policy-content {
    background: var(--bg-light);
    padding: var(--spacing-md);
    border-radius: 8px;
    min-height: 150px;
}

.policy-content h4 {
    color: var(--primary-dark);
    margin-bottom: var(--spacing-sm);
}

.policy-content p {
    color: var(--text-dark);
    line-height: 1.6;
    margin-bottom: var(--spacing-md);
}

/* Settings */
.settings-options {
    margin-bottom: var(--spacing-lg);
}

.setting-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    cursor: pointer;
}

.setting-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.setting-item span {
    color: var(--text-dark);
}

/* ============================
   BOTTOM MOBILE NAVIGATION
   ============================ */

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--white);
    border-top: 2px solid var(--border-light);
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    z-index: 99;
    box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.1);
}

@media (min-width: 769px) {
    .bottom-nav {
        display: none;
    }
}

.nav-item {
    flex: 1 1 0;
    max-width: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    color: #555;
    font-size: 12px;
    font-weight: 600;
    min-height: 64px;
    min-width: 0;
    position: relative;
}

.nav-item:hover {
    background-color: rgba(251, 191, 36, 0.05);
}

.nav-item.active {
    color: #f59e0b;
}

.nav-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
    line-height: 1;
}

.nav-item span {
    font-size: 11px;
    line-height: 1.2;
    text-align: center;
    overflow-wrap: anywhere;
}

span {
    margin-top: 2px;
}

/* ============================
   ANIMATIONS
   ============================ */

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card {
    animation: slideInUp 0.4s ease forwards;
}

.product-card:nth-child(1) { animation-delay: 0.05s; }
.product-card:nth-child(2) { animation-delay: 0.1s; }
.product-card:nth-child(3) { animation-delay: 0.15s; }
.product-card:nth-child(4) { animation-delay: 0.2s; }
.product-card:nth-child(5) { animation-delay: 0.25s; }
.product-card:nth-child(6) { animation-delay: 0.3s; }
.product-card:nth-child(7) { animation-delay: 0.35s; }
.product-card:nth-child(8) { animation-delay: 0.4s; }

/* ============================
   SCROLLBAR
   ============================ */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

/* ============================
   ACCESSIBILITY
   ============================ */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================
   PROFESSIONAL MESSAGING ENHANCEMENTS
   ============================ */

/* Typing Indicator */
.typing-indicator {
    display: flex;
    align-items: center;
    padding: 8px 16px;
    color: var(--text-light);
    font-size: 14px;
    animation: fadeIn 0.3s ease;
}

.typing-dots {
    display: flex;
    gap: 4px;
    margin-right: 8px;
}

.typing-dots span {
    width: 6px;
    height: 6px;
    background-color: var(--text-light);
    border-radius: 50%;
    animation: typing 1.4s infinite;
}

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

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Message Status */
.message-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
}

.message-status {
    font-size: 12px;
    margin-left: 8px;
}

.status-sending {
    color: var(--text-lighter);
}

.status-sent {
    color: var(--text-lighter);
}

.status-delivered {
    color: var(--primary);
}

.status-read {
    color: var(--primary);
}

/* Message Context Menu */
.message-context-menu {
    background: var(--white);
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-light);
    overflow: hidden;
    min-width: 150px;
}

.context-menu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.2s;
    font-size: 14px;
    color: var(--text-dark);
}

.context-menu-item:hover {
    background-color: var(--bg-light);
}

.context-menu-item i {
    width: 16px;
    color: var(--text-light);
}

/* Error Toast */
.error-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #dc2626;
    color: white;
    padding: 12px 16px;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 1000;
    animation: slideInRight 0.3s ease;
}

.error-toast i {
    font-size: 16px;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Message Image */
.message-image {
    padding: 4px;
}

.message-image-content {
    max-width: 250px;
    max-height: 250px;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.2s;
}

.message-image-content:hover {
    transform: scale(1.05);
}

/* Online Status */
.online-indicator {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 14px;
    height: 14px;
    background-color: #10b981;
    border: 2px solid white;
    border-radius: 50%;
}

.user-status.online {
    color: #10b981;
}

.user-status.offline {
    color: var(--text-lighter);
}

/* Enhanced Message Bubbles */
.message-bubble {
    position: relative;
    max-width: 70%;
    background-color: var(--white);
    border-radius: 18px;
    padding: 12px 16px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    word-wrap: break-word;
    transition: all 0.2s ease;
}

.message-bubble:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.message-other .message-bubble {
    background-color: var(--white);
    border-bottom-left-radius: 4px;
}

.message-own .message-bubble {
    background-color: var(--primary);
    color: white;
    border-bottom-right-radius: 4px;
}

/* Quick Replies */
.quick-replies {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.quick-reply-btn {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-dark);
}

.quick-reply-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Voice Message */
.voice-message {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 200px;
}

.voice-play-btn {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.2s;
}

.voice-play-btn:hover {
    background: rgba(251, 191, 36, 0.1);
}

.voice-waveform {
    flex: 1;
    height: 30px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 15px;
    position: relative;
    overflow: hidden;
}

.voice-duration {
    font-size: 12px;
    color: var(--text-light);
    min-width: 35px;
    text-align: center;
}

/* Enhanced Loading States */
.message-loading {
    display: flex;
    justify-content: center;
    padding: 20px;
}

.message-loading i {
    animation: spin 1s linear infinite;
}

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

/* Professional animations and enhancements */
.conversation-item {
    transition: all 0.2s ease;
    cursor: pointer;
}

.conversation-item:hover {
    background-color: rgba(251, 191, 36, 0.05);
    transform: translateX(2px);
}

.conversation-item.unread {
    background-color: rgba(251, 191, 36, 0.08);
    border-left: 3px solid var(--primary);
}

.message-bubble {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.typing-indicator {
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.online-indicator {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 12px;
    height: 12px;
    background-color: var(--success);
    border: 2px solid white;
    border-radius: 50%;
    animation: onlinePulse 2s ease-in-out infinite;
}

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

.message-status {
    font-size: 11px;
    color: var(--text-lighter);
    margin-left: 4px;
    display: inline-flex;
    align-items: center;
}

.message-status.sent .fa-check {
    color: var(--primary);
}

.message-status.delivered .fa-check-double {
    color: var(--primary);
}

.message-status.read .fa-check-double {
    color: var(--success);
}

/* Context menu styles */
.context-menu {
    position: absolute;
    background: white;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    padding: 8px 0;
    z-index: 1000;
    min-width: 120px;
    border: 1px solid var(--border-light);
}

.context-menu-item {
    display: block;
    width: 100%;
    padding: 8px 16px;
    text-decoration: none;
    color: var(--text-dark);
    font-size: 14px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.context-menu-item:hover {
    background-color: var(--bg-light);
}

.context-menu-item.danger {
    color: var(--accent);
}

.context-menu-item.danger:hover {
    background-color: rgba(220, 38, 38, 0.1);
}

/* Error toast styles */
.error-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: var(--accent);
    color: white;
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    z-index: 10000;
    animation: slideInRight 0.3s ease-out;
    max-width: 300px;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.error-toast.fade-out {
    animation: slideOutRight 0.3s ease-in forwards;
}

@keyframes slideOutRight {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

/* Enhanced mobile responsiveness */
@media (max-width: 768px) {
    .messages-main {
        padding-bottom: 100px;
    }

    .chat-messages {
        min-height: calc(100vh - 200px);
    }

    .conversation-item {
        padding: 14px 16px;
        margin: 4px 8px;
        border-radius: var(--radius);
    }

    .conversation-avatar {
        width: 48px;
        height: 48px;
        flex-shrink: 0;
    }

    .conversation-seller {
        font-size: 16px;
        font-weight: 600;
    }

    .conversation-message {
        font-size: 14px;
        line-height: 1.4;
    }

    .unread-badge {
        min-width: 20px;
        height: 20px;
        font-size: 12px;
    }

    .chat-input-area {
        padding: 12px 16px;
        gap: 8px;
    }

    .message-input {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 10px 0;
    }

    .message-bubble {
        max-width: 85%;
        padding: 12px 16px;
        font-size: 15px;
    }

    .product-icon {
        font-size: 12px;
        margin-right: 4px;
    }
}

/* Touch-friendly interactions */
@media (hover: none) and (pointer: coarse) {
    .conversation-item {
        min-height: 60px;
    }

    .send-btn, .attach-btn, .voice-btn {
        min-width: 44px;
        min-height: 44px;
    }
}

/* Messenger button specific styles */
#messages-btn {
    color: var(--primary);
    position: relative;
}

#messages-btn:hover {
    background-color: rgba(251, 191, 36, 0.1);
    color: var(--primary-dark);
}

#messages-btn .badge {
    background-color: var(--accent);
    animation: pulse 2s infinite;
}

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

/* Mobile and tablet responsive adjustments */
@media (max-width: 768px) {
    .header-actions {
        gap: var(--spacing-sm);
    }

    .icon-btn {
        font-size: 18px;
        padding: 8px;
    }

    .bottom-nav {
        justify-content: space-evenly;
    }

    .nav-item {
        padding: 10px 4px;
    }

    #messages-btn {
        order: -1; /* Show messenger button first on mobile */
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    /* Tablet specific adjustments */
    .header-actions {
        gap: var(--spacing-sm);
    }
}

/* Quick replies styles */
.quick-replies {
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid var(--border-light);
    border-radius: var(--radius) var(--radius) 0 0;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.quick-replies-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-light);
    border-radius: var(--radius) var(--radius) 0 0;
}

.quick-replies-header span {
    font-weight: 600;
    color: var(--text-dark);
}

.quick-replies-toggle {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.quick-replies-toggle:hover {
    background-color: var(--border-light);
}

.quick-replies-list {
    display: none;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 16px;
    max-height: 120px;
    overflow-y: auto;
}

.quick-reply-btn {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    font-size: 13px;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
}

.quick-reply-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-1px);
}

@media (max-width: 768px) {
    .quick-replies-list {
        max-height: 100px;
        padding: 10px 12px;
    }

    .quick-reply-btn {
        font-size: 12px;
        padding: 6px 10px;
    }
}

/* ============================
   POLICIES PAGE
   ============================ */

.policies-page {
    padding: 24px 20px 120px;
    max-width: 1200px;
    margin: 0 auto;
}

.policies-hero {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.16), rgba(249, 115, 22, 0.18));
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: 24px;
    padding: 32px 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-md);
}

.policies-kicker {
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 12px;
    color: var(--secondary);
    font-weight: 700;
    margin-bottom: 10px;
}

.policies-hero h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 12px;
    color: var(--text-dark);
}

.policies-intro {
    max-width: 760px;
    color: var(--text-light);
    font-size: 16px;
}

.policies-anchor-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
    position: sticky;
    top: 84px;
    z-index: 20;
    background: rgba(249, 250, 251, 0.9);
    backdrop-filter: blur(10px);
    padding: 10px 0;
}

.policies-anchor-nav a {
    text-decoration: none;
    color: var(--text-dark);
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 999px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.policies-anchor-nav a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--text-dark);
}

.policies-grid {
    display: grid;
    gap: 18px;
}

.policy-anchor-offset {
    position: relative;
    top: -96px;
    height: 0;
    visibility: hidden;
}

.policy-detail-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(244, 162, 97, 0.22), transparent 30%),
        radial-gradient(circle at right, rgba(251, 191, 36, 0.18), transparent 24%),
        linear-gradient(180deg, #fffaf5 0%, #f8fafc 52%, #eef2f7 100%);
}

.policy-detail-page {
    max-width: 1040px;
    margin: 0 auto;
    padding: 28px 20px 120px;
}

.policy-detail-page > .back-button {
    margin-bottom: 18px;
}

.policy-detail-shell {
    display: grid;
    gap: 20px;
}

.policy-detail-banner,
.policy-detail-card {
    background: rgba(255, 255, 255, 0.94);
    border-radius: 26px;
    border: 1px solid rgba(244, 162, 97, 0.18);
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.08);
}

.policy-detail-banner {
    padding: 32px 26px;
    background: linear-gradient(135deg, rgba(244, 162, 97, 0.18), rgba(255, 255, 255, 0.95));
}

.policy-detail-banner h1 {
    font-size: clamp(2rem, 4vw, 3.1rem);
    line-height: 1.05;
    margin-bottom: 12px;
    color: #1f2937;
    overflow-wrap: anywhere;
}

.policy-detail-intro {
    max-width: 720px;
    color: var(--text-light);
    font-size: 16px;
    overflow-wrap: anywhere;
}

.policy-detail-card {
    padding: 28px 26px;
}

.policy-detail-status {
    border-radius: 18px;
    background: rgba(244, 162, 97, 0.12);
    color: #b45309;
    padding: 18px;
    font-weight: 700;
}

.policy-detail-content {
    display: grid;
    gap: 14px;
}

.policy-detail-content p {
    color: var(--text-light);
    font-size: 16px;
    line-height: 1.85;
}

.support-chat-section {
    margin-top: 12px;
    padding: 20px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(0, 123, 255, 0.08), rgba(255, 255, 255, 0.96));
    border: 1px solid rgba(0, 123, 255, 0.18);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.support-chat-copy {
    display: grid;
    gap: 6px;
}

.support-chat-copy h3 {
    font-size: 18px;
    color: #0f172a;
}

.support-chat-copy p {
    margin: 0;
}

.support-chat-button {
    background: #007BFF;
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    border: none;
    font-size: 15px;
    font-weight: 700;
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 10px 20px rgba(0, 123, 255, 0.18);
}

.support-chat-button:hover {
    background: #005ec7;
    transform: translateY(-1px);
}

.support-chat-button:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .support-chat-section {
        padding: 18px;
    }

    .support-chat-button {
        width: 100%;
        justify-content: center;
    }
}

/* ============================
   ACCOUNT DASHBOARD
   ============================ */

.account-page-body,
.seller-page-body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(244, 162, 97, 0.24), transparent 32%),
        radial-gradient(circle at top right, rgba(251, 191, 36, 0.22), transparent 28%),
        linear-gradient(180deg, #fffaf5 0%, #f8fafc 55%, #eef2f7 100%);
}

.account-page,
.seller-page {
    padding: 24px 16px 112px;
}

.account-shell {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    gap: 20px;
}

.account-sidebar,
.account-content {
    display: grid;
    gap: 20px;
}

.account-sidebar > .back-button,
.seller-card > .back-button {
    width: fit-content;
}

.account-sidebar-card,
.account-hero-card,
.account-panel,
.account-mobile-card,
.seller-card {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 24px;
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(18px);
}

.account-sidebar-card {
    padding: 28px 22px;
    text-align: center;
}

.account-avatar-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.account-avatar {
    width: 86px;
    height: 86px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f4a261 0%, #fbbf24 100%);
    color: #ffffff;
    font-size: 28px;
    font-weight: 800;
    letter-spacing: 1px;
    box-shadow: 0 16px 30px rgba(244, 162, 97, 0.28);
}

.account-avatar-large {
    width: 92px;
    height: 92px;
    border-radius: 28px;
}

.account-sidebar-card h1,
.account-hero-text h2,
.seller-card h1 {
    font-size: clamp(1.5rem, 2vw, 2.2rem);
    line-height: 1.1;
    margin-bottom: 8px;
}

.account-sidebar-card p,
.account-hero-text p,
.seller-copy {
    color: var(--text-light);
}

.account-edit-btn {
    margin-top: 18px;
    width: 100%;
    border: none;
    border-radius: 16px;
    background: #1f2937;
    color: #ffffff;
    padding: 14px 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.account-edit-btn:hover,
.merchant-cta-btn:hover,
.account-logout-btn:hover,
.account-menu-item:hover,
.account-action-row:hover,
.account-link-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 30px rgba(15, 23, 42, 0.12);
}

.account-sidebar-menu {
    display: grid;
    gap: 12px;
}

.account-menu-item {
    border: none;
    border-radius: 18px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.84);
    color: var(--text-dark);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.account-menu-item.active {
    background: linear-gradient(135deg, rgba(244, 162, 97, 0.18), rgba(251, 191, 36, 0.24));
    color: #b45309;
}

.account-menu-item-highlight {
    background: linear-gradient(135deg, #f4a261 0%, #fbbf24 100%);
    color: #fffdf8;
}

.account-menu-item-danger,
.account-logout-btn {
    background: rgba(220, 38, 38, 0.08);
    color: #b91c1c;
}

.account-hero-card {
    padding: 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.account-hero-main {
    display: flex;
    align-items: center;
    gap: 18px;
}

.account-kicker,
.seller-kicker,
.account-section-label {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 11px;
    font-weight: 800;
    color: #c2410c;
    margin-bottom: 8px;
}

.desktop-edit-btn {
    width: auto;
    min-width: 190px;
    margin-top: 0;
}

.account-panel,
.account-mobile-card {
    padding: 24px;
}

.account-panel-hidden {
    display: none;
}

.account-section-header,
.account-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.account-section-header h3,
.account-mobile-header h3 {
    font-size: 1.3rem;
    line-height: 1.2;
}

.account-section-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(251, 191, 36, 0.16);
    color: #b45309;
    font-size: 12px;
    font-weight: 800;
}

.account-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.account-info-card,
.account-action-row,
.account-link-card {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 20px;
}

.account-info-card {
    padding: 18px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.account-info-icon,
.merchant-cta-icon,
.seller-icon {
    width: 46px;
    height: 46px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(244, 162, 97, 0.12);
    color: #c2410c;
    flex-shrink: 0;
}

.account-info-label {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 4px;
}

.account-info-value {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-dark);
    word-break: break-word;
}

.account-stack {
    display: grid;
    gap: 14px;
}

.account-action-row,
.account-link-card,
.account-logout-btn {
    width: 100%;
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    text-align: left;
    color: var(--text-dark);
    cursor: pointer;
    transition: var(--transition);
}

.account-action-row {
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.account-action-row-static {
    cursor: default;
}

.account-action-copy {
    display: flex;
    align-items: center;
    gap: 14px;
}

.account-action-copy i:first-child {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(251, 191, 36, 0.14);
    color: #b45309;
}

.account-action-copy strong,
.merchant-cta-copy h4 {
    display: block;
    margin-bottom: 4px;
    font-size: 16px;
}

.account-action-copy p,
.merchant-cta-copy p,
.seller-point span {
    color: var(--text-light);
    font-size: 14px;
}

.account-link-card {
    text-decoration: none;
}

.account-switch {
    position: relative;
    width: 56px;
    height: 32px;
    flex-shrink: 0;
}

.account-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.account-switch-slider {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #d1d5db;
    transition: var(--transition);
}

.account-switch-slider::before {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    left: 4px;
    top: 4px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
    transition: var(--transition);
}

.account-switch input:checked + .account-switch-slider {
    background: linear-gradient(135deg, #f4a261 0%, #fbbf24 100%);
}

.account-switch input:checked + .account-switch-slider::before {
    transform: translateX(24px);
}

.merchant-cta-card {
    background: linear-gradient(135deg, rgba(244, 162, 97, 0.18), rgba(251, 191, 36, 0.16));
    border: 1px solid rgba(244, 162, 97, 0.22);
    border-radius: 24px;
    padding: 24px;
    display: grid;
    gap: 18px;
}

.merchant-cta-btn {
    border: none;
    border-radius: 18px;
    background: linear-gradient(135deg, #f4a261 0%, #f59e0b 100%);
    color: #fffdf9;
    padding: 16px 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 800;
    font-size: 15px;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    text-align: center;
    line-height: 1.35;
}

.merchant-cta-btn-full {
    width: 100%;
}

.account-mobile-sections {
    display: grid;
    gap: 18px;
}

.seller-card {
    max-width: 760px;
    margin: 0 auto;
    padding: 28px;
    display: grid;
    gap: 20px;
}

.seller-icon {
    width: 72px;
    height: 72px;
    font-size: 28px;
}

.seller-points {
    display: grid;
    gap: 12px;
}

.seller-point {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 18px;
}

.seller-point i {
    color: #c2410c;
}

.seller-actions {
    display: grid;
    gap: 12px;
}

.seller-secondary-link {
    text-align: center;
    color: var(--text-dark);
    font-weight: 700;
    text-decoration: none;
}

@media (min-width: 900px) {
    .account-shell {
        grid-template-columns: 320px minmax(0, 1fr);
        align-items: start;
    }

    .account-sidebar {
        position: sticky;
        top: 24px;
    }

    .account-mobile-sections {
        display: none;
    }
}

@media (max-width: 899px) {
    .account-page,
    .seller-page {
        padding: 18px 14px 110px;
    }

    .account-sidebar-menu,
    .account-panel,
    .desktop-edit-btn {
        display: none;
    }

    .account-sidebar-card {
        padding: 22px 18px;
    }

    .account-hero-card {
        padding: 22px 18px;
        flex-direction: column;
        align-items: flex-start;
    }

    .account-hero-main {
        width: 100%;
    }

    .account-info-grid {
        grid-template-columns: 1fr;
    }

    .mobile-info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .account-avatar,
    .account-avatar-large {
        width: 78px;
        height: 78px;
        border-radius: 22px;
        font-size: 24px;
    }

    .account-action-copy {
        align-items: flex-start;
    }

    .account-action-row,
    .account-link-card,
    .account-logout-btn,
    .merchant-cta-btn {
        padding: 16px;
    }

    .account-mobile-card,
    .seller-card {
        padding: 20px;
        border-radius: 22px;
    }

    .back-button {
        font-size: 14px;
    }
}

.policy-card {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    padding: 24px;
    box-shadow: var(--shadow);
    scroll-margin-top: 150px;
}

.policy-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

.policy-index {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--text-dark);
    font-weight: 800;
}

.policy-card h2 {
    font-size: 22px;
    color: var(--text-dark);
}

.policy-card-body p,
.policy-loading {
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.8;
}

.profile-menu-title {
    font-size: 20px;
    margin-bottom: 16px;
    color: var(--text-dark);
}

@media (max-width: 768px) {
    .policies-page {
        padding: 18px 14px 110px;
    }

    .policy-detail-page {
        padding: 18px 14px 110px;
    }

    .policies-hero {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .policy-detail-banner,
    .policy-detail-card {
        padding: 22px 18px;
        border-radius: 20px;
    }

    .policies-anchor-nav {
        top: 70px;
        gap: 8px;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 12px;
    }

    .policies-anchor-nav a {
        white-space: nowrap;
        font-size: 13px;
        padding: 9px 14px;
    }

    .policy-card {
        padding: 18px;
        border-radius: 16px;
    }

    .policy-card-header {
        align-items: flex-start;
    }

    .policy-card h2 {
        font-size: 18px;
    }

    .policy-detail-content p {
        font-size: 15px;
    }
}

/* ============================
   AUTHENTICATION PAGES
   ============================ */

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fef3c7 0%, #fed7aa 100%);
    padding: var(--spacing-lg);
}

.auth-card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.14);
    overflow: hidden;
    width: 100%;
    max-width: 900px;
    min-height: 520px;
    display: flex;
    position: relative;
}

/* Left side - Visual/Gradient */
.auth-visual {
    flex: 1;
    background: linear-gradient(135deg, #f59e0b 0%, #f59e0b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.auth-visual::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
    animation: float 6s ease-in-out infinite;
}

.auth-gradient {
    text-align: center;
    color: white;
    z-index: 2;
    position: relative;
    padding: var(--spacing-xl);
}

.auth-gradient h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: var(--spacing-md);
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.auth-gradient p {
    font-size: 1.1rem;
    opacity: 0.9;
    line-height: 1.6;
}

/* Right side - Form */
.auth-form-block {
    flex: 1;
    padding: var(--spacing-xl);
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 350px;
}

.auth-form-block h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: var(--spacing-sm);
}

.auth-form-block > p {
    color: var(--text-light);
    margin-bottom: var(--spacing-xl);
    font-size: 1rem;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.name-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
}

.name-field {
    display: flex;
    flex-direction: column;
}

.auth-form label {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: var(--spacing-xs);
    display: block;
}

.auth-form input {
    width: 100%;
    padding: 16px 14px;
    border: 1px solid #dfe4ea;
    border-radius: 12px;
    font-size: 1rem;
    transition: var(--transition);
    background-color: #fcfcfd;
    margin-bottom: 12px;
}

.auth-form input:focus {
    outline: none;
    border-color: #f59e0b;
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.auth-password-field {
    position: relative;
    margin-bottom: 12px;
}

.auth-password-field input {
    margin-bottom: 0;
    padding-right: 54px;
}

.auth-password-toggle {
    position: absolute;
    top: 50%;
    right: 10px;
    width: 38px;
    height: 38px;
    border: none;
    background: transparent;
    color: #94a3b8;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transform: translateY(-50%);
    transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.auth-password-toggle:hover {
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.1);
}

.auth-password-toggle:focus-visible {
    outline: none;
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.12);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.auth-password-toggle svg {
    width: 20px;
    height: 20px;
    display: block;
}

.auth-password-toggle.is-visible {
    color: #b45309;
}

.auth-field-help {
    display: flex;
    justify-content: flex-end;
    margin-top: -6px;
    margin-bottom: 6px;
}

.auth-link-inline {
    color: #b45309;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.auth-link-inline:hover {
    color: #92400e;
    text-decoration: underline;
}

.auth-btn {
    background: #f59e0b;
    color: white;
    border: none;
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.auth-btn-outline {
    background: transparent;
    color: #f59e0b;
    border: 2px solid #f59e0b;
    padding: calc(var(--spacing-md) - 2px) calc(var(--spacing-lg) - 2px);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.auth-btn-outline:hover {
    background: #f59e0b;
    color: white;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.auth-btn-outline:active {
    transform: translateY(0);
}

.auth-btn:hover {
    background: #f59e0b;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.auth-btn:active {
    transform: translateY(0);
}

.profile-info {
    text-align: center;
}

.profile-info h3 {
    margin: 0 0 var(--spacing-sm) 0;
    color: var(--text-dark);
    font-size: 1.5rem;
}

.profile-info p {
    margin: 0 0 var(--spacing-lg) 0;
    color: var(--text-light);
    font-size: 1rem;
}

.logout-btn {
    background: #dc2626;
    color: white;
}

.logout-btn:hover {
    background: #b91c1c;
}

.auth-divider {
    display: flex;
    align-items: center;
    margin: var(--spacing-lg) 0;
    text-align: center;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: var(--border-light);
}

.auth-divider span {
    padding: 0 var(--spacing-md);
    color: var(--text-lighter);
    font-size: 0.9rem;
    font-weight: 500;
}

.google-auth-btn {
    width: 100%;
    min-height: 56px;
    padding: 14px 18px;
    border-radius: 16px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    color: #1f2937;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.google-auth-btn:hover {
    background: #ffffff;
    border-color: rgba(245, 158, 11, 0.32);
    box-shadow: 0 16px 30px rgba(245, 158, 11, 0.16);
    transform: translateY(-1px);
}

.google-auth-btn:active {
    transform: translateY(0);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.1);
}

.google-auth-btn:focus-visible {
    outline: none;
    border-color: rgba(245, 158, 11, 0.5);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.google-auth-btn:disabled {
    cursor: wait;
    opacity: 0.78;
    transform: none;
}

.google-auth-btn-icon {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.google-auth-btn-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.google-auth-btn-text {
    line-height: 1.2;
}

.auth-loading-screen,
.oauth-callback-page {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(251, 191, 36, 0.26), transparent 28%),
        radial-gradient(circle at bottom right, rgba(249, 115, 22, 0.2), transparent 32%),
        linear-gradient(180deg, #fffaf0 0%, #fff7ed 48%, #fffbeb 100%);
}

.auth-loading-screen {
    position: fixed;
    inset: 0;
    z-index: 4000;
    display: grid;
    place-items: center;
    padding: 24px;
}

.auth-loading-card,
.oauth-callback-card {
    width: min(100%, 460px);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(245, 158, 11, 0.14);
    border-radius: 28px;
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.14);
    padding: 34px 28px;
    text-align: center;
    backdrop-filter: blur(16px);
}

.auth-loading-badge,
.oauth-callback-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 18px;
}

.auth-loading-spinner,
.oauth-callback-spinner {
    width: 66px;
    height: 66px;
    margin: 0 auto 20px;
    border-radius: 50%;
    border: 4px solid rgba(245, 158, 11, 0.18);
    border-top-color: #f59e0b;
    animation: authSpin 0.9s linear infinite;
}

.auth-loading-title,
.oauth-callback-title {
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    line-height: 1.1;
    color: #111827;
    margin-bottom: 10px;
}

.auth-loading-copy,
.oauth-callback-copy {
    color: #6b7280;
    font-size: 1rem;
    line-height: 1.7;
}

.oauth-callback-page {
    display: grid;
    place-items: center;
    padding: 28px;
}

.oauth-callback-logo {
    width: 84px;
    height: 84px;
    object-fit: contain;
    background: #ffffff;
    border-radius: 24px;
    padding: 14px;
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.08);
    margin: 0 auto 18px;
}

.oauth-callback-progress {
    width: 100%;
    height: 10px;
    background: rgba(245, 158, 11, 0.12);
    border-radius: 999px;
    overflow: hidden;
    margin-top: 22px;
}

.oauth-callback-progress-bar {
    width: 45%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #f59e0b 0%, #f97316 100%);
    animation: oauthProgress 1.4s ease-in-out infinite;
}

.oauth-callback-help {
    margin-top: 18px;
    color: #6b7280;
    font-size: 0.95rem;
}

.oauth-callback-help a {
    color: #b45309;
    font-weight: 600;
    text-decoration: none;
}

.oauth-callback-help a:hover {
    text-decoration: underline;
}

.auth-switch {
    text-align: center;
    margin-top: var(--spacing-lg);
    color: var(--text-light);
    font-size: 0.9rem;
}

.auth-switch a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-switch a:hover {
    text-decoration: underline;
}

.auth-feedback {
    margin-top: var(--spacing-md);
    padding: var(--spacing-md);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
}

.auth-feedback.error {
    background-color: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.auth-feedback.success {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

/* Responsive Design */

/* Tablet */
@media (max-width: 1024px) {
    .auth-card {
        max-width: 700px;
        min-height: 450px;
    }

    .auth-gradient h1 {
        font-size: 2rem;
    }

    .auth-form-block {
        padding: var(--spacing-lg);
    }
}

/* Mobile */
@media (max-width: 768px) {
    .auth-page {
        padding: var(--spacing-md);
    }

    .auth-card {
        flex-direction: column;
        max-width: 100%;
        min-height: auto;
        box-shadow: 0 8px 22px rgba(0, 0, 0, 0.13);
    }

    .auth-visual {
        min-height: 220px;
        flex: none;
        border-radius: 16px 16px 0 0;
    }

    .auth-gradient {
        padding: var(--spacing-lg) var(--spacing-md);
    }

    .auth-gradient h1 {
        font-size: 1.8rem;
    }

    .auth-gradient p {
        font-size: 1rem;
    }

    .auth-form-block {
        padding: var(--spacing-lg) var(--spacing-md);
        flex: 1;
    }

    .auth-form-block h2 {
        font-size: 1.5rem;
    }

    .name-fields {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .auth-form-block {
        padding: var(--spacing-md);
    }

    .auth-form {
        gap: var(--spacing-md);
    }

    .auth-password-field input {
        padding-right: 50px;
    }

    .auth-password-toggle {
        right: 8px;
        width: 36px;
        height: 36px;
    }

    .google-auth-btn {
        min-height: 52px;
        padding: 13px 16px;
        border-radius: 14px;
    }

    .auth-gradient h1 {
        font-size: 1.5rem;
    }
}

/* Floating animation for visual background */
@keyframes float {
    0%, 100% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    50% {
        transform: translate(-50%, -50%) rotate(180deg);
    }
}

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

@keyframes oauthProgress {
    0% {
        transform: translateX(-120%);
    }
    100% {
        transform: translateX(260%);
    }
}
/* ============================
   PROFILE PAGE STYLES
   ============================ */

.profile-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: var(--spacing-lg) var(--spacing-md);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 100;
}

.profile-header-content h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
}

.profile-main {
    padding: var(--spacing-lg) var(--spacing-md);
    max-width: 600px;
    margin: 0 auto;
}

/* Profile Card Section */
.profile-card-section {
    margin-bottom: var(--spacing-xl);
}

.profile-card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.profile-card-content {
    padding: var(--spacing-xl);
    text-align: center;
}

.profile-status {
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: var(--spacing-lg);
    font-weight: 500;
}

.profile-buttons {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
    flex-wrap: wrap;
}

.profile-btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.profile-btn-outline:hover {
    background: var(--primary);
    color: white;
}

.profile-btn-primary {
    background: var(--primary);
    border: 2px solid var(--primary);
    color: white;
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.profile-btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}

/* User Info Styles */
.user-info {
    text-align: center;
}

.user-info h2 {
    color: var(--primary);
    margin-bottom: var(--spacing-sm);
    font-size: 1.5rem;
}

.user-email {
    color: var(--text-light);
    margin-bottom: var(--spacing-lg);
    font-size: 1rem;
}

.profile-btn-logout {
    background: #dc2626;
    border: 2px solid #dc2626;
    color: white;
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.profile-btn-logout:hover {
    background: #b91c1c;
    border-color: #b91c1c;
}

/* Loading state */
.loading {
    text-align: center;
    color: var(--text-light);
    padding: var(--spacing-lg);
}

/* Profile Menu */
.profile-menu {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--border-light);
    cursor: pointer;
    transition: var(--transition);
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item:hover {
    background-color: var(--bg-light);
}

.menu-item-left {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.menu-item-left i {
    font-size: 1.2rem;
    color: var(--primary);
    width: 24px;
    text-align: center;
}

.menu-item-left span {
    font-size: 1rem;
    color: var(--text-dark);
    font-weight: 500;
}

.menu-arrow {
    color: var(--text-lighter);
    font-size: 0.9rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .profile-header {
        padding: var(--spacing-md);
    }
    
    .profile-main {
        padding: var(--spacing-md);
    }
    
    .profile-card-content {
        padding: var(--spacing-lg);
    }
    
    .profile-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .profile-btn-outline,
    .profile-btn-primary {
        width: 100%;
        max-width: 280px;
    }
    
    .menu-item {
        padding: var(--spacing-md);
    }
}

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

.empty-state i {
    font-size: 48px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 18px;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.empty-state p {
    font-size: 14px;
    color: var(--text-secondary);
    max-width: 280px;
    line-height: 1.5;
}

/* Chat Page */
.chat-header .header-container {
    justify-content: space-between;
}

.chat-seller-info {
    display: flex;
    align-items: center;
    flex: 1;
    margin: 0 15px;
}

.seller-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--gray-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    overflow: hidden;
}

.seller-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.seller-avatar i {
    color: var(--text-secondary);
    font-size: 18px;
}

.seller-details {
    flex: 1;
}

.seller-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 2px 0;
}

.seller-status {
    font-size: 12px;
    color: var(--success);
}

.view-shop-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.view-shop-btn:hover {
    background-color: var(--primary-dark);
}

.view-shop-btn i {
    font-size: 10px;
}

.chat-product-card {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-light);
    padding: 12px 15px;
}

.product-card-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.product-card-image {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
}

.product-card-info {
    flex: 1;
}

.product-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 4px 0;
}

.product-card-price {
    font-size: 13px;
    color: var(--primary);
    font-weight: 600;
    margin: 0;
}

.product-card-link {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.product-card-link:hover {
    background-color: var(--gray-light);
}

.chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background-color: #f8f9fa;
    min-height: calc(100vh - 200px);
}

.message {
    margin-bottom: 15px;
    display: flex;
}

.message-other {
    justify-content: flex-start;
}

.message-own {
    justify-content: flex-end;
}

.message-bubble {
    max-width: 70%;
    background-color: var(--white);
    border-radius: 18px;
    padding: 12px 16px;
    position: relative;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.message-other .message-bubble {
    background-color: var(--white);
    border-bottom-left-radius: 4px;
}

.message-own .message-bubble {
    background-color: var(--primary);
    color: white;
    border-bottom-right-radius: 4px;
}

.message-text {
    margin: 0 0 5px 0;
    font-size: 14px;
    line-height: 1.4;
}

.message-time {
    font-size: 11px;
    opacity: 0.7;
    display: block;
    text-align: right;
}

.message-own .message-time {
    color: rgba(255, 255, 255, 0.8);
}

.message-product {
    max-width: 70%;
    background-color: var(--white);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.message-product-image {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
}

.message-product-info {
    flex: 1;
}

.message-product-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 2px 0;
}

.message-product-price {
    font-size: 12px;
    color: var(--primary);
    font-weight: 600;
    margin: 0;
}

/* Chat Input Area */
.chat-input-area {
    background-color: var(--white);
    border-top: 1px solid var(--border-light);
    padding: 12px 15px;
    position: sticky;
    bottom: 0;
}

.input-container {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: var(--gray-light);
    border-radius: 25px;
    padding: 8px 12px;
}

.input-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
    flex-shrink: 0;
}

.input-btn:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.input-btn:active {
    background-color: rgba(0, 0, 0, 0.2);
}

.attach-btn {
    color: var(--text-secondary);
}

.voice-btn {
    color: var(--text-secondary);
}

.send-btn {
    background-color: var(--primary);
    color: white;
}

.send-btn:hover {
    background-color: var(--primary-dark);
}

.message-input {
    flex: 1;
    border: none;
    background: none;
    outline: none;
    font-size: 16px;
    padding: 8px 0;
    min-width: 0;
}

.message-input::placeholder {
    color: var(--text-secondary);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .messages-main {
        padding-bottom: 80px;
    }

    .chat-messages {
        min-height: calc(100vh - 180px);
    }

    .conversation-item {
        padding: 12px 15px;
    }

    .conversation-avatar {
        width: 45px;
        height: 45px;
    }

    .conversation-seller {
        font-size: 15px;
    }

    .conversation-message {
        font-size: 13px;
    }

    .view-shop-btn span {
        display: none;
    }

    .chat-seller-info {
        margin: 0 10px;
    }

    .seller-name {
        font-size: 15px;
    }

    .message-bubble {
        max-width: 80%;
        padding: 10px 14px;
    }

    .message-product {
        max-width: 80%;
    }
}

/* Loading states */
.message-loading {
    display: flex;
    justify-content: center;
    padding: 20px;
}

.message-loading i {
    animation: spin 1s linear infinite;
}

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


