/* TR-ETS — Sustainable Green Theme
   Doğa tonları: orman yeşili, toprak kahve, gök mavisi vurgu */
:root {
  --accent: #2d6a4f;       /* orman yeşili — primary */
  --accent-light: #52b788;  /* açık yeşil — secondary */
  --accent-dark: #1b4332;   /* koyu yeşil — hover */
  --leaf: #95d5b2;          /* yaprak açık */
  --teal: #40916c;          /* su yeşili */
  --earth: #744210;         /* toprak — accent2 */
  --gold: #ca8a04;          /* hasat altını — score */
  --ink: #1b2d1d;           /* mürekkep koyu */
  --muted: #5c6f5c;         /* muted yeşil */
  --bg: #f0f7f0;            /* sayfa arka planı */
  --card: #ffffff;
  --border: #d8e2dc;        /* kart kenarlığı */
  --shadow: 0 1px 4px rgba(45, 106, 79, .12);
  --shadow-hover: 0 2px 8px rgba(45, 106, 79, .18);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: linear-gradient(180deg, #e8f3e8 0%, #f0f7f0 50%, #f0f7f0 100%);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
}
.wrap { max-width: 1180px; margin: 0 auto; padding: 18px; }
h1 {
  font-size: 28px; margin: 0 0 4px;
  background: linear-gradient(90deg, #2d6a4f 0%, #52b788 50%, #95d5b2 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  font-weight: 800; letter-spacing: -0.5px;
}
h4 { margin: 0; display: inline-block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }
.sub { color: var(--muted); margin-bottom: 12px; font-size: 14px; }

/* 🌿 Sürdürülebilirlik rozetleri */
.badge {
  display: inline-block;
  border-radius: 12px;
  padding: 3px 10px;
  margin-right: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.badge.live { background: linear-gradient(135deg, #2d6a4f, #52b788); }
.badge.real { background: linear-gradient(135deg, #40916c, #95d5b2); }
.badge.estimated { background: linear-gradient(135deg, #ca8a04, #eab308); }
.badge.synthetic { background: linear-gradient(135deg, #6b7280, #9ca3af); }

.banner {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7f0 100%);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 16px;
  font-size: 12.5px;
  box-shadow: var(--shadow);
}

.tabs {
  display: flex; flex-wrap: wrap; gap: 4px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 18px;
  padding: 4px 0 0 4px;
}
.tab {
  padding: 10px 16px;
  cursor: pointer; border: none; background: none;
  font-size: 14px; color: var(--muted);
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  border-radius: 8px 8px 0 0;
  transition: all .2s ease;
}
.tab:hover {
  background: rgba(149, 213, 178, .15);
  color: var(--accent);
}
.tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
  font-weight: 700;
  background: linear-gradient(180deg, rgba(149, 213, 178, .2) 0%, transparent 100%);
}

.row { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  box-shadow: var(--shadow);
  flex: 1; min-width: 150px;
  transition: box-shadow .2s ease;
}
.card:hover { box-shadow: var(--shadow-hover); }
.metric .t {
  font-size: 12px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.5px;
  font-weight: 600;
}
.metric .v {
  font-size: 26px; font-weight: 800;
  color: var(--accent);
  margin: 4px 0;
}
.metric .s { font-size: 11.5px; color: var(--muted); }
.headrow {
  display: flex; align-items: center; gap: 4px;
  margin: 4px 0 10px;
  font-weight: 600; color: var(--ink);
}
label { font-size: 13px; color: var(--ink); display: block; margin-bottom: 6px; }
input[type=range] { width: 100%; accent-color: var(--accent); }

.btn {
  background: linear-gradient(135deg, #2d6a4f, #40916c);
  color: #fff; border: none;
  border-radius: 7px;
  padding: 8px 16px;
  cursor: pointer; font-size: 14px;
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(45, 106, 79, .2);
  transition: all .2s ease;
}
.btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(45, 106, 79, .3);
}
.btn.ghost {
  background: #fff;
  color: var(--accent);
  border: 1.5px solid var(--accent);
  box-shadow: none;
}
.btn.ghost:hover { background: rgba(149, 213, 178, .1); }

.hidden { display: none !important; }
.graph { flex: 1; min-width: 280px; position: relative; }
/* Satırda tek grafik varsa tam genişlik kullan (yarım-boş satır kalmasın) */
.row > .graph:only-child { flex-basis: 100%; }
.note { color: var(--muted); font-size: 13px; line-height: 1.5; }
hr {
  border: none;
  border-top: 1px dashed var(--border);
  margin: 20px 0;
}

/* ⓘ baloncuk (tooltip) */
.help-tip { display: inline-block; position: relative; }
.help-tip-inline { margin-left: 5px; vertical-align: middle; }
.help-tip-abs { position: absolute; top: 6px; right: 10px; z-index: 60; }
.help-ico {
  display: inline-block;
  width: 18px; height: 18px; line-height: 18px;
  text-align: center; border-radius: 50%;
  background: var(--accent-light);
  color: #fff; font-size: 11px; font-weight: 700;
  cursor: help;
  transition: background .2s ease;
}
.help-tip:hover .help-ico { background: var(--accent); }
.help-bubble {
  visibility: hidden; opacity: 0;
  position: absolute; top: 26px;
  width: 340px; max-width: 78vw;
  background: var(--ink);
  color: #ecf0f1;
  padding: 12px 16px;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,.28);
  z-index: 200;
  transition: opacity .15s;
  font-size: 12.5px; line-height: 1.5;
  text-align: left; font-weight: 400;
}
.help-tip-abs .help-bubble { right: 0; }
.help-tip-inline .help-bubble { left: 0; }
.help-tip:hover .help-bubble { visibility: visible; opacity: 1; }
.help-bubble b { color: #95d5b2; }

.advice {
  background: linear-gradient(135deg, #ffffff 0%, #f6fcf6 100%);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent-light);
  border-radius: 10px;
  padding: 12px 22px;
  line-height: 1.6;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}
.advice b { color: var(--accent-dark); }
.advice code {
  background: var(--leaf);
  color: var(--accent-dark);
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 600;
}
.meth {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 24px;
  line-height: 1.6;
  box-shadow: var(--shadow);
}
.meth h4 { color: var(--accent-dark); }
.meth table { border-collapse: collapse; }
.meth td, .meth th {
  border: 1px solid var(--border);
  padding: 5px 9px;
  text-align: left;
}
.meth th { background: rgba(149, 213, 178, .15); color: var(--accent-dark); }

/* 🟢 canlı veri pill'leri */
.pill {
  font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 12px;
  background: linear-gradient(135deg, #d8f3dc, #b7e4c7);
  color: #1b4332;
  border: 1px solid #95d5b2;
}
.pill.off {
  background: linear-gradient(135deg, #fdecea, #fadbd8);
  color: #c0392b;
  border: 1px solid #e6b0aa;
}

/* 🌱 input renkleri */
input[type="number"] {
  padding: 5px 8px;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  font-size: 13px;
  background: #fafff9;
  color: var(--ink);
}
input[type="number"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(82, 183, 136, .2);
}

/* 🌍 sürdürülebilirlik rozeti (header'da) */
.eco-badge {
  display: inline-block;
  background: linear-gradient(135deg, #52b788, #95d5b2);
  color: #1b4332;
  font-size: 11px; font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  margin-left: 6px;
  vertical-align: middle;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Scrollbar (webkit) */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #e8f3e8; }
::-webkit-scrollbar-thumb {
  background: var(--accent-light);
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* Responsive */
@media (max-width: 768px) {
  h1 { font-size: 22px; }
  .row { flex-direction: column; }
  .card { min-width: 0; }
}
