/* ── Right Dose Pharmacy - Shop Styles ── */
:root {
    --ocean-blue: #0077B6;
    --ocean-dark: #005F92;
    --ocean-light: #90E0EF;
    --soft-teal: #48CAE4;
    --calm-blue: #CAF0F8;
    --white: #FFFFFF;
    --light-grey: #F8FAFC;
    --text-dark: #1E3A5F;
    --text-medium: #4A6178;
}

* { scroll-behavior: smooth; box-sizing: border-box; }

body { font-family: 'Inter', sans-serif; color: var(--text-dark); margin: 0; overflow-x: hidden; }
.font-heading { font-family: 'Merriweather', serif; }
.bg-ocean { background-color: var(--ocean-blue); }
.bg-ocean-dark { background-color: var(--ocean-dark); }
.bg-calm-blue { background-color: var(--calm-blue); }
.bg-light-grey { background-color: var(--light-grey); }
.text-ocean { color: var(--ocean-blue); }
.text-ocean-dark { color: var(--ocean-dark); }
.text-soft-teal { color: var(--soft-teal); }
.border-ocean { border-color: var(--ocean-blue); }

.hero-gradient {
    background: linear-gradient(135deg, var(--ocean-blue) 0%, var(--ocean-dark) 50%, #003D5C 100%);
}

.nav-shadow { box-shadow: 0 2px 10px rgba(0,0,0,0.08); }
.card-shadow { box-shadow: 0 4px 20px rgba(0,119,182,0.1); }

.header-logo { height: 56px; width: auto; object-fit: contain; }
@media (min-width: 769px) { .header-logo { height: 64px; } }

/* ── Utility Classes ── */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }
.pb-safe { padding-bottom: env(safe-area-inset-bottom); }

/* ── Category Buttons ── */
.category-btn {
    white-space: nowrap;
    padding: 8px 20px;
    border-radius: 9999px;
    font-size: 0.95rem;
    font-weight: 600;
    border: 2px solid #e5e7eb;
    background: white;
    color: var(--text-medium);
    cursor: pointer;
    transition: all 0.2s ease;
}
.category-btn:hover { border-color: var(--ocean-blue); color: var(--ocean-blue); }
.category-btn.active {
    background: #22c55e;
    color: white;
    border-color: #22c55e;
}

/* ── Product Card ── */
.product-card {
    background: white;
    border-radius: 1.25rem;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,119,182,0.08);
    border: 1px solid #f0f4f8;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.product-card:hover {
    box-shadow: 0 12px 40px rgba(0,119,182,0.18);
    transform: translateY(-4px);
}
.product-card-image {
    width: 100%;
    height: 220px;
    min-height: 220px;
    max-height: 220px;
    object-fit: contain;
    padding: 1rem;
    background: var(--light-grey);
}
.product-card-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.product-card-category {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--ocean-blue);
    background: var(--calm-blue);
    padding: 4px 12px;
    border-radius: 9999px;
    display: inline-block;
    margin-bottom: 8px;
    width: fit-content;
}
.product-card-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 6px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}
.product-card-desc {
    font-size: 0.9rem;
    color: var(--text-medium);
    line-height: 1.5;
    margin-bottom: 12px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.product-card-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--ocean-blue);
}
.product-card-mrp {
    font-size: 0.95rem;
    color: #9ca3af;
    text-decoration: line-through;
    margin-left: 8px;
}
.product-card-stock {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 4px 0;
}
.stock-in { color: #16a34a; }
.stock-out { color: #dc2626; }
.stock-low { color: #ea580c; }

.product-card-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}
.btn-add-cart {
    flex: 1;
    padding: 10px 16px;
    background: var(--ocean-blue);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
}
.btn-add-cart:hover { background: var(--ocean-dark); }
.btn-add-cart:disabled { background: #cbd5e1; cursor: not-allowed; }

@media (max-width: 768px) {
    .product-card-image {
        height: 140px;
        min-height: 140px;
        max-height: 140px;
        padding: 0.75rem;
    }
    .product-card-body {
        padding: 0.75rem;
    }
    .product-card-name {
        font-size: 0.95rem;
        margin-bottom: 4px;
    }
    .product-card-price {
        font-size: 1.1rem;
    }
    .product-card-mrp {
        font-size: 0.8rem;
    }
    .btn-add-cart {
        padding: 8px 12px;
        font-size: 0.85rem;
    }
}
.btn-view-detail {
    padding: 10px 16px;
    background: var(--calm-blue);
    color: var(--ocean-blue);
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
}
.btn-view-detail:hover { background: #b8e6f8; }

/* ── Quantity selector in card ── */
.qty-selector {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    border-radius: 10px;
    overflow: hidden;
}
.qty-selector button {
    width: 34px;
    height: 34px;
    border: none;
    background: transparent;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    color: var(--text-dark);
    transition: background 0.15s;
}
.qty-selector button:hover { background: #e2e8f0; }
.qty-selector input {
    width: 36px;
    text-align: center;
    border: none;
    background: transparent;
    font-size: 0.95rem;
    font-weight: 600;
    outline: none;
}

/* ── Cart Item ── */
.cart-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--light-grey);
    border-radius: 12px;
    align-items: center;
}
.cart-item-image {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 8px;
    background: white;
    padding: 4px;
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cart-item-price { font-size: 0.9rem; color: var(--ocean-blue); font-weight: 600; }
.cart-item-remove {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: background 0.15s;
}
.cart-item-remove:hover { background: #fee2e2; }

/* ── Detail Page Tabs ── */
.detail-tab {
    padding: 10px 20px;
    font-weight: 600;
    color: var(--text-medium);
    border: none;
    background: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
}
.detail-tab:hover { color: var(--ocean-blue); }
.detail-tab.active {
    color: var(--ocean-blue);
    border-bottom-color: var(--ocean-blue);
}
.tab-content {
    word-break: break-word;
    overflow-wrap: break-word;
}

/* ── Thumbnail Gallery ── */
.thumb-img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 12px;
    border: 3px solid transparent;
    cursor: pointer;
    padding: 4px;
    background: white;
    transition: all 0.2s;
}
.thumb-img:hover, .thumb-img.active {
    border-color: var(--ocean-blue);
    box-shadow: 0 2px 10px rgba(0,119,182,0.2);
}

/* ── Animation ── */
@keyframes modalIn {
    from { opacity: 0; transform: scale(0.9) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.animate-modal { animation: modalIn 0.3s ease; }

/* Added to cart toast */
.toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgb(34, 197, 94);
    color: white;
    padding: 14px 28px;
    border-radius: 14px;
    font-weight: 600;
    font-size: 1rem;
    z-index: 9998;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
    white-space: nowrap;
    max-width: calc(100vw - 32px);
    text-align: center;
    opacity: 0;
    visibility: hidden;
}
.toast.show { 
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    visibility: visible;
}

/* On mobile, toast must sit above the bottom nav (64px) */
@media (max-width: 767px) {
    .toast { bottom: 80px; }
}

/* Product title clamp utility */
.product-title-clamp {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--light-grey); }
::-webkit-scrollbar-thumb { background: var(--ocean-blue); border-radius: 4px; }

/* ── Accessibility ── */
a:focus, button:focus { outline: 3px solid var(--soft-teal); outline-offset: 2px; }

/* ── Responsive adjustments ── */
@media (max-width: 640px) {
    .product-card-actions { flex-direction: column; }
}

/* ── Placeholder image ── */
.placeholder-img {
    width: 100%;
    height: 220px;
    min-height: 220px;
    max-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--calm-blue), #e0f2fe);
    color: var(--ocean-blue);
}

/* ── Footer & Floating WhatsApp ── */
.footer-logo {
    height: 80px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    animation: float-bounce 3s infinite ease-in-out;
}
@keyframes float-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

/* ── Mobile Menu (Full-screen) ── */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background: rgba(0, 77, 120, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 24px;
    position: relative;
}

.mobile-menu-close {
    position: absolute;
    top: 24px;
    right: 24px;
    color: #fff;
    padding: 8px;
    border-radius: 12px;
    transition: background 0.2s ease;
}

.mobile-menu-close:hover {
    background: rgba(255, 255, 255, 0.15);
}

.mobile-menu-logo-wrap {
    margin-bottom: 40px;
}

.mobile-menu-logo {
    height: 80px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: 300px;
}

.mobile-nav-link {
    display: block;
    width: 100%;
    text-align: center;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 700;
    padding: 14px 24px;
    border-radius: 14px;
    transition: background 0.2s ease;
    text-decoration: none;
    letter-spacing: 0.3px;
}

.mobile-nav-link:hover,
.mobile-nav-link:active {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.mobile-nav-cta {
    display: block;
    width: 100%;
    text-align: center;
    background: #fff;
    color: var(--ocean-dark);
    font-size: 1.15rem;
    font-weight: 700;
    padding: 16px 24px;
    border-radius: 14px;
    margin-top: 16px;
    transition: background 0.2s ease, transform 0.15s ease;
    text-decoration: none;
}

.mobile-nav-cta:hover {
    background: #e6f7ff;
    transform: scale(1.02);
}

body.menu-open {
    overflow: hidden;
}

@media (max-width: 767px) {
    .mobile-logo-center {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
}

/* (End of file — duplicate rules removed) */

/* ── Mobile Menu (Full-screen) ── */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background: rgba(0, 77, 120, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 24px;
    position: relative;
}

.mobile-menu-close {
    position: absolute;
    top: 24px;
    right: 24px;
    color: #fff;
    padding: 8px;
    border-radius: 12px;
    transition: background 0.2s ease;
}

.mobile-menu-close:hover {
    background: rgba(255, 255, 255, 0.15);
}

.mobile-menu-logo-wrap {
    margin-bottom: 40px;
}

.mobile-menu-logo {
    height: 80px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: 300px;
}

.mobile-nav-link {
    display: block;
    width: 100%;
    text-align: center;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 700;
    padding: 14px 24px;
    border-radius: 14px;
    transition: background 0.2s ease;
    text-decoration: none;
    letter-spacing: 0.3px;
}

.mobile-nav-link:hover,
.mobile-nav-link:active {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.mobile-nav-cta {
    display: block;
    width: 100%;
    text-align: center;
    background: #fff;
    color: var(--ocean-dark);
    font-size: 1.15rem;
    font-weight: 700;
    padding: 16px 24px;
    border-radius: 14px;
    margin-top: 16px;
    transition: background 0.2s ease, transform 0.15s ease;
    text-decoration: none;
}

.mobile-nav-cta:hover {
    background: #e6f7ff;
    transform: scale(1.02);
}

body.menu-open {
    overflow: hidden;
}

@media (max-width: 767px) {
    .mobile-logo-center {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
}
.footer-logo {
    height: 80px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    animation: float-bounce 3s infinite ease-in-out;
}
@keyframes float-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}
