:root {
  --bg: #0b0f12;
  --bg2: #070a0c;
  --panel: rgba(255, 255, 255, .06);
  --panel2: rgba(255, 255, 255, .08);
  --text: rgba(255, 255, 255, .92);
  --muted: rgba(255, 255, 255, .65);
  --muted2: rgba(255, 255, 255, .5);
  --brand: #2e7d32;
  /* yeşil */
  --brand2: #38b000;
  --border: rgba(255, 255, 255, .12);
  --shadow: 0 14px 60px rgba(0, 0, 0, .55);
  --radius: 14px;
  --radius2: 18px;
  --max: 980px;
  --input-bg: rgba(0, 0, 0, 0.3);
}

/* LIGHT MODE OVERRIDES */
html[data-theme="light"] {
  --bg: #f6f7f9;
  --bg2: #ffffff;
  --panel: rgba(0, 0, 0, .04);
  --panel2: rgba(0, 0, 0, .06);
  --text: rgba(0, 0, 0, .88);
  --muted: rgba(0, 0, 0, .60);
  --muted2: rgba(0, 0, 0, .45);
  --border: rgba(0, 0, 0, .10);
  --shadow: 0 14px 60px rgba(0, 0, 0, .12);
  --input-bg: #ffffff;
}

html[data-theme="light"] body {
  background: linear-gradient(180deg, #f6f7f9 0%, #eef0f2 100%);
  color: var(--text);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
  background: radial-gradient(1200px 700px at 50% 30%, rgba(56, 176, 0, .12), transparent 55%),
    radial-gradient(900px 500px at 70% 10%, rgba(46, 125, 50, .14), transparent 60%),
    linear-gradient(180deg, #070a0c 0%, #0b0f12 40%, #080b0d 100%);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
  width: auto;
  height: auto;
  padding: 10px 12px;
  background: #111820;
  border: 1px solid var(--border);
  border-radius: 10px;
  z-index: 9999;
}

header {
  padding: 18px 18px 0 18px;
}

/* Layout Wrapper for Homepage */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 18px;
}

/* Advertising Areas */
.ad-above-fold {
  width: 100%;
  max-width: 728px;
  height: 90px;
  margin: 20px auto;
  background: rgba(255, 255, 255, .02);
  border: 1px dashed var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 12px;
  border-radius: 8px;
}

@media (max-width: 768px) {
  .ad-above-fold {
    height: auto;
    padding: 10px;
  }
}

.topbar {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.brand-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: .06em;
  opacity: .9;
}

.brand-mini .dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--brand2);
  box-shadow: 0 0 0 4px rgba(56, 176, 0, .12);
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Header & Action Buttons Dark Mode Fixes */
.icon-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .05);
  border-radius: 10px;
  color: var(--muted);
  cursor: pointer;
}

html[data-theme="light"] .icon-btn {
  background: #f0f0f0;
  color: #333;
  border-color: #ddd;
}

.btn {
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .04);
  color: rgba(255, 255, 255, .88);
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  display: inline-flex;
  gap: 8px;
  align-items: center;
  transition: all 0.2s;
}

html[data-theme="light"] .btn {
  background: #eee;
  color: #333;
  border-color: #ccc;
}

.search input {
  background: rgba(255, 255, 255, 0.05) !important;
  color: var(--text) !important;
  border: 1px solid var(--border) !important;
  padding: 8px 12px;
  border-radius: 8px 0 0 8px;
}

html[data-theme="light"] .search input {
  background: #fff !important;
  color: #000 !important;
  border-color: #ccc !important;
}

.search button {
  background: var(--brand);
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 0 8px 8px 0;
  cursor: pointer;
}

/* Common Card Styling Fix for Dark/Light */
.card:hover {
  background: var(--panel2);
}

html[data-theme="light"] .card:hover {
  background: #fdfdfd;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.stats {
  margin-top: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

/* Hero & Search Section */
.hero {
  padding: 40px 0;
  text-align: center;
}

.logo-title {
  margin-bottom: 30px;
}

.logo-title .logo {
  width: 80px;
  height: 80px;
  background: var(--brand);
  color: white;
  margin: 0 auto 15px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 28px;
  box-shadow: 0 10px 30px rgba(46, 125, 50, .4);
}

.logo-title h1 {
  margin: 0 0 10px;
  font-size: 32px;
  letter-spacing: -0.02em;
}

.logo-title .subtitle {
  margin: 0;
  color: var(--muted);
}

.search-card {
  max-width: 600px;
  margin: 0 auto 30px;
  position: relative;
}

.search-row {
  display: flex;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  overflow: hidden;
}

.search-row input {
  flex: 1;
  padding: 16px 20px;
  border: none !important;
  background: var(--panel2) !important;
  color: var(--text) !important;
  font-size: 16px;
  border-radius: 0 !important;
}

.search-row button {
  width: 60px;
  border: none;
  background: var(--brand);
  color: white;
  cursor: pointer;
  font-size: 20px;
  border-radius: 0 !important;
}

.search-tools {
  margin-top: 10px;
  font-size: 14px;
  color: var(--muted2);
}

.cta-row {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 40px;
}

/* Son eklenen yazılar: tek satır 4 blok */
.latest {
  margin: 22px auto 0;
  width: min(920px, 100%);
}

.latest-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  color: rgba(255, 255, 255, .84);
}

.latest-head h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .02em;
}

.latest-head a {
  font-size: 13px;
  color: var(--muted);
}

.latest-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.card {
  display: block;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, .12);
  background: rgba(255, 255, 255, .03);
  overflow: hidden;
  min-height: 78px;
}

.card:hover {
  background: var(--panel2);
  border-color: var(--border);
}

.card .kicker {
  font-size: 12px;
  color: rgba(255, 255, 255, .58);
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card .title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: rgba(255, 255, 255, .9);
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* In-content ad (arama + latest sonrası) */
.ad-in-content {
  margin: 18px auto 0;
  width: min(920px, 100%);
  border: 1px dashed rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .02);
  border-radius: var(--radius);
  min-height: 250px;
  /* 300x250 responsive */
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted2);
  padding: 10px;
}

footer {
  margin-top: 26px;
  padding: 22px 18px 34px;
  color: rgba(255, 255, 255, .6);
  font-size: 13px;
  text-align: center;
}

footer .links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

footer .links a {
  padding: 6px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, .10);
  background: rgba(255, 255, 255, .02);
  color: rgba(255, 255, 255, .65);
}

footer .links a:hover {
  background: rgba(255, 255, 255, .06);
}

/* Responsive */
@media (max-width: 900px) {
  .latest-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  .logo {
    width: 58px;
    height: 58px;
    border-radius: 16px;
  }

  .logo span {
    font-size: 24px;
  }

  .latest-grid {
    grid-template-columns: 1fr;
  }

  .top-actions {
    gap: 8px;
  }
}