/* ====================================================
   Sahih-i Buhari · Tema Sistemi
   Kullanım: <html data-theme="..." data-font="..." data-fontsize="...">
   ==================================================== */

/* ===== KARANLIK (Dark) ===== */
:root[data-theme="karanlik"] {
  --bg: #1a1410;
  --card: #2a2018;
  --text: #f5e6cf;
  --text-light: #d4b896;
  --text-muted: #998866;
  --border: #4a3a2a;
  --border-light: #3a2e20;
  --gold: #d4b454;
  --gold-dark: #a8932e;
  --gold-light: #e8c75c;
  --c1: #d4495c; --c2: #e09b3a; --c3: #4a9070; --c4: #5b85b5; --c5: #9367ad;
  --green: #4a9070; --green-bg: #1f3327;
  --blue: #5b85b5; --blue-bg: #1a2b3d;
  --gray: #998866; --gray-bg: #2a2520;
}
:root[data-theme="karanlik"] body{
  background-image:
    radial-gradient(circle at 15% 20%, rgba(212,180,84,0.08) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(212,73,92,0.06) 0%, transparent 40%) !important;
}
:root[data-theme="karanlik"] .stat-card,
:root[data-theme="karanlik"] .nav-card,
:root[data-theme="karanlik"] .card,
:root[data-theme="karanlik"] .result-card,
:root[data-theme="karanlik"] .cilt-row,
:root[data-theme="karanlik"] .cilt-card,
:root[data-theme="karanlik"] .stat-mini,
:root[data-theme="karanlik"] .mini,
:root[data-theme="karanlik"] .winner,
:root[data-theme="karanlik"] .finding,
:root[data-theme="karanlik"] .milestone,
:root[data-theme="karanlik"] .tempo,
:root[data-theme="karanlik"] .info-cell,
:root[data-theme="karanlik"] .milestone-mini,
:root[data-theme="karanlik"] section.block,
:root[data-theme="karanlik"] .detail-block,
:root[data-theme="karanlik"] .current-pos,
:root[data-theme="karanlik"] .kutub-card{
  background: var(--card) !important;
  color: var(--text);
  border-color: var(--border-light) !important;
}
:root[data-theme="karanlik"] .pos-item,
:root[data-theme="karanlik"] .timeline-wrap,
:root[data-theme="karanlik"] .book-visual,
:root[data-theme="karanlik"] .progress-big .track,
:root[data-theme="karanlik"] .pos-detail,
:root[data-theme="karanlik"] .custom-tempo{
  background: var(--bg) !important;
  color: var(--text);
}
:root[data-theme="karanlik"] th{
  background: #3a2e20 !important;
  color: var(--gold-light) !important;
}
:root[data-theme="karanlik"] tr:hover td{ background: rgba(212,180,84,0.08) !important; }
:root[data-theme="karanlik"] tr.total{ background: rgba(212,180,84,0.15) !important; color: var(--gold-light) !important; }
:root[data-theme="karanlik"] .topic{ background: #3a2e20 !important; color: var(--gold-light); border-color: var(--border); }
:root[data-theme="karanlik"] .insight,
:root[data-theme="karanlik"] .hero,
:root[data-theme="karanlik"] .today-card,
:root[data-theme="karanlik"] .result-summary,
:root[data-theme="karanlik"] .progress-card{
  background: linear-gradient(135deg, #2a2018, #3a2e20) !important;
  color: var(--text);
  border-color: var(--border) !important;
}
:root[data-theme="karanlik"] input[type="number"],
:root[data-theme="karanlik"] input[type="date"],
:root[data-theme="karanlik"] input[type="text"],
:root[data-theme="karanlik"] select{
  background: #1f1812 !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}
:root[data-theme="karanlik"] .radio{ background: #1f1812 !important; color: var(--text); border-color: var(--border); }
:root[data-theme="karanlik"] .radio.sel-okudum{ background: var(--green-bg) !important; color: var(--green); }
:root[data-theme="karanlik"] .radio.sel-okuyorum{ background: var(--blue-bg) !important; color: var(--blue); }
:root[data-theme="karanlik"] .micro,
:root[data-theme="karanlik"] .info-cell,
:root[data-theme="karanlik"] .progress-bar-mini{ background: #1f1812 !important; }

/* ===== SEPYA (Sepia) ===== */
:root[data-theme="sepya"] {
  --bg: #f4ecd8; --card: #faf3e0;
  --text: #4a3520; --text-light: #6b4a2a; --text-muted: #8b6a4a;
  --border: #c8a878; --border-light: #e0c8a0;
  --gold: #b8860b; --gold-dark: #8b6914; --gold-light: #d4a017;
}

/* ===== MODERN AÇIK (Modern Light) ===== */
:root[data-theme="modern"] {
  --bg: #f8f9fa; --card: #ffffff;
  --text: #212529; --text-light: #495057; --text-muted: #6c757d;
  --border: #ced4da; --border-light: #e9ecef;
  --gold: #0d6efd; --gold-dark: #0a58ca; --gold-light: #6ea8fe;
  --c1: #dc3545; --c2: #fd7e14; --c3: #198754; --c4: #0d6efd; --c5: #6f42c1;
  --green: #198754; --green-bg: #d1e7dd;
  --blue: #0d6efd; --blue-bg: #cfe2ff;
}
:root[data-theme="modern"] body{ background-image: none !important; }

/* ===== YEŞİL (Mint) ===== */
:root[data-theme="yesil"] {
  --bg: #f0f8f4; --card: #ffffff;
  --text: #1a3d2d; --text-light: #2d6a4f; --text-muted: #5a8a72;
  --border: #b5d8c4; --border-light: #d5e8de;
  --gold: #2d6a4f; --gold-dark: #1a3d2d; --gold-light: #4a9070;
}
:root[data-theme="yesil"] body{
  background-image: radial-gradient(circle at 15% 20%, rgba(45,106,79,0.05) 0%, transparent 40%) !important;
}

/* ===== OKYANUS (Ocean Blue) ===== */
:root[data-theme="okyanus"] {
  --bg: #eef4fa; --card: #ffffff;
  --text: #1a3a5c; --text-light: #2c5282; --text-muted: #5a7a9e;
  --border: #a5c0e0; --border-light: #d5e0ee;
  --gold: #2c5282; --gold-dark: #1a3a5c; --gold-light: #4670a5;
}
:root[data-theme="okyanus"] body{
  background-image: radial-gradient(circle at 15% 20%, rgba(44,82,130,0.05) 0%, transparent 40%) !important;
}

/* ===== GÜL (Rose) ===== */
:root[data-theme="gul"] {
  --bg: #fdf2f4; --card: #ffffff;
  --text: #5a1d29; --text-light: #8b2d3f; --text-muted: #a06070;
  --border: #e0b5c0; --border-light: #f0d5dc;
  --gold: #a02334; --gold-dark: #7a1825; --gold-light: #d4495c;
}

/* ===== GECE (Deep Night) ===== */
:root[data-theme="gece"] {
  --bg: #0a0805; --card: #14100a;
  --text: #c9a227; --text-light: #a8932e; --text-muted: #8b6914;
  --border: #2a2018; --border-light: #1f1812;
  --gold: #d4b454; --gold-dark: #b8860b; --gold-light: #e8c75c;
  --c1: #a02334; --c2: #b8860b; --c3: #2d6a4f; --c4: #2c5282; --c5: #6b2c91;
}
:root[data-theme="gece"] body{
  background-image:
    radial-gradient(circle at 50% 50%, rgba(201,162,39,0.05) 0%, transparent 60%) !important;
}
:root[data-theme="gece"] .stat-card,
:root[data-theme="gece"] .nav-card,
:root[data-theme="gece"] .card,
:root[data-theme="gece"] .result-card,
:root[data-theme="gece"] .cilt-row,
:root[data-theme="gece"] .cilt-card,
:root[data-theme="gece"] section.block,
:root[data-theme="gece"] .kutub-card{
  background: var(--card) !important;
  color: var(--text);
  border-color: var(--border) !important;
}
:root[data-theme="gece"] input,
:root[data-theme="gece"] select{ background: #1a140c !important; color: var(--text) !important; }
:root[data-theme="gece"] th{ background: #1a140c !important; color: var(--gold) !important; }

/* ====================================================
   YAZI TİPLERİ (Fonts)
   ==================================================== */
:root[data-font="sistem"] body,:root[data-font="sistem"] input,:root[data-font="sistem"] select,:root[data-font="sistem"] button,:root[data-font="sistem"] textarea{font-family:-apple-system,BlinkMacSystemFont,system-ui,sans-serif !important}
:root[data-font="segoe"] body,:root[data-font="segoe"] input,:root[data-font="segoe"] select,:root[data-font="segoe"] button,:root[data-font="segoe"] textarea{font-family:'Segoe UI',Tahoma,sans-serif !important}
:root[data-font="georgia"] body,:root[data-font="georgia"] input,:root[data-font="georgia"] select,:root[data-font="georgia"] button,:root[data-font="georgia"] textarea{font-family:Georgia,'Times New Roman',serif !important}
:root[data-font="tahoma"] body,:root[data-font="tahoma"] input,:root[data-font="tahoma"] select,:root[data-font="tahoma"] button,:root[data-font="tahoma"] textarea{font-family:Tahoma,Geneva,sans-serif !important}
:root[data-font="verdana"] body,:root[data-font="verdana"] input,:root[data-font="verdana"] select,:root[data-font="verdana"] button,:root[data-font="verdana"] textarea{font-family:Verdana,Geneva,sans-serif !important}
:root[data-font="arial"] body,:root[data-font="arial"] input,:root[data-font="arial"] select,:root[data-font="arial"] button,:root[data-font="arial"] textarea{font-family:Arial,Helvetica,sans-serif !important}
:root[data-font="times"] body,:root[data-font="times"] input,:root[data-font="times"] select,:root[data-font="times"] button,:root[data-font="times"] textarea{font-family:'Times New Roman',Times,serif !important}
:root[data-font="palatino"] body,:root[data-font="palatino"] input,:root[data-font="palatino"] select,:root[data-font="palatino"] button,:root[data-font="palatino"] textarea{font-family:'Palatino Linotype','Book Antiqua',Palatino,serif !important}
:root[data-font="garamond"] body,:root[data-font="garamond"] input,:root[data-font="garamond"] select,:root[data-font="garamond"] button,:root[data-font="garamond"] textarea{font-family:Garamond,'Times New Roman',serif !important}
:root[data-font="trebuchet"] body,:root[data-font="trebuchet"] input,:root[data-font="trebuchet"] select,:root[data-font="trebuchet"] button,:root[data-font="trebuchet"] textarea{font-family:'Trebuchet MS',sans-serif !important}
:root[data-font="lucida"] body,:root[data-font="lucida"] input,:root[data-font="lucida"] select,:root[data-font="lucida"] button,:root[data-font="lucida"] textarea{font-family:'Lucida Sans','Lucida Sans Unicode',sans-serif !important}
:root[data-font="courier"] body,:root[data-font="courier"] input,:root[data-font="courier"] select,:root[data-font="courier"] button,:root[data-font="courier"] textarea{font-family:'Courier New',Courier,monospace !important}
:root[data-font="consolas"] body,:root[data-font="consolas"] input,:root[data-font="consolas"] select,:root[data-font="consolas"] button,:root[data-font="consolas"] textarea{font-family:Consolas,'Lucida Console',monospace !important}

/* ====================================================
   YAZI BOYUTLARI (Font Sizes) — zoom kullanılıyor
   ==================================================== */
:root[data-fontsize="kucuk"] body{ zoom: 0.88; }
:root[data-fontsize="normal"] body{ zoom: 1; }
:root[data-fontsize="buyuk"] body{ zoom: 1.12; }
:root[data-fontsize="xbuyuk"] body{ zoom: 1.25; }
:root[data-fontsize="xxbuyuk"] body{ zoom: 1.4; }
