/*
Theme Name:   ANOVA Child
Theme URI:    https://www.anovainsaat.com.tr
Description:  Hello Elementor child theme for ANOVA İnşaat & Yapı Kimyasalları. Adds the "Hizmet" post type, schema.org data, GTM and the service-finder assets. Layout and styling are built with Elementor.
Author:       ANOVA İnşaat
Template:     hello-elementor
Version:      1.10.3
Requires at least: 6.4
Requires PHP: 7.4
Text Domain:  anova-child
License:      GNU General Public License v3 or later
License URI:  https://www.gnu.org/licenses/gpl-3.0.html
*/

/*
 * Görsel tasarım Elementor global ayarlarında ve sayfalarda tutulur.
 * Buraya yalnızca Elementor'un kendi kontrolleriyle yapılamayan küçük kurallar eklenir.
 */

html {
	scroll-behavior: smooth;
}

/* Sticky header: üst bilgi çubuğu (40px) kayıp gider, menü satırı üstte kalır. */
.elementor-location-header {
	position: sticky;
	top: -40px;
	z-index: 50;
}

.admin-bar .elementor-location-header {
	top: -8px; /* 32px yönetim çubuğu - 40px üst bilgi çubuğu */
}

@media (max-width: 1024px) {
	.elementor-location-header,
	.admin-bar .elementor-location-header {
		top: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}

/* Başlık içindeki vurgulu kelimeler: başlığa "anova-hl" global sınıfı verilir, vurgulanacak kelime <span> içine yazılır. */
.anova-hl span {
	color: var(--accent, #fcbb02);
}

/* Eyebrow başlıkları: "— BAŞLIK" stili. Elementor elemanına "anova-eyebrow" global sınıfı verilir. */
.anova-eyebrow::before {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	width: 18px;
	height: 2px;
	background: currentColor;
	transform: translateY(-50%);
}

/* Kart hover efekti: container'a "anova-lift" sınıfı verilir. */
.anova-lift {
	transition: transform 250ms cubic-bezier(0.22, 0.61, 0.36, 1), box-shadow 250ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.anova-lift:hover {
	transform: translateY(-4px);
	box-shadow: 0 25px 60px rgba(17, 24, 39, 0.12);
}

/* Rehber yazıları: makale içi bağlantılar (Elementor paragraf içindeki <a> etiketleri). */
.anova-article a {
	color: var(--accent-dark, #e3a802);
	font-weight: 700;
}

.anova-article a:hover {
	color: var(--primary, #1d2a5b);
}

/* Sayfa içi bağlantılarda (#services-list, #contact-form…) sticky header hedefi örtmesin. */
[id] {
	scroll-margin-top: 110px;
}

/* =========================================================
   FLOATING BUTTONS (inc/floating-buttons.php)
   Elementor kitinin genel buton stili (.elementor-kit-N button) ezmesin diye "html body" ile başlar.
   ========================================================= */
html body .anova-fab {
	position: fixed;
	right: 22px;
	width: 56px;
	height: 56px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	cursor: pointer;
	box-shadow: 0 25px 60px rgba(17, 24, 39, 0.12);
	z-index: 60;
	transition: transform 250ms cubic-bezier(0.22, 0.61, 0.36, 1), background 250ms cubic-bezier(0.22, 0.61, 0.36, 1), opacity 250ms ease;
}
html body .anova-fab:hover,
html body .anova-fab:focus { color: #fff; }
html body .anova-fab svg { width: 26px; height: 26px; }
html body .anova-fab--whatsapp { background: #25d366; bottom: 22px; }
html body .anova-fab--whatsapp:hover { background: #1ebe5b; transform: scale(1.08); }
html body .anova-fab--call { display: none; background: #fcbb02; bottom: 88px; }
html body .anova-fab--call:hover { background: #e3a802; transform: scale(1.08); }
html body .anova-fab--top {
	background: #1d2a5b;
	bottom: 154px;
	opacity: 0;
	pointer-events: none;
	transform: translateY(8px);
}
html body .anova-fab--top.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
html body .anova-fab--top:hover { background: #2a3a78; }
@media (max-width: 640px) {
	html body .anova-fab--call { display: inline-flex; }
}

/* Sayfa yolu (Anasayfa › ...): Elementor kitindeki ".elementor-kit-N a:hover" sarı rengi beyaz zeminde okunmuyordu.
   Yerel sitedeki gibi üzerine gelince lacivert olur. */
html body .anova-crumb a:hover,
html body .anova-crumb a:focus { color: #1d2a5b; }

/* =========================================================
   REHBER YAZISI (WordPress editörüyle yazılan yazılar — inc/blog.php, inc/blog-layout.php)
   Şablondaki "İçerik" widget'ı yazıyı kenar çubuklu düzende gösterir (tasarım: design/rehber-yazi-ornek.html).
   Elementor ile yapılmış eski yazılar bu kurallardan etkilenmez (body.anova-block-post yok).
   ========================================================= */
/* Widget'ın kendi ayarları (.elementor-387 …) daha güçlü seçici kullandığı için !important. */
html body.anova-block-post .elementor-widget-theme-post-content {
	width: 100% !important;
	max-width: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.anova-post {
	--ap-primary: #1d2a5b;
	--ap-primary-dark: #14204a;
	--ap-accent: #fcbb02;
	--ap-accent-dark: #e3a802;
	--ap-ink: #111827;
	--ap-text: #4b5563;
	--ap-muted: #6b7280;
	--ap-line: #e5e7eb;
	--ap-soft: #f6f7fb;
	color: var(--ap-text);
	font-size: 16px;
	line-height: 1.75;
}
.anova-post *,
.anova-post *::before,
.anova-post *::after { box-sizing: border-box; }

.anova-post__grid {
	width: min(1200px, 100%);
	margin: 0 auto;
	padding: 32px 24px 72px; /* sitedeki kapsayıcıyla (anova-container: 1200px, 24px kenar) aynı hizada */
	display: grid;
	grid-template-columns: minmax(0, 1fr) 340px;
	gap: 40px;
	align-items: start;
}

/* Yazı kartı */
.anova-post__article {
	min-width: 0;
	background: #fff;
	border: 1px solid var(--ap-line);
	border-radius: 22px;
	box-shadow: 0 2px 8px rgba(17, 24, 39, 0.06);
	overflow: hidden;
}
.anova-post__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 18px;
	padding: 18px 48px;
	border-bottom: 1px solid var(--ap-line);
	font-size: 14px;
	line-height: 1.5;
	color: var(--ap-muted);
}
.anova-post__meta span { display: inline-flex; align-items: center; gap: 6px; }
.anova-post__meta svg { width: 16px; height: 16px; color: var(--ap-accent-dark); flex: 0 0 auto; }
.anova-post__image { margin: 0; }
.anova-post__image img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 8; object-fit: cover; border-radius: 0; }
.anova-post__image figcaption { padding: 10px 48px 0; font-size: 13px; color: var(--ap-muted); }

/* Yazı metni */
.anova-post__body { padding: 32px 48px 40px; }
.anova-post__body > :first-child { margin-top: 0; }
.anova-post__body > :last-child { margin-bottom: 0; }
html body .anova-post__body p { margin: 0 0 16px; }
html body .anova-post__body h2,
html body .anova-post__body h3,
html body .anova-post__body h4 { color: var(--ap-primary); font-weight: 800; letter-spacing: -0.02em; line-height: 1.3; scroll-margin-top: 110px; }
html body .anova-post__body h2 { font-size: 24px; margin: 34px 0 10px; }
html body .anova-post__body h3 { font-size: 19px; margin: 26px 0 8px; }
html body .anova-post__body h4 { font-size: 16px; margin: 20px 0 6px; }
html body .anova-post__body strong { color: #1f2937; }
html body .anova-post__body a { color: var(--ap-accent-dark); font-weight: 700; }
html body .anova-post__body a:hover { color: var(--ap-primary); }
.anova-post__body ul,
.anova-post__body ol { margin: 4px 0 18px; padding: 0; }
.anova-post__body ul { list-style: none; }
.anova-post__body ul > li { position: relative; padding-left: 22px; margin-bottom: 6px; }
.anova-post__body ul > li::before { content: ""; position: absolute; left: 2px; top: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--ap-accent-dark); }
.anova-post__body ol { padding-left: 22px; }
.anova-post__body ol > li { margin-bottom: 6px; padding-left: 4px; }
.anova-post__body ol > li::marker { color: var(--ap-accent-dark); font-weight: 700; }
.anova-post__body img { max-width: 100%; height: auto; border-radius: 14px; }
.anova-post__body figure { margin: 22px 0; }
.anova-post__body figcaption { margin-top: 8px; font-size: 13px; color: var(--ap-muted); text-align: center; }
.anova-post__body blockquote { margin: 22px 0; padding: 16px 20px; border-left: 4px solid var(--ap-accent); background: var(--ap-soft); border-radius: 0 12px 12px 0; color: #1f2937; }
.anova-post__body blockquote p:last-child { margin-bottom: 0; }
.anova-post__body .wp-block-table { margin: 22px 0; overflow-x: auto; }
.anova-post__body table { width: 100%; border-collapse: collapse; font-size: 15px; }
.anova-post__body th,
.anova-post__body td { padding: 10px 12px; border: 1px solid var(--ap-line); text-align: left; }
.anova-post__body th { background: var(--ap-soft); color: var(--ap-primary); }
.anova-post__body .anova-note { margin: 22px 0; padding: 16px 20px; border: 1px solid #fcd34d; border-left-width: 4px; border-radius: 12px; background: #fffbeb; }
.anova-post__body .anova-note p:last-child { margin-bottom: 0; }

/* SSS: Ayrıntılar (Details) blokları */
.anova-post__body details { margin: 0 0 12px; background: var(--ap-soft); border: 1px solid rgba(17, 24, 39, 0.06); border-radius: 14px; overflow: hidden; }
.anova-post__body details[open] { border-color: var(--ap-accent); background: #fff; }
.anova-post__body details summary { position: relative; padding: 18px 56px 18px 22px; color: #111; font-size: 16px; font-weight: 600; line-height: 1.5; cursor: pointer; list-style: none; }
.anova-post__body details summary::-webkit-details-marker { display: none; }
.anova-post__body details summary::after { content: "+"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); color: var(--ap-accent-dark); font-size: 24px; font-weight: 400; line-height: 1; transition: transform 200ms ease; }
.anova-post__body details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.anova-post__body details > :not(summary) { margin: 0; padding: 0 22px 18px; color: #666; font-size: 15px; line-height: 1.7; }

/* Anahtar kelimeler ve etiketler */
.anova-post__tags { margin: 0 48px; padding: 24px 0 32px; border-top: 1px solid var(--ap-line); display: grid; gap: 12px; }
.anova-post__tag-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.anova-post__tag-label { min-width: 132px; font-size: 13px; font-weight: 700; color: var(--ap-primary); }
.anova-post .anova-chip { display: inline-flex; align-items: center; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--ap-line); background: var(--ap-soft); color: var(--ap-primary); font-size: 13px; font-weight: 600; line-height: 1.4; text-decoration: none; }
.anova-post a.anova-chip:hover { border-color: var(--ap-accent); background: #fffbeb; color: var(--ap-primary); }
.anova-post .anova-chip--key { background: #fffbeb; border-color: #fcd34d; color: #92400e; }

/* Kenar çubuğu: yazı boyunca uzar ki en alttaki "Hızlı teklif" kutusu kaydırırken sabit kalabilsin. */
.anova-post__sidebar { display: grid; gap: 22px; min-width: 0; align-self: stretch; align-content: start; }
.anova-widget { background: #fff; border: 1px solid var(--ap-line); border-radius: 22px; padding: 22px; box-shadow: 0 2px 8px rgba(17, 24, 39, 0.06); }
.anova-widget__title { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; font-size: 16px; font-weight: 800; line-height: 1.3; color: var(--ap-primary); }
.anova-widget__title::before { content: ""; width: 4px; height: 16px; border-radius: 2px; background: var(--ap-accent); }
.anova-widget__note { margin: 0 0 12px; font-size: 14px; line-height: 1.5; }
.anova-widget__btns { display: grid; gap: 10px; position: relative; z-index: 1; }
html body .anova-post-btn { display: flex; align-items: center; justify-content: center; padding: 12px 18px; border-radius: 10px; font-size: 15px; font-weight: 700; line-height: 1.3; text-decoration: none; transition: transform 200ms, background 200ms; }
html body .anova-post-btn:hover { transform: translateY(-1px); }
html body .anova-post-btn--primary { background: var(--ap-accent); color: var(--ap-primary-dark); }
html body .anova-post-btn--primary:hover { background: var(--ap-accent-dark); color: var(--ap-primary-dark); }
html body .anova-post-btn--wa { background: #25d366; color: #fff; }
html body .anova-post-btn--wa:hover { background: #1ebe5b; color: #fff; }

.anova-widget--cta { position: relative; overflow: hidden; background: var(--ap-primary-dark); border: 0; color: #fff; }
.anova-widget--cta::after { content: ""; position: absolute; right: -60px; top: -60px; width: 180px; height: 180px; border-radius: 50%; background: rgba(252, 187, 2, 0.12); }
.anova-widget__badge { display: inline-block; margin-bottom: 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; color: var(--ap-accent); }
.anova-widget__heading { margin: 0 0 8px; font-size: 22px; font-weight: 800; line-height: 1.25; color: #fff; }
.anova-widget__text { margin: 0 0 16px; font-size: 14px; line-height: 1.6; color: rgba(255, 255, 255, 0.78); }
.anova-widget__checks { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 6px; font-size: 14px; line-height: 1.5; color: rgba(255, 255, 255, 0.9); }
.anova-widget__checks li::before { content: "✓"; margin-right: 8px; color: var(--ap-accent); font-weight: 800; }
html body .anova-widget__phone { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 14px; color: #fff; font-size: 15px; font-weight: 700; text-decoration: none; }
html body .anova-widget__phone:hover { color: var(--ap-accent); }
.anova-widget__phone svg { width: 18px; height: 18px; color: var(--ap-accent); }

.anova-widget--toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; display: grid; gap: 2px; }
.anova-widget--toc li { counter-increment: toc; }
html body .anova-widget--toc a { display: flex; gap: 10px; padding: 7px 8px; border-radius: 8px; color: var(--ap-text); font-size: 14px; line-height: 1.45; text-decoration: none; }
.anova-widget--toc a::before { content: counter(toc, decimal-leading-zero); padding-top: 1px; color: var(--ap-accent-dark); font-size: 12px; font-weight: 700; }
html body .anova-widget--toc a:hover,
html body .anova-widget--toc a.is-active { background: var(--ap-soft); color: var(--ap-primary); font-weight: 600; }

.anova-recent { display: grid; gap: 14px; }
html body .anova-recent a { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 12px; align-items: center; text-decoration: none; }
.anova-recent img { width: 76px; height: 60px; object-fit: cover; border-radius: 10px; }
.anova-recent strong { display: block; color: var(--ap-ink); font-size: 14px; font-weight: 700; line-height: 1.35; }
.anova-recent a:hover strong { color: var(--ap-accent-dark); }
.anova-recent time { font-size: 12px; color: var(--ap-muted); }

.anova-svc { display: grid; gap: 6px; }
html body .anova-svc a { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; border-radius: 10px; background: var(--ap-soft); color: var(--ap-primary); font-size: 14px; font-weight: 600; line-height: 1.4; text-decoration: none; }
html body .anova-svc a:hover { background: #fffbeb; color: var(--ap-primary); }
.anova-svc a::after { content: "→"; color: var(--ap-accent-dark); }

.anova-widget--sticky { position: sticky; top: 100px; }

/* Benzer yazılar */
.anova-post__related { background: var(--ap-soft); padding: 64px 0; }
.anova-post__related-inner { width: min(1200px, 100%); margin: 0 auto; padding: 0 24px; }
.anova-post__eyebrow { display: inline-flex; align-items: center; gap: 10px; color: var(--ap-accent-dark); font-size: 13px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.anova-post__eyebrow::before { content: ""; width: 18px; height: 2px; background: currentColor; }
.anova-post__related-title { margin: 6px 0 24px; color: var(--ap-ink); font-size: 28px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; }
.anova-post__related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
html body .anova-post-card { display: block; overflow: hidden; background: #fff; border: 1px solid var(--ap-line); border-radius: 22px; text-decoration: none; transition: transform 250ms, box-shadow 250ms; }
html body .anova-post-card:hover { transform: translateY(-4px); box-shadow: 0 25px 60px rgba(17, 24, 39, 0.12); }
.anova-post-card img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.anova-post-card__body { display: block; padding: 18px 20px 22px; }
.anova-post-card__body .anova-chip { padding: 3px 10px; font-size: 12px; }
.anova-post-card strong { display: block; margin: 10px 0 6px; color: var(--ap-ink); font-size: 17px; line-height: 1.35; }
.anova-post-card__more { font-size: 14px; font-weight: 700; color: var(--ap-accent-dark); }

@media (max-width: 1024px) {
	.anova-post__grid { grid-template-columns: minmax(0, 1fr); }
	.anova-post__sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.anova-widget--toc { display: none; }
	.anova-widget--sticky { position: static; }
	.anova-post__related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	.anova-post__grid { padding: 24px 16px 56px; }
	.anova-post__related-inner { padding: 0 16px; }
	.anova-post__meta { padding: 14px 20px; }
	.anova-post__image figcaption { padding: 10px 20px 0; }
	.anova-post__body { padding: 24px 20px 28px; }
	.anova-post__body h2 { font-size: 21px; }
	.anova-post__tags { margin: 0 20px; }
	.anova-post__tag-label { min-width: 100%; }
	.anova-post__sidebar { grid-template-columns: minmax(0, 1fr); }
	.anova-post__related { padding: 48px 0; }
	.anova-post__related-title { font-size: 24px; }
	.anova-post__related-grid { grid-template-columns: minmax(0, 1fr); }
	/* Tablolar mobilde sıkışmasın: doğal genişliğinde kalır, kutu içinde yana kaydırılır. */
	html body .anova-post__body .wp-block-table { -webkit-overflow-scrolling: touch; }
	html body .anova-post__body .wp-block-table table { min-width: 560px; table-layout: auto; font-size: 14px; }
}

/* Başlık altındaki tarih: bu yazılarda kartın bilgi satırında (yazar, tarih, okuma süresi) zaten var. */
.anova-block-post [data-id="3e63a0a3"] { display: none; }

/* Şablondaki ortak iletişim çağrısı (global sınıf "anova-post-cta") yalnızca WordPress editörüyle yazılan
   yazılarda görünür; Elementor ile yapılmış eski yazıların kendi iletişim çağrısı vardır. */
body:not(.anova-block-post) .anova-post-cta { display: none !important; }
