.nav {
    position: sticky;
    top: 0;
    z-index: 30;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 10px 14px;
    background: linear-gradient(to right, #318835, #308735, #43ac48);
    box-shadow: 0 6px 18px rgba(0, 0, 0, .06);
    border-bottom: 1px solid #f2f2f2;
}

.hamburger {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    margin-inline: 6px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .10);
    align-items: center;
    justify-content: center;
    position: relative;
}

.hamburger span {
    display: none;
}

.hamburger::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 18px;
    height: 2px;
    background: #1f2937;
    border-radius: 1px;
    transform: translate(-50%, -50%);
    box-shadow: 0 6px 0 #1f2937, 0 -6px 0 #1f2937;
}

.icons {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.icon-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border: 1px solid #eee;
    border-radius: 10px;
    background: #fff;
    font-weight: 700;
}

.icon-badge .badge {
    position: absolute;
    top: -8px;
    left: -8px;
    background: #e11d48;
    color: #fff;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 999px;
    line-height: 1;
    min-width: 18px;
    text-align: center;
}

.backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .35);
    z-index: 40;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
}

body.menu-open .backdrop {
    opacity: 1;
    pointer-events: auto;
}

.side-menu {
    position: fixed;
    inset-block: 0;
    right: 0;
    width: min(86vw, 360px);
    background: #fff;
    z-index: 50;
    box-shadow: -10px 0 30px rgba(0, 0, 0, .12);
    transform: translateX(110%);
    transition: transform .25s ease;
    display: flex;
    flex-direction: column;
}

body.menu-open .side-menu {
    transform: translateX(0);
}

.side-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px;
    border-bottom: 1px solid #f2f2f2;
}

.side-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--brand, #2e7d32);
}

.close {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid #eee;
    background: #fff;
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
}

.side-body {
    padding: 14px;
    overflow: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sheet-search .search {
    width: 100%;
    display: flex;
}

.sheet-links {
    display: grid;
    gap: 8px;
}

.sheet-link {
    display: block;
    padding: 10px 12px;
    border: 1px solid #eee;
    border-radius: 12px;
    background: #fafafa;
    transition: background .15s ease, transform .15s ease;
    text-decoration: none;
    color: #111;
}

.sheet-link:active {
    transform: scale(.98);
    background: #f3f3f3;
}

.sheet-link--withicon {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sheet-link-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    color: #2b2b2b;
}

.menu-badge {
    margin-inline-start: auto;
    background: #2e7d32;
    color: #fff;
    font-size: 12px;
    line-height: 1;
    padding: 3px 8px;
    border-radius: 999px;
    min-width: 24px;
    text-align: center;
    font-weight: 700;
}

.sheet-icons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.sheet-icons .icon-badge {
    flex: 1 1 48%;
}

@media (max-width: 768px) {
    .nav {
        grid-template-columns: auto 1fr auto;
        gap: 10px;
    }

    .hamburger {
        display: inline-flex;
    }

    .icons {
        display: none;
    }

    .search {
        order: 3;
        width: 100%;
    }
}

.brand {
    font-weight: 800;
    font-size: clamp(18px, 2vw, 20px);
    color: var(--brand);
}

.search {
    flex: 1;
    display: flex;
    justify-content: center;
    min-width: 200px;
}

.search input {
    width: min(800px, 100%);
    padding: 10px 14px;
    border-radius: 999px;
    border: 1px solid var(--brand);
    outline: none;
    background: var(--bg);
    background-color: #fff;
}

.social-link {
    display: inline-block;
    margin: 0 4px;
}

.social-icon {
    width: 35px;
    height: 35px;
    object-fit: contain;
    vertical-align: middle;
}

@media (max-width:768px) {
    .nav {
        gap: 10px;
    }

    .brand {
        order: 1;
        font-size: medium;
    }

    .search {
        order: 3;
        width: 100%;
    }
}

body.menu-open {
    overflow: hidden;
}

.breadcrumb-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 12px 0 16px;
    flex-wrap: wrap;
    gap: 10px;
}

.breadcrumb {
    font-size: 14px;
    color: #555;
}

.breadcrumb a {
    color: var(--brand, #2e7d32);
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb .current {
    font-weight: 700;
    color: #111;
}

.crumb-btn {
    background: linear-gradient(135deg, var(--brand, #2e7d32), var(--brand-2, #E67000));
    color: #fff;
    padding: 8px 16px;
    border-radius: 999px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    transition: all .2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .12);
}

.crumb-btn:hover {
    filter: brightness(1.05);
    box-shadow: 0 6px 14px rgba(0, 0, 0, .18);
}

.crumb-btn:active {
    filter: brightness(.95);
}

.product-page {
    padding-top: 8px;
}

.product-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: 1.2fr 1fr;
}

@media (max-width: 992px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}

.gallery-main {
    position: relative;
    background: #fff;
    border-radius: 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: center;
    height: clamp(260px, 45vw, 520px);
    overflow: hidden;
}

.gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: opacity .3s ease;
}

.gallery .gallery-main video{
  width:100% !important;
  height:100% !important;
  object-fit: contain !important;  
  background:#000;                
}

.btn-fav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    color: #6b7280;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    transition: box-shadow .2s ease, filter .2s ease, transform .12s ease, color .2s ease, background .2s ease, border-color .2s ease;
}

.btn-fav:hover {
    filter: brightness(1.03);
    box-shadow: 0 6px 14px rgba(0, 0, 0, .06);
}

.btn-fav.active {
    background: #ffe4e6;
    color: #e11d48;
    border-color: #fecdd3;
    box-shadow: 0 0 0 3px rgba(225, 29, 72, .12);
}

.ribbon {
    position: absolute;
    left: 12px;
    top: 12px;
    background: var(--brand-2);
    color: #fff;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 12px;
}

.oos {
    position: absolute;
    left: 12px;
    bottom: 12px;
    background: #b91c1c;
    color: #fff;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 12px;
}

.thumbs-wrap {
    position: relative;
    margin-top: 12px;
}

.thumbs {
    display: flex;
    gap: 10px;
    overflow: auto;
    padding: 6px 4px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.thumbs::-webkit-scrollbar {
    height: 8px;
}

.thumbs::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 8px;
}

.thumb {
    width: 86px;
    height: 86px;
    object-fit: cover;
    border-radius: 10px;
    border: 2px solid transparent;
    cursor: pointer;
    background: #fff;
    box-shadow: var(--shadow);
}

.thumb.active {
    border-color: var(--brand);
}

.thumb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border-radius: 999px;
    border: 1px solid #2e7d32;
    background: #fff;
    box-shadow: 0 10px 15px rgba(0, 0, 0, .1);
    cursor: pointer;
}

.thumb-nav.left {
    right: -6px;
}

.thumb-nav.right {
    left: -6px;
}

@media (max-width:576px) {
    .thumb-nav {
        display: none;
    }
}

.gallery-main.loading::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 16px;
    z-index: 1;
    background: linear-gradient(90deg, #eee 25%, #f5f5f5 37%, #eee 63%);
    background-size: 400% 100%;
    animation: shimmer 1.2s linear infinite;
}

.gallery-main.loading img {
    opacity: 0;
}

.thumb.loading {
    background: linear-gradient(90deg, #eee 25%, #f5f5f5 37%, #eee 63%);
    background-size: 400% 100%;
    animation: shimmer 1.2s linear infinite;
}

.variants {
    margin-top: 12px;
}

.variants .title {
    font-weight: 600;
    margin-bottom: 8px;
}

.variant-strip {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 6px 0 8px;
    -webkit-overflow-scrolling: touch;
}

.variant-item {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 6px;
    min-width: 92px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    background: #fff;
    user-select: none;
}

.variant-item.active {
    border-color: #E67000;
    box-shadow: 0 0 0 3px rgba(230, 112, 0, .15);
}

.variant-img {
    width: 72px;
    height: 72px;
    border-radius: 8px;
    object-fit: cover;
    display: block;
}

.variant-label {
    font-size: 13px;
    color: #111827;
    text-align: center;
    max-width: 84px;
    word-break: break-word;
}

.selected-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #FDEAD7;
    color: #7C2D12;
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 12px;
    margin-top: 8px;
}

.product-title {
    margin: 0 0 8px;
    font-size: clamp(20px, 3.6vw, 28px);
    font-weight: 800;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 6px 0 16px;
}

.product-price .now {
    font-size: clamp(20px, 3.2vw, 24px);
    font-weight: 900;
    color: #1f2937;
}

.product-price .old {
    text-decoration: line-through;
    color: #9ca3af;
}

.product-desc {
    color: #4b5563;
    line-height: 1.9;
    white-space: pre-line;
}

.stock-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.stock-badge {
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 13px;
}

.in-badge {
    background: #e6f7e7;
    color: #106a17;
    border: 1px solid #bae7c1;
}

.oos-badge {
    background: #fee2e2;
    color: #7f1d1d;
    border: 1px solid #fecaca;
}

.stock-note {
    color: #6b7280;
}

.action-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.qty {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    box-shadow: var(--shadow);
    user-select: none;
}

.qty input {
    width: 64px;
    text-align: center;
    border: none;
    outline: none;
    background: transparent;
    font-weight: 700;
    font-size: 16px;
    color: #111;
}

.qty-btn {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    background: #f3f3f3;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:active {
    transform: translateY(1px);
}

.share-row {
    margin-top: 14px;
}

.btn-disabled {
    opacity: .6;
    pointer-events: none;
}

.btn.btn-disabled[disabled] {
    opacity: .55;
    cursor: not-allowed;
}

.rel-title {
    margin: 8px 6px 12px;
    font-size: 20px;
    font-weight: 800;
}

.grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fill, minmax(clamp(220px, 42vw, 280px), 1fr));
}

.card {
    background: #f1f1f1;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    opacity: 0;
    transform: translateY(14px);
    transition: transform .4s ease, opacity .5s ease;
}

.card.show {
    opacity: 1;
    transform: translateY(0);
}

.card:hover {
    transform: translateY(-6px);
}

.card.clickable {
    cursor: pointer;
}

.card-img {
    height: clamp(160px, 30vw, 260px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #fff;
    position: relative;
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.content {
    padding: 14px 12px 16px;
}

.title {
    font-weight: 800;
    margin: 0 0 6px;
    font-size: clamp(15px, 2.2vw, 18px);
}

.desc {
    color: var(--muted);
    font-size: clamp(13px, 2vw, 14px);
    line-height: 1.6;
    height: 44px;
    overflow: hidden;
}

.price {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0 12px;
}

.price .now {
    font-size: clamp(18px, 2.8vw, 20px);
    font-weight: 800;
    color: #1f2937;
}

.price .old {
    text-decoration: line-through;
    color: #9ca3af;
}

.actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
    margin-top: 8px;
    padding: 0 4px;
}

.actions .btn-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    padding: 0 12px;
    border-radius: 12px;
    font-weight: 800;
    border: 1px solid #e5e7eb;
    background: #fff;
    color: #111;
    box-shadow: 0 6px 14px rgba(0, 0, 0, .06);
    transition: transform .12s ease, box-shadow .2s ease, filter .2s ease;
    flex: 0 0 auto;
}

.actions .btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(0, 0, 0, .10);
    filter: brightness(1.02);
}

.actions .btn-sm:active {
    transform: translateY(0);
    filter: brightness(.98);
}

.actions .btn-fav {
    width: 40px;
    padding: 0;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    color: #6b7280;
}

.actions .btn-fav.active {
    background: #ffe4e6;
    color: #e11d48;
    border-color: #fecdd3;
    box-shadow: 0 0 0 3px rgba(225, 29, 72, .12);
}

.actions .btn-add {
    min-width: 128px;
    border: none;
    background: linear-gradient(135deg, var(--brand, #2e7d32), #43ac48);
    color: #fff;
    box-shadow: 0 10px 20px rgba(46, 125, 50, .20);
}

.actions .btn-details {
    min-width: 50px;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
}

.btn-disabled {
    opacity: .6;
    pointer-events: none;
}

@media (max-width:576px) {
    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .card-img {
        height: 170px;
    }

    .content {
        padding: 10px 8px;
    }

    .title {
        font-size: 14px;
    }

    .desc {
        font-size: 12px;
        height: 36px;
    }

    .price .now {
        font-size: 16px;
    }

    .actions {
        gap: 8px;
        margin: 6px 6px 0;
    }

    .actions .btn-add {
        min-width: 44px;
        width: 44px;
    }

    .btn-details {
        display: none;
    }

    .actions .btn-add {
        position: relative;
        color: transparent;
        text-indent: -9999px;
        overflow: hidden;
        height: 40px;
        padding: 0;
        border-radius: 12px;
    }

    .actions .btn-add::before {
        content: "";
        position: absolute;
        width: 22px;
        height: 22px;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg' stroke='%23ffffff' fill='none' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='20' r='1.5'/%3E%3Ccircle cx='18' cy='20' r='1.5'/%3E%3Cpath d='M2 3h2l2.4 10.4A2 2 0 0 0 8.35 15H17a2 2 0 0 0 2-1.6L21 7H6'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-size: contain;
        background-position: center;
    }
}

.only-mobile {
    margin-top: 5px;
    display: none;
}

@media (hover:none) and (pointer:coarse) {
    .only-mobile {
        display: inline-flex;
    }
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}