/* Livestock › poultry house control film (Faz 2 plan §5.4, §13.6 T4): this page only, after site.css,
   livestock-site.css and livestock-tools.css. Ported from the prototype's kontrol-filmi.css (design only); new classes
   keep the "kf-" prefix. Gold (site accent) only on the lighting programme; the lime accent only on the film's hour
   and the chosen item; stage colours only in this tool's drawing. */
.kf-pencere {
  --kf-isitma: #c97a52;
  --kf-minimum: #2c4239;
  --kf-gecis: #2f7a62;
  --kf-tunel: #42d39c;
  --kf-ped: #2fa8c9;
  --kf-bos: #0d1d18;
  --kf-cam: rgba(7, 18, 15, 0.66);
  --kf-gold: var(--ls-gold, #e0b84a);
  --kf-hot: #f0a46a;
  --kf-day: #f0d660;
}

/* ---------- Hero: başlık ve giriş tek satırda, pencere hemen altında ---------- */
.kf-hero { padding-top: clamp(28px, 3.4vw, 48px); padding-bottom: clamp(56px, 7vw, 96px); }

/* ---------- Pencere ---------- */
.kf-pencere { box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255, 255, 255, 0.08); }
.kf-pencere .aw-title { display: inline-flex; align-items: baseline; gap: 0; }
.kf-yer { font-weight: 600; color: #a9bbb3; }
.kf-yer:not(:empty)::before { content: '·'; margin: 0 8px; color: #6b7a74; }
.kf-pencere > .aw-body { padding: 18px; display: grid; gap: 16px; }
.kf-duzen { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 330px); grid-template-areas: 'film girdi' 'plan girdi'; gap: 18px; align-items: start; }
.kf-film { grid-area: film; min-width: 0; }
.kf-plan { grid-area: plan; min-width: 0; }
.kf-girdiler { grid-area: girdi; display: grid; gap: 14px; min-width: 0; }
.kf-senaryo { margin-top: 12px; font-size: 0.8rem; color: var(--ar-yazi-3); }
@media (max-width: 1100px) { .kf-duzen { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'film' 'girdi' 'plan'; } .kf-girdiler { grid-template-columns: repeat(2, minmax(0, 1fr)); } .kf-girdiler > .ar-giris { grid-row: span 2; } }
@media (max-width: 760px) { .kf-girdiler { grid-template-columns: minmax(0, 1fr); } .kf-girdiler > .ar-giris { grid-row: auto; } }
@media (max-width: 560px) { .kf-pencere > .aw-body { padding: 12px; gap: 12px; } .kf-pencere .aw-bar { gap: 8px; padding: 0 12px; } .kf-pencere .aw-badge + .aw-badge { margin-left: 6px; } .kf-pencere .win-brand { display: none; } }
@media (max-width: 420px) { .kf-pencere .aw-dots { display: none; } .kf-yer { display: none; } }

/* ---------- Sahne: tuval, üst bilgi, katmanlar ---------- */
.kf-sahne-kap { position: relative; }
.kf-sahne { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #07120f; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08); isolation: isolate; }
.kf-sahne canvas { position: absolute; inset: 0; z-index: 0; display: block; width: 100%; height: 100%; }
.kf-sahne::after { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), inset 0 -60px 80px -60px rgba(3, 9, 7, 0.65); }
.kf-hud { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.kf-hud-sol { position: absolute; top: 12px; left: 12px; padding: 10px 13px 11px; border-radius: 11px; background: var(--kf-cam); border: 1px solid rgba(255, 255, 255, 0.1); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.kf-hud-sahne { display: flex; align-items: baseline; gap: 8px; margin: 0; font-size: 0.7rem; color: #a9bbb3; }
.kf-hud-sahne span { font-weight: 700; letter-spacing: 0.06em; font-variant-numeric: tabular-nums; }
.kf-hud-sahne b { font-size: 0.78rem; font-weight: 750; letter-spacing: 0.01em; color: #fff; }
.kf-hud-saat { display: flex; align-items: center; gap: 8px; margin: 4px 0 0; font-size: 1.7rem; font-weight: 750; letter-spacing: -0.02em; line-height: 1; color: #fff; font-variant-numeric: tabular-nums; }
.kf-hud-saat::before { content: ''; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(216, 243, 106, 0.18); }
.kf-hud-gun { margin: 6px 0 0; font-size: 0.74rem; color: #c9d8d1; }
.kf-hud-sag { position: absolute; top: 12px; right: 12px; display: grid; gap: 6px; justify-items: end; }

/* Hava (sahnenin sağ üstü) ve sistemler (sahnenin altında, gösterge şeridi) */
.kf-hud-sag { min-width: 150px; padding: 8px 12px 9px; border-radius: 11px; background: var(--kf-cam); border: 1px solid rgba(255, 255, 255, 0.1); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); gap: 3px; justify-items: stretch; }
.kf-hud-sag p { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin: 0; font-size: 0.74rem; color: #a9bbb3; }
.kf-hud-sag p b { font-size: 0.9rem; font-weight: 750; color: #fff; font-variant-numeric: tabular-nums; }
.kf-hud-sag .kf-hava-ust { justify-content: flex-end; margin-bottom: 2px; }
.kf-hud-sag .ar-rozet { height: 18px; padding: 0 6px; font-size: 0.56rem; }
.kf-sis { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); margin: 10px 0 0; border-radius: 12px; background: var(--ar-kutu); border: 1px solid var(--ar-cizgi); overflow: hidden; }
.kf-sis:empty { display: none; }
.kf-sis > div { min-width: 0; padding: 9px 11px 10px; border-left: 1px solid var(--ar-cizgi); }
.kf-sis > div:first-child { border-left: 0; }
.kf-sis dt { display: flex; align-items: center; gap: 6px; font-size: 0.68rem; line-height: 1.25; color: #a9bbb3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kf-sis dt::before { content: ''; flex: none; width: 6px; height: 6px; border-radius: 50%; background: #3a4d46; transition: background-color var(--dur-2) var(--ease); }
.kf-sis dt.is-acik::before { background: var(--brand-mint); box-shadow: 0 0 0 3px rgba(66, 211, 156, 0.16); }
.kf-sis dt.is-isik::before { background: var(--kf-gold); box-shadow: 0 0 0 3px var(--site-accent-soft, rgba(224, 184, 74, 0.18)); }
.kf-sis dt.is-isi::before { background: var(--kf-isitma); box-shadow: 0 0 0 3px rgba(201, 122, 82, 0.2); }
.kf-sis dt.is-ped::before { background: var(--kf-ped); box-shadow: 0 0 0 3px rgba(47, 168, 201, 0.2); }
.kf-sis dd { margin: 4px 0 0; font-size: 0.86rem; font-weight: 700; line-height: 1.2; color: #fff; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kf-sis dd small { display: block; margin-top: 2px; font-size: 0.7rem; font-weight: 600; color: #a9bbb3; }
@media (max-width: 1240px) and (min-width: 1101px) { .kf-sis { grid-template-columns: repeat(4, minmax(0, 1fr)); } .kf-sis > div:nth-child(5) { border-left: 0; } .kf-sis > div:nth-child(n + 5) { border-top: 1px solid var(--ar-cizgi); } }

/* Katmanlar: tahmin grafiği ve plan özeti, sahnenin üstünde */
.kf-katman { position: absolute; inset: 0; z-index: 4; display: grid; align-content: center; padding: clamp(14px, 3vw, 34px); background: rgba(5, 13, 10, 0.8); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); opacity: 0; visibility: hidden; transition: opacity var(--dur-3) var(--ease), visibility var(--dur-3); }
.kf-katman.is-acik { opacity: 1; visibility: visible; }
.kf-katman-ust { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; margin-bottom: 10px; }
.kf-katman-ust p { margin: 0; font-size: 0.74rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brand-mint); }
.kf-katman svg { display: block; width: 100%; height: auto; overflow: visible; }
.kf-katman .chart .kf-cubuk { transform-box: fill-box; transform-origin: 50% 100%; transform: scaleY(0.02); transition: transform 700ms var(--ease); }
.kf-katman.is-acik .chart .kf-cubuk { transform: none; }
.kf-katman .chart .kf-cubuk.is-sicak { filter: saturate(1.25); }
.kf-katman .chart .kf-hafta-y { fill: var(--kf-hot); font-size: 10.5px; font-weight: 700; }
.kf-katman .chart .kf-hafta { fill: none; stroke: rgba(240, 164, 106, 0.75); stroke-width: 1.4; }
.kf-katman .chart .kf-im { fill: #fff; font-size: 10.5px; font-weight: 700; }
.kf-katman .chart .kf-im-ok { fill: #fff; }
.kf-ozet { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 0; margin: 0; }
.kf-ozet > div { padding: 0 18px; border-left: 1px solid rgba(255, 255, 255, 0.12); min-width: 0; }
.kf-ozet > div:nth-child(3n + 1) { padding-left: 0; border-left: 0; }
.kf-ozet dt { font-size: 0.74rem; line-height: 1.3; color: #a9bbb3; }
.kf-ozet dd { margin: 5px 0 0; font-size: clamp(1.25rem, 2.4vw, 2rem); font-weight: 750; letter-spacing: -0.02em; line-height: 1.1; color: #fff; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kf-ozet dd small { margin-left: 5px; font-size: 0.45em; font-weight: 600; letter-spacing: 0; color: #a9bbb3; }
.kf-ozet-not { margin: 16px 0 0; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, 0.12); font-size: 0.8rem; color: #c9d8d1; }
.kf-sahne-durum { position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; margin: 0; padding: 20px; text-align: center; font-size: 0.86rem; color: var(--ar-yazi-2); background: rgba(7, 18, 15, 0.7); }
.kf-sahne-durum[hidden] { display: none; }

/* ---------- Zaman çizelgesi: düğmeler ve yedi sahne ---------- */
.kf-zaman { display: flex; align-items: center; gap: 14px; margin-top: 12px; }
.kf-zaman[hidden] { display: none; }
.kf-dugmeler { display: flex; gap: 6px; flex: none; }
.kf-btn { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(255, 255, 255, 0.04); color: #eef4f0; cursor: pointer; transition: background-color var(--dur-1) var(--ease), border-color var(--dur-1) var(--ease); }
.kf-btn:hover { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.3); }
.kf-btn svg { width: 16px; height: 16px; }
.kf-oynat { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.kf-oynat:hover { background: #e6fa95; border-color: #e6fa95; }
.kf-oynat .kf-i-dur, .kf-oynat[aria-pressed='true'] .kf-i-oynat { display: none; }
.kf-oynat[aria-pressed='true'] .kf-i-dur { display: block; }
.kf-noktalar { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; flex: 1; min-width: 0; margin: 0; padding: 0; list-style: none; }
.kf-noktalar button { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 2px 7px; width: 100%; height: 100%; min-height: 44px; padding: 5px 8px 8px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: #a9bbb3; font: inherit; text-align: left; cursor: pointer; transition: background-color var(--dur-1) var(--ease), color var(--dur-1) var(--ease); }
.kf-noktalar button:hover { background: rgba(255, 255, 255, 0.05); color: #fff; }
.kf-no { font-size: 0.7rem; font-weight: 800; font-variant-numeric: tabular-nums; color: #6f8279; }
.kf-ad { display: -webkit-box; overflow: hidden; font-size: 0.72rem; font-weight: 650; line-height: 1.18; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.kf-ilerleme { position: absolute; left: 8px; right: 8px; bottom: 4px; height: 2px; border-radius: 1px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.kf-ilerleme::after { content: ''; position: absolute; inset: 0; transform-origin: 0 50%; transform: scaleX(var(--p, 0)); background: var(--brand-mint); }
.kf-noktalar li.is-gecti .kf-ilerleme::after { transform: scaleX(1); opacity: 0.55; }
.kf-noktalar li.is-etkin button { background: rgba(216, 243, 106, 0.07); border-color: rgba(216, 243, 106, 0.32); color: #fff; }
.kf-noktalar li.is-etkin .kf-no { color: var(--accent); }
.kf-noktalar li.is-etkin .kf-ilerleme::after { background: var(--accent); }
.kf-btn:focus-visible, .kf-noktalar button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.kf-altyazi { min-height: 4.4em; margin: 12px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--ar-kutu); border: 1px solid var(--ar-cizgi); font-size: 0.9rem; line-height: 1.55; color: #dbe7e1; }
.kf-altyazi:empty { display: none; }
.kf-altyazi b { color: #fff; }

/* ---------- Plan ızgarası: 15 gün × 24 saat ---------- */
.kf-izgara { position: relative; touch-action: pan-y; }
.kf-izgara svg { display: block; width: 100%; height: auto; }
.kf-izgara .kf-hucre { shape-rendering: crispEdges; }
.kf-izgara .kf-gl { fill: #c9d8d1; font-size: 11px; font-weight: 650; }
.kf-izgara .kf-gl.is-sicak { fill: #f6c39a; }
.kf-izgara .kf-tx { fill: #8fa59c; font-size: 10.5px; font-weight: 650; text-anchor: end; }
.kf-izgara .kf-tx.is-sicak { fill: #f6c39a; }
.kf-izgara .kf-ax { fill: #8a9b93; font-size: 10.5px; }
.kf-izgara .kf-isik { fill: var(--kf-gold); }
.kf-izgara .kf-isik-dim { fill: var(--kf-gold); fill-opacity: 0.45; }
.kf-izgara .kf-tasma { fill: url(#kf-tarama); }
.kf-izgara .kf-gece-ciz { stroke: rgba(255, 255, 255, 0.06); stroke-width: 1; }
.kf-izgara .kf-hafta-ciz { stroke: rgba(240, 164, 106, 0.8); stroke-width: 2; stroke-linecap: round; }
.kf-izgara .kf-imlec { stroke: var(--accent); stroke-width: 2; stroke-linecap: round; }
.kf-izgara .kf-satir-sec { fill: none; stroke: rgba(216, 243, 106, 0.55); stroke-width: 1.2; }
.kf-izgara .kf-isaret { fill: none; stroke: #fff; stroke-width: 1.5; }
.kf-lejant { gap: 6px 14px; }
.kf-k-gun::before { background-color: rgba(240, 214, 96, 0.12) !important; background-image: repeating-linear-gradient(45deg, var(--kf-day) 0 1.5px, transparent 1.5px 4px) !important; }
.kf-okuma { min-height: 1.5em; margin: 10px 0 0; font-size: 0.82rem; line-height: 1.5; color: var(--ar-yazi-2); }
.kf-okuma b { color: #fff; font-weight: 700; }

/* Kartlar: altı değer */
.kf-kartlar { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.kf-kartlar .ar-kart dt { align-items: flex-start; }
.kf-kartlar .ar-kart dt .ar-rozet { height: 18px; padding: 0 6px; font-size: 0.55rem; }
.kf-kartlar .ar-kart.is-ana .ar-alt { font-size: 0.76rem; font-weight: 500; letter-spacing: 0; }
@media (max-width: 1180px) { .kf-kartlar { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .kf-kartlar { grid-template-columns: repeat(2, minmax(0, 1fr)); } .kf-kartlar .ar-kart dt { flex-direction: column; align-items: flex-start; gap: 5px; } }

.kf-tablo { margin-top: 0; }
.kf-tablo .ar-tablo td.is-sicak { color: #f6c39a; }
.kf-lisans { margin: -6px 0 0; font-size: 0.74rem; color: var(--ar-yazi-3); }
.kf-noscript { margin: 0; font-size: 0.86rem; color: #ffd2b0; }

/* ---------- Sayfa bölümleri ---------- */
.kf-oku-iki { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(24px, 4vw, 64px); margin-top: clamp(36px, 4vw, 56px); }
.kf-oku-iki .h3 { margin: 0 0 12px; }
@media (max-width: 860px) { .kf-oku-iki { grid-template-columns: minmax(0, 1fr); } }
.kf-sahne-tablo tbody th { width: 15rem; white-space: nowrap; }
.kf-sahne-tablo td { color: var(--fg-2); }
.kf-sahne-tablo td:last-child, .kf-etiket-tablo td:last-child { width: 1%; white-space: nowrap; }
.kf-sahne-tablo .tags, .kf-etiket-tablo .tags { flex-wrap: nowrap; }
.kf-etiket-tablo td:first-child { color: var(--fg-2); }
.kf-not { margin: 24px 0 0; max-width: 80ch; }
@media (max-width: 720px) {
  .kf-sahne-tablo tbody th { width: auto; white-space: normal; }
  .kf-sahne-tablo td:last-child, .kf-etiket-tablo td:last-child { width: auto; }
  .kf-sahne-tablo .tags, .kf-etiket-tablo .tags { flex-wrap: wrap; }
  .table-stack.kf-sahne-tablo td[data-k='Etiket']::before, .table-stack.kf-etiket-tablo td[data-k='Etiket']::before { display: block; margin-bottom: 4px; }
}

/* ---------- Telefon ---------- */
@media (max-width: 760px) {
  .kf-sahne { aspect-ratio: 4 / 3; }
  .kf-hud-sol { top: 8px; left: 8px; padding: 7px 10px 8px; }
  .kf-hud-saat { font-size: 1.25rem; }
  .kf-hud-gun { display: none; }
  .kf-hud-sag { top: 8px; right: 8px; min-width: 0; padding: 6px 9px 7px; }
  .kf-hud-sag p:nth-child(n + 3), .kf-hud-sag .kf-hava-ust { display: none; }
  .kf-hud-sag p { gap: 8px; font-size: 0.66rem; }
  .kf-hud-sag p b { font-size: 0.8rem; }
  .kf-sis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kf-sis > div:nth-child(3n + 1) { border-left: 0; }
  .kf-sis > div:nth-child(n + 4) { border-top: 1px solid var(--ar-cizgi); }
  .kf-sis > div:last-child { grid-column: 1 / -1; border-left: 0; }
  .kf-sis > div:last-child dd small { display: inline; margin-left: 8px; }
  .kf-zaman { flex-wrap: wrap; gap: 10px; }
  .kf-noktalar { flex-basis: 100%; order: 2; gap: 4px; }
  .kf-noktalar button { grid-template-columns: minmax(0, 1fr); justify-items: center; min-height: 36px; padding: 4px 2px 8px; }
  .kf-ad { display: none; }
  .kf-no { font-size: 0.78rem; }
  .kf-ozet { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 0; }
  .kf-ozet > div { padding: 0 12px; }
  .kf-ozet > div:nth-child(3n + 1) { padding-left: 12px; border-left: 1px solid rgba(255, 255, 255, 0.12); }
  .kf-ozet > div:nth-child(2n + 1) { padding-left: 0; border-left: 0; }
  .kf-ozet > div:nth-child(n + 5) { display: none; }
  .kf-ozet-not { display: none; }
  .kf-katman-ust { margin-bottom: 4px; }
  .kf-katman-ust p { font-size: 0.64rem; }
  .kf-katman { padding: 10px 12px; }
}
@media (max-width: 480px) {
  .kf-sis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kf-sis > div:nth-child(n) { border-left: 1px solid var(--ar-cizgi); }
  .kf-sis > div:nth-child(2n + 1) { border-left: 0; }
  .kf-sis > div:nth-child(n + 3) { border-top: 1px solid var(--ar-cizgi); }
  .kf-sis > div { padding: 8px 10px 9px; }
}

@media (prefers-reduced-motion: reduce) {
  .kf-katman, .kf-katman .chart .kf-cubuk { transition: none; }
  .kf-sis dt::before { transition: none; }
}
