/* =============================================
   PRODUCT CARD COMMON STYLES
   Her iki modül (customer_product & category_products) tarafından kullanılır.
   Dosya yolu: catalog/view/css/product_card_common.css
   ============================================= */

/* =========================
   PRODUCT CARD
========================= */
.pc-catCart {
    height: 100%;
    border: 1px solid #f0f0f0;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
    transition: box-shadow 0.15s ease;
}
.pc-catCart:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}
.pc-cart-width {
    display: grid;
    min-height: 130px;
    align-content: center;
    margin-bottom: -3px !important;
}

/* =========================
   IMAGE
========================= */
.pc-pimg-container {
    position: relative;
    overflow: hidden;
    border-radius: 8px 8px 0 0;
}
.pc-pimg {
    width: 100%;
    display: block;
    height: auto;
}

/* =========================
   PRODUCT NAME
========================= */
.pc-product-name {
    margin: 5px 0;
    height: 15px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* =========================
   RATING
========================= */
.pc-rating-container {
    display: flex;
    align-items: center;
    font-size: 10px;
    color: #777;
}
.pc-stars {
    margin-right: 5px;
    font-size: 12px;
    color: #ffc107;
}

/* =========================
   COLOR PALETTE
========================= */
.pc-color-palette {
    display: flex;
    gap: 2px;
    align-items: center;
}
.pc-color-circle {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.15);
    cursor: pointer;
    transition: transform 0.2s ease;
    filter: saturate(0.5) brightness(1);
    text-decoration: none;
}
.pc-color-circle:hover {
    transform: scale(1.2);
}
.pc-color-circle--more {
    background-color: #e0e0e0;
    color: #555;
    font-size: 9px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: default;
    text-decoration: none;
}

/* =========================
   VIEW BADGE (satıldı / adet / sectionlar)
========================= */
.pc-view-badge {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0px 2px;
}

.pc-badge { font-size: 9px; font-weight: 600; white-space: nowrap; }
.pc-badge--sold { color: #ff4500; }
.pc-badge--stock { color: #e00; border-bottom: 2px solid #e00; padding-bottom: 1px; }
.pc-badge--cart { color: #2d7d46; }
.pc-badge--wishlist { color: #e91e63; }
.pc-badge--viewed { color: #666; }

.pc-view-badge i {
    font-size: 10px;
    color: #333;
}
.pc-view-badge b {
    color: #4b4b4b;
}

@media (min-width: 990px) {
    .pc-badge { font-size: 12px; }
    .pc-view-badge {
        padding: 0px 3px;
    }
    .pc-app-price-text {
        font-size: 16px !important;
    }
}

/* =========================
   PRICE
========================= */
.pc-price-container {
    margin-bottom: 10px;
}
.pc-old-price-kamp {
    display: flex;
    align-items: baseline;
    margin: 0 0 2px 5px;
    font-size: 12px;
    font-weight: 300;
    color: #555;
    position: relative;
}
.pc-app-price-badge {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    font-size: 14px;
    font-weight: 600;
    color: #000000;
}
.pc-app-price-badge-kampanya {
    font-size: 14px;
    justify-content: space-around;
    color: #fff;
    padding: 2px 15px;
    border-radius: 5px;
    height: 22px;
    background: linear-gradient(90deg, #115b19, #41924a, #41924a, #115b19) !important;
}
.pc-app-price-text {
    padding: 2px 2px;
    font-size: 15px;
    font-weight: 700;
    color: #006e00;
    border-radius: 5px;
    flex-grow: 1;
    text-align: center;
    background: #5cb95d3d;
}
.pc-special .csp-price {
    font-size: 15px;
}
.pc-kampanya-name {
    color: #fff;
}
.pc-discount-badge {
    background: #ed6700;
    color: white;
    padding: 0px 3px;
    margin: 2px 0px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    border-radius: 5px;
}

@media (min-width: 380px) {
    .pc-app-price-badge {
        font-size: 15px !important;
    }
}

/* =========================
   SEPETE EKLE BUTONU (Görselin sağ altı)
========================= */
.pc-add-cart-btn {
    position: absolute;
    bottom: 8px;
    right: 8px;
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #ffffff94;
    color: black;
    font-size: 20px;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.pc-add-cart-btn:hover {
    background: white;
    transform: scale(1.1);
}
.pc-add-cart-btn:active {
    transform: scale(0.95);
}
.pc-add-cart-btn.eklendi {
    background: rgba(40, 167, 69, 0.9);
    color: white;
}

/* =========================
   BEDEN SEÇİMİ PANELİ
========================= */
.pc-size-panel-container {
    position: relative;
    background: #fff;
    border-top: 1px solid #eee;
    padding: 12px 10px 10px;
    animation: pcSizePanelSlideUp 0.25s ease-out;
}

@keyframes pcSizePanelSlideUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.pc-size-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}
.pc-size-panel-title {
    font-size: 13px;
    font-weight: 700;
    color: #333;
}
.pc-size-panel-close {
    cursor: pointer;
    font-size: 20px;
    color: #999;
    line-height: 1;
    padding: 0 4px;
    transition: color 0.15s;
}
.pc-size-panel-close:hover {
    color: #333;
}

.pc-size-panel-product-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f0f0f0;
}
.pc-size-panel-product-info img {
    width: 40px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
}
.pc-size-panel-product-info .pc-sp-name {
    font-size: 12px;
    font-weight: 500;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pc-size-panel-product-info .pc-sp-price {
    font-size: 14px;
    font-weight: 700;
    color: #000;
}

.pc-size-options {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}
.pc-size-option {
    min-width: 44px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid #ddd;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    padding: 0 10px;
    position: relative;
}
.pc-size-option:hover {
    border-color: #333;
}
.pc-size-option.selected {
    border-color: #6c757d;
    background: #6c757d;
    color: #fff;
}
.pc-size-option.out-of-stock {
    border-color: #eee;
    color: #ccc;
    cursor: not-allowed;
    background: #fafafa;
    text-decoration: line-through;
}

.pc-size-panel-cart-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 10px 0;
    border: none;
    border-radius: 8px;
    background: linear-gradient(90deg,#ff3131,#ff914d);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}
.pc-size-panel-cart-btn:hover {
    background: #333;
}
.pc-size-panel-cart-btn:active {
    transform: scale(0.98);
}
.pc-size-panel-cart-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}
.pc-size-panel-cart-btn.eklendi {
    background: #28a745;
}
.pc-size-panel-cart-btn i {
    font-size: 16px;
}

.pc-size-warning {
    color: #e00;
    font-size: 11px;
    font-weight: 600;
    margin-bottom: 6px;
    display: none;
    animation: pcShake 0.3s ease;
}
@keyframes pcShake {
    0%, 100% { transform: translateX(0); }
    25%      { transform: translateX(-4px); }
    75%      { transform: translateX(4px); }
}

/* =========================
   RENK PANELİ (mobil)
========================= */
.pc-color-option-container {
    /* color-option-products-container ile aynı */
}

/* =========================
   TAB HEADER (ortak)
========================= */
.pc-tabbed-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}
.pc-nav-tabs {
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 5px 0;
    list-style: none;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    border-bottom: none;
}
.pc-nav-tabs::-webkit-scrollbar { display: none; }

.pc-nav-tabs .pc-nav-link {
    position: relative;
    padding: 5px 0;
    border: none;
    background: transparent;
    color: rgb(107, 107, 106);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}
.pc-nav-tabs .pc-nav-link:hover,
.pc-nav-tabs .pc-nav-link.active {
    color: #0086d9;
}
.pc-nav-tabs .pc-nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #0086d9;
    transition: width 0.15s;
}
.pc-nav-tabs .pc-nav-link.active::after {
    width: 100%;
}

/* Dark mode tabs */
.pc-module-dark-bg .pc-nav-tabs .pc-nav-link {
    color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.pc-module-dark-bg .pc-nav-tabs .pc-nav-link:hover,
.pc-module-dark-bg .pc-nav-tabs .pc-nav-link.active {
    color: #ffffff;
}
.pc-module-dark-bg .pc-nav-tabs .pc-nav-link::after {
    background-color: #ffffff;
}

/* =========================
   VIEW ALL BUTTON (ortak)
========================= */
.pc-view-all-btn {
    padding: 5px 15px;
    font-size: 15px;
    font-weight: bold;
    color: #000;
    border-radius: 20px;
    text-decoration: none;
    transition: background 0.15s;
    white-space: nowrap;
}
.pc-view-all-btn:hover {
    background: rgb(0 0 0 / 20%);
    color: #fff !important;
    text-decoration: none;
}
.pc-module-dark-bg .pc-view-all-btn {
    color: #fff;
    background: rgba(255, 255, 255, 0.2);
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.pc-module-dark-bg .pc-view-all-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    color: #fff !important;
}

/* =========================
   LOADING (ortak)
========================= */
.pc-loading-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}
.pc-spinner-border {
    width: 3rem;
    height: 3rem;
    border: 0.25em solid rgba(0,0,0,0.1);
    border-right-color: #000;
    border-radius: 50%;
    animation: pcSpinner 0.75s linear infinite;
}
.pc-module-dark-bg .pc-spinner-border {
    border-color: rgba(255, 255, 255, 0.3);
    border-right-color: #fff;
}
@keyframes pcSpinner {
    to { transform: rotate(360deg); }
}

/* =========================
   ANIMATED TEXT (Sana Özel tab)
========================= */
.pc-animated-text {
    position: relative;
    padding: 5px 0;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    border: none;
    background: linear-gradient(90deg, #ff00be, #ff7a17, #ff00be);
    background-size: 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: pcFlow 3s linear infinite;
}
.pc-animated-text::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff00be, #ff7a17);
    transition: width 0.15s;
}
.pc-animated-text.active::after {
    width: 100%;
}
@keyframes pcFlow {
    0%   { background-position: 0%; }
    100% { background-position: 200%; }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
    .pc-size-panel-container {
        position: fixed;
        bottom: 0;
        left: 0;
        z-index: 1300;
        width: 100%;
    }
}
