﻿html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}


/* ================= AMAZON STYLE PRODUCT CARD ================= */

.product-card-amazon {
    background: #fff;
    border: 1px solid #e3e6e6;
    border-radius: 1px;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: all 0.2s ease-in-out;
}

    .product-card-amazon:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    }





/* BODY */
.product-body {
    padding: 10px 12px 14px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* TITLE */
.product-title {
    font-size: 13.5px;
    line-height: 1.4;
    color: #0f1111;
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}



.product-price .currency {
    font-size: 14px;
    font-weight: 500;
}


.address-card {
    cursor: pointer;
    border: 1px solid #dee2e6; /* daha belirgin */
    transition: all .2s ease;
}

    .address-card:hover {
        border-color: #0d6efd;
        box-shadow: 0 0 0 0.15rem rgba(13,110,253,.15);
    }

/* Seçili adres */
.address-card-selected {
    border: 2px solid #0d6efd !important;
    background-color: #CAE1FF;
    /*background-color:#f8fbff;*/
    box-shadow: 0 0 0 0.2rem rgba(13,110,253,.25);
}


.cart-item-card {
    border-radius: 12px;
    transition: all 0.2s ease;
}

.cart-item-card:hover {
    transform: translateY(-2px);
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background-color: #f8f9fa;
    font-weight: bold;
    transition: 0.2s;
}

    .qty-btn:hover {
        background-color: #ff6a00;
        color: #fff;
        border-color: #ff6a00;
    }


.form-label {
    font-size: 15px;
    font-weight:bold;
}

.card-header strong {
    font-size: 20px;
}

.the-main-title {
    font-size: 28px;
}

/* ?? Product Sidebar ?? */
.product-sidebar {
    border-radius: 12px;
}

.sidebar-title {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .6px;
    text-transform: uppercase;
    color: #9e9e9e;
    margin-bottom: 10px;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: 8px;
    font-size: 13px;
    color: #555;
    text-decoration: none;
    transition: background .15s;
}

    .sidebar-item:hover,
    .sidebar-item.active {
        background: #f5f0eb;
        color: #2c2c2a;
    }

    .sidebar-item.active {
        font-weight: 500;
    }

    .sidebar-item .dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #b4b2a9;
        flex-shrink: 0;
    }

    .sidebar-item .item-count {
        margin-left: auto;
        font-size: 11px;
        background: #f0ebe4;
        padding: 2px 7px;
        border-radius: 20px;
    }

/* ?? Product Card ?? */
.product-card {
    background: #fff;
    border: 1px solid rgba(0,0,0,.07);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    transition: border-color .2s, box-shadow .2s;
}

    .product-card:hover {
        border-color: rgba(0,0,0,.14);
        box-shadow: 0 4px 16px rgba(0,0,0,.06);
    }

/* Görsel */
.product-img-wrap {
    position: relative;
    overflow: hidden;
    background: #f5efe8;
}

.product-img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}



.product-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}





.product-card:hover .product-img {
    transform: scale(1.05);
}

/* Kategori badge */
.product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    font-size: 10px;
    font-weight: 500;
    padding: 3px 8px;
    border-radius: 20px;
    background: rgba(255,255,255,.85);
    color: #666;
    letter-spacing: .3px;
    backdrop-filter: blur(4px);
}

/* Sepete ekle butonu */
.cart-btn {
    position: absolute;
    bottom: 52px; /* product-body yüksekliðine göre ayarla */
    right: 10px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,.92);
    border: 1px solid rgba(0,0,0,.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #333;
    cursor: pointer;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity .2s, transform .2s;
    z-index: 2;
}

.product-card:hover .cart-btn {
    opacity: 1;
    transform: translateY(0);
}

.cart-btn:hover {
    background: #fff;
    border-color: rgba(0,0,0,.22);
}

/* Kart içeriði */
.product-body {
    padding: 11px 13px 13px;
}

.product-name {
    font-size: 13px;
    font-weight: 500;
    color: #2c2c2a;
    margin: 0 0 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 3px;
}

.product-price {
    font-size: 15px;
    font-weight: 600;
    color: #2c2c2a;
}

.product-currency {
    font-size: 11px;
    color: #9e9e9e;
}



    /* ── Stok badge ── */
    .stock-badge {
        display: inline-block;
        font-size: 15px;
        font-weight: 500;
        padding: 2px 8px;
        border-radius: 20px;
        white-space: nowrap;
    }

    .stock-in {
        background: #eaf3de;
        color: #3b6d11;
    }

    .stock-low {
        background: #faeeda;
        color: #854f0b;
    }

    .stock-out {
        background: #fcebeb;
        color: #a32d2d;
    }

    /* ── Tükendi görsel overlay ── */
    .stock-overlay {
        position: absolute;
        inset: 0;
        background: rgba(255,255,255,.55);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
        font-weight: 600;
        color: #a32d2d;
        letter-spacing: .5px;
    }

    .out-of-stock .product-img {
        filter: grayscale(40%);
    }

    /* ── Sepete Ekle butonu ── */
    .cart-action {
        padding: 0 10px 10px;
    }

    .cart-btn-full {
        width: 100%;
        height: 36px;
        border-radius: 8px;
        border: none;
        background: #6e9e7a; /* yumuşak sage yeşil */
        color: #fff;
        font-size: 13px;
        font-weight: 500;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        cursor: pointer;
        transition: background .15s;
        text-decoration: none;
    }

        .cart-btn-full:hover:not(.disabled) {
            background: #5a8a65;
        }

    .cart-btn-outline {
        background: #f0f4f1;
        color: #4a7a56;
        border: 1px solid #b8d4be;
    }

        .cart-btn-outline:hover {
            background: #deeee3;
            color: #3b6d11;
        }

    .cart-btn-full.disabled {
        background: #f0ebe4;
        color: #b4b2a9;
        border-color: transparent;
        cursor: not-allowed;
    }

    .cart-btn-full i {
        font-size: 15px;
    }

    @@media (max-width: 767px) {
        .cart-btn-full {
            height: 34px;
            font-size: 12px;
        }
    }



/* ?? Mobil: sidebar yatay + 2 kolon grid ?? */
@media (max-width: 767px) {
    .product-sidebar {
        display: flex !important;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 6px;
        padding: 10px !important;
    }

    .sidebar-title {
        display: none;
    }

    .sidebar-item {
        padding: 5px 12px;
        border: 1px solid rgba(0,0,0,.08);
        border-radius: 20px;
        font-size: 12px;
    }

        .sidebar-item .dot {
            display: none;
        }

        .sidebar-item .item-count {
            display: none;
        }


    /* Mobilde sepet butonu her zaman görünür */
    .cart-btn {
        opacity: 1;
        transform: none;
        bottom: 46px;
    }
}