/* ruyalar.gen.tr — tek dosyalik stil katmani. Harici font/CDN kullanilmaz. */

:root {
  color-scheme: light dark;

  --bg: #f6f4ff;
  --bg-soft: #efebff;
  --surface: #ffffff;
  --surface-2: #f8f7ff;
  --border: #e3ddf7;
  --text: #191a2c;
  --text-muted: #5b6080;
  --accent: #6d3fe0;
  --accent-soft: #ede7ff;
  --accent-contrast: #ffffff;
  --sky: #0b7fc4;
  --gold: #b8860b;
  --shadow: 0 1px 2px rgba(25, 26, 44, .06), 0 8px 24px -12px rgba(25, 26, 44, .18);
  --shadow-lg: 0 24px 60px -28px rgba(58, 30, 130, .45);
  --radius: 14px;
  --radius-lg: 22px;
  --container: 68rem;
  --header-h: 64px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a0e1f;
    --bg-soft: #0e1430;
    --surface: #141a33;
    --surface-2: #1a2142;
    --border: #262f55;
    --text: #e8eaf7;
    --text-muted: #a1a8c8;
    --accent: #a78bfa;
    --accent-soft: #221d47;
    --accent-contrast: #14112b;
    --sky: #56c8f5;
    --gold: #fbbf24;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 30px -18px rgba(0, 0, 0, .8);
    --shadow-lg: 0 30px 70px -30px rgba(0, 0, 0, .85);
  }
}

:root[data-theme="dark"] {
  --bg: #0a0e1f;
  --bg-soft: #0e1430;
  --surface: #141a33;
  --surface-2: #1a2142;
  --border: #262f55;
  --text: #e8eaf7;
  --text-muted: #a1a8c8;
  --accent: #a78bfa;
  --accent-soft: #221d47;
  --accent-contrast: #14112b;
  --sky: #56c8f5;
  --gold: #fbbf24;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 30px -18px rgba(0, 0, 0, .8);
  --shadow-lg: 0 30px 70px -30px rgba(0, 0, 0, .85);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; }
a { color: var(--accent); text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent); text-underline-offset: .18em; }
a:hover { text-decoration-color: currentColor; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.container { width: min(100% - 2.5rem, var(--container)); margin-inline: auto; }

.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;
}

.skip-link {
  position: absolute; left: 50%; translate: -50% -120%;
  z-index: 100; background: var(--accent); color: var(--accent-contrast);
  padding: .6rem 1.1rem; border-radius: 0 0 12px 12px; font-weight: 600; text-decoration: none;
  transition: translate .2s ease;
}
.skip-link:focus-visible { translate: -50% 0; }

/* ------------------------------------------------------------- ust menu */

.site-header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.site-header__inner {
  display: flex; align-items: center; gap: 1rem;
  min-height: var(--header-h);
}

.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--text); flex: none; }
.logo-mark { width: 30px; height: 30px; flex: none; }
.brand__text { display: flex; flex-direction: column; font-weight: 700; line-height: 1.15; letter-spacing: -.01em; }
.brand__text small { font-weight: 500; font-size: .68rem; color: var(--text-muted); letter-spacing: .02em; }

.theme-toggle {
  margin-inline-start: auto; flex: none;
  display: grid; place-items: center; width: 40px; height: 40px;
  background: var(--surface); color: var(--text-muted);
  border: 1px solid var(--border); border-radius: 12px; cursor: pointer;
  transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
.theme-toggle svg { width: 19px; height: 19px; }
/* Dugmede, gecis yapilacak temanin ikonu gorunur. */
.icon-sun { display: none; }
.icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .icon-sun { display: block; }
  :root:not([data-theme="light"]) .icon-moon { display: none; }
}
:root[data-theme="dark"] .icon-sun { display: block; }
:root[data-theme="dark"] .icon-moon { display: none; }
:root[data-theme="light"] .icon-sun { display: none; }
:root[data-theme="light"] .icon-moon { display: block; }

/* ---------------------------------------------------------------- arama */

.search { position: relative; display: flex; align-items: center; gap: .5rem; }
.search--header { flex: 1 1 auto; max-width: 26rem; margin-inline: auto; }
.search--hero { width: min(100%, 40rem); margin: 1.6rem auto 0; }

.search__icon {
  position: absolute; inset-inline-start: .85rem; width: 18px; height: 18px;
  color: var(--text-muted); pointer-events: none;
}
.search__input {
  width: 100%; font: inherit; color: var(--text);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 999px; padding: .6rem 1rem .6rem 2.6rem;
  box-shadow: var(--shadow);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.search__input::placeholder { color: var(--text-muted); }
.search__input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.search--hero .search__input { padding: .95rem 1.2rem .95rem 3rem; font-size: 1.05rem; border-radius: var(--radius-lg); }
.search--hero .search__icon { inset-inline-start: 1.1rem; width: 20px; height: 20px; }

.search__submit {
  flex: none; font: inherit; font-weight: 600; cursor: pointer;
  color: var(--accent-contrast); background: var(--accent);
  border: 1px solid transparent; border-radius: 999px; padding: .6rem 1.2rem;
  transition: filter .15s ease;
}
.search__submit:hover { filter: brightness(1.08); }
.search--header .search__submit { display: none; }
.search--hero .search__submit { padding: .95rem 1.6rem; border-radius: var(--radius-lg); }

.search__results {
  position: absolute; top: calc(100% + .5rem); inset-inline: 0; z-index: 50;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); overflow: hidden; padding: .35rem;
  max-height: min(60vh, 26rem); overflow-y: auto;
}
.search__results[hidden] { display: none; }
.search__result {
  display: block; padding: .6rem .75rem; border-radius: 10px;
  text-decoration: none; color: var(--text);
}
.search__result:hover, .search__result.is-active { background: var(--accent-soft); }
.search__result strong { display: block; font-size: .97rem; font-weight: 650; }
.search__result span { display: block; font-size: .82rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search__empty { padding: .9rem; color: var(--text-muted); font-size: .9rem; text-align: center; }

/* ----------------------------------------------------------------- hero */

.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(60rem 30rem at 15% -20%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 70%),
    radial-gradient(45rem 26rem at 85% 0%, color-mix(in srgb, var(--sky) 22%, transparent), transparent 70%),
    var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    radial-gradient(1.5px 1.5px at 12% 30%, var(--gold), transparent),
    radial-gradient(1.5px 1.5px at 78% 22%, var(--gold), transparent),
    radial-gradient(1.2px 1.2px at 46% 62%, var(--sky), transparent),
    radial-gradient(1.2px 1.2px at 88% 68%, var(--accent), transparent),
    radial-gradient(1px 1px at 28% 78%, var(--gold), transparent);
}
.hero__inner { position: relative; z-index: 1; padding: clamp(2.5rem, 7vw, 4.5rem) 0 clamp(2.2rem, 5vw, 3.5rem); text-align: center; }
.hero__eyebrow {
  display: inline-block; margin: 0 0 .9rem; padding: .3rem .85rem;
  font-size: .8rem; font-weight: 600; letter-spacing: .02em;
  color: var(--accent); background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 999px;
}
.hero__title {
  margin: 0; font-size: clamp(2rem, 6vw, 3.25rem); line-height: 1.1;
  letter-spacing: -.03em; font-weight: 800;
}
.hero__lead { margin: .9rem auto 0; max-width: 42rem; color: var(--text-muted); font-size: clamp(1rem, 2.4vw, 1.15rem); }
.hero__hint { margin: 1rem 0 0; font-size: .9rem; color: var(--text-muted); }
.hero__hint a {
  display: inline-block; margin: .2rem .15rem; padding: .18rem .6rem;
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  text-decoration: none; color: var(--text);
}
.hero__hint a:hover { border-color: var(--accent); color: var(--accent); }

/* -------------------------------------------------------------- bolumler */

.section { padding-block: clamp(2rem, 5vw, 3.25rem); }
.section__title { margin: 0 0 .35rem; font-size: clamp(1.3rem, 3vw, 1.75rem); letter-spacing: -.02em; }
.section__lead { margin: 0 0 1.4rem; color: var(--text-muted); }

.page-head { padding-block: clamp(1.6rem, 4vw, 2.6rem) 0; }
.page-title { margin: .4rem 0 .3rem; font-size: clamp(1.6rem, 4.5vw, 2.4rem); letter-spacing: -.025em; line-height: 1.2; }
.page-lead { margin: 0; color: var(--text-muted); }

.breadcrumb { font-size: .85rem; color: var(--text-muted); display: flex; flex-wrap: wrap; gap: .4rem; }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--accent); }

/* ------------------------------------------------------------ harf dizini */

.letter-grid {
  display: grid; gap: .6rem;
  grid-template-columns: repeat(auto-fill, minmax(4.4rem, 1fr));
}
.letter-tile {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .1rem; padding: .85rem .4rem; text-decoration: none;
  background: var(--surface); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius);
  transition: transform .15s ease, border-color .15s ease, background .15s ease;
}
.letter-tile:hover { transform: translateY(-2px); border-color: var(--accent); background: var(--surface-2); }
.letter-tile__label { font-size: 1.4rem; font-weight: 700; line-height: 1; }
.letter-tile__count { font-size: .72rem; color: var(--text-muted); }

.letter-strip { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: 1.2rem; }
.letter-strip__item {
  min-width: 2.1rem; text-align: center; padding: .3rem .5rem;
  font-weight: 650; text-decoration: none; color: var(--text-muted);
  background: var(--surface); border: 1px solid var(--border); border-radius: 9px;
}
.letter-strip__item:hover { color: var(--accent); border-color: var(--accent); }
.letter-strip__item.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-contrast); }

/* --------------------------------------------------------------- kartlar */

.card-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); }
.card {
  display: flex; flex-direction: column; gap: .45rem; padding: 1.15rem 1.2rem;
  text-decoration: none; color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  transition: transform .18s ease, border-color .18s ease;
}
.card:hover { transform: translateY(-3px); border-color: var(--accent); }
.card__title { margin: 0; font-size: 1.05rem; letter-spacing: -.01em; }
.card__text { margin: 0; font-size: .88rem; color: var(--text-muted); }
.card__more { margin-top: auto; font-size: .82rem; font-weight: 650; color: var(--accent); }

.chip-grid { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip {
  padding: .4rem .85rem; border-radius: 999px; text-decoration: none;
  color: var(--text); background: var(--surface); border: 1px solid var(--border); font-size: .92rem;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }

/* ---------------------------------------------------------------- liste */

.entry-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; grid-template-columns: repeat(auto-fill, minmax(20rem, 1fr)); }
.entry-list__link {
  display: block; height: 100%; padding: .85rem 1rem; text-decoration: none; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  transition: border-color .15s ease, background .15s ease;
}
.entry-list__link:hover { border-color: var(--accent); background: var(--surface-2); }
.entry-list__title { display: block; font-weight: 650; letter-spacing: -.01em; }
.entry-list__excerpt { display: block; margin-top: .2rem; font-size: .85rem; color: var(--text-muted); }

/* --------------------------------------------------------------- makale */

.article { padding-block: clamp(1.6rem, 4vw, 2.6rem) 0; max-width: 48rem; }
.article__title { margin: .5rem 0 1rem; font-size: clamp(1.7rem, 4.5vw, 2.4rem); letter-spacing: -.025em; line-height: 1.2; }

.prose { max-width: 48rem; }
.prose p { margin: 0 0 1.05rem; }
.prose h2 { margin: 2.2rem 0 .6rem; font-size: 1.4rem; letter-spacing: -.02em; }
.prose h3 { margin: 1.8rem 0 .5rem; font-size: 1.15rem; }
.prose h4 { margin: 1.4rem 0 .35rem; font-size: 1rem; color: var(--accent); }
.prose ul { margin: 0 0 1.05rem; padding-inline-start: 1.2rem; }
.prose li { margin-bottom: .35rem; }
.prose .muted { color: var(--text-muted); font-size: .9rem; }

.notice {
  margin: 1.6rem 0; padding: .9rem 1.1rem; font-size: .9rem;
  color: var(--text-muted); background: var(--surface-2);
  border: 1px solid var(--border); border-inline-start: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.pager { display: flex; gap: .75rem; justify-content: space-between; margin: 2rem 0 0; }
.pager__link {
  display: flex; flex-direction: column; gap: .1rem; max-width: 48%;
  padding: .7rem 1rem; text-decoration: none; color: var(--text); font-weight: 650;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
}
.pager__link:hover { border-color: var(--accent); }
.pager__link span { font-size: .75rem; font-weight: 500; color: var(--text-muted); }
.pager__link--next { text-align: end; margin-inline-start: auto; }

.empty { padding: 2rem 1rem; text-align: center; color: var(--text-muted); }
.empty .letter-strip { justify-content: center; }

.button {
  display: inline-block; padding: .7rem 1.4rem; border-radius: 999px; font-weight: 650;
  text-decoration: none; color: var(--accent-contrast); background: var(--accent);
}
.button:hover { filter: brightness(1.08); }
.contact-cta { margin: 1.5rem 0; }

/* -------------------------------------------------------------- altbilgi */

.site-footer { margin-top: clamp(2.5rem, 6vw, 4rem); background: var(--bg-soft); border-top: 1px solid var(--border); }
.site-footer__inner { padding-block: 2rem; display: grid; gap: 1.25rem; }
.footer-letters { display: flex; flex-wrap: wrap; gap: .3rem; }
.footer-letters a {
  min-width: 1.9rem; text-align: center; padding: .2rem .35rem; font-size: .88rem; font-weight: 650;
  color: var(--text-muted); text-decoration: none; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface);
}
.footer-letters a:hover { color: var(--accent); border-color: var(--accent); }
.footer-meta { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; align-items: center; font-size: .9rem; color: var(--text-muted); }
.footer-meta p { margin: 0; }
.footer-meta nav { display: flex; gap: 1rem; }
.footer-external { white-space: nowrap; }
.footer-note { margin: 0; font-size: .82rem; color: var(--text-muted); opacity: .85; }

@media (max-width: 700px) {
  /* Ust menu iki satira dagilir, arama kutusu tam genislik alir. */
  .site-header__inner { flex-wrap: wrap; padding-block: .6rem; row-gap: .55rem; }
  .search--header { order: 3; flex-basis: 100%; max-width: none; }
  .brand__text small { display: none; }
  .pager__link { max-width: 100%; }
  .entry-list { grid-template-columns: 1fr; }
}
