/* Custom CSS - Antik Halı Teması */

/* Tailwind Custom Colors */
:root {
    --dark-red: #8B0000;
    --bordo: #6B0000;
    --cream: #F5F5DC;
    --light-cream: #FAF9F6;
    --gold: #D4AF37;
    --brown: #654321;
    --beige: #F5E6D3;
    --dark-brown: #3E2723;
}

/* Accessibility - Skip to Content Link */
.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border-width: 0 !important;
    opacity: 0 !important;
}

.sr-only:focus,
.sr-only.focus\:not-sr-only:focus {
    position: absolute;
    width: auto;
    height: auto;
    padding: 0.5rem 1rem;
    margin: 0;
    overflow: visible;
    clip: auto;
    white-space: normal;
    z-index: 9999;
    background-color: var(--dark-red);
    color: white;
    border-radius: 0.5rem;
}

/* Fonts */
.font-cinzel {
    font-family: 'Cinzel', serif;
}

.font-lora {
    font-family: 'Lora', serif;
}

body {
    font-family: 'Lora', serif;
    scroll-behavior: smooth;
    overflow-x: hidden; /* Yatay scroll'u önle */
}

/* Text Overflow Prevention - Mobil için */
* {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

h1, h2, h3, h4, h5, h6 {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

p, li, span, a {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Custom Colors for Tailwind */
.bg-dark-red {
    background-color: var(--dark-red);
}

.bg-bordo {
    background-color: var(--bordo);
}

.bg-cream {
    background-color: var(--cream);
}

.bg-light-cream {
    background-color: var(--light-cream);
}

.bg-gold {
    background-color: var(--gold);
}

.bg-dark-brown {
    background-color: var(--dark-brown);
}

.text-dark-red {
    color: var(--dark-red);
}

.text-dark-brown {
    color: var(--dark-brown);
}

.text-cream {
    color: var(--cream);
}

.text-gold {
    color: var(--gold);
}

.border-gold {
    border-color: var(--gold);
}

/* Header Sticky Background */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header.scrolled {
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.15);
}

/* WhatsApp Floating Button */
.whatsapp-button {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    width: 56px;
    height: 56px;
    background-color: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
    animation: whatsapp-pulse 2s infinite;
}

.whatsapp-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
    animation: none;
}

.whatsapp-button:active {
    transform: scale(0.95);
}

.whatsapp-button svg {
    width: 32px;
    height: 32px;
    fill: white;
}

@media (min-width: 768px) {
    .whatsapp-button {
        width: 64px;
        height: 64px;
        bottom: 30px;
        right: 30px;
    }
    
    .whatsapp-button svg {
        width: 36px;
        height: 36px;
    }
}

@keyframes whatsapp-pulse {
    0% {
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.6), 0 0 0 8px rgba(37, 211, 102, 0.1);
    }
    100% {
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    }
}

/* Hero Slider Styles - Ortak Stiller */
.hero-overlok,
.hero-halilar {
    width: 100%;
    height: 100vh;
}

.hero-overlok .swiper-slide,
.hero-halilar .swiper-slide {
    position: relative;
}

.hero-overlok .swiper-button-next,
.hero-overlok .swiper-button-prev,
.hero-halilar .swiper-button-next,
.hero-halilar .swiper-button-prev {
    color: white;
    background: rgba(0, 0, 0, 0.3);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    transition: all 0.3s;
    cursor: pointer;
}

.hero-overlok .swiper-button-next:hover,
.hero-overlok .swiper-button-prev:hover,
.hero-halilar .swiper-button-next:hover,
.hero-halilar .swiper-button-prev:hover {
    background: rgba(0, 0, 0, 0.5);
}

.hero-overlok .swiper-button-next:active,
.hero-overlok .swiper-button-prev:active,
.hero-halilar .swiper-button-next:active,
.hero-halilar .swiper-button-prev:active {
    transform: scale(0.9);
}

.hero-overlok .swiper-button-next::after,
.hero-overlok .swiper-button-prev::after,
.hero-halilar .swiper-button-next::after,
.hero-halilar .swiper-button-prev::after {
    font-size: 20px;
}

/* Mobilde navigation butonları daha küçük ama dokunulabilir */
@media (max-width: 768px) {
    .hero-overlok .swiper-button-next,
    .hero-overlok .swiper-button-prev,
    .hero-halilar .swiper-button-next,
    .hero-halilar .swiper-button-prev {
        width: 45px;
        height: 45px;
        background: rgba(0, 0, 0, 0.5);
    }
    
    .hero-overlok .swiper-button-next::after,
    .hero-overlok .swiper-button-prev::after,
    .hero-halilar .swiper-button-next::after,
    .hero-halilar .swiper-button-prev::after {
        font-size: 18px;
    }
    
    /* Mobilde pagination daha görünür */
    .hero-overlok .swiper-pagination,
    .hero-halilar .swiper-pagination {
        bottom: 20px !important;
    }
    
    .hero-overlok .swiper-pagination-bullet,
    .hero-halilar .swiper-pagination-bullet {
        width: 10px;
        height: 10px;
        margin: 0 6px;
    }
    
    /* Swiper touch feedback */
    .hero-overlok,
    .hero-halilar {
        -webkit-tap-highlight-color: transparent;
        touch-action: pan-y;
    }
}

.hero-overlok .swiper-pagination-bullet,
.hero-halilar .swiper-pagination-bullet {
    background: white;
    opacity: 0.5;
    width: 12px;
    height: 12px;
}

.hero-overlok .swiper-pagination-bullet-active,
.hero-halilar .swiper-pagination-bullet-active {
    opacity: 1;
    background: var(--gold);
}

/* Animation Classes */
.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

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

/* Scroll Animation Classes */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Mobile Menu */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

#mobile-menu.active {
    max-height: 500px;
}

/* Smooth Scroll Offset */
html {
    scroll-padding-top: 80px;
}

/* Button Styles */
.btn-primary {
    display: inline-block;
    text-align: center;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Halı Card Hover Effect */
.halı-card {
    transition: all 0.3s ease;
}

.halı-card:hover {
    transform: translateY(-5px);
}

/* Overlok Image Hover */
.overlok-item img {
    transition: transform 0.3s ease;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    /* Mobile menu improvements */
    #mobile-menu {
        background-color: rgba(245, 245, 220, 0.98);
        backdrop-filter: blur(10px);
        padding: 1rem;
        border-radius: 0.5rem;
        margin-top: 0.5rem;
    }
    
    /* Better spacing on mobile */
    section {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
    
    /* Smaller text on mobile */
    h1 {
        font-size: 1.75rem !important;
        line-height: 1.3;
    }
    
    h2 {
        font-size: 2rem;
        line-height: 1.3;
    }
    
    h3 {
        font-size: 1.5rem;
        line-height: 1.3;
    }
    
    /* Header logo için mobilde kısa text */
    .logo a {
        font-size: 0.875rem !important;
    }
    
    .logo a .sr-only {
        display: none !important;
    }
    
    .logo a span:not(.sr-only) {
        font-size: 0.875rem;
        max-width: 120px;
        display: block;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .logo a .sr-only {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
    }
    
    /* Hero slider text'leri mobilde küçült */
    .hero-overlok h1,
    .hero-overlok h2,
    .hero-halilar h2 {
        font-size: 1.75rem !important;
        padding: 0 0.5rem;
    }
    
    .hero-overlok p,
    .hero-halilar p {
        font-size: 1rem !important;
        padding: 0 0.5rem;
    }
    
    /* Butonlar mobilde daha küçük */
    .btn-primary {
        font-size: 0.9rem;
        padding: 0.75rem 1.5rem;
        white-space: nowrap;
    }
    
    /* Paragraflar için padding */
    p {
        padding: 0 0.25rem;
    }
    
    /* Adres ve iletişim bilgileri */
    #iletisim p,
    #iletisim li {
        word-break: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
    
    /* Container için max-width kontrolü */
    .container {
        max-width: 100%;
        overflow-x: hidden;
    }
    
    /* Overlok item başlıkları - Mobilde kayma sorununu önle */
    .overlok-item {
        overflow-x: hidden !important;
        width: 100%;
        max-width: 100%;
        transform: none !important;
    }
    
    .overlok-item h3 {
        font-size: 1.25rem;
        line-height: 1.4;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
    
    .overlok-item p {
        font-size: 0.95rem;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
    
    .overlok-item ul {
        word-wrap: break-word;
        overflow-wrap: break-word;
        padding-left: 1rem;
    }
    
    /* Overlok item içindeki div'ler için overflow kontrolü */
    .overlok-item > div,
    .overlok-item > article {
        max-width: 100%;
        overflow-x: hidden;
        box-sizing: border-box;
    }
    
    /* Mobilde transform animasyonlarını kaldır */
    .overlok-item[style*="translate-x"] {
        transform: none !important;
    }
}

@media (max-width: 480px) {
    /* Extra small devices */
    .hero-overlok .swiper-button-next,
    .hero-overlok .swiper-button-prev,
    .hero-halilar .swiper-button-next,
    .hero-halilar .swiper-button-prev {
        width: 35px;
        height: 35px;
    }
    
    h1 {
        font-size: 1.5rem !important;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    .container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    /* Header logo çok küçük ekranlarda */
    .logo a {
        font-size: 0.75rem !important;
    }
    
    .logo a span[aria-hidden="true"] {
        font-size: 0.75rem;
        max-width: 100px;
    }
    
    /* Hero slider text çok küçük ekranlar */
    .hero-overlok h1,
    .hero-overlok h2,
    .hero-halilar h2 {
        font-size: 1.5rem !important;
        padding: 0 0.5rem;
    }
    
    .hero-overlok p,
    .hero-halilar p {
        font-size: 0.9rem !important;
    }
    
    /* Butonlar çok küçük ekranlarda */
    .btn-primary {
        font-size: 0.85rem;
        padding: 0.625rem 1.25rem;
    }
    
    /* Paragraflar */
    p, li {
        font-size: 0.9rem;
    }
    
    /* İletişim bilgileri */
    #iletisim .text-lg {
        font-size: 0.95rem;
    }
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

