:root{
  --primary:#2563eb;
  --primary-hover:#1d4ed8;
  --bg-panel:rgba(255,255,255,.92);

  /* AYBÜ theme */
  --acc-turquoise:#13c0d7;
  --acc-navy:#002d72;
  --acc-border:#e2e8f0;
  --acc-text:#0f172a;
  --acc-muted:#94a3b8;
  --acc-soft:#f8fafc;
  --acc-shadow:0 10px 40px rgba(2,32,71,.18);
}

/* =========================================================
   GLOBAL MODES
   ========================================================= */

/* Disleksi Dostu Font */
.dyslexic-font{
  font-family:'Lexend', sans-serif !important;
}

/* Yüksek Kontrast */
.high-contrast{
  background-color:#000 !important;
  color:#fff !important;
}
.high-contrast *:not(.acc-fixed):not(#acc-toggle):not(#accessibility-panel){
  background-color:#000 !important;
  color:#ffff00 !important;
  border-color:#ffff00 !important;
}

/* Karanlık Mod */
.dark-mode{
  background-color:#121212 !important;
  color:#e5e7eb !important;
}
.dark-mode header,
.dark-mode footer,
.dark-mode main>div{
  background-color:#1f2937 !important;
  border-color:#374151 !important;
}
.dark-mode p,
.dark-mode h2,
.dark-mode h3{
  color:#f3f4f6 !important;
}

/* Gri Tonlama */
.grayscale-mode{ filter:grayscale(100%) !important; }

/* Bağlantıları Vurgula */
.highlight-links a:not(.acc-btn){
  outline:3px solid #facc15 !important;
  background-color:#000 !important;
  color:#facc15 !important;
  font-weight:bold !important;
  text-decoration:underline !important;
  padding:2px 4px !important;
}

/* Büyük İmleç */
.big-cursor{
  cursor:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 24 24' fill='black' stroke='white' stroke-width='1'><path d='M3 3l7.07 16.97 2.51-7.39 7.39-2.51L3 3z'/></svg>"), auto !important;
}
.big-cursor a,
.big-cursor button{
  cursor:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 24 24' fill='black' stroke='white' stroke-width='1'><path d='M3 3l7.07 16.97 2.51-7.39 7.39-2.51L3 3z'/></svg>"), pointer !important;
}

/* Animasyonları Durdur */
.stop-animations *{
  animation:none !important;
  transition:none !important;
}

/* Odak Vurgusu */
.enhanced-focus *:focus{
  outline:4px solid #facc15 !important;
  outline-offset:2px !important;
  box-shadow:0 0 0 6px rgba(0,0,0,.8) !important;
}

/* =========================================================
   READING HELPERS
   ========================================================= */
#reading-guide{
  position:fixed;
  left:0;
  width:100%;
  height:4px;
  background:#ff0000;
  z-index:9999;
  pointer-events:none;
  display:none;
  box-shadow:0 0 10px rgba(255,0,0,.5);
}
#reading-mask{
  position:fixed;
  inset:0;
  z-index:9998;
  pointer-events:none;
  display:none;
  background:rgba(0,0,0,.7);
  clip-path:polygon(0% 0%,0% 100%,100% 100%,100% 0%,0% 0%,0% 45%,100% 45%,100% 55%,0% 55%,0% 45%);
}

/* =========================================================
   ACCESSIBILITY PANEL (RIGHT SLIDE)
   ========================================================= */
#accessibility-panel{
  position:fixed !important;
  top:16px !important;
  right:16px !important;
  bottom:16px !important;
  width:400px !important;
  max-width:calc(100vw - 16px) !important;

  background:var(--bg-panel) !important;
  border-left:1px solid rgba(255,255,255,.35) !important;
  border-radius:12px 0 0 12px !important;
  box-shadow:var(--acc-shadow) !important;

  display:flex !important;
  flex-direction:column !important;
  overflow:hidden !important;

  transform:translateX(120%) !important;
  transition:transform .35s ease !important;
  z-index:100000 !important;
}
#accessibility-panel.open{ transform:translateX(0) !important; }

@media (max-width:480px){
  #accessibility-panel{ width:320px !important; }
}

/* Header fixed */
#accessibility-panel .acc-panel-header{
  flex:0 0 auto !important;
  display:flex !important;
  align-items:center !important;
  justify-content:space-between !important;
  gap:12px !important;
  padding:14px !important;
  background:rgba(255,255,255,.86) !important;
  border-bottom:1px solid rgba(15,23,42,.10) !important;
  backdrop-filter:blur(12px) !important;
  -webkit-backdrop-filter:blur(12px) !important;
}

/* Body scrollable */
#accessibility-panel .acc-panel-body{
  flex:1 1 auto !important;
  min-height:0 !important; /* CRITICAL */
  overflow-y:auto !important;
  overflow-x:hidden !important;
  padding:16px 20px 24px !important;
  -webkit-overflow-scrolling:touch;
  overscroll-behavior:contain;
}

/* Scrollbar */
#accessibility-panel .acc-panel-body::-webkit-scrollbar{ width:8px; }
#accessibility-panel .acc-panel-body::-webkit-scrollbar-thumb{
  background:rgba(19,192,215,.55);
  border-radius:10px;
}
#accessibility-panel .acc-panel-body::-webkit-scrollbar-thumb:hover{
  background:rgba(19,192,215,.75);
}

/* Header actions: TR/EN + X */
#accessibility-panel .acc-panel-actions{
  display:flex !important;
  align-items:center !important;
  gap:10px !important;
}

/* Lang pill */
#accessibility-panel .acc-lang{
  display:inline-flex !important;
  align-items:center !important;
  gap:6px !important;
  padding:2px !important;
  border-radius:999px !important;
  background:#f1f5f9 !important;
  border:1px solid var(--acc-border) !important;
}
#accessibility-panel .lang-btn{
  border:0 !important;
  background:transparent !important;
  padding:8px 12px !important;
  border-radius:999px !important;
  font-weight:800 !important;
  font-size:12px !important;
  color:#334155 !important;
  cursor:pointer !important;
  line-height:1 !important;
}
#accessibility-panel .lang-btn:hover{
  background:rgba(19,192,215,.14) !important;
  color:#0f172a !important;
}
#accessibility-panel .lang-btn.acc-btn-active{
  background:var(--acc-turquoise) !important;
  color:#fff !important;
  box-shadow:0 6px 16px rgba(19,192,215,.25) !important;
}

/* Close */
#accessibility-panel .acc-close,
#accessibility-panel #acc-close{
  width:38px !important;
  height:38px !important;
  border-radius:12px !important;
  border:1px solid var(--acc-border) !important;
  background:#fff !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  cursor:pointer !important;
}
#accessibility-panel .acc-close:hover,
#accessibility-panel #acc-close:hover{
  background:#f8fafc !important;
  border-color:#cbd5e1 !important;
}

/* Buttons */
#accessibility-panel .acc-btn{
  width:100% !important;
  border:1px solid var(--acc-border) !important;
  border-radius:14px !important;
  background:#fff !important;
  padding:10px 12px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:flex-start !important;
  gap:10px !important;
  box-shadow:0 2px 12px rgba(2,32,71,.06) !important;
  cursor:pointer !important;
}
#accessibility-panel .acc-btn:hover{
  border-color:rgba(37,99,235,.40) !important;
  background:#fcfdff !important;
  box-shadow:0 10px 20px rgba(37,99,235,.08) !important;
}
#accessibility-panel .acc-btn span,
#accessibility-panel .acc-btn .acc-btn-text{
  font-size:12px !important;
  font-weight:800 !important;
  color:#334155 !important;
}

/* Grid 2 */
#accessibility-panel .acc-grid-2{
  display:grid !important;
  grid-template-columns:1fr 1fr !important;
  gap:12px !important;
}
@media (max-width:480px){
  #accessibility-panel .acc-grid-2{ grid-template-columns:1fr !important; }
}

/* Sliders 3 columns */
#accessibility-panel .acc-sliders{
  display:grid !important;
  grid-template-columns:repeat(3, minmax(0,1fr)) !important;
  gap:12px !important;
}
@media (max-width:520px){
  #accessibility-panel .acc-sliders{ grid-template-columns:1fr !important; }
}
#accessibility-panel .acc-slider{
  background:#f8fafc !important;
  border:1px solid var(--acc-border) !important;
  border-radius:14px !important;
  padding:12px !important;
  display:flex !important;
  flex-direction:column !important;
  gap:10px !important;
}
#accessibility-panel .acc-slider-head{
  display:flex !important;
  justify-content:space-between !important;
  align-items:center !important;
  font-size:12px !important;
  font-weight:800 !important;
  color:#334155 !important;
}
#accessibility-panel .acc-val{
  font-size:11px !important;
  font-weight:900 !important;
  background:var(--acc-turquoise) !important;
  color:#fff !important;
  padding:3px 8px !important;
  border-radius:999px !important;
}
#accessibility-panel input[type="range"]{
  -webkit-appearance:none !important;
  appearance:none !important;
  height:6px !important;
  background:#e2e8f0 !important;
  border-radius:999px !important;
  outline:none !important;
}
#accessibility-panel input[type="range"]::-webkit-slider-thumb{
  -webkit-appearance:none !important;
  appearance:none !important;
  width:16px !important;
  height:16px !important;
  border-radius:50% !important;
  background:var(--acc-turquoise) !important;
  cursor:pointer !important;
  box-shadow:0 4px 12px rgba(19,192,215,.35) !important;
  border:2px solid #fff !important;
}
#accessibility-panel input[type="range"]::-moz-range-thumb{
  width:16px !important;
  height:16px !important;
  border-radius:50% !important;
  background:var(--acc-turquoise) !important;
  cursor:pointer !important;
  border:none !important;
}

/* Reset */
#accessibility-panel .acc-reset{
  width:100% !important;
  border-radius:14px !important;
  border:1px solid rgba(239,68,68,.25) !important;
  background:rgba(239,68,68,.08) !important;
  color:#dc2626 !important;
  font-weight:900 !important;
  padding:12px !important;
}
#accessibility-panel .acc-footer{
  margin:0 !important;
  text-align:center !important;
  font-size:9px !important;
  font-weight:900 !important;
  letter-spacing:.22em !important;
  text-transform:uppercase !important;
  color:var(--acc-muted) !important;
}

/* Panel and toggle always clickable */
.acc-fixed, #acc-toggle{
  z-index:100010 !important;
  pointer-events:auto !important;
}
#accessibility-panel *{ pointer-events:auto !important; }

/* =========================================================
   COLOR BLIND FILTERS
   ========================================================= */
.protanopia-filter{ filter:url('#protanopia') !important; }
.deuteranopia-filter{ filter:url('#deuteranopia') !important; }
.tritanopia-filter{ filter:url('#tritanopia') !important; }

/* =========================================================
   MAGNIFIER
   ========================================================= */
#acc-magnifier{
  position:fixed;
  width:200px;
  height:200px;
  border:4px solid #3b82f6;
  border-radius:50%;
  pointer-events:none;
  z-index:10000;
  display:none;
  box-shadow:0 0 30px rgba(0,0,0,.4);
  background:#fff;
  overflow:hidden;
}

/* =========================================================
   VIRTUAL KEYBOARD
   ========================================================= */
#acc-keyboard{
  position:fixed;
  bottom:20px;
  left:50%;
  transform:translateX(-50%) translateY(120%);
  background:#fff;
  padding:15px;
  border-radius:16px;
  box-shadow:0 10px 40px rgba(0,0,0,.2);
  z-index:10001;
  display:grid;
  grid-template-columns:repeat(10, 1fr);
  gap:5px;
  transition:transform .4s ease;
  border:1px solid var(--acc-border);
  max-width:90vw;
}
#acc-keyboard.active{
  transform:translateX(-50%) translateY(0);
}
.kbd-key{
  background:#f8fafc;
  border:1px solid var(--acc-border);
  border-radius:6px;
  padding:8px;
  text-align:center;
  font-size:14px;
  font-weight:600;
  cursor:pointer;
  transition:all .2s;
  user-select:none;
}
.kbd-key:hover{
  background:#eff6ff;
  border-color:#3b82f6;
  color:#2563eb;
}
.kbd-key:active{ transform:scale(.95); }
.kbd-key.wide{ grid-column:span 2; }
.kbd-key.space{ grid-column:span 5; }

/* =========================================================
   PAGE SUMMARY
   ========================================================= */
#acc-summary-panel{
  position:fixed;
  left:20px;
  top:55%;
  transform:translateY(-50%) translateX(-120%);
  background:#fff;
  width:280px;
  max-height:80vh;
  border-radius:16px;
  box-shadow:0 10px 40px rgba(0,0,0,.15);
  z-index:9997;
  padding:20px;
  overflow-y:auto;
  transition:transform .4s ease;
  border:1px solid var(--acc-border);
}
#acc-summary-panel.active{
  transform:translateY(-50%) translateX(0);
}
.summary-item{
  display:block;
  padding:8px 12px;
  border-radius:8px;
  text-decoration:none;
  color:#475569;
  font-size:13px;
  margin-bottom:4px;
  transition:all .2s;
}
.summary-item:hover{
  background:#f1f5f9;
  color:#2563eb;
  padding-left:16px;
}
.summary-h1{ font-weight:800; font-size:14px; margin-top:10px; }
.summary-h2{ margin-left:15px; }
.summary-h3{ margin-left:25px; opacity:.8; }

/* =========================================================
   TOGGLE BUTTON
   ========================================================= */
#acc-toggle{
  position:fixed !important;
  right:20px !important;
  bottom:20px !important;
  width:64px !important;
  height:64px !important;
  border-radius:9999px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  background:var(--acc-navy) !important;
  color:#fff !important;
  box-shadow:0 8px 30px rgba(37,99,235,.25) !important;
  z-index:99999 !important;
  border:0 !important;
  cursor:pointer !important;
}

/* =========================================================
   TAILWIND SHIM (SADECE PANEL) - minimal
   ========================================================= */
#accessibility-panel .flex{display:flex;}
#accessibility-panel .grid{display:grid;}
#accessibility-panel .grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr));}
#accessibility-panel .items-center{align-items:center;}
#accessibility-panel .justify-between{justify-content:space-between;}
#accessibility-panel .justify-center{justify-content:center;}
#accessibility-panel .flex-1{flex:1 1 0%;}
#accessibility-panel .w-full{width:100%;}
#accessibility-panel .text-center{text-align:center;}
#accessibility-panel .sr-only{
  position:absolute;width:1px;height:1px;padding:0;margin:-1px;
  overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0;
}
/* === SPACING'i KISALT === */
#accessibility-panel .acc-panel-body{
  padding: 12px 14px 12px !important;
}

#accessibility-panel .acc-grid-2{
  gap: 10px !important;
  margin-bottom: 10px !important;
}

#accessibility-panel .acc-sliders{
  gap: 10px !important;
  margin-top: 6px !important;
}

#accessibility-panel .acc-slider{
  padding: 10px !important;
}

#accessibility-panel .acc-btn{
  padding: 10px 12px !important;
  border-radius: 14px !important;
}

/* Başlıklar arası boşluğu azalt */
#accessibility-panel h3,
#accessibility-panel h4,
#accessibility-panel .acc-section-title{
  margin: 10px 0 8px !important;
  padding-top: 0 !important;
}

/* === ALT KISMI SABİTLE (Ayarları Sıfırla + AYBÜ yazısı) === */
/* Panel body içinde en altta bir footer alanın varsa: */
#accessibility-panel .acc-footer{
  margin-top: 0 !important;
  padding: 8px 0 6px !important;
  font-size: 9px !important;
}

/* “Ayarları Sıfırla” butonunu altta sticky yap */
#accessibility-panel .acc-reset{
  position: sticky !important;
  bottom: 10px !important;
  z-index: 5 !important;

  margin-top: 12px !important;
  padding: 12px !important;
  border-radius: 14px !important;

  /* arkadaki içerik görünmesin diye hafif zemin */
  background: rgba(239,68,68,.10) !important;
  backdrop-filter: blur(6px) !important;
}

/* Sticky reset ile içerik çakışmasın diye body'nin altına küçük pay */
#accessibility-panel .acc-panel-body{
  padding-bottom: 70px !important;
}
/* Ayarları Sıfırla biraz daha aşağı */
#accessibility-panel .acc-reset{
  position: sticky !important;
  bottom: 0 !important;          /* daha aşağı */
  margin-top: 20px !important;   /* üstten biraz boşluk */
  margin-bottom: 12px !important;
}

/* Panel body alt boşluğu artır */
#accessibility-panel .acc-panel-body{
  padding-bottom: 40px !important;
}