/* Hizmet önizlemeleri ve sektör rehberi mevcut temanın renklerini kullanır. */
main:has(.demo-workbench) > .page-head { padding-block: 1.25rem 1.5rem; }
.band:has(> .demo-workbench) { padding-block: clamp(1.3rem,2.6vw,2.5rem); }
.demo-workbench {
  display: grid;
  grid-template-columns: minmax(12rem, .68fr) minmax(0, 2.4fr);
  gap: clamp(1.25rem, 4vw, 4.5rem);
  align-items: start;
}
.demo-index h2 { margin-bottom: .85rem; font-size: 1.2rem; }
.demo-index nav { display: grid; border-top: 1px solid var(--line); }
.demo-index a {
  display: flex; align-items: center; gap: .75rem; min-height: 3.25rem;
  padding: .65rem .7rem; border-bottom: 1px solid var(--line); color: var(--muted);
  text-decoration: none; font-size: .94rem; line-height: 1.3;
}
.demo-index a:hover, .demo-index a[aria-current] { color: var(--ink); background: var(--bg-alt); }
.demo-index a[aria-current] { box-shadow: inset 3px 0 var(--accent-secondary); font-weight: 650; }
.demo-index svg, .demo-appbar svg, .demo-detail svg, .sector-links svg { width: 1.15em; height: 1.15em; flex: none; }
.demo-index svg { color: var(--primary); }
.demo-lab { min-width: 0; }
.demo-lab-head, .demo-tools, .demo-appbar, .demo-record {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .6rem 1rem;
}
.demo-lab-head { margin-bottom: .85rem; align-items: end; }
.demo-lab-head h2 { font-size: clamp(1.5rem, 2.3vw, 2.05rem); letter-spacing: -.035em; }
.demo-caption, .demo-picker label, .demo-angle, .demo-fields dt, .demo-metrics dt, .demo-task small {
  color: var(--muted); font-size: .81rem; line-height: 1.4;
}
.demo-picker { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; max-width: 100%; }
.demo-picker select, .demo-picker button, .demo-tools button, .demo-task button {
  font: inherit; font-size: .85rem; border-radius: var(--r-sm); color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); padding: .45rem .7rem;
}
.demo-picker select { max-width: 100%; }
.demo-picker button, .demo-tools button, .demo-task button { cursor: pointer; font-weight: 600; }
.demo-scene {
  perspective: 1200px; isolation: isolate; display: grid; place-items: center;
  min-width: 0; padding: clamp(1.5rem, 4.2vw, 3.8rem) clamp(.9rem, 4.5vw, 4.2rem);
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--bg-alt); overflow: hidden; touch-action: pan-y; cursor: grab;
}
.demo-scene:active { cursor: grabbing; }
.demo-device {
  width: min(100%, 43rem); position: relative; transform-style: preserve-3d;
  transform: rotateY(var(--yaw, -6deg)) rotateX(var(--pitch, 3deg));
}
.demo-device::before {
  position: absolute; content: ''; inset: 0; background: var(--line); border-radius: var(--r-md);
  transform: translate3d(2px, 4px, -10px); box-shadow: 0 14px 24px -16px var(--deep);
}
.demo-face {
  position: relative; border: 1px solid var(--line);
  border-radius: var(--r-md); background: var(--surface); color: var(--ink);
}
.demo-appbar {
  padding: .7rem 1rem; border-bottom: 1px solid var(--line);
  border-radius: var(--r-md) var(--r-md) 0 0; font-size: .81rem;
}
.demo-appbar strong { display: flex; align-items: center; gap: .5rem; color: var(--primary); }
.demo-appbar > span { font-family: ui-monospace, monospace; color: var(--muted); }
.demo-sheet { padding: clamp(.9rem, 2.2vw, 1.75rem); }
.demo-record { align-items: baseline; gap: .35rem; }
.demo-record h3 { font-size: clamp(1.18rem, 2vw, 1.55rem); line-height: 1.2; letter-spacing: -.025em; }
.demo-record > span { font-size: .78rem; color: var(--accent-secondary); }
.demo-fields { margin: .95rem 0; }
.demo-fields > div { display: flex; justify-content: space-between; align-items: baseline; gap: .75rem; padding: .35rem 0; border-bottom: 1px solid var(--line); }
.demo-fields dd { margin: 0; text-align: right; font-size: .88rem; }
.demo-fields--columns { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); border-block: 1px solid var(--line); }
.demo-fields--columns > div { display: block; border: 0; padding: .7rem .3rem .7rem 0; }
.demo-fields--columns dd { text-align: left; margin-top: .15rem; font-weight: 600; }
.demo-fields--route > div { position: relative; padding-left: 1.2rem; border: 0; }
.demo-fields--route > div::before { content: ''; position: absolute; left: .22rem; top: 50%; height: 100%; border-left: 1px solid var(--line); }
.demo-fields--route > div:last-child::before { display: none; }
.demo-fields--route > div::after { content: ''; position: absolute; left: 0; top: calc(50% - .25rem); width: .5rem; height: .5rem; border-radius: 50%; background: var(--surface); border: 2px solid var(--primary); }
.demo-seats, .demo-slots { display: grid; gap: .25rem; margin: .6rem 0; }
.demo-seats { grid-template-columns: repeat(8,1fr); }
.demo-seats span, .demo-slots span { text-align: center; border: 1px solid var(--line); border-radius: 3px; color: var(--muted); font-size: .77rem; padding: .2rem; }
.demo-seats .is-booked { border-color: var(--primary); color: var(--primary); }
.demo-seats .is-boarded { background: var(--signal); border-color: var(--signal); color: var(--signal-ink); }
.demo-slots { grid-template-columns: repeat(3,1fr); }
.demo-slots b { display: block; }
.demo-slots span:has([data-slot]) { border-color: var(--primary); color: var(--primary); }
.demo-metrics { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .5rem; }
.demo-metrics > div { padding: .65rem .8rem; border-left: 2px solid var(--line); background: var(--bg-alt); }
.demo-metrics dd { margin: .2rem 0 0; font: 650 clamp(1.05rem, 2vw, 1.5rem)/1.2 var(--font-display); font-variant-numeric: tabular-nums; }
.demo-actions { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .5rem; margin-top: 1rem; }
.demo-task { position: relative; display: flex; flex-direction: column; gap: .3rem; min-width: 0; }
.demo-task small { font-weight: 600; }
.demo-task button { min-height: 2.6rem; height: 100%; padding: .38rem; line-height: 1.2; overflow-wrap: anywhere; }
.demo-task button:enabled { color: var(--signal-ink); background: var(--signal); border-color: var(--signal); }
.demo-task button:disabled { cursor: default; color: var(--muted); }
.demo-task.is-done button { border-color: var(--accent-secondary); }
.demo-task.is-done small::after { content: ' ✓'; color: var(--accent-secondary); }
.demo-task.is-testing button { outline: 2px solid var(--focus); outline-offset: 2px; }
.demo-pointer {
  display: none; position: absolute; z-index: 2; right: 0; bottom: -.45rem;
  pointer-events: none; padding: .15rem .35rem; background: var(--primary); color: var(--primary-ink);
  border-radius: 3px; font: 650 .67rem/1.3 var(--font-body); white-space: nowrap;
}
.demo-pointer::before {
  content: ''; position: absolute; top: -.52rem; left: -.4rem; width: .8rem; height: .9rem;
  background: inherit; clip-path: polygon(0 0,100% 57%,55% 66%,38% 100%);
}
.demo-task.is-testing .demo-pointer { display: block; animation: demo-click 1.05s ease-out both; }
@keyframes demo-click {
  0% { transform: translate(.6rem,-1.15rem); opacity: 0; }
  35%, 74% { transform: translate(0,0); opacity: 1; }
  88% { transform: translate(-2px,-2px) scale(.95); }
  100% { transform: none; }
}
.demo-device--phone { max-width: 20rem; }
.demo-device--phone .demo-face { border: 4px solid var(--line); border-radius: 1.25rem; }
.demo-device--phone::before { border-radius: 1.25rem; }
.demo-device--phone .demo-appbar { padding: .75rem; }
.demo-device--phone .demo-sheet { padding: .85rem; }
.demo-device--phone .demo-actions { grid-template-columns: 1fr; }
.demo-device--phone .demo-task { display: grid; grid-template-columns: .6fr 1fr; align-items: center; }
.demo-tools { margin-top: .75rem; }
.demo-run, .demo-angle { display: flex; align-items: center; gap: .5rem; }
.demo-tools button { min-height: 2.45rem; }
.demo-tools [data-play] { border-color: var(--primary); color: var(--primary); min-width: 7.7rem; }
.demo-angle input { width: 6.6rem; max-width: 100%; accent-color: var(--accent-secondary); cursor: pointer; }
.demo-feedback { min-height: 1.5em; margin-top: .6rem; font-size: .85rem; color: var(--muted); }
.demo-detail, .sector-links a { display: inline-flex; align-items: center; gap: .35rem; font-size: .93rem; font-weight: 600; }
.demo-detail { margin-top: .8rem; }
.demo-fallback { margin: 1rem 0 0 1.3rem; font-size: .88rem; }
.demo-directory { grid-column: 1/-1; border-block: 1px solid var(--line); padding: .95rem 0; }
.demo-directory summary { width: fit-content; cursor: pointer; font-weight: 600; }
.demo-directory dl { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,18rem),1fr)); gap: 1.3rem 2rem; padding-block: 1.3rem .4rem; }
.demo-directory dt { font-weight: 650; }
.demo-directory dd { margin: .3rem 0 0; color: var(--muted); font-size: .92rem; }

.sector-guide { padding-bottom: var(--band); }
.sector-index { display: flex; gap: .45rem 1.4rem; flex-wrap: wrap; padding-block: 1.1rem; }
.sector-index a { color: var(--primary); text-underline-offset: .22em; font-size: .93rem; padding-block: .3rem; }
.sector-entry {
  display: grid; grid-template-columns: minmax(0, .75fr) minmax(0,1.4fr);
  gap: 1rem clamp(2rem, 6vw, 7rem); padding-block: clamp(2rem, 4.5vw, 4rem); border-top: 1px solid var(--line);
}
.sector-intro h2 { font-size: clamp(1.45rem, 2.8vw, 2.15rem); letter-spacing: -.035em; line-height: 1.15; }
.sector-intro p, .sector-notes dd { color: var(--muted); line-height: 1.65; }
.sector-intro p { margin-block: .75rem 1rem; max-width: 44ch; }
.sector-links { display: flex; flex-wrap: wrap; gap: .5rem 1.1rem; }
.sector-notes { display: grid; gap: 1rem; max-width: 75ch; }
.sector-notes dt { margin-bottom: .18rem; font-weight: 650; }
.sector-notes dd { margin: 0; }

@media (max-width: 760px) {
  .demo-workbench, .sector-entry { grid-template-columns: minmax(0,1fr); }
  .demo-index nav { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .demo-index a { min-height: 2.8rem; font-size: .87rem; }
  .sector-intro p { max-width: none; }
}
@media (max-width: 480px) {
  .demo-scene { padding: 1.15rem .65rem; }
  .demo-sheet { padding: .75rem; }
  .demo-actions { grid-template-columns: 1fr; }
  .demo-task { display: grid; grid-template-columns: minmax(0,.68fr) minmax(0,1fr); align-items: center; }
  .demo-task button { min-height: 2.35rem; }
  .demo-angle input { width: 5rem; }
}
@media (prefers-reduced-motion: reduce) {
  .demo-device { transform: rotateY(var(--yaw, 0deg)) rotateX(var(--pitch, 0deg)); }
  .demo-task.is-testing .demo-pointer { animation: none; }
}

/* ---------- Mobil düzeltmeler ---------- */
@media (max-width: 760px) {
  /* iPhone, 16 pikselden küçük yazılı seçim kutusuna dokunulunca sayfayı yakınlaştırır. */
  .demo-picker select { font-size: 16px; min-height: 2.75rem; }
  .demo-tools button { min-height: 2.75rem; }
  .demo-angle input { height: 2rem; }
  .sector-index a { padding-block: .6rem; }
  .demo-detail, .sector-links a { padding-block: .5rem; }
}
