/* ============================================
   RetroCore Pro - WooCommerce Cyberpunk Theme
   ============================================ */

:root {
    --woocommerce: #e63946;
    --rc-bg: #0a0a0a;
    --rc-surface: #111113;
    --rc-surface2: #1a1a1e;
    --rc-accent: #e63946;
    --rc-accent-glow: rgba(230, 57, 70, 0.3);
    --rc-text: #f1f1f1;
    --rc-dim: #999;
    --rc-border: #2a2a2e;
}

/* === Global WooCommerce Overrides === */
.woocommerce,
.woocommerce-page {
    color: var(--rc-text);
}

/* === Product Cards === */
.woocommerce ul.products li.product {
    background: var(--rc-surface);
    border: 1px solid rgba(230, 57, 70, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    overflow: hidden;
}

.woocommerce ul.products li.product:hover {
    border-color: rgba(230, 57, 70, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(230, 57, 70, 0.15);
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    color: #ffffff;
    font-size: 1.2rem;
}

.woocommerce ul.products li.product .price {
    color: var(--rc-accent) !important;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 700;
    font-size: 1.3rem;
}

.woocommerce ul.products li.product .price del {
    color: var(--rc-dim);
    opacity: 0.6;
}

.woocommerce ul.products li.product .price ins {
    color: var(--rc-accent);
    text-decoration: none;
}

.woocommerce ul.products li.product img {
    border-radius: 6px;
    margin-bottom: 1rem;
}

/* === Sale Badge === */
.woocommerce span.onsale {
    background: var(--rc-accent);
    color: #fff;
    font-family: 'Press Start 2P', monospace;
    font-size: 0.55rem;
    padding: 0.5rem 0.8rem;
    border-radius: 2px;
    letter-spacing: 1px;
    min-height: auto;
    line-height: 1.4;
    box-shadow: 0 0 15px var(--rc-accent-glow);
}

/* === Buttons === */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce .button,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.woocommerce #respond input#submit,
.woocommerce #respond input#submit.alt {
    background: var(--rc-accent) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 0.8rem 1.8rem;
    box-shadow: 0 4px 20px var(--rc-accent-glow);
    transition: all 0.3s ease;
    cursor: pointer;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce .button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover,
.woocommerce #respond input#submit:hover,
.woocommerce #respond input#submit.alt:hover {
    background: #c1303d !important;
    box-shadow: 0 8px 30px rgba(230, 57, 70, 0.5);
    transform: translateY(-2px);
}

.woocommerce a.button.alt.disabled,
.woocommerce button.button.alt.disabled,
.woocommerce a.button.alt:disabled,
.woocommerce button.button.alt:disabled {
    background: var(--rc-surface2) !important;
    color: var(--rc-dim) !important;
    box-shadow: none;
    cursor: not-allowed;
}

/* === Tables (Cart, Checkout, Orders) === */
.woocommerce table.shop_table {
    background: var(--rc-surface);
    border: 1px solid rgba(230, 57, 70, 0.15);
    border-radius: 8px;
    overflow: hidden;
    border-collapse: separate;
}

.woocommerce table.shop_table th {
    background: var(--rc-surface2);
    color: var(--rc-dim);
    font-family: 'Press Start 2P', monospace;
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 1rem;
    border-bottom: 1px solid var(--rc-border);
}

.woocommerce table.shop_table td {
    color: var(--rc-text);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem;
    background: transparent;
}

.woocommerce table.shop_table tbody tr:hover td {
    background: rgba(230, 57, 70, 0.03);
}

/* === Form Inputs === */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce-page form .form-row input.input-text,
.woocommerce-page form .form-row textarea,
.woocommerce-page form .form-row select,
.woocommerce .select2-container--default .select2-selection--single {
    background: var(--rc-surface2) !important;
    border: 1px solid rgba(230, 57, 70, 0.2) !important;
    color: var(--rc-text) !important;
    border-radius: 4px !important;
    padding: 0.8rem 1rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus {
    border-color: var(--rc-accent) !important;
    box-shadow: 0 0 10px rgba(230, 57, 70, 0.2);
    outline: none;
}

.woocommerce form .form-row label {
    color: var(--rc-dim);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* === Notices === */
.woocommerce-message,
.woocommerce-info {
    background: var(--rc-surface) !important;
    border-top-color: var(--rc-accent) !important;
    color: var(--rc-text);
    border-radius: 4px;
}

.woocommerce-message::before,
.woocommerce-info::before {
    color: var(--rc-accent) !important;
}

.woocommerce-error {
    background: var(--rc-surface) !important;
    border-top-color: #ff4444 !important;
    color: var(--rc-text);
}

.woocommerce-error li {
    color: var(--rc-text);
}

/* === Star Ratings === */
.woocommerce .star-rating span::before,
.woocommerce .star-rating::before {
    color: var(--rc-accent);
}

/* === Single Product === */
.woocommerce div.product .product_title {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 700;
    color: #ffffff;
    font-size: clamp(2rem, 4vw, 2.5rem);
}

.woocommerce div.product p.price,
.woocommerce div.product span.price {
    color: var(--rc-accent) !important;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 700;
    font-size: 1.8rem;
}

.woocommerce div.product .woocommerce-product-details__short-description {
    color: var(--rc-dim);
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
    background: transparent;
    border-bottom: 1px solid var(--rc-border);
    padding: 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li {
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    margin: 0;
    padding: 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    color: var(--rc-dim);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.85rem;
    padding: 0.8rem 1.5rem;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
    border-bottom-color: var(--rc-accent);
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
    color: #fff;
}

.woocommerce div.product .woocommerce-tabs .panel {
    background: var(--rc-surface);
    border: 1px solid var(--rc-border);
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding: 2rem;
    color: var(--rc-dim);
}

/* === Quantity Input === */
.woocommerce .quantity .qty {
    background: var(--rc-surface2);
    border: 1px solid rgba(230, 57, 70, 0.2);
    color: var(--rc-text);
    border-radius: 4px;
}

/* === My Account === */
.woocommerce-MyAccount-navigation {
    background: var(--rc-surface);
    border: 1px solid var(--rc-border);
    border-radius: 8px;
    overflow: hidden;
}

.woocommerce-MyAccount-navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.woocommerce-MyAccount-navigation ul li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.woocommerce-MyAccount-navigation ul li a {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--rc-dim);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.woocommerce-MyAccount-navigation ul li a:hover {
    color: #fff;
    background: rgba(230, 57, 70, 0.05);
}

.woocommerce-MyAccount-navigation ul li.is-active a {
    color: var(--rc-accent);
    border-left: 3px solid var(--rc-accent);
    background: rgba(230, 57, 70, 0.05);
}

.woocommerce-MyAccount-content {
    color: var(--rc-text);
}

/* === Cart page === */
.woocommerce-cart .cart-collaterals .cart_totals {
    background: var(--rc-surface);
    border: 1px solid var(--rc-border);
    border-radius: 8px;
    padding: 1.5rem;
}

/* === Checkout === */
.woocommerce-checkout #payment {
    background: var(--rc-surface) !important;
    border: 1px solid var(--rc-border);
    border-radius: 8px;
}

.woocommerce-checkout #payment div.payment_box {
    background: var(--rc-surface2) !important;
    color: var(--rc-dim);
}

.woocommerce-checkout #payment div.payment_box::before {
    border-bottom-color: var(--rc-surface2) !important;
}

.woocommerce-checkout #payment ul.payment_methods {
    border-bottom-color: var(--rc-border) !important;
}

.woocommerce-checkout #payment ul.payment_methods li label {
    color: var(--rc-text);
}

/* === Breadcrumbs === */
.woocommerce .woocommerce-breadcrumb {
    color: var(--rc-dim);
    font-size: 0.8rem;
    font-family: 'Inter', sans-serif;
}

.woocommerce .woocommerce-breadcrumb a {
    color: var(--rc-accent);
    text-decoration: none;
}

.woocommerce .woocommerce-breadcrumb a:hover {
    color: #ff6b6b;
}

/* === WooCommerce Block Styles (Cart/Checkout blocks) === */
.wc-block-cart,
.wc-block-checkout {
    color: var(--rc-text);
}

.wc-block-cart .wc-block-cart-items .wc-block-cart-items__row,
.wc-block-checkout .wc-block-checkout__sidebar .wc-block-components-order-summary .wc-block-components-order-summary-item {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

.wc-block-components-text-input input,
.wc-block-components-text-input textarea,
.wc-block-components-combobox .wc-block-components-combobox-control input {
    background: var(--rc-surface2) !important;
    border-color: rgba(230, 57, 70, 0.2) !important;
    color: var(--rc-text) !important;
}

.wc-block-components-text-input input:focus,
.wc-block-components-combobox .wc-block-components-combobox-control input:focus {
    border-color: var(--rc-accent) !important;
    box-shadow: 0 0 10px rgba(230, 57, 70, 0.2) !important;
}

.wc-block-components-button {
    background: var(--rc-accent) !important;
    color: #fff !important;
    border-radius: 4px;
    box-shadow: 0 4px 20px var(--rc-accent-glow);
    transition: all 0.3s ease;
}

.wc-block-components-button:hover {
    background: #c1303d !important;
    box-shadow: 0 8px 30px rgba(230, 57, 70, 0.5);
}

.wc-block-components-totals-wrapper {
    border-color: rgba(255, 255, 255, 0.05) !important;
}

.wc-block-components-order-summary .wc-block-components-order-summary__button {
    color: var(--rc-text);
    border-color: var(--rc-border);
}

/* === Pagination === */
.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
    background: var(--rc-surface);
    border-color: var(--rc-border);
    color: var(--rc-dim);
}

.woocommerce nav.woocommerce-pagination ul li a:hover {
    background: var(--rc-surface2);
    color: #fff;
    border-color: rgba(230, 57, 70, 0.3);
}

.woocommerce nav.woocommerce-pagination ul li span.current {
    background: var(--rc-accent);
    border-color: var(--rc-accent);
    color: #fff;
}

/* === Related Products / Upsells heading === */
.woocommerce .related > h2,
.woocommerce .upsells > h2,
.woocommerce .cross-sells > h2 {
    font-family: 'Rajdhani', sans-serif;
    color: #ffffff;
    font-weight: 600;
}

/* === Widget area === */
.woocommerce .widget_price_filter .ui-slider {
    background: var(--rc-surface2);
}

.woocommerce .widget_price_filter .ui-slider .ui-slider-range {
    background: var(--rc-accent);
}

.woocommerce .widget_price_filter .ui-slider .ui-slider-handle {
    background: var(--rc-accent);
    border-color: var(--rc-accent);
}

/* === Pixel line utility (for use in Gutenberg) === */
.pixel-line {
    height: 4px;
    background: repeating-linear-gradient(90deg,
        var(--rc-accent) 0px, var(--rc-accent) 4px,
        transparent 4px, transparent 8px,
        var(--rc-border) 8px, var(--rc-border) 12px,
        transparent 12px, transparent 16px
    );
    opacity: 0.4;
}

/* === Cyber label utility === */
.cyber-label {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--rc-accent);
}

/* === Scrollbar === */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--rc-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--rc-border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--rc-accent);
}
