/* FizikRehberi — ortak stil */
:root {
  --bg: #ebe3cf;
  --panel: #f4eee0;
  --ink: #1f1d18;
  --muted: #6e6754;
  --line: #d2c7ac;
  --grid: rgba(70, 55, 25, .07);
  --accent: #1f5c7a;
  --accent-2: #a8432a;
  --ok: #2f7d4f;
  --radius: 6px;
  --sans: "Instrument Sans", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #101214; --panel: #16191c; --ink: #e9e7e0; --muted: #8c8a83;
    --line: #2a2e33; --grid: rgba(255, 255, 255, .035);
    --accent: #7db9d8; --accent-2: #e0835f; --ok: #5cc98a; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #101214; --panel: #16191c; --ink: #e9e7e0; --muted: #8c8a83;
  --line: #2a2e33; --grid: rgba(255, 255, 255, .035);
  --accent: #7db9d8; --accent-2: #e0835f; --ok: #5cc98a; color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background-color: var(--bg);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
.mono { font-family: var(--mono); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* Üst bar */
.bar {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.bar .wrap { display: flex; align-items: center; gap: 24px; height: 56px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; letter-spacing: -.01em; }
.logo svg { width: 22px; height: 22px; }
.logo em { font-style: normal; color: var(--accent); }
.bar nav { display: flex; gap: 20px; margin-left: auto; font-size: 14px; }
.bar .icon-btn { margin-left: auto; }
.bar nav + .icon-btn { margin-left: 0; }
.bar nav a { text-decoration: none; color: var(--muted); }
.bar nav a:hover { color: var(--ink); }
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: var(--ink); cursor: pointer;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 16px; height: 16px; }

/* Etiket stili: laboratuvar defteri */
.tag {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted);
}

/* Ana sayfa */
.hero { display: grid; grid-template-columns: 1fr 1.15fr; gap: 48px; align-items: center; padding: 72px 0 56px; }
.hero h1 { font-size: clamp(36px, 5.2vw, 60px); line-height: 1.02; letter-spacing: -.035em; margin: 14px 0 18px; font-weight: 600; }
.hero p { color: var(--muted); font-size: 17px; max-width: 42ch; margin: 0 0 28px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px;
  border: 1px solid var(--ink); border-radius: var(--radius);
  background: var(--ink); color: var(--bg); text-decoration: none; font-weight: 500; font-size: 14px;
  transition: transform .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--ink); }
.btns { display: flex; gap: 10px; flex-wrap: wrap; }

.scope { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.scope-head, .scope-foot {
  display: flex; justify-content: space-between; padding: 8px 12px;
  font-family: var(--mono); font-size: 11px; color: var(--muted);
}
.scope-head { border-bottom: 1px solid var(--line); }
.scope-foot { border-top: 1px solid var(--line); }
.scope canvas { display: block; width: 100%; height: 300px; cursor: crosshair; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); margin-right: 6px; animation: blink 2s infinite; }
@keyframes blink { 50% { opacity: .3; } }

/* Ders bölümleri */
.course { padding: 40px 0; border-top: 1px solid var(--line); }
.course-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.course-head h2 { font-size: 28px; letter-spacing: -.02em; margin: 4px 0 0; font-weight: 600; }
.course-head .count { font-family: var(--mono); font-size: 13px; color: var(--muted); }

.weeks { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.week {
  display: grid; grid-template-columns: 64px 1fr auto; gap: 16px; align-items: center;
  padding: 14px 16px; border-top: 1px solid var(--line);
  opacity: 0; transform: translateY(6px); animation: rise .5s forwards;
}
.week:first-child { border-top: 0; }
@keyframes rise { to { opacity: 1; transform: none; } }
.week .no { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.week .topic { font-size: 15px; }
.sims { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.chip {
  font-family: var(--mono); font-size: 12px; padding: 4px 10px; border-radius: 999px;
  border: 1px dashed var(--line); color: var(--muted); white-space: nowrap; text-decoration: none;
}
a.chip { border-style: solid; border-color: var(--ink); color: var(--ink); }
a.chip:hover { background: var(--ink); color: var(--panel); }
a.chip::before { content: "▸ "; }

footer { padding: 32px 0 48px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }

/* Simülasyon sayfası */
.sim-layout { display: grid; grid-template-columns: 1fr 300px; gap: 16px; padding: 20px 0 32px; }
.sim-title { display: flex; align-items: end; justify-content: space-between; gap: 12px; padding-top: 24px; flex-wrap: wrap; }
.sim-title h1 { margin: 4px 0 0; font-size: 30px; letter-spacing: -.02em; font-weight: 600; }
.stage { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; display: flex; flex-direction: column; min-height: 520px; }
.stage { position: relative; }
.stage canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.stage:fullscreen { border: 0; border-radius: 0; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); padding: 16px; display: flex; flex-direction: column; gap: 18px; align-self: start; }
.ctrl label { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 6px; }
.ctrl output { font-family: var(--mono); }
input[type=range] { width: 100%; accent-color: var(--accent); }
input[type=checkbox] { accent-color: var(--accent); width: 15px; height: 15px; margin: 0; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13px; cursor: pointer; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.seg button {
  font: inherit; font-size: 13px; padding: 7px 8px; border: 0; background: transparent; color: var(--muted); cursor: pointer;
}
.seg button + button { border-left: 1px solid var(--line); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--panel); }
.vtable { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 12.5px; }
.vtable th, .vtable td { text-align: right; padding: 5px 4px; border-bottom: 1px solid var(--line); font-weight: 400; }
.vtable th { color: var(--muted); font-size: 11px; }
.vtable td:first-child, .vtable th:first-child { text-align: left; }
.sw { display: inline-block; width: 10px; height: 3px; vertical-align: middle; margin-right: 6px; }
.readouts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.readout { border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 10px; }
.readout b { display: block; font-family: var(--mono); font-size: 18px; font-weight: 500; }
.row { display: flex; gap: 8px; }
.row .btn { flex: 1; justify-content: center; }
.note { font-size: 13px; color: var(--muted); border-left: 2px solid var(--line); padding-left: 10px; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; padding-top: 40px; gap: 28px; }
  .bar nav { display: none; }
  .bar .icon-btn { margin-left: auto; }
  .week { grid-template-columns: 44px 1fr; }
  .sims { grid-column: 2; justify-content: flex-start; }
  .sim-layout { grid-template-columns: 1fr; }
  .stage { min-height: 380px; }
}
@media (prefers-reduced-motion: reduce) {
  .week { animation: none; opacity: 1; transform: none; }
}
.calc { font-family: var(--mono); font-size: 13px; line-height: 1.9; border-top: 1px solid var(--line); padding-top: 10px; }
.calc b { font-weight: 500; }
