/* assets/css/style.css */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

:root {
    --color-primary: #a3d9cf; /* Açık su yeşili */
    --color-primary-dark: #8fc2b8;
    --color-secondary: #ffffff;
    --color-accent: #22c55e; /* Güven veren yeşil (WhatsApp, Sipariş) */
    --color-accent-hover: #16a34a;
    --color-text-main: #1f2937;
    --color-text-muted: #6b7280;
    --color-bg-light: #f9fafb;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--color-bg-light);
    color: var(--color-text-main);
    overflow-x: hidden;
}

/* Kayan Duyuru Bandı */
.ticker-wrap {
    width: 100%;
    overflow: hidden;
    background-color: var(--color-primary);
    padding-top: 8px;
    padding-bottom: 8px;
    white-space: nowrap;
}

.ticker {
    display: inline-block;
    white-space: nowrap;
    padding-right: 100%;
    animation: ticker 20s linear infinite;
}

.ticker__item {
    display: inline-block;
    padding: 0 2rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #0f3f35;
}

@keyframes ticker {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-100%, 0, 0); }
}

/* İndirim Badge */
.discount-badge {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(239, 68, 68, 0.3);
    animation: pulse-soft 2s infinite;
}

@keyframes pulse-soft {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

/* Kategori Scroll */
.category-scroll {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.category-scroll::-webkit-scrollbar {
    display: none;
}

.category-card {
    transition: all 0.3s ease;
}
.category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Ürün Kartı */
.product-card {
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #f3f4f6;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.product-card:hover {
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
    transform: translateY(-4px);
}
.product-image-wrapper {
    position: relative;
    padding-top: 100%; /* 1:1 Aspect ratio */
    overflow: hidden;
    background-color: #f9fafb;
}
.product-image-wrapper img {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.product-card:hover .product-image-wrapper img {
    transform: scale(1.05);
}

.product-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-title {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--color-text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3rem; /* 2 satır yüksekliği */
}

.product-price-area {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.btn-order {
    background-color: var(--color-accent);
    color: white;
    width: 100%;
    padding: 0.75rem;
    border-radius: 8px;
    font-weight: 600;
    transition: background-color 0.2s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}
.btn-order:hover {
    background-color: var(--color-accent-hover);
}

@media (max-width: 768px) {
    .btn-order {
        padding: 0.5rem 0.25rem;
        font-size: 0.85rem;
        font-weight: 500;
        gap: 0.25rem;
    }
    .btn-order svg {
        width: 16px;
        height: 16px;
    }
}

/* Modal */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 50;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.modal-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -45%);
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 51;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}
.modal-backdrop.active .modal-content {
    opacity: 1;
    transform: translate(-50%, -50%);
    pointer-events: auto;
}

/* Input Styles */
.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: 'Poppins', sans-serif;
}
.form-input:focus {
    border-color: var(--color-primary-dark);
    box-shadow: 0 0 0 3px rgba(163, 217, 207, 0.3);
}

/* Hamburger Menu Anim */
.hamburger-line {
    transition: all 0.3s ease;
    transform-origin: left;
}
.mobile-menu-active .hamburger-line:first-child { transform: rotate(45deg); }
.mobile-menu-active .hamburger-line:nth-child(2) { opacity: 0; }
.mobile-menu-active .hamburger-line:last-child { transform: rotate(-45deg); }

/* ==============================
   Sticky WhatsApp Sipariş Butonu
   ============================== */
.whatsapp-sticky-wrapper {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: whatsapp-slide-in 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 1s both;
}

.whatsapp-sticky-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    cursor: pointer;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

/* Üstteki yazı balonu */
.whatsapp-sticky-label {
    background: #ffffff;
    color: #1f2937;
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12), 0 1px 3px rgba(0, 0, 0, 0.08);
    white-space: nowrap;
    position: relative;
    letter-spacing: 0.02em;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Balonun alt ok işareti */
.whatsapp-sticky-label::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 10px;
    height: 10px;
    background: #ffffff;
    box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.06);
}

/* WhatsApp yeşil yuvarlak ikon */
.whatsapp-sticky-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: #25D366;
    color: #ffffff;
    box-shadow:
        0 4px 15px rgba(37, 211, 102, 0.4),
        0 2px 6px rgba(37, 211, 102, 0.25);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
    animation: whatsapp-pulse 2.5s ease-in-out infinite;
}

/* Hover efektleri */
.whatsapp-sticky-btn:hover .whatsapp-sticky-icon {
    transform: scale(1.1);
    box-shadow:
        0 6px 25px rgba(37, 211, 102, 0.5),
        0 3px 10px rgba(37, 211, 102, 0.3);
}

.whatsapp-sticky-btn:hover .whatsapp-sticky-label {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

/* Active (tıklama) efekti */
.whatsapp-sticky-btn:active .whatsapp-sticky-icon {
    transform: scale(0.95);
}

/* Animasyonlar */
@keyframes whatsapp-slide-in {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes whatsapp-pulse {
    0%, 100% {
        box-shadow:
            0 4px 15px rgba(37, 211, 102, 0.4),
            0 2px 6px rgba(37, 211, 102, 0.25);
    }
    50% {
        box-shadow:
            0 4px 15px rgba(37, 211, 102, 0.4),
            0 2px 6px rgba(37, 211, 102, 0.25),
            0 0 0 12px rgba(37, 211, 102, 0.08);
    }
}

/* Mobil Responsive */
@media (max-width: 768px) {
    .whatsapp-sticky-wrapper {
        bottom: 16px;
        right: 16px;
    }

    .whatsapp-sticky-icon {
        width: 52px;
        height: 52px;
    }

    .whatsapp-sticky-icon svg {
        width: 24px;
        height: 24px;
    }

    .whatsapp-sticky-label {
        font-size: 11px;
        padding: 5px 12px;
    }
}

@media (max-width: 380px) {
    .whatsapp-sticky-wrapper {
        bottom: 12px;
        right: 12px;
    }

    .whatsapp-sticky-icon {
        width: 48px;
        height: 48px;
    }

    .whatsapp-sticky-icon svg {
        width: 22px;
        height: 22px;
    }

    .whatsapp-sticky-label {
        font-size: 10px;
        padding: 4px 10px;
    }
}
