/*
Theme Name: FixParts Brantial Child
Template: auto-parts-and-car-accessories
Description: FixParts icin ozel ilan sablonlari (parent: Auto Parts and Car Accessories)
Version: 1.0.0
Text Domain: fixparts-brantial-child
*/

/* ===== Genel ===== */
.fixparts-page-wrap { max-width: 1280px; margin: 0 auto; padding: 20px 20px 60px; }
.fixparts-page-header h1 { font-size: 28px; margin-bottom: 10px; }

/* ===== Hero (anasayfa) ===== */
.fixparts-hero { background: linear-gradient(rgba(10,10,10,0.55), rgba(10,10,10,0.75)), url('https://images.unsplash.com/photo-1618312980096-873bd19759a0?auto=format&fit=crop&w=1920&q=80') center/cover no-repeat; color: #fff; padding: 90px 20px; text-align: center; }
.fixparts-hero-inner { max-width: 720px; margin: 0 auto; }
.fixparts-hero h1 { font-size: 42px; margin-bottom: 12px; color: #fff; text-shadow: 0 2px 10px rgba(0,0,0,0.6); }
.fixparts-hero p { color: #fff; font-size: 18px; opacity: 0.95; margin-bottom: 24px; text-shadow: 0 1px 6px rgba(0,0,0,0.6); }
.fixparts-hero-search { display: flex; gap: 8px; max-width: 520px; margin: 0 auto 18px; }
.fixparts-hero-search input[type="text"] { flex: 1; padding: 12px 14px; border-radius: 6px; border: none; font-size: 15px; }
.fixparts-hero-search button { padding: 12px 22px; background: #d64545; color: #fff; border: none; border-radius: 6px; font-weight: 600; cursor: pointer; }
.fixparts-hero-search button:hover { background: #b83535; }
.fixparts-hero-whatsapp { display: inline-block; background: #25D366; color: #fff; padding: 10px 22px; border-radius: 6px; text-decoration: none; font-weight: 600; }
.fixparts-hero-whatsapp:hover { background: #1ebe57; color: #fff; }

/* ===== Toolbar (arama + siralama) ===== */
.fixparts-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; background: #f7f7f7; padding: 14px 18px; border-radius: 8px; margin-bottom: 10px; }
.fixparts-search-form { display: flex; gap: 8px; flex: 1; min-width: 240px; }
.fixparts-search-form input[type="text"] { flex: 1; padding: 9px 12px; border: 1px solid #ccc; border-radius: 5px; }
.fixparts-search-form button { padding: 9px 18px; background: #222; color: #fff; border: none; border-radius: 5px; cursor: pointer; }
.fixparts-toolbar-right { display: flex; align-items: center; gap: 16px; font-size: 14px; color: #555; }
.fixparts-toolbar-right select { padding: 6px 10px; border-radius: 5px; border: 1px solid #ccc; }
.fixparts-active-filters { margin-bottom: 20px; font-size: 13px; color: #555; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.fixparts-chip { background: #eee; padding: 4px 10px; border-radius: 14px; }
.fixparts-chip a { color: #b83535; text-decoration: none; margin-left: 6px; font-weight: bold; }
.fixparts-clear-all { color: #b83535; text-decoration: underline; margin-left: 8px; }

/* ===== Layout: sidebar + grid ===== */
.fixparts-layout { display: flex; gap: 28px; align-items: flex-start; }
.fixparts-aside { width: 260px; flex-shrink: 0; }
.fixparts-main { flex: 1; min-width: 0; }
.fixparts-section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.fixparts-section-header h2 { font-size: 22px; margin: 0; }
.fixparts-see-all { color: #b83535; text-decoration: none; font-weight: 600; font-size: 14px; }

/* ===== Kategori / marka agaci ===== */
.fixparts-sidebar-block { background: #fff; border: 1px solid #eaeaea; border-radius: 8px; padding: 16px; margin-bottom: 20px; }
.fixparts-sidebar-block h3 { font-size: 15px; text-transform: uppercase; letter-spacing: 0.5px; margin: 0 0 12px; color: #333; border-bottom: 2px solid #d64545; padding-bottom: 8px; }
.fixparts-tree, .fixparts-subtree { list-style: none; margin: 0; padding: 0; }
.fixparts-tree > li { margin-bottom: 2px; }
.fixparts-tree a { display: block; padding: 7px 8px; color: #333; text-decoration: none; border-radius: 4px; font-size: 14px; }
.fixparts-tree a:hover { background: #f5f5f5; color: #b83535; }
.fixparts-tree > li.active > a { background: #fdeaea; color: #b83535; font-weight: 600; }
.fixparts-subtree { margin-left: 10px; border-left: 2px solid #f0f0f0; }
.fixparts-subtree li.active > a { color: #b83535; font-weight: 600; }
.fixparts-subtree a { padding: 6px 10px; font-size: 13px; }
.fixparts-count { color: #999; font-size: 12px; }

/* ===== Ilan karti (grid) ===== */
.fixparts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.fixparts-card { display: block; background: #fff; border: 1px solid #eaeaea; border-radius: 8px; overflow: hidden; text-decoration: none; color: inherit; transition: box-shadow 0.15s, transform 0.15s; }
.fixparts-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.1); transform: translateY(-2px); }
.fixparts-card-thumb { display: block; aspect-ratio: 4/3; background: #f5f5f5; overflow: hidden; }
.fixparts-card-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fixparts-card-body { display: block; padding: 12px 14px; }
.fixparts-card-body h3 { font-size: 15px; margin: 0 0 6px; color: #222; }
.fixparts-card-title { display: block; font-size: 15px; margin: 0 0 6px; color: #222; font-weight: 600; }
.fixparts-card-price { display: block; font-size: 16px; font-weight: 700; color: #b83535; margin-bottom: 4px; }
.fixparts-card-location { display: block; font-size: 12px; color: #888; }

/* ===== Sayfalama ===== */
.fixparts-pagination { margin-top: 30px; display: flex; gap: 6px; flex-wrap: wrap; }
.fixparts-pagination .page-numbers { padding: 8px 14px; border: 1px solid #ddd; border-radius: 5px; text-decoration: none; color: #333; }
.fixparts-pagination .page-numbers.current { background: #d64545; color: #fff; border-color: #d64545; }
.fixparts-pagination .page-numbers:hover { background: #f5f5f5; }

.fixparts-empty { padding: 40px; text-align: center; background: #f9f9f9; border-radius: 8px; color: #666; }

/* ===== Responsive ===== */
@media (max-width: 900px) {
	.fixparts-layout { flex-direction: column; }
	.fixparts-aside { width: 100%; }
	.fixparts-hero h1 { font-size: 26px; }
}

/* ===== Ac/Kapa (accordion) - kategori & marka agaci ===== */
.fixparts-toggle {
	display: inline-block;
	width: 12px;
	margin-right: 4px;
	cursor: pointer;
	transition: transform 0.2s ease;
	color: #b83535;
	font-size: 11px;
}
.fixparts-toggle::before {
	content: "\25B8";
}
.fixparts-tree-group.active > .fixparts-toggle,
.fixparts-tree-group.fixparts-open > .fixparts-toggle {
	transform: rotate(90deg);
}
.fixparts-subtree {
	display: none;
}
.fixparts-tree-group.active > .fixparts-subtree,
.fixparts-tree-group.fixparts-open > .fixparts-subtree {
	display: block;
}

/* ===== One Cikan Markalar ===== */
.fixparts-brand-showcase {
	max-width: 1200px;
	margin: 0 auto;
	padding: 32px 16px 8px;
}
.fixparts-brand-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 16px;
	margin-top: 16px;
}
.fixparts-brand-card {
	position: relative;
	display: block;
	height: 160px;
	border-radius: 10px;
	background-size: cover;
	background-position: center;
	background-color: #222;
	overflow: hidden;
	text-decoration: none;
	box-shadow: 0 2px 8px rgba(0,0,0,0.15);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.fixparts-brand-card:hover {
	transform: translateY(-4px) scale(1.02);
	box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}
.fixparts-brand-card-overlay {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 10px 14px;
	background: linear-gradient(to top, rgba(0,0,0,0.75), rgba(0,0,0,0));
	color: #fff;
	display: flex;
	flex-direction: column;
}
.fixparts-brand-card-name {
	font-weight: 700;
	font-size: 16px;
}
.fixparts-brand-card-count {
	font-size: 12px;
	opacity: 0.85;
}


/* ===== Kenar cubugu dropdown (ilk seviye secim) ===== */
.fixparts-select-wrap {
	margin-bottom: 10px;
}
.fixparts-tree-select {
	width: 100%;
	padding: 10px 12px;
	border-radius: 6px;
	border: 1px solid #ddd;
	font-size: 14px;
	color: #333;
	background: #fff;
	cursor: pointer;
}
.fixparts-tree-select:hover {
	border-color: #b83535;
}
.fixparts-subtree-flat {
	list-style: none;
	margin: 10px 0 0;
	padding: 0 0 0 4px;
	border-left: 2px solid #f0f0f0;
}
.fixparts-subtree-flat li {
	margin-bottom: 2px;
}
.fixparts-subtree-flat a {
	display: block;
	padding: 6px 10px;
	color: #333;
	text-decoration: none;
	border-radius: 4px;
	font-size: 13px;
}
.fixparts-subtree-flat a:hover {
	background: #f5f5f5;
	color: #b83535;
}
.fixparts-subtree-flat li.active > a {
	color: #b83535;
	font-weight: 600;
	background: #fdeaea;
}

/* ===== Detay sayfasi tam ekran gorsel goruntuleyici (lightbox) ===== */
.fixparts-gallery-img { transition: transform 0.15s ease; }
.fixparts-gallery-img:hover { transform: scale(1.03); }
.fixparts-lightbox {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,0.92);
	z-index: 99999;
	align-items: center;
	justify-content: center;
}
.fixparts-lightbox.active { display: flex; }
.fixparts-lightbox img {
	max-width: 90%;
	max-height: 85%;
	border-radius: 6px;
	box-shadow: 0 10px 40px rgba(0,0,0,0.5);
}
.fixparts-lightbox-close,
.fixparts-lightbox-prev,
.fixparts-lightbox-next {
	position: absolute;
	color: #fff;
	cursor: pointer;
	user-select: none;
	background: rgba(255,255,255,0.12);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}
.fixparts-lightbox-close {
	top: 24px;
	right: 30px;
	width: 44px;
	height: 44px;
	font-size: 28px;
	line-height: 1;
}
.fixparts-lightbox-prev,
.fixparts-lightbox-next {
	top: 50%;
	transform: translateY(-50%);
	width: 50px;
	height: 50px;
	font-size: 22px;
}
.fixparts-lightbox-prev { left: 20px; }
.fixparts-lightbox-next { right: 20px; }
.fixparts-lightbox-close:hover,
.fixparts-lightbox-prev:hover,
.fixparts-lightbox-next:hover { background: rgba(255,255,255,0.25); }


/* Site logo image replacement */
#headerimg { padding: 18px 0; }
#headerimg h1 { margin: 0; font-size: 0; line-height: 0; }
#headerimg h1 a { display: inline-block; width: 190px; height: 68px; background: url('https://brantial.co/wp-content/uploads/2026/07/fixparts-logo.png') no-repeat left center; background-size: contain; text-indent: -9999px; overflow: hidden; }
#headerimg .description { display: none; }
.fixparts-single h1 { font-size: 26px; line-height: 1.35; margin: 20px 0 16px; font-weight: 700; }
@media (max-width: 600px) { .fixparts-single h1 { font-size: 20px; } #headerimg h1 a { width: 150px; height: 54px; } }

/* Site logo image (block-based header - Site Editor) */
.wp-block-site-title { font-size: 0 !important; line-height: 0 !important; }
.wp-block-site-title a { display: inline-block !important; width: 170px; height: 56px; background: url('https://brantial.co/wp-content/uploads/2026/07/fixparts-logo.png') no-repeat left center; background-size: contain; text-indent: -9999px; overflow: hidden; }

/* Karti gorsel iyilestirmeleri: baslik kirpma, rozet, CTA */
.fixparts-card-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; min-height: 40px; line-height: 1.3; }
.fixparts-card-thumb { position: relative; }
.fixparts-card-badges { position: absolute; top: 8px; left: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.fixparts-badge { display: inline-block; padding: 3px 9px; border-radius: 4px; font-size: 11px; font-weight: 700; color: #fff; text-transform: uppercase; letter-spacing: 0.3px; box-shadow: 0 1px 4px rgba(0,0,0,0.25); }
.fixparts-badge-orijinal { background: #2e9e4f; }
.fixparts-badge-cikma { background: #2d6cdf; }
.fixparts-card-cta { display: inline-block; margin: 2px 0 6px; padding: 5px 12px; background: #fdecec; color: #b83535; border-radius: 5px; font-size: 13px; font-weight: 700; }
.fixparts-card:hover .fixparts-card-cta { background: #b83535; color: #fff; }

/* Detay sayfasi rozet ve fiyat CTA */
.fixparts-badges-single { display: flex; gap: 8px; margin: 8px 0 18px; flex-wrap: wrap; }
.fixparts-price-cta { display: inline-block; background: #fdecec; color: #b83535; font-size: 18px; font-weight: 700; padding: 10px 18px; border-radius: 6px; margin-bottom: 10px; }

/* Detay sayfasi gercek fiyat + iletisim bloku */
.fixparts-price { display: inline-block; background: #fdecec; color: #b83535; font-size: 20px; font-weight: 700; padding: 10px 18px; border-radius: 6px; margin-bottom: 10px; }
.fixparts-contact-block { margin-top: 22px; padding: 16px 18px; background: #f8f8f8; border-left: 3px solid #b83535; border-radius: 4px; }
.fixparts-contact-block p { margin: 0 0 8px; font-size: 14px; color: #333; line-height: 1.5; }
.fixparts-contact-block p:last-child { margin-bottom: 0; }
.fixparts-contact-block a { color: #b83535; text-decoration: underline; }
.fixparts-hl { font-weight: 700; color: #111; padding: 2px 6px; border-radius: 2px; }
.fixparts-hl-orange { background: #f5a623; }
.fixparts-hl-yellow { background: #ffe600; }
.fixparts-hl-green { background: #7ed957; }
.fixparts-hl-cyan { background: #5ce1e6; }