.ccvt-form {
    margin: 1.5em 0 0;
    color: #111827;
}

.single-product .woocommerce div.product {
    align-items: flex-start;
}

.single-product .woocommerce div.product .woocommerce-product-gallery,
.single-product .woocommerce div.product .summary {
    align-self: flex-start;
}

.single-product .woocommerce div.product .woocommerce-product-gallery {
    margin-top: 0;
    padding-top: 0;
    display: block;
}

.single-product .woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__wrapper,
.single-product .woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__image,
.single-product .woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__image a {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    margin-top: 0;
    padding-top: 0;
}

.single-product .woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__image img {
    display: block;
    width: 100%;
    height: auto;
    margin-top: 0;
    align-self: flex-start;
}

.ccvt-hide-summary-title-price .single-product .product_title,
.ccvt-hide-summary-title-price .single-product .summary > .price,
.ccvt-hide-summary-title-price .single-product .summary .price {
    display: none !important;
}

.ccvt-notices {
    margin-bottom: 1rem;
}

.ccvt-notice {
    padding: 0.9rem 1rem;
    border-radius: 0.875rem;
    font-size: 0.95rem;
    line-height: 1.4;
}

.ccvt-notice-success {
    background: #ecfdf5;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.ccvt-notice-error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.ccvt-table-wrap {
    max-height: 72vh;
    overflow-x: auto;
    overflow-y: auto;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    scrollbar-gutter: stable;
    overscroll-behavior: contain;
}

.ccvt-variation-table,
.ccvt-grouped-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 4px;
    margin: 0;
}

.ccvt-variation-table thead th,
.ccvt-grouped-table thead th {
    background: #f9fafb;
    color: #374151;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: 0;
    border: 0;
    border-bottom: 1px solid #e5e7eb;
    padding: 12px 14px;
    position: sticky;
    top: 0;
    z-index: 2;
}

.ccvt-variation-table tbody td,
.ccvt-grouped-table tbody td {
    background: #ffffff;
    border-top: 1px solid #d7dde5;
    border-bottom: 1px solid #d7dde5;
    vertical-align: middle;
    padding: 12px 14px;
}

.ccvt-variation-row:hover td,
.ccvt-grouped-row:hover td {
    background: #fbfcfe;
}

.ccvt-variation-row.ccvt-out-of-stock,
.ccvt-grouped-row.ccvt-out-of-stock {
    opacity: 0.6;
}


.ccvt-variation-cell {
    color: #111827;
    background: none !important;
    padding-left: 12px !important;
    border: 0;
}

.ccvt-variation-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.ccvt-variation-image {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    min-width: 56px;
    height: 56px;
    padding: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    box-sizing: border-box;
}

.ccvt-variation-image img,
.ccvt-variation-image svg {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0 !important;
    border: 0;
    box-shadow: none;
}

.ccvt-variation-name {
    min-width: 0;
}

.ccvt-variation-copy {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.ccvt-variation-label {
    display: block;
    font-weight: 500;
    font-size: 1rem;
    line-height: 1.35;
    color: #374151;
}

.ccvt-stock-status {
    display: block;
    font-size: 0.8rem;
    color: #b45309;
}

.ccvt-variation-price,
.ccvt-grouped-price {
    text-align: center;
    white-space: nowrap;
    font-weight: 500;
    color: #111827;
    border-left: 0 !important;
    border-right: 0 !important;
    background: transparent;
    width: 18%;
}

.ccvt-variation-price-value,
.ccvt-grouped-price-value {
    display: inline-block;
}
.ccvt-variation-quantity, .quantity-th{
    border-right: 1px solid #d7dde5 !important;
}

.ccvt-variation-meta, .color-th{
    border-left: 1px solid #d7dde5 !important;
}
.ccvt-variation-quantity,
.ccvt-grouped-quantity {
    min-width: 150px;
    width: 22%;
}

.ccvt-qty-control {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 130px;
    max-width: 100%;
    height: 34px;
    border: 1.5px solid #8f5f4a;
    border-radius: 999px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: none;
}

.ccvt-qty-button {
    width: 50px;
    min-width: 40px;
    height: 34px;
    border: 0 !important;
    background: #ffffff;
    color: #000;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
}

.ccvt-qty-button:hover:not(:disabled) {
    background: #ffffff;
    color: #000;
}

.ccvt-qty-button:active:not(:disabled) {
    background: #ffffff;
    color: #000;
}

.ccvt-qty-button:focus-visible {
    outline: 2px solid rgba(182, 125, 104, 0.35);
    outline-offset: -1px;
    background: #ffffff;
    color: #000;
}

.ccvt-qty-button:disabled {
    cursor: not-allowed;
    opacity: 0.4;
}

.ccvt-qty-button.ccvt-qty-increment, .ccvt-qty-button.ccvt-qty-decrement{
    background: #ffffff !important;
    color: #000 !important;
    border-left: 0 !important;
}

.ccvt-variation-qty,
.ccvt-grouped-qty-input {
    width: 40px;
    min-width: 40px;
    height: 34px;
    border: 0 !important;
    padding: 0 !important;
    background: #ffffff;
    color: #111827;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    line-height: 34px;
    font-family: inherit;
    caret-color: #111827;
    appearance: textfield;
    -moz-appearance: textfield;
    -webkit-text-fill-color: #111827;
}

.ccvt-variation-qty:focus,
.ccvt-grouped-qty-input:focus {
    outline: none;
    box-shadow: none;
}

.ccvt-variation-qty::-webkit-outer-spin-button,
.ccvt-variation-qty::-webkit-inner-spin-button,
.ccvt-grouped-qty-input::-webkit-outer-spin-button,
.ccvt-grouped-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.ccvt-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-top: 1rem;
    padding-top: 0.25rem;
    flex-wrap: wrap;
}

.ccvt-summary {
    display: inline-flex;
    align-items: baseline;
    gap: 0.5rem;
    color: #334155;
}

.ccvt-summary-label {
    font-size: 0.95rem;
}

.ccvt-total-items {
    font-size: 1.05rem;
}

.ccvt-add-to-cart {
    min-width: 240px;
    padding: 0.95rem 1.25rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #cbb0df, #b79ad7);
    border: 0;
    box-shadow: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.ccvt-add-to-cart:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: none;
}

.ccvt-grouped-heading {
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 1rem;
}

.ccvt-grouped-range {
    font-size: 1.85rem;
    line-height: 1;
    font-weight: 700;
    color: #111827;
    letter-spacing: -0.03em;
}

.ccvt-grouped-product-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.ccvt-grouped-product-image {
    flex: 0 0 auto;
    display: inline-flex;
    width: 56px;
    min-width: 56px;
    height: 56px;
    padding: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    box-sizing: border-box;
}

.ccvt-grouped-product-image img,
.ccvt-grouped-product-image svg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    display: block;
    border: 0;
    box-shadow: none;
}

.ccvt-grouped-product-copy {
    min-width: 0;
}

.ccvt-grouped-product-label {
    display: block;
    font-weight: 500;
    color: #374151;
    line-height: 1.35;
}

.ccvt-grouped-qty-control {
    margin-left: auto;
}

.ccvt-grouped-unavailable {
    display: inline-block;
    color: #64748b;
    font-size: 0.92rem;
}

.ccvt-button-count {
    font-weight: 700;
}

.ccvt-loading {
    opacity: 0.65;
    cursor: wait;
}

.ccvt-empty-variations {
    display: inline-block;
    padding: 0.75rem 0;
    color: #64748b;
}

.woocommerce-cart-form table.shop_table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 4px;
    margin: 0;
}

.woocommerce-cart-form table.shop_table thead th {
    background: #f3f4f6;
    color: #374151;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: 0;
    border: 0;
    padding: 8px;
}

.woocommerce-cart-form table.shop_table tbody td {
    background: #ffffff;
    border-top: 1px solid #d7dde5;
    border-bottom: 1px solid #d7dde5;
    vertical-align: middle;
    padding: 8px;
}

.woocommerce-cart-form table.shop_table tbody tr:hover td {
    background: #fbfcfe;
}

.woocommerce-cart-form .product-remove {
    width: 42px;
    text-align: center;
}

.woocommerce-cart-form .product-remove a.remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    color: #111827 !important;
    text-decoration: none;
    font-size: 22px;
    line-height: 1;
}

.woocommerce-cart-form .product-thumbnail {
    width: 60px;
}

.woocommerce-cart-form .product-thumbnail img {
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #e5e7eb;
    box-shadow: none;
}

.woocommerce-cart-form .product-name a {
    color: #374151;
    font-weight: 500;
    text-decoration: none;
}

.woocommerce-cart-form .product-price,
.woocommerce-cart-form .product-subtotal {
    color: #111827;
    white-space: nowrap;
    font-weight: 500;
}

.woocommerce-cart-form .product-quantity {
    white-space: nowrap;
}

.woocommerce-cart-form .ccvt-variation-quantity {
    min-width: 150px;
}

.woocommerce-cart-form .ccvt-cart-qty-control {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 130px;
    max-width: 100%;
    height: 34px;
    border: 1.5px solid #8f5f4a;
    border-radius: 999px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: none;
    white-space: nowrap;
}

.woocommerce-cart-form .ccvt-cart-qty-control .ccvt-qty-button {
    flex: 0 0 50px;
    width: 50px;
    min-width: 50px;
    height: 34px;
    border: 0 !important;
    background: #ffffff;
    color: #000;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.woocommerce-cart-form .ccvt-cart-qty-control .ccvt-variation-qty {
    flex: 1 1 40px;
    width: 40px !important;
    min-width: 40px;
    height: 34px;
    border: 0 !important;
    padding: 0 !important;
    background: #ffffff;
    color: #111827;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    line-height: 34px;
    font-family: inherit;
    caret-color: #111827;
    appearance: textfield;
    -moz-appearance: textfield;
    -webkit-text-fill-color: #111827;
    box-shadow: none !important;
    margin: 0 !important;
}

.woocommerce-cart-form .ccvt-cart-qty-control .ccvt-variation-qty:focus {
    outline: none;
    box-shadow: none;
}

.woocommerce-cart-form .ccvt-cart-qty-control .ccvt-variation-qty::-webkit-outer-spin-button,
.woocommerce-cart-form .ccvt-cart-qty-control .ccvt-variation-qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.woocommerce-cart-form .button[name="update_cart"] {
    min-width: 240px;
    padding: 0.95rem 1.25rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #cbb0df, #b79ad7);
    border: 0;
    box-shadow: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.woocommerce-cart-form .button[name="update_cart"]:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: none;
}

.woocommerce-cart-form .actions {
    padding-top: 0.35rem;
}

@media screen and (max-width: 720px) {
    .ccvt-variation-table,
    .ccvt-grouped-table {
        border-spacing: 0 4px;
        min-width: 640px;
    }

    .ccvt-table-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        max-height: 58vh;
        border-radius: 12px;
    }

    .ccvt-variation-table thead th,
    .ccvt-grouped-table thead th {
        font-size: 0.82rem;
        padding: 0.65rem 0.75rem;
    }

    .ccvt-variation-table tbody td,
    .ccvt-grouped-table tbody td {
        padding: 0.75rem;
    }

    .ccvt-variation-meta,
    .ccvt-grouped-product-card {
        gap: 0.6rem;
    }

    .ccvt-variation-image img,
    .ccvt-variation-image svg,
    .ccvt-grouped-product-image img,
    .ccvt-grouped-product-image svg {
        width: 100%;
        height: 100%;
    }

    .ccvt-variation-label,
    .ccvt-grouped-product-label {
        font-size: 0.95rem;
    }

    .ccvt-qty-control {
        width: 92px;
    }

    .ccvt-grouped-range {
        font-size: 1.6rem;
    }

    .ccvt-footer {
        align-items: stretch;
    }

    .ccvt-summary,
    .ccvt-add-to-cart {
        width: 100%;
        justify-content: center;
    }

    .woocommerce-cart-form table.shop_table {
        border-spacing: 0 4px;
        min-width: 640px;
    }

    .woocommerce-cart-form table.shop_table thead th {
        font-size: 0.82rem;
        padding: 0.65rem 0.75rem;
    }

    .woocommerce-cart-form table.shop_table tbody td {
        padding: 0.75rem;
    }

    .woocommerce-cart-form .ccvt-cart-qty-control {
        width: 92px;
    }

    .woocommerce-cart-form .button[name="update_cart"] {
        width: 100%;
        justify-content: center;
    }
}
