/* ============================================================
   NAINS HERBALS — nains-product.css
   Single Product Page Styles
   ============================================================ */

/* ----- Variables ----- */
:root {
    --np-green:    #2C4A2E;
    --np-green-lt: #E8F5EE;
    --np-tan:      #F5F0E8;
    --np-border:   #E5D5C3;
    --np-muted:    #8B7D6B;
    --np-orange:   #C2714F;
    --np-mint:     #74C69D;
    --np-gold:     #F4A261;
}

/* ----- Layout ----- */
.np-page { background: var(--np-tan); min-height: 100vh; }

.np-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

@media (min-width: 768px)  { .np-container { padding: 0 48px; } }
@media (min-width: 1024px) { .np-container { padding: 0 64px; } }

/* ----- Breadcrumb ----- */
.np-breadcrumb-bar {
    background: #fff;
    border-bottom: 1px solid var(--np-border);
    padding: 14px 0;
}
.np-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    color: var(--np-muted);
}
.np-breadcrumb a { color: var(--np-muted); text-decoration: none; }
.np-breadcrumb a:hover { color: var(--np-green); }
.np-bc-sep { opacity: .5; }
.np-bc-current { color: var(--np-green); font-weight: 500; }

/* ----- Product grid ----- */
.np-product-wrap { padding-top: 48px; padding-bottom: 48px; }

.np-product-grid {
    display: grid;
    gap: 48px;
}
@media (min-width: 900px) {
    .np-product-grid { grid-template-columns: 1fr 1fr; align-items: start; }
}

/* ----- Image Gallery (scroll strip) ----- */
.np-gallery-wrap {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
    aspect-ratio: 1 / 1;
}

/* The horizontal scroll strip */
.np-gallery-strip {
    display: flex;
    overflow-x: scroll;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    height: 100%;
}
.np-gallery-strip::-webkit-scrollbar { display: none; }

.np-gallery-slide {
    flex: 0 0 100%;
    scroll-snap-align: start;
    height: 100%;
}
.np-gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Badges */
.np-badge {
    position: absolute;
    top: 16px;
    font-size: 12px;
    font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    padding: 4px 12px;
    border-radius: 20px;
    color: #fff;
    z-index: 2;
}
.np-badge-sale  { left: 16px;  background: var(--np-orange); }
.np-badge-onsale{ right: 16px; background: var(--np-mint); }

/* Dot indicators */
.np-dots {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 2;
}
.np-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,.5);
    border: none;
    cursor: pointer;
    padding: 0;
    transition: background .2s, transform .2s;
}
.np-dot.active {
    background: #fff;
    transform: scale(1.3);
}

/* Thumbnail row */
.np-thumbs {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 4px;
}
.np-thumbs::-webkit-scrollbar { display: none; }
.np-thumb {
    flex: 0 0 68px;
    height: 68px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    background: none;
    padding: 0;
    transition: border-color .2s;
}
.np-thumb.active,
.np-thumb:hover { border-color: var(--np-green); }
.np-thumb-img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ----- Info Column ----- */
.np-product-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 700;
    color: var(--np-green);
    line-height: 1.2;
    margin: 0 0 16px;
}

/* Rating */
.np-rating-row { margin-bottom: 16px; }
.np-stars { display: flex; align-items: center; gap: 4px; }
.np-star {
    width: 18px; height: 18px;
    fill: #ddd; color: #ddd;
    transition: fill .2s;
}
.np-star.filled { fill: var(--np-gold); color: var(--np-gold); }
.np-rating-text {
    margin-left: 8px;
    font-size: 13px;
    color: var(--np-muted);
    font-family: 'DM Sans', sans-serif;
}

/* Short desc */
.np-short-desc {
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    color: var(--np-muted);
    line-height: 1.7;
    margin-bottom: 24px;
}
.np-short-desc p { margin: 0; }

/* Price */
.np-price-block {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}
.np-price-current {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 36px;
    font-weight: 700;
    color: var(--np-green);
    line-height: 1;
}
.np-price-original {
    font-size: 22px;
    color: var(--np-muted);
    text-decoration: line-through;
    font-family: 'DM Sans', sans-serif;
}
.np-save-badge {
    background: var(--np-mint);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    padding: 4px 10px;
    border-radius: 20px;
}

.np-divider {
    border: none;
    border-top: 1px solid var(--np-border);
    margin: 0 0 24px;
}

/* ----- Variants ----- */
.np-variations-wrap { margin-bottom: 24px; }
.np-variant-group { margin-bottom: 20px; }
.np-variant-label {
    display: block;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: var(--np-green);
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 10px;
}
.np-variant-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.np-pill {
    padding: 8px 18px;
    border-radius: 50px;
    border: 2px solid var(--np-border);
    background: #fff;
    color: var(--np-green);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all .2s;
}
.np-pill:hover { border-color: var(--np-green); }
.np-pill.active {
    border-color: var(--np-green);
    background: var(--np-green);
    color: #fff;
}

/* ----- Qty + Cart ----- */
.np-qty-cart {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}
.np-qty-control {
    display: flex;
    align-items: center;
    border: 2px solid var(--np-border);
    border-radius: 50px;
    overflow: hidden;
    background: #fff;
}
.np-qty-btn {
    width: 40px;
    height: 48px;
    background: transparent;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--np-green);
    transition: background .2s;
    line-height: 1;
}
.np-qty-btn:hover { background: var(--np-tan); }
.np-qty-input {
    width: 48px;
    text-align: center;
    border: none;
    font-size: 16px;
    font-weight: 600;
    color: var(--np-green);
    font-family: 'DM Sans', sans-serif;
    -moz-appearance: textfield;
    appearance: textfield;
    background: transparent;
}
.np-qty-input::-webkit-inner-spin-button,
.np-qty-input::-webkit-outer-spin-button { -webkit-appearance: none; }

.np-atc-form { flex: 1; min-width: 180px; }
.np-atc-btn {
    width: 100%;
    height: 56px;
    background: var(--np-green);
    color: #fff;
    border: none;
    border-radius: 50px;
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background .2s, transform .15s;
}
.np-atc-btn:hover { background: #1a2e1b; transform: translateY(-1px); }
.np-atc-btn:active { transform: translateY(0); }
.np-atc-btn--oos { background: #ccc; cursor: not-allowed; }
.np-btn-icon {
    width: 20px; height: 20px;
    stroke: currentColor; fill: none;
    stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

.np-icon-btn {
    width: 56px;
    height: 56px;
    border: 2px solid var(--np-border);
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .2s;
    flex-shrink: 0;
}
.np-icon-btn svg {
    width: 20px; height: 20px;
    stroke: var(--np-green); fill: none;
    stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.np-icon-btn:hover { border-color: var(--np-green); }

/* Claims */
.np-claims {
    background: var(--np-green-lt);
    border-radius: 16px;
    padding: 16px 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.np-claim-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    color: var(--np-green);
}
.np-check {
    width: 18px; height: 18px;
    fill: var(--np-mint);
    flex-shrink: 0;
}

/* ----- Tabs ----- */
.np-tabs-section {
    margin-top: 64px;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
}
.np-tabs-nav {
    display: flex;
    border-bottom: 1px solid var(--np-border);
    overflow-x: auto;
    scrollbar-width: none;
}
.np-tabs-nav::-webkit-scrollbar { display: none; }
.np-tab-btn {
    padding: 18px 28px;
    border: none;
    border-bottom: 3px solid transparent;
    background: transparent;
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: var(--np-muted);
    cursor: pointer;
    white-space: nowrap;
    transition: color .2s, border-color .2s;
    margin-bottom: -1px;
}
.np-tab-btn:hover { color: var(--np-green); }
.np-tab-btn.active { color: var(--np-green); border-bottom-color: var(--np-green); font-weight: 700; }

.np-tab-content { display: none; padding: 40px; }
.np-tab-content.active { display: block; }

.np-desc-body {
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    color: var(--np-green);
    line-height: 1.8;
}
.np-desc-body ul { padding-left: 20px; }
.np-desc-body li { margin-bottom: 6px; }

.np-empty-tab {
    font-family: 'DM Sans', sans-serif;
    color: var(--np-muted);
    font-style: italic;
}

/* WooCommerce native review form inside tab */
#np-tab-reviews .woocommerce-Reviews { padding: 0; }
#np-tab-reviews #comments { background: transparent; }

/* ----- Related / Cross-sell ----- */
.np-related-section { margin-top: 64px; }
.np-section-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 700;
    color: var(--np-green);
    margin-bottom: 32px;
}
.np-product-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
@media (min-width: 640px)  { .np-product-row { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px)  { .np-product-row { grid-template-columns: repeat(4, 1fr); } }

/* ----- Responsive tweaks ----- */
@media (max-width: 600px) {
    .np-qty-cart { flex-direction: column; align-items: stretch; }
    .np-qty-control { justify-content: center; }
    .np-claims { grid-template-columns: 1fr; }
    .np-tab-btn { padding: 14px 18px; font-size: 13px; }
    .np-tab-content { padding: 24px 20px; }
}

/* ============================================================
   Related / Cross-sell product cards inside single product page
   Re-uses .nh-product-card from nains-homepage.css
   ============================================================ */

.np-product-row .nh-product-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow .25s, transform .25s;
    border: 1px solid var(--np-border);
}
.np-product-row .nh-product-card:hover {
    box-shadow: 0 8px 32px rgba(44,74,46,.12);
    transform: translateY(-3px);
}
.np-product-row .nh-product-img {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--np-tan);
}
.np-product-row .nh-product-img img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .4s ease;
}
.np-product-row .nh-product-card:hover .nh-product-img img {
    transform: scale(1.05);
}
.np-product-row .nh-product-badge {
    position: absolute;
    top: 10px; left: 10px;
    font-size: 11px; font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    color: #fff;
    font-family: 'DM Sans', sans-serif;
}
.np-product-row .nh-badge-orange { background: var(--np-orange); }

.np-product-row .nh-product-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 6px;
}
.np-product-row .nh-product-cat {
    font-family: 'DM Sans', sans-serif;
    font-size: 11px;
    font-weight: 600;
    color: var(--np-mint);
    text-transform: uppercase;
    letter-spacing: .06em;
    margin: 0;
}
.np-product-row .nh-product-name {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: var(--np-green);
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.np-product-row .nh-product-name a {
    color: var(--np-green);
    text-decoration: none;
}
.np-product-row .nh-product-name a:hover { color: var(--np-orange); }

/* Hide long description in related cards — too much text */
.np-product-row .nh-product-desc { display: none; }

.np-product-row .nh-product-rating {
    display: flex;
    align-items: center;
    gap: 2px;
    font-family: 'DM Sans', sans-serif;
    font-size: 12px;
    color: var(--np-muted);
}

.np-product-row .nh-product-price-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: auto;
    padding-top: 8px;
}
.np-product-row .nh-product-price {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: var(--np-green);
}
.np-product-row .nh-product-orig {
    font-size: 13px;
    color: var(--np-muted);
    text-decoration: line-through;
    font-family: 'DM Sans', sans-serif;
}
.np-product-row .nh-product-saving {
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    background: var(--np-mint);
    padding: 2px 8px;
    border-radius: 20px;
    font-family: 'DM Sans', sans-serif;
}

.np-product-row .nh-add-to-cart {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
    padding: 10px;
    background: var(--np-green);
    color: #fff;
    border-radius: 50px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s;
}
.np-product-row .nh-add-to-cart:hover { background: #1a2e1b; color: #fff; }

/* ============================================================
   Modern polish refresh (single product)
   ============================================================ */
.np-page {
    background: linear-gradient(180deg, #f8f3ea 0%, #f5f0e8 100%);
}
.np-product-grid {
    gap: 56px;
}
.np-gallery-wrap {
    border: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 14px 40px rgba(28,37,32,0.10);
    border-radius: 22px;
}
.np-gallery-img {
    object-fit: cover;
    object-position: center center;
}
.np-info-col {
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 20px;
    padding: 28px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.np-product-title {
    color: #1C2520;
    letter-spacing: -0.2px;
}
.np-short-desc {
    color: #6e6155;
}
.np-price-current {
    color: #1C2520;
}
.np-atc-btn {
    background: #1C2520;
    border-radius: 14px;
    height: 54px;
    box-shadow: 0 10px 24px rgba(28,37,32,0.18);
}
.np-atc-btn:hover {
    background: #E67E22;
}
.np-icon-btn {
    border-radius: 14px;
    width: 54px;
    height: 54px;
}
.np-tabs-section {
    border: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 10px 28px rgba(28,37,32,0.07);
}
.np-tab-btn.active {
    border-bottom-color: #E67E22;
    color: #E67E22;
}
.np-related-section {
    margin-top: 56px;
}
@media (max-width: 900px) {
    .np-info-col {
        padding: 20px;
    }
}
