/* =====================================================================
   Ic sayfalar + portal + admin stilleri
   ===================================================================== */

/* ---------- faaliyet alani detay ---------- */
.area-detail-grid { display: grid; grid-template-columns: 1fr 320px; gap: 60px; align-items: start; }
.prose { font-size: 1.02rem; line-height: 1.85; color: var(--text-2); }
.prose h2 {
  font-family: var(--serif); font-size: 1.7rem; color: var(--text);
  margin: 38px 0 14px; font-weight: 700;
}
.prose h3 { font-size: 1.2rem; color: var(--text); margin: 28px 0 10px; }
.prose p { margin-bottom: 16px; }
.prose ul, .prose ol { margin: 0 0 18px 24px; }
html[dir='rtl'] .prose ul, html[dir='rtl'] .prose ol { margin: 0 24px 18px 0; }
.prose li { margin-bottom: 8px; }
.prose a { color: var(--gold); text-decoration: underline; }
.prose strong { color: var(--text); }
.prose blockquote {
  border-inline-start: 3px solid var(--gold); padding: 14px 22px; margin: 22px 0;
  background: var(--gold-soft); border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}

.side-panel { position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 22px; }
.side-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 26px;
}
.side-card h4 {
  font-size: 0.8rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 16px;
}
html[dir='rtl'] .side-card h4 { letter-spacing: 0.05em; }
.side-card a.item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; font-size: 0.92rem; color: var(--text-2);
  border-bottom: 1px solid var(--line-soft);
  transition: color 0.3s, padding-inline-start 0.3s var(--ease);
}
.side-card a.item:last-child { border-bottom: 0; }
.side-card a.item:hover { color: var(--gold); padding-inline-start: 8px; }
.side-card a.item.current { color: var(--gold); font-weight: 700; }

/* ---------- makale detay ---------- */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 60px; align-items: start; }
.article-meta-line {
  display: flex; align-items: center; flex-wrap: wrap; gap: 14px;
  font-size: 0.84rem; color: var(--text-3); margin-top: 18px;
}
.article-meta-line .chip {
  background: var(--gold-soft); color: var(--gold); font-weight: 700;
  padding: 4px 14px; border-radius: 999px; font-size: 0.78rem;
  letter-spacing: 0.08em; text-transform: uppercase;
}
.toc-list { font-size: 0.9rem; }
.toc-list a {
  display: block; padding: 8px 0 8px 14px; color: var(--text-2);
  border-inline-start: 2px solid var(--line-soft);
  transition: color 0.3s, border-color 0.3s;
}
html[dir='rtl'] .toc-list a { padding: 8px 14px 8px 0; }
.toc-list a:hover, .toc-list a.active { color: var(--gold); border-color: var(--gold); }
.disclaimer-box {
  margin-top: 46px; padding: 22px 26px;
  background: var(--gold-soft); border: 1px solid var(--line);
  border-radius: var(--radius-sm); font-size: 0.88rem; color: var(--text-2);
  display: flex; gap: 14px; align-items: flex-start;
}
.disclaimer-box svg { flex: 0 0 auto; color: var(--gold); width: 22px; height: 22px; margin-top: 2px; }

/* makale listesi filtre cubugu */
.filter-bar {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  margin-top: 40px;
}
.filter-bar .search {
  flex: 1; min-width: 240px; position: relative;
}
.filter-bar .search input {
  width: 100%; padding: 14px 20px 14px 48px;
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: 999px; transition: border-color 0.3s;
}
html[dir='rtl'] .filter-bar .search input { padding: 14px 48px 14px 20px; }
.filter-bar .search input:focus { outline: none; border-color: var(--gold); }
.filter-bar .search svg {
  position: absolute; inset-inline-start: 18px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; color: var(--text-3);
}
.cat-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.cat-pills a {
  padding: 9px 20px; border-radius: 999px; font-size: 0.85rem; font-weight: 600;
  border: 1px solid var(--line-soft); color: var(--text-2);
  transition: all 0.3s;
}
.cat-pills a:hover { border-color: var(--gold); color: var(--gold); }
.cat-pills a.active { background: var(--gold); border-color: var(--gold); color: #17130a; }

/* ---------- SSS ---------- */
.faq-list { max-width: 820px; margin: 50px auto 0; }
.faq-item {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); margin-bottom: 14px; overflow: hidden;
  transition: border-color 0.35s;
}
.faq-item.open { border-color: var(--line); }
.faq-q {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding: 24px 28px; text-align: start;
  font-weight: 700; font-size: 1.05rem; font-family: var(--serif);
}
.faq-q .ic {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%;
  border: 1px solid var(--line); color: var(--gold);
  display: grid; place-items: center;
  transition: transform 0.45s var(--ease), background 0.35s;
}
.faq-item.open .faq-q .ic { transform: rotate(45deg); background: var(--gold-soft); }
.faq-a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.5s var(--ease);
}
.faq-a-inner { padding: 0 28px 26px; color: var(--text-2); font-size: 0.95rem; line-height: 1.75; }

/* ---------- iletisim ---------- */
.contact-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 60px; align-items: start; }
.contact-info-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 36px;
}
.contact-info-card .row { display: flex; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line-soft); }
.contact-info-card .row:last-child { border-bottom: 0; }
.contact-info-card .ic {
  flex: 0 0 auto; width: 46px; height: 46px; border-radius: 12px;
  background: var(--gold-soft); color: var(--gold);
  display: grid; place-items: center;
}
.contact-info-card .ic svg { width: 22px; height: 22px; }
.contact-info-card .lbl { font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); }
.contact-info-card .val { font-weight: 600; font-size: 0.98rem; line-height: 1.5; }
.contact-info-card .val a:hover { color: var(--gold); }
.map-frame {
  margin-top: 26px; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); aspect-ratio: 16/9;
}
.map-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.quick-contact-row { display: flex; gap: 12px; margin-top: 26px; flex-wrap: wrap; }

/* ---------- randevu ---------- */
.appt-steps { display: flex; gap: 0; margin: 46px 0 34px; }
.appt-step {
  flex: 1; text-align: center; position: relative;
  padding-bottom: 18px; font-size: 0.88rem; font-weight: 700; color: var(--text-3);
}
.appt-step::after {
  content: ''; position: absolute; inset-inline: 0; bottom: 0; height: 2px;
  background: var(--line-soft); transition: background 0.4s;
}
.appt-step.active { color: var(--gold); }
.appt-step.active::after { background: var(--gold); }
.appt-step .n {
  display: inline-grid; place-items: center; width: 26px; height: 26px;
  border-radius: 50%; border: 1px solid currentColor; margin-inline-end: 8px;
  font-size: 0.8rem;
}
.appt-panel { max-width: 760px; margin: 0 auto; }
/* minmax(0,1fr): hucre icerigi (rozet yazisi) sutunlari genisletemesin */
.appt-calendar {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px; margin-top: 20px; width: 100%;
}
.appt-calendar .dow {
  text-align: center; font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-3); padding: 8px 0;
}
.appt-day {
  aspect-ratio: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 2px;
  border: 1px solid var(--line-soft); border-radius: 10px;
  font-weight: 600; font-size: 0.95rem; padding: 2px;
  transition: all 0.25s var(--ease);
  min-width: 0; overflow: hidden;   /* tasmayi kesin engelle */
}
.appt-day:not(:disabled):hover { border-color: var(--gold); color: var(--gold); transform: scale(1.06); }
.appt-day.selected { background: var(--gold); border-color: var(--gold); color: #17130a; }
.appt-day.selected .dstate { color: #17130a; opacity: 0.75; }
.appt-day:disabled { cursor: not-allowed; }
.appt-day.other-month { visibility: hidden; }

/* gun durum rozetleri */
.appt-day .dstate {
  font-size: 0.58rem; font-weight: 700; line-height: 1;
  letter-spacing: 0.02em; white-space: nowrap;
}
.appt-day .dstate.free { color: var(--gold); opacity: 0.85; }
.appt-day .dstate.full { color: #e07060; }
/* DOLU gun: kirmizi tonlu, tiklanamaz ama net gorunur */
.appt-day.is-full {
  opacity: 1;
  border-color: rgba(192, 57, 43, 0.45);
  background: rgba(192, 57, 43, 0.08);
  color: var(--text-3);
}
/* KAPALI gun (hafta sonu / tatil) ve gecmis: soluk */
.appt-day.is-closed { opacity: 0.28; }
.appt-day[data-status='musait'] { border-color: rgba(201, 162, 39, 0.35); }

/* takvim altindaki renk aciklamasi */
.cal-legend-row {
  display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 16px;
  font-size: 0.78rem; color: var(--text-3);
}
.cal-legend-row span { display: inline-flex; align-items: center; gap: 6px; }
.cal-legend-row i {
  width: 12px; height: 12px; border-radius: 4px; display: inline-block;
  border: 1px solid var(--line-soft);
}
.cal-legend-row i.lg-free { border-color: rgba(201, 162, 39, 0.55); background: rgba(201, 162, 39, 0.12); }
.cal-legend-row i.lg-full { border-color: rgba(192, 57, 43, 0.45); background: rgba(192, 57, 43, 0.12); }
.cal-legend-row i.lg-closed { opacity: 0.3; }

/* dar ekranda rozet kisalir: "10 saat müsait" -> "10" */
@media (max-width: 700px) {
  .appt-calendar { gap: 5px; }
  .appt-day { font-size: 0.85rem; border-radius: 8px; padding: 1px; }
  .appt-day .dstate { font-size: 0.55rem; }
  .appt-day .dword { display: none; }          /* "saat müsait" gizlenir */
  .appt-day .dstate.full { font-size: 0.48rem; letter-spacing: -0.02em; }
  .cal-legend-row { gap: 4px 12px; font-size: 0.72rem; }
}
@media (max-width: 400px) {
  .appt-calendar { gap: 3px; }
  .appt-day { border-radius: 6px; font-size: 0.78rem; }
  .appt-day .dstate.full { font-size: 0.42rem; }
}
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-top: 26px; }
.cal-head .title { font-family: var(--serif); font-size: 1.4rem; font-weight: 700; }
.cal-head button {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line-soft);
  display: grid; place-items: center; transition: all 0.3s;
}
.cal-head button:hover { border-color: var(--gold); color: var(--gold); }

.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin-top: 24px; }
.slot {
  padding: 13px 8px; text-align: center; border: 1px solid var(--line-soft);
  border-radius: 10px; font-weight: 700; font-size: 0.92rem;
  transition: all 0.25s var(--ease);
}
.slot:not(:disabled):hover { border-color: var(--gold); color: var(--gold); }
.slot.selected { background: var(--gold); border-color: var(--gold); color: #17130a; }
.slot:disabled { opacity: 0.3; cursor: not-allowed; text-decoration: line-through; }

.type-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 22px; }
.type-card {
  padding: 18px 14px; text-align: center; border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm); cursor: pointer; transition: all 0.3s;
  font-size: 0.88rem; font-weight: 600;
}
.type-card svg { width: 24px; height: 24px; margin: 0 auto 8px; color: var(--text-3); transition: color 0.3s; }
.type-card.selected { border-color: var(--gold); background: var(--gold-soft); }
.type-card.selected svg { color: var(--gold); }
.appt-nav { display: flex; justify-content: space-between; margin-top: 30px; gap: 14px; }

/* randevu ozet kutusu */
.appt-summary {
  background: var(--gold-soft); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 18px 24px; margin-bottom: 26px;
  display: flex; gap: 24px; flex-wrap: wrap; font-size: 0.95rem;
}
.appt-summary b { color: var(--gold); }

/* ---------- araclar ---------- */
.tool-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 60px; align-items: start; }
.calc-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 40px;
}
/* minmax(0,1fr): uzun secenek metni (dosya adi + esas no) sutunu tasirmasin */
.calc-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 24px; }
.calc-result {
  margin-top: 10px; border-radius: var(--radius);
  background:
    radial-gradient(400px 200px at 90% 0%, rgba(201, 162, 39, 0.18), transparent 60%),
    var(--bg-3);
  border: 1px solid var(--line);
  padding: 34px 38px;
  display: none;
}
.calc-result.show { display: block; animation: resultIn 0.6s var(--ease); }
@keyframes resultIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.calc-result .big {
  font-family: var(--serif); font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700; color: var(--gold); line-height: 1.1;
}
.calc-result .rows { margin-top: 20px; }
.calc-result .rrow {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 10px 0; border-bottom: 1px dashed var(--line-soft);
  font-size: 0.94rem;
}
.calc-result .rrow:last-child { border-bottom: 0; }
.calc-result .rrow .k { color: var(--text-2); }
.calc-result .rrow .v { font-weight: 700; }
.tool-actions { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }

/* bilgi karti (nafaka/infaz gibi hesaplanamayan) */
.info-list { display: grid; gap: 14px; margin-top: 10px; }
.info-item {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm); padding: 22px 26px;
}
.info-item h4 { font-family: var(--serif); font-size: 1.15rem; margin-bottom: 8px; color: var(--gold); }
.info-item p { font-size: 0.92rem; color: var(--text-2); line-height: 1.7; }

/* ---------- portal & admin ortak ---------- */
.app-shell { display: grid; grid-template-columns: 264px 1fr; min-height: 100vh; }
.app-side {
  background: var(--bg-2); border-inline-end: 1px solid var(--line-soft);
  padding: 28px 18px; display: flex; flex-direction: column; gap: 4px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.app-side .brand { padding: 0 12px 24px; }
.app-side a.nav-item, .app-side button.nav-item {
  display: flex; align-items: center; gap: 13px;
  padding: 13px 16px; border-radius: 10px;
  font-size: 0.94rem; font-weight: 600; color: var(--text-2);
  transition: all 0.25s; width: 100%; text-align: start;
}
.app-side a.nav-item:hover { background: var(--gold-soft); color: var(--gold); }
.app-side a.nav-item.active { background: var(--gold); color: #17130a; }
.app-side .nav-item svg { width: 20px; height: 20px; flex: 0 0 auto; }
.app-side .spacer { flex: 1; }
.app-side .badge {
  margin-inline-start: auto; background: #c0392b; color: #fff;
  font-size: 0.7rem; font-weight: 800; padding: 2px 8px; border-radius: 999px;
}
.app-side a.nav-item.active .badge { background: #17130a; color: var(--gold); }

.app-main { padding: 40px 44px; min-width: 0; }
.app-title { font-family: var(--serif); font-size: 2rem; font-weight: 700; margin-bottom: 6px; }
.app-sub { color: var(--text-3); font-size: 0.92rem; margin-bottom: 34px; }

.stat-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 38px; }
.stat-cards--3 { grid-template-columns: repeat(3, 1fr); }
.stat-card {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 26px;
  transition: transform 0.35s var(--ease), border-color 0.35s;
}
.stat-card:hover { transform: translateY(-4px); border-color: var(--line); }
.stat-card .num { font-family: var(--serif); font-size: 2.4rem; font-weight: 700; color: var(--gold); line-height: 1; }
.stat-card .lbl { font-size: 0.82rem; color: var(--text-3); margin-top: 8px; letter-spacing: 0.06em; text-transform: uppercase; }

.data-table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-soft); }
.data-table th {
  text-align: start; padding: 15px 18px; font-size: 0.75rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-3); background: var(--bg-2);
  border-bottom: 1px solid var(--line-soft);
}
.data-table td { padding: 15px 18px; font-size: 0.92rem; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tr:hover td { background: color-mix(in srgb, var(--gold) 3%, transparent); }

.pill { display: inline-block; padding: 4px 14px; border-radius: 999px; font-size: 0.76rem; font-weight: 800; letter-spacing: 0.05em; }
.pill--gold { background: var(--gold-soft); color: var(--gold); }
.pill--green { background: rgba(46, 160, 67, 0.12); color: #58c472; }
.pill--red { background: rgba(192, 57, 43, 0.12); color: #e07060; }
.pill--gray { background: var(--line-soft); color: var(--text-3); }

.card-box {
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 30px; margin-bottom: 26px;
}
.card-box > h3 { font-family: var(--serif); font-size: 1.3rem; margin-bottom: 20px; }

/* mesajlasma */
.chat-wrap { display: grid; grid-template-rows: 1fr auto; height: calc(100vh - 220px); min-height: 420px; }
.chat-scroll { overflow-y: auto; padding: 10px 4px; display: flex; flex-direction: column; gap: 12px; }
.bubble {
  max-width: 70%; padding: 13px 18px; border-radius: 16px; font-size: 0.94rem; line-height: 1.55;
  position: relative;
}
.bubble .when { display: block; font-size: 0.7rem; opacity: 0.6; margin-top: 5px; }
.bubble--me { align-self: flex-end; background: var(--gold); color: #17130a; border-end-end-radius: 4px; }
.bubble--them { align-self: flex-start; background: var(--bg-3); border: 1px solid var(--line-soft); border-end-start-radius: 4px; }
.chat-input { display: flex; gap: 12px; padding-top: 16px; }
.chat-input textarea {
  flex: 1; padding: 14px 18px; background: var(--bg-2);
  border: 1px solid var(--line-soft); border-radius: var(--radius-sm);
  min-height: 54px; max-height: 140px; resize: vertical;
}
.chat-input textarea:focus { outline: none; border-color: var(--gold); }

/* portal giris ekrani */
.auth-wrap {
  min-height: 100vh; display: grid; place-items: center;
  background:
    radial-gradient(900px 500px at 75% 10%, rgba(201, 162, 39, 0.12), transparent 60%),
    var(--bg);
  padding: 40px 20px;
}
.auth-card {
  width: 100%; max-width: 440px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 20px; padding: 46px 42px;
  box-shadow: var(--shadow);
}
.auth-card .brand { justify-content: center; margin-bottom: 26px; }
.auth-card h1 { font-family: var(--serif); font-size: 1.7rem; text-align: center; margin-bottom: 8px; }
.auth-card .sub { text-align: center; color: var(--text-3); font-size: 0.9rem; margin-bottom: 30px; }

/* bildirimler listesi */
.notif-item {
  display: flex; gap: 16px; padding: 18px 20px;
  background: var(--surface); border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm); margin-bottom: 12px;
  transition: border-color 0.3s;
}
.notif-item:hover { border-color: var(--line); }
.notif-item.unread { border-inline-start: 3px solid var(--gold); }
.notif-item .ic {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 10px;
  background: var(--gold-soft); color: var(--gold); display: grid; place-items: center;
}
/* dosya adinin yanindaki esas/dosya no — ayni konulu dosyalari ayirir */
.muted-sm { color: var(--text-3); font-size: 0.82rem; white-space: nowrap; }
/* uzun dosya adlari / esas no'lar satiri tasirmasin, kelime icinden kirilsin */
.notif-item > div { min-width: 0; }
.notif-item .t { font-weight: 700; font-size: 0.95rem; overflow-wrap: anywhere; }
.notif-item .b { font-size: 0.86rem; color: var(--text-2); overflow-wrap: anywhere; }
.notif-item .when { font-size: 0.75rem; color: var(--text-3); margin-inline-start: auto; white-space: nowrap; }
/* satir sonundaki eylem butonlari (gorev tamam/sil, bitti...) */
.notif-actions { display: flex; gap: 8px; flex: 0 0 auto; align-items: center; }

/* zaman cizelgesi (durusma) */
.timeline { position: relative; padding-inline-start: 30px; }
.timeline::before {
  content: ''; position: absolute; inset-block: 6px; inset-inline-start: 9px;
  width: 2px; background: var(--line-soft);
}
.tl-item { position: relative; padding-bottom: 26px; }
.tl-item::before {
  content: ''; position: absolute; inset-inline-start: -27px; top: 5px;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--gold);
}
.tl-item.past::before { border-color: var(--text-3); }
.tl-item .date { font-weight: 800; color: var(--gold); font-size: 0.95rem; }
.tl-item.past .date { color: var(--text-3); }
.tl-item .info { font-size: 0.9rem; color: var(--text-2); margin-top: 4px; }

/* admin form ic gruplar */
.lang-tabs { display: flex; gap: 6px; margin-bottom: 20px; }
.lang-tabs button {
  padding: 9px 22px; border-radius: 999px; font-weight: 700; font-size: 0.85rem;
  border: 1px solid var(--line-soft); color: var(--text-2); transition: all 0.3s;
}
.lang-tabs button.active { background: var(--gold); border-color: var(--gold); color: #17130a; }
.lang-pane { display: none; }
.lang-pane.active { display: block; }

/* ---------- kaydirilabilir liste kutusu ----------
   Uzun listeler sayfayi asagi uzatmasin: icerik biriktikce bolum
   kendi icinde kayar (mesajlar sol listesindeki davranisin geneli). */
.scroll-box {
  max-height: min(62vh, 600px);
  overflow-y: auto;
  padding-inline-end: 4px;
  min-height: 0;
}
.scroll-box--short { max-height: min(46vh, 420px); }
/* tablo iceren scroll-box'ta baslik satiri yapisik kalir */
.scroll-box .data-table thead th { position: sticky; top: 0; z-index: 2; }

/* ince, tema uyumlu kaydirma cubugu (tum ic kaydirma alanlari) */
.scroll-box, .app-side, .chat-scroll, #threadList {
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.scroll-box::-webkit-scrollbar, .app-side::-webkit-scrollbar,
.chat-scroll::-webkit-scrollbar, #threadList::-webkit-scrollbar { width: 8px; }
.scroll-box::-webkit-scrollbar-track, .app-side::-webkit-scrollbar-track,
.chat-scroll::-webkit-scrollbar-track, #threadList::-webkit-scrollbar-track { background: transparent; }
.scroll-box::-webkit-scrollbar-thumb, .app-side::-webkit-scrollbar-thumb,
.chat-scroll::-webkit-scrollbar-thumb, #threadList::-webkit-scrollbar-thumb {
  background: var(--line); border-radius: 8px;
}
.scroll-box::-webkit-scrollbar-thumb:hover { background: var(--gold-dark); }

/* ---------- admin takvim ---------- */
/* minmax(0,1fr): hucrelerin icerigi (nowrap etiketler) sutunlari
   genisletemesin — sag kenardan tasmanin kesin cozumu */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  grid-auto-rows: minmax(106px, auto);
  gap: 6px;
  width: 100%;
}
.cal-dow {
  text-align: center; font-size: 0.72rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--text-3); padding: 6px 0;
}
.cal-cell {
  min-width: 0; overflow: hidden;
  border: 1px solid var(--line-soft); border-radius: 10px;
  padding: 8px; display: flex; flex-direction: column; gap: 3px;
  transition: border-color 0.25s, background 0.25s;
}
.cal-cell:hover { border-color: var(--line); }
.cal-cell.other { border: 0; }
.cal-cell.today { border-color: var(--gold); background: var(--gold-soft); }
.cal-cell.weekend { background: color-mix(in srgb, var(--bg-2) 55%, transparent); }
.cal-cell .dn { font-weight: 800; font-size: 0.85rem; color: var(--text-3); flex: 0 0 auto; }
.cal-cell.today .dn { color: var(--gold); }
.cal-item {
  display: flex; align-items: center; gap: 5px;
  font-size: 0.72rem; color: var(--text-2); min-width: 0;
}
.cal-item .dot { flex: 0 0 auto; width: 7px; height: 7px; border-radius: 50%; }
.cal-item .lbl {
  min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transition: color 0.2s;
}
.cal-item:hover .lbl { color: var(--gold); }
.cal-more { font-size: 0.68rem; color: var(--text-3); }
.cal-legend { display: inline-flex; align-items: center; gap: 6px; margin-inline-end: 16px; }
.cal-legend .dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
@media (max-width: 1080px) {
  .cal-grid { grid-auto-rows: minmax(84px, auto); gap: 4px; }
  .cal-cell { padding: 5px; border-radius: 8px; }
  .cal-item { font-size: 0.66rem; }
}

/* ---------- ikon boyutu guvenceleri ---------- */
.faq-q .ic svg { width: 15px; height: 15px; }
.notif-item .ic svg { width: 20px; height: 20px; }
.success-icon { width: 74px; height: 74px; border-radius: 50%; background: var(--gold-soft); color: var(--gold); display: grid; place-items: center; margin: 0 auto 22px; }
.success-icon svg { width: 34px; height: 34px; }

/* ---------- RTL ince ayarlari ---------- */
html[dir='rtl'] .hero-title { line-height: 1.3; }
html[dir='rtl'] .hero-title .line { overflow: visible; }
html[dir='rtl'] .section-title { line-height: 1.35; }

@media (max-width: 1080px) {
  .area-detail-grid, .article-layout, .tool-layout { grid-template-columns: 1fr; }
  .side-panel { position: static; }
  .contact-grid { grid-template-columns: 1fr; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
}
/* =====================================================================
   MOBIL: admin + portal premium uyarlama
   ===================================================================== */

/* mobil ust cubuk — yalniz 860px altinda gorunur */
.app-topbar {
  display: none;
  position: sticky; top: 0; z-index: 90;
  align-items: center; gap: 14px;
  padding: 12px 16px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.app-topbar .tb-burger {
  width: 44px; height: 44px; border-radius: 12px;
  border: 1px solid var(--line); display: grid; place-items: center;
  color: var(--gold); flex: 0 0 auto;
}
.app-topbar .tb-burger svg { width: 22px; height: 22px; }
.app-topbar .tb-brand {
  display: flex; align-items: center; gap: 10px; min-width: 0;
}
.app-topbar .tb-brand .brand-mono { width: 36px; height: 36px; font-size: 1.2rem; }
.app-topbar .tb-title {
  font-family: var(--serif); font-weight: 700; font-size: 1.05rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.app-topbar .tb-badge {
  margin-inline-start: auto; flex: 0 0 auto;
  background: #c0392b; color: #fff; font-size: 0.72rem; font-weight: 800;
  min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px;
  display: grid; place-items: center;
}

/* cekmece arkasi karartma */
.side-backdrop {
  position: fixed; inset: 0; z-index: 99;
  background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(2px);
  opacity: 0; pointer-events: none; transition: opacity 0.35s;
}
body.side-open .side-backdrop { opacity: 1; pointer-events: auto; }

@media (max-width: 860px) {
  .app-shell { display: block; }
  .app-topbar { display: flex; }
  .app-side {
    position: fixed; inset-block: 0; inset-inline-start: 0; z-index: 100;
    height: 100dvh; width: min(310px, 86vw);
    transform: translateX(-100%);
    transition: transform 0.38s var(--ease);
    box-shadow: 24px 0 60px rgba(0, 0, 0, 0.45);
    border-inline-end: 1px solid var(--line);
  }
  html[dir='rtl'] .app-side { transform: translateX(100%); box-shadow: -24px 0 60px rgba(0, 0, 0, 0.45); }
  body.side-open .app-side { transform: none; }
  /* cekmece acikken arka plan kaymasin */
  html.side-locked, body.side-open { overflow: hidden; height: 100%; }
  .app-main { padding: 20px 16px 40px; }
  .app-title { font-size: 1.5rem; }
  .app-sub { margin-bottom: 22px; }

  .calc-grid-2 { grid-template-columns: 1fr; }
  .type-cards { grid-template-columns: 1fr; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .stat-cards--3 { grid-template-columns: 1fr; }
  .stat-card { padding: 18px; }
  .stat-card .num { font-size: 1.7rem; }
  .card-box { padding: 20px 16px; border-radius: 12px; }

  /* tablolar: data-label'li olanlar KART gorunumune doner,
     digerleri yatayda parmakla kaydirilir */
  .data-table:not(.cards) { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .data-table.cards { display: block; border: 0; background: transparent; }
  .data-table.cards thead { display: none; }
  .data-table.cards tbody { display: block; }
  .data-table.cards tr {
    display: block; margin-bottom: 12px;
    background: var(--surface); border: 1px solid var(--line-soft);
    border-radius: 12px; padding: 14px 16px;
  }
  .data-table.cards tr:hover td { background: transparent; }
  .data-table.cards td {
    display: flex; justify-content: space-between; align-items: center; gap: 14px;
    border: 0; padding: 6px 0; font-size: 0.9rem; text-align: end;
  }
  .data-table.cards td::before {
    content: attr(data-label);
    font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase;
    color: var(--text-3); font-weight: 700; text-align: start; flex: 0 0 auto;
  }
  .data-table.cards td:not([data-label])::before { content: none; }
  .data-table.cards td:not([data-label]) { justify-content: flex-end; padding-top: 10px; }
  .scroll-box .data-table.cards thead th { position: static; }

  /* sohbet mobil */
  .chat-wrap { height: calc(100dvh - 190px) !important; min-height: 360px; }
  .bubble { max-width: 88%; }
  .chat-input { flex-direction: column; }
  .chat-input textarea { min-height: 64px; }
  .chat-input .btn { width: 100%; }

  /* mesajlar: sol liste + sohbet alt alta */
  .msg-grid { grid-template-columns: 1fr !important; }
  .msg-grid > .card-box:first-child { max-height: 300px !important; }

  /* takvim mobil: kompakt hucreler, yalniz nokta + etiket kucuk */
  .cal-grid { grid-auto-rows: minmax(64px, auto); gap: 3px; }
  .cal-cell { padding: 4px; border-radius: 6px; }
  .cal-cell .dn { font-size: 0.72rem; }
  .cal-item { font-size: 0; gap: 0; margin-top: 2px; }
  .cal-item .dot { width: 8px; height: 8px; }
  .cal-more { font-size: 0.62rem; }
  .cal-head .title { font-size: 1.1rem; }

  /* dokunma hedefleri */
  .btn--sm { padding: 11px 18px; }
  .app-side a.nav-item, .app-side button.nav-item { padding: 14px 16px; }

  /* gorev/bildirim satirlari mobilde: butonlar icerigi sikistirmasin,
     alta tam genislik satira insin */
  .notif-item { flex-wrap: wrap; gap: 8px 12px; padding: 14px; }
  .notif-item .t { line-height: 1.5; }
  .notif-item .t .pill { display: inline-block; margin-top: 4px; margin-inline-start: 0 !important; }
  .notif-item .when { flex-basis: 100%; order: 5; margin-inline-start: 52px; margin-top: -4px; }
  .notif-actions { flex-basis: 100%; order: 9; justify-content: stretch; }
  .notif-actions form { flex: 1; display: flex; }
  .notif-actions .btn { width: 100%; justify-content: center; }
}

/* iOS otomatik zoom onleme: dokunmatikte form yazilari >= 16px */
@media (max-width: 860px) {
  input, select, textarea { font-size: 16px !important; }
}
