/*
Theme Name: Erzincan Haber Ozel
Theme URI: https://erzincanhaber.net/
Author: Codex
Description: Erzincan Haber icin ozgun, hizli ve sade haber temasi.
Version: 1.0.0
Text Domain: erz-haber
*/

:root {
  --ink: #151719;
  --muted: #66707a;
  --line: #d9dee4;
  --paper: #ffffff;
  --soft: #f4f6f8;
  --brand: #b61022;
  --brand-dark: #7d0714;
  --accent: #0f766e;
  --gold: #c58b1a;
  --radius: 6px;
  --shadow: 0 10px 28px rgba(20, 24, 30, .08);
  --max: 1180px;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}
body.dark-mode {
  --ink: #edf1f5;
  --muted: #a9b2bd;
  --line: #2b333d;
  --paper: #101418;
  --soft: #171d23;
  background: var(--paper);
}
a { color: inherit; text-decoration: none; }
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--brand), #fff 24%);
  outline-offset: 3px;
}
img { display: block; max-width: 100%; height: auto; }
.wrap { width: min(var(--max), calc(100% - 32px)); margin: 0 auto; }

.topline {
  background: var(--ink);
  color: #fff;
  font-size: 13px;
}
.topline .wrap {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 0;
  align-items: center;
  overflow-x: auto;
  white-space: nowrap;
}
.live-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 900;
}
.live-dot:before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #19c37d;
}
.mode-toggle {
  border: 1px solid rgba(255,255,255,.22);
  background: transparent;
  color: inherit;
  min-width: 34px;
  height: 28px;
  cursor: pointer;
}
.masthead {
  border-bottom: 1px solid var(--line);
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 20;
  transition: box-shadow .18s ease, transform .18s ease;
}
body.dark-mode .masthead,
body.dark-mode .nav { background: var(--paper); }
.masthead.is-compact { box-shadow: var(--shadow); }
.masthead.is-compact .masthead-inner { padding: 12px 0; }
.masthead-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0 18px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: 0;
}
.brand-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: #fff;
  font-weight: 900;
  border-radius: var(--radius);
}
.custom-logo { max-width: 190px; max-height: 56px; width: auto; height: auto; }
.brand-text strong {
  display: block;
  font-size: 30px;
  line-height: 1;
}
.brand-text span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}
.search-form {
  display: flex;
  width: min(360px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.search-form input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 11px 12px;
  font: inherit;
}
.search-form button {
  border: 0;
  background: var(--ink);
  color: #fff;
  padding: 0 16px;
  font-weight: 800;
  cursor: pointer;
}
.nav {
  border-bottom: 3px solid var(--brand);
  background: #fff;
}
.nav .menu,
.nav ul {
  display: flex;
  gap: 2px;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
}
.nav a {
  display: block;
  padding: 13px 14px;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}
.nav a:hover { background: var(--soft); color: var(--brand); }

.ticker {
  border-bottom: 1px solid var(--line);
  background: var(--soft);
}
.ticker .wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 0;
}
.ticker-label {
  background: var(--brand);
  color: #fff;
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 900;
  border-radius: 3px;
}
.ticker-text {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.main { padding: 28px 0 44px; }
.grid-home {
  display: grid;
  grid-template-columns: 1.35fr .85fr;
  gap: 24px;
}
.lead-card {
  min-height: 430px;
  position: relative;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.lead-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .82;
}
.lead-card:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.78), rgba(0,0,0,.05));
}
.lead-body {
  position: relative;
  z-index: 1;
  color: #fff;
  padding: 28px;
}
.kicker {
  display: inline-block;
  margin-bottom: 9px;
  color: #fff;
  background: var(--brand);
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 900;
  border-radius: 3px;
}
.kicker.small {
  margin: 0;
  justify-self: start;
  font-size: 11px;
}
.lead-body h1,
.lead-body h2 {
  margin: 0;
  font-size: 36px;
  line-height: 1.08;
}
.lead-body p { max-width: 680px; margin: 12px 0 0; color: #e8ecef; }

.side-stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.mini-card,
.post-card {
  border-bottom: 1px solid var(--line);
  background: #fff;
  transition: transform .16s ease, box-shadow .16s ease;
}
body.dark-mode .mini-card,
body.dark-mode .post-card { background: var(--paper); }
.mini-card:hover,
.post-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.mini-card a,
.post-card a { display: grid; gap: 10px; }
.mini-card img,
.post-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--soft);
  border-radius: var(--radius);
}
.mini-card h3,
.post-card h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.22;
}
.post-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.meta {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}
.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 34px 0 16px;
  font-size: 22px;
  line-height: 1.15;
}
.section-title:after {
  content: "";
  height: 3px;
  flex: 1;
  background: var(--line);
}
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.archive-layout,
.single-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 34px;
}
.archive-list {
  display: grid;
  gap: 22px;
}
.archive-item {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 18px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}
.archive-item img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}
.archive-item h2 { margin: 0 0 8px; font-size: 24px; line-height: 1.18; }
.archive-item p { margin: 0; color: var(--muted); }
.single h1 {
  margin: 0 0 12px;
  font-size: 42px;
  line-height: 1.08;
}
.dek {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 21px;
}
.article-tools,
.share-row,
.post-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}
.article-tools button,
.share-row a,
.post-nav a,
.newsletter button {
  border: 1px solid var(--line);
  background: var(--soft);
  color: var(--ink);
  padding: 8px 10px;
  border-radius: var(--radius);
  font-weight: 800;
  cursor: pointer;
}
.share-row {
  margin-top: 10px;
  border-top: 0;
}
.single .featured { margin: 24px 0; }
.single .featured img { width: 100%; border-radius: var(--radius); }
.content {
  font-size: 18px;
}
.content p { margin: 0 0 18px; }
.content table {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0;
}
.content th,
.content td {
  border: 1px solid var(--line);
  padding: 10px;
}
.content blockquote {
  margin: 24px 0;
  padding-left: 18px;
  border-left: 4px solid var(--brand);
  color: var(--muted);
}
.toc {
  margin: 22px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--soft);
}
.toc ol { margin: 10px 0 0; }
.tags { margin-top: 24px; color: var(--muted); font-weight: 800; }
.author-box {
  margin-top: 24px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--soft);
}
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--brand);
  z-index: 50;
}
.sidebar {
  border-left: 1px solid var(--line);
  padding-left: 22px;
}
.widget {
  margin-bottom: 28px;
}
.newsletter {
  padding: 16px;
  background: var(--soft);
  border-radius: var(--radius);
}
.newsletter form { display: grid; gap: 8px; }
.newsletter input {
  width: 100%;
  border: 1px solid var(--line);
  padding: 10px;
  border-radius: var(--radius);
}
.widget h3 {
  margin: 0 0 12px;
  padding-bottom: 9px;
  border-bottom: 3px solid var(--brand);
  font-size: 18px;
}
.widget ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.widget li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}
.pagination {
  margin-top: 28px;
  display: flex;
  gap: 8px;
}
.page-numbers {
  padding: 8px 12px;
  border: 1px solid var(--line);
  font-weight: 800;
}
.page-numbers.current {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.footer {
  background: var(--ink);
  color: #fff;
  padding: 28px 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 28px;
  color: #c9d0d6;
  font-size: 14px;
}
.footer h3 { color: #fff; margin: 0 0 10px; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin: 0 0 8px; }
.copyright {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.13);
  color: #c9d0d6;
}
.ad {
  min-height: 70px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  color: var(--muted);
}
.mobile-bottom { display: none; }
.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 78px;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  box-shadow: var(--shadow);
  cursor: pointer;
  display: none;
  z-index: 30;
}
.back-to-top.is-visible { display: block; }

@media (max-width: 860px) {
  .masthead-inner,
  .topline .wrap,
  .footer .wrap { align-items: flex-start; }
  .search-form { width: 100%; }
  .grid-home,
  .archive-layout,
  .single-layout { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .archive-item { grid-template-columns: 1fr; }
  .sidebar { border-left: 0; padding-left: 0; }
  .lead-card { min-height: 360px; }
  .lead-body h1,
  .lead-body h2,
  .single h1 { font-size: 31px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .mobile-bottom {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--line);
    z-index: 40;
  }
  .mobile-bottom a,
  .mobile-bottom button {
    display: grid;
    place-items: center;
    min-height: 50px;
    border: 0;
    background: var(--paper);
    color: var(--ink);
    font-weight: 900;
  }
  body { padding-bottom: 50px; }
}

@media (max-width: 560px) {
  .wrap { width: min(var(--max), calc(100% - 24px)); }
  .post-grid { grid-template-columns: 1fr; }
  .brand-text strong { font-size: 24px; }
  .lead-body { padding: 20px; }
  .lead-body h1,
  .lead-body h2,
  .single h1 { font-size: 27px; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media print {
  .topline, .masthead, .nav, .ticker, .sidebar, .footer, .mobile-bottom, .share-row, .article-tools { display: none !important; }
  body { color: #000; background: #fff; padding: 0; }
  .single-layout { display: block; }
}
