/*
Theme Name: banyutheme
Theme URI: https://example.com/banyutheme
Author: Didik / Banyumedia
Author URI: https://banyumedia.id
Description: Tema WooCommerce ringan untuk toko jasa & material (banyutheme).
Version: 1.0.0
Text Domain: banyutheme
*/

/* ============================================================
   1. GLOBAL FIXES & HEADER
   ============================================================ */
/* Mencegah logo menjadi raksasa di halaman Single Product */
.header-logo img, 
.site-branding img,
.custom-logo-link img {
    max-width: 180px; 
    height: auto;
    display: block;
}

/* Padding Body dihapus agar tidak ada jarak putih di bawah footer */
body.single-product { padding-bottom: 0 !important; }

/* ============================================================
   1B. READABILITY SCALE
   ============================================================ */
html { font-size: 16px; }
body {
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

button,
input,
select,
textarea {
    font-size: 1rem;
}

.text-\[8px\],
.text-\[9px\] {
    font-size: 0.75rem !important;
    line-height: 1rem !important;
}

.text-\[10px\],
.text-\[11px\],
.text-\[12px\],
.text-xs {
    font-size: 0.8125rem !important;
    line-height: 1.25rem !important;
}

.text-sm {
    font-size: 0.9375rem !important;
    line-height: 1.5rem !important;
}

p,
li,
td,
th,
.banyu-custom-desc,
.prose,
.woocommerce-product-details__short-description {
    line-height: 1.65;
}

.line-clamp-2.h-10,
.line-clamp-2.min-h-\[32px\],
.line-clamp-2.min-h-\[40px\] {
    height: auto !important;
    min-height: 2.85rem !important;
}

.w-4.h-4.text-\[10px\] {
    width: 1.25rem !important;
    height: 1.25rem !important;
    min-width: 1.25rem !important;
}

.text-\[8px\].leading-none,
.text-\[9px\].leading-none,
.text-\[10px\].leading-none,
.text-xs.leading-none {
    line-height: 1.15rem !important;
}

table,
.pricing-table,
.woocommerce table {
    font-size: 0.9375rem;
}

table th,
table td,
.pricing-table th,
.pricing-table td {
    line-height: 1.55;
}

@media (max-width: 768px) {
    html { font-size: 16px; }

    .text-\[8px\],
    .text-\[9px\],
    .text-\[10px\],
    .text-\[11px\],
    .text-\[12px\],
    .text-xs {
        font-size: 0.875rem !important;
        line-height: 1.35rem !important;
    }

    .text-sm {
        font-size: 1rem !important;
        line-height: 1.6rem !important;
    }
}

@media (min-width: 640px) {
    .sm\:text-\[11px\],
    .sm\:text-xs {
        font-size: 0.8125rem !important;
        line-height: 1.25rem !important;
    }

    .sm\:text-sm {
        font-size: 0.9375rem !important;
        line-height: 1.5rem !important;
    }

    .sm\:text-xl {
        font-size: 1.25rem !important;
        line-height: 1.75rem !important;
    }
}

@media (min-width: 768px) {
    .md\:text-\[10px\],
    .md\:text-\[11px\],
    .md\:text-xs {
        font-size: 0.8125rem !important;
        line-height: 1.25rem !important;
    }

    .md\:text-\[14px\],
    .md\:text-sm {
        font-size: 0.9375rem !important;
        line-height: 1.5rem !important;
    }

    .md\:text-base {
        font-size: 1rem !important;
        line-height: 1.65rem !important;
    }

    .md\:text-lg {
        font-size: 1.125rem !important;
        line-height: 1.75rem !important;
    }

    .md\:text-xl {
        font-size: 1.25rem !important;
        line-height: 1.8rem !important;
    }
}

/* ============================================================
   2. BREADCRUMB
   ============================================================ */
.breadcrumb { margin: 16px 0 8px; font-size: 14px; color: #6b7280; }
.breadcrumb-list { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0; padding: 0; }
.breadcrumb-item a { color: #4b5563; text-decoration: none; }
.breadcrumb-item a:hover { color: #111827; }
.breadcrumb-separator { color: #9ca3af; }
.breadcrumb-current { color: #111827; font-weight: 500; }
@media (max-width: 768px) { .breadcrumb { font-size: 14px; margin-top: 12px; } }

/* ============================================================
   3. TESTIMONIAL & REVIEWS
   ============================================================ */
.product-all-reviews.is-hidden { display: none; }
.product-all-reviews { margin-top: 16px; }
.testimonial-more-wrap { margin-top: 16px; text-align: center; }
.testimonial-more-btn { padding: 8px 16px; border-radius: 999px; border: 1px solid #111827; background: #ffffff; font-size: 14px; cursor: pointer; transition: all 0.2s ease; }
.testimonial-more-btn:hover { background: #111827; color: #ffffff; }
.testimonial-card-full { margin-bottom: 8px; }

/* ============================================================
   4. TABLE OF CONTENTS (TOC)
   ============================================================ */
.banyu-toc-container { background: #f9fafb; border: 1px solid #e5e7eb; padding: 20px; margin: 20px 0; border-radius: 8px; display: inline-block; min-width: 250px; max-width: 100%; }
.banyu-toc-title { font-weight: 700; margin-top: 0; margin-bottom: 12px; font-size: 16px; color: #111827; border-bottom: 2px solid #e5e7eb; padding-bottom: 8px; display: inline-block; }
.banyu-toc-container ul { list-style: none; padding-left: 0; margin: 0; }
.banyu-toc-container li { margin-bottom: 6px; line-height: 1.5; }
.banyu-toc-container li a { text-decoration: none; color: #4b5563; font-size: 14px; transition: color 0.2s; }
.banyu-toc-container li a:hover { color: #2563eb; text-decoration: underline; }
.banyu-toc-container li.toc-sub-item { padding-left: 20px; margin-top: 2px; font-size: 0.95em; border-left: 2px solid #e5e7eb; }

/* ============================================================
   5. STICKY BANNER: FLOATING CARD (SPACIOUS)
   ============================================================ */
#banyu-promo-sticky {
    position: fixed;
    z-index: 99990;
    background: #111827; /* Hitam Solid */
    color: #ffffff;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3); /* Shadow lebih tebal agar terlihat melayang */
    font-family: inherit;
    transition: all 0.3s ease;
    border: 1px solid #374151;
}

.banyu-promo-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px; 
    gap: 20px;
    position: relative;
}

/* Badge Hijau */
.promo-badge {
    background: #22c55e;
    color: white;
    font-size: 12px;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: inline-block;
}

/* Typography */
.promo-text h3 { margin: 0; font-size: 16px; font-weight: 700; color: #ffffff; line-height: 1.4; }
.promo-text p { margin: 6px 0 0; font-size: 15px; color: #9ca3af; line-height: 1.6; }

/* Tombol Putih */
.promo-btn {
    background: #ffffff;
    color: #111827;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
    transition: background 0.2s;
    border: none;
}
.promo-btn:hover { background: #e5e7eb; color: #000; }

/* Tombol Close */
.promo-close {
    position: absolute;
    top: 8px;
    right: 8px;
    background: transparent;
    border: none;
    color: #6b7280;
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}
.promo-close:hover { color: #fff; }

/* --- RESPONSIVE: MOBILE (Floating Center Bottom) --- */
@media (max-width: 768px) {
    #banyu-promo-sticky {
        bottom: 24px;
        left: 50%;
        transform: translateX(-50%);
        width: 92%; 
        max-width: 420px;
        border-radius: 16px;
        animation: slideUp 0.5s ease-out;
    }
    
    .promo-text p { display: none; }
    .banyu-promo-content { padding: 16px 20px; gap: 15px; } 
    .promo-btn { padding: 10px 16px; font-size: 13px; }

    /* GESER TOMBOL WA DI HP */
    .whatsapp-btn, #wa-widget, .joinchat_button, .wa__btn_popup { 
        bottom: 110px !important; 
        right: 15px !important; 
        z-index: 99995 !important; 
    }
}

/* --- RESPONSIVE: DESKTOP (Floating Right with Gap) --- */
@media (min-width: 769px) {
    #banyu-promo-sticky {
        top: 50%;
        
        /* JARAK KANAN: Ini yang membuat banner bergeser ke kiri */
        right: 30px; 
        
        transform: translateY(-50%);
        width: 340px; 
        
        /* Karena melayang, semua sudut dibuat melengkung */
        border-radius: 16px; 
        
        animation: slideLeft 0.5s ease-out;
    }

    .banyu-promo-content {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        padding: 30px; 
    }
    
    .promo-action { width: 100%; margin-top: 20px; }
    .promo-btn { display: block; text-align: center; width: 100%; }

    /* GESER TOMBOL WA DI DESKTOP */
    .whatsapp-btn, #wa-widget, .joinchat_button, .wa__btn_popup { 
        left: 30px !important; 
        right: auto !important; 
        bottom: 30px !important; 
    }
}

/* Paksa logo header tidak membesar */
.site-logo{
  max-height: 40px;
  width: auto;
  height: auto;
  display: block;
}
@media (max-width: 768px){
  .site-logo{ max-height: 32px; }
}

/* Footer logo: lebih besar tapi tetap aman */
.footer-logo{
  height: 48px !important;   /* ubah 48/56/64 sesuai selera */
  width: auto !important;
  max-width: none !important;
  object-fit: contain !important;
  display: block !important;
}

@media (max-width: 768px){
  .footer-logo{
    height: 40px !important;
  }
}


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

/* ============================================================
   6. SINGLE PRODUCT POLISH + SERP TOC
   ============================================================ */
body.single-product {
    overflow-x: hidden;
    background: #f8fafc;
}

.banyu-product-page {
    background: #f8fafc !important;
    color: #0f172a;
}

.banyu-product-page > .mx-auto {
    padding-left: clamp(1rem, 3vw, 1.5rem) !important;
    padding-right: clamp(1rem, 3vw, 1.5rem) !important;
}

.banyu-product-page section,
.banyu-product-page [id^="product-"],
.banyu-product-page #lokasi-layanan,
.banyu-product-page #cta-section {
    scroll-margin-top: 96px;
}

.banyu-product-page h1,
.banyu-product-page h2,
.banyu-product-page h3 {
    letter-spacing: 0 !important;
}

.banyu-serp-toc {
    margin: 1rem 0 1.25rem;
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 14px 40px rgba(15, 23, 42, 0.04);
}

.banyu-serp-toc__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: .75rem;
}

.banyu-serp-toc__label {
    color: #0f172a;
    font-size: .95rem;
    font-weight: 800;
}

.banyu-serp-toc__hint {
    color: #64748b;
    font-size: .8125rem;
    font-weight: 600;
}

.banyu-serp-toc__list {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.banyu-serp-toc__list a {
    display: inline-flex;
    align-items: center;
    min-height: 2.25rem;
    padding: .45rem .75rem;
    border: 1px solid #dbe4ee;
    border-radius: 999px;
    background: #f8fafc;
    color: #334155;
    font-size: .875rem;
    font-weight: 700;
    text-decoration: none;
}

.banyu-serp-toc__list a:hover,
.banyu-serp-toc__list a:focus-visible {
    border-color: #10b981;
    color: #047857;
    background: #ecfdf5;
}

.banyu-hero-placeholder {
    min-height: 220px;
    color: #64748b;
    background:
        linear-gradient(135deg, rgba(15, 23, 42, .04), rgba(16, 185, 129, .08)),
        #f8fafc;
}

.banyu-hero-placeholder-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    margin-bottom: 1rem;
    border-radius: 999px;
    background: #0f172a;
    color: #ffffff;
    font-weight: 900;
    font-size: 1.4rem;
}

.banyu-hero-placeholder strong {
    color: #0f172a;
    font-size: 1rem;
    line-height: 1.4;
}

.banyu-hero-placeholder span:last-child {
    display: block;
    max-width: 18rem;
    margin-top: .45rem;
    font-size: .875rem;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .banyu-product-page > .mx-auto {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
        padding-bottom: 3.5rem !important;
    }

    .banyu-product-page section {
        margin-top: 1.25rem !important;
        margin-bottom: 1.5rem !important;
    }

    .banyu-product-page .banyu-product-hero {
        margin-top: .75rem !important;
        margin-bottom: 1.25rem !important;
        padding: 1rem !important;
        border-radius: 20px !important;
        box-shadow: 0 14px 34px rgba(15, 23, 42, .06) !important;
    }

    .banyu-product-page .banyu-product-hero > div {
        gap: 1.25rem !important;
    }

    .banyu-product-page .banyu-product-hero h1 {
        margin-bottom: .75rem !important;
        font-size: 1.45rem !important;
        line-height: 1.22 !important;
        text-transform: none !important;
    }

    .banyu-product-page .banyu-product-hero .grid.grid-cols-2 {
        grid-template-columns: 1fr !important;
        gap: .7rem !important;
        margin-bottom: 1rem !important;
    }

    .banyu-product-page .banyu-product-hero .text-3xl {
        font-size: 1.7rem !important;
        line-height: 2rem !important;
    }

    .banyu-product-page .banyu-product-hero a {
        min-height: 3rem;
        border-radius: .85rem !important;
        white-space: normal !important;
    }

    .banyu-product-page #hero-image-container {
        aspect-ratio: 16 / 10 !important;
        border-radius: 18px !important;
    }

    .banyu-product-page #hero-image-container.banyu-empty-visual {
        aspect-ratio: auto !important;
        min-height: 190px;
    }

    .banyu-product-page .thumb-item {
        width: 4.25rem !important;
        height: 4.25rem !important;
        border-radius: .85rem !important;
    }

    .banyu-serp-toc {
        margin-top: .75rem;
        padding: .9rem;
        border-radius: 16px;
    }

    .banyu-serp-toc__head {
        align-items: flex-start;
        flex-direction: column;
        gap: .15rem;
    }

    .banyu-serp-toc__hint {
        font-size: .8rem;
    }

    .banyu-serp-toc__list {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: .15rem;
        -webkit-overflow-scrolling: touch;
    }

    .banyu-serp-toc__list a {
        white-space: nowrap;
        font-size: .875rem;
    }

    .banyu-product-page #product-trust,
    .banyu-product-page #product-portfolio,
    .banyu-product-page #product-testimonials,
    .banyu-product-page #product-pricing > div,
    .banyu-product-page #product-description,
    .banyu-product-page #product-benefits,
    .banyu-product-page #product-process,
    .banyu-product-page #product-expert,
    .banyu-product-page #lokasi-layanan,
    .banyu-product-page #cta-section,
    .banyu-product-page #product-related {
        border-radius: 18px !important;
    }

    .banyu-product-page #product-services {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .banyu-product-page #product-services .mb-10,
    .banyu-product-page #product-portfolio .mb-12,
    .banyu-product-page #product-testimonials > .flex,
    .banyu-product-page #product-benefits > .mb-6,
    .banyu-product-page #product-process > .mb-8,
    .banyu-product-page #product-faq > .mb-6,
    .banyu-product-page #product-description > .mb-6 {
        margin-bottom: 1.25rem !important;
    }

    .banyu-product-page #product-services h2,
    .banyu-product-page #product-trust h2,
    .banyu-product-page #product-testimonials h2,
    .banyu-product-page #product-benefits h2,
    .banyu-product-page #product-process h2,
    .banyu-product-page #product-faq h2,
    .banyu-product-page #product-description h2,
    .banyu-product-page #product-expert h2,
    .banyu-product-page #product-related h2 {
        font-size: 1.35rem !important;
        line-height: 1.28 !important;
        text-transform: none !important;
        font-style: normal !important;
    }

    .banyu-product-page #product-portfolio h3 {
        font-size: 2rem !important;
        line-height: 1.05 !important;
        text-transform: none !important;
        font-style: normal !important;
    }

    .banyu-product-page #product-services .grid,
    .banyu-product-page #product-benefits .grid,
    .banyu-product-page #product-process .grid,
    .banyu-product-page #product-faq .grid,
    .banyu-product-page #product-testimonials #reviews-grid,
    .banyu-product-page #product-expert .grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }

    .banyu-product-page #product-services .group,
    .banyu-product-page #product-portfolio .group,
    .banyu-product-page #product-benefits .group,
    .banyu-product-page #product-process .group,
    .banyu-product-page #product-faq details,
    .banyu-product-page #product-testimonials article,
    .banyu-product-page #product-expert > div,
    .banyu-product-page #lokasi-layanan {
        padding: 1rem !important;
        border-radius: 16px !important;
        box-shadow: 0 10px 28px rgba(15, 23, 42, .04) !important;
    }

    .banyu-product-page #product-services .mb-8 {
        margin-bottom: 1rem !important;
    }

    .banyu-product-page #product-services .w-16.h-16 {
        width: 3rem !important;
        height: 3rem !important;
        border-radius: 14px !important;
    }

    .banyu-product-page #product-trust {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    .banyu-product-page #product-trust .grid {
        gap: .75rem !important;
    }

    .banyu-product-page #product-trust .rounded-\[2rem\] {
        padding: 1rem !important;
        border-radius: 16px !important;
    }

    .client-rolling-section {
        padding: 2rem 0 !important;
        border-radius: 0 !important;
    }

    .client-rolling-title {
        margin-bottom: 1.25rem !important;
    }

    .client-rolling-title h2 {
        font-size: .95rem !important;
        letter-spacing: .04em !important;
        text-transform: none !important;
    }

    .banyu-product-page #product-portfolio {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    .banyu-product-page #product-portfolio .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .banyu-product-page #product-pricing {
        margin-top: 1.5rem !important;
    }

    .banyu-product-page #product-pricing > div,
    .banyu-product-page #product-pricing > div > div {
        border-radius: 18px !important;
    }

    .banyu-product-page #product-pricing > div > div {
        padding: 1rem !important;
    }

    .banyu-product-page #product-pricing table {
        min-width: 620px;
        font-size: .9rem !important;
    }

    .banyu-product-page #product-pricing th,
    .banyu-product-page #product-pricing td {
        padding: .85rem .9rem !important;
    }

    .banyu-product-page #product-pricing .text-lg,
    .banyu-product-page #product-pricing .md\:text-xl {
        font-size: 1.1rem !important;
    }

    .banyu-product-page #product-faq summary {
        align-items: flex-start !important;
        gap: .75rem;
        padding: 1rem !important;
    }

    .banyu-product-page #product-faq summary span:first-child {
        font-size: 1rem !important;
        line-height: 1.45 !important;
    }

    .banyu-product-page #product-faq details > div {
        padding: 1rem !important;
        font-size: .95rem !important;
        line-height: 1.65 !important;
    }

    .banyu-product-page #desc-content {
        font-size: 1rem !important;
        line-height: 1.75 !important;
    }

    .banyu-product-page #lokasi-layanan iframe,
    .banyu-product-page #lokasi-layanan .aspect-video {
        min-height: 240px;
    }

    .banyu-product-page #cta-section > div {
        padding: 1.25rem !important;
        border-radius: 18px !important;
        box-shadow: 0 16px 32px rgba(4, 120, 87, .18) !important;
    }

    .banyu-product-page #cta-section .absolute {
        opacity: 0 !important;
    }

    .banyu-product-page #cta-section h2 {
        font-size: 1.55rem !important;
    }

    .banyu-product-page #cta-section .min-w-\[280px\] {
        min-width: 0 !important;
    }

    .banyu-product-page #cta-section a {
        width: 100%;
        min-height: 3.1rem;
    }

    .banyu-product-page #product-related {
        margin-top: 2rem !important;
        padding-top: 1.5rem !important;
    }

    .banyu-product-page #product-related .grid {
        grid-template-columns: 1fr !important;
        gap: .9rem !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .banyu-product-page #product-related a.group {
        padding: 1rem !important;
        border-radius: 16px !important;
    }

    .banyu-product-page #product-related h3 {
        height: auto !important;
        min-height: 0 !important;
        font-size: 1rem !important;
        line-height: 1.35 !important;
        text-transform: none !important;
        font-style: normal !important;
    }

    #toc-bubble {
        right: 1rem !important;
        bottom: 8.25rem !important;
        padding: .75rem .9rem !important;
    }

    #toc-panel {
        right: 1rem !important;
        bottom: 12.25rem !important;
        width: min(20rem, calc(100vw - 2rem)) !important;
    }

    body.single-product footer {
        margin-top: 2.5rem !important;
        padding-top: 2.5rem !important;
        padding-bottom: 1.5rem !important;
    }

    body.single-product footer .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    body.single-product footer .grid {
        gap: 2rem !important;
        margin-bottom: 2rem !important;
    }

    body.single-product footer h3,
    body.single-product footer .uppercase {
        letter-spacing: .08em !important;
    }

    body.single-product footer p,
    body.single-product footer a,
    body.single-product footer span {
        line-height: 1.6 !important;
    }

    body.single-product footer .rounded-3xl {
        padding: 1.25rem !important;
        border-radius: 18px !important;
    }
}

@media (min-width: 420px) and (max-width: 768px) {
    .banyu-product-page #product-related .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}
