/*
 Theme Name:   istanbul-escort
 Theme URI:    https://istanbulescort.org
 Description:  GeneratePress child theme — directory mimarisi (CPT `ilan` + lokasyon/kategori/format taxonomyleri).
 Author:       istanbulescort.org
 Template:     generatepress
 Version:      2.0.0
 Text Domain:  istanbul-escort
*/

/* ============ ROOT ============ */
:root {
  --bg: #150b26;
  --bg-card: #241438;
  --bg-elev: #2d1a4a;
  --bg-deep: #0f071c;
  --accent: #ff3d8b;
  --accent-hover: #ff6ba6;
  --accent-soft: #ff3d8b22;
  --text: #f5f0ff;
  --text-dim: #b8a8d0;
  --text-strong: #ffffff;
  --border: #3d2560;
  --border-soft: #2a1640;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 20px rgba(0,0,0,0.3);
  --shadow-strong: 0 8px 32px rgba(255,61,139,0.15);
}

/* ============ BASE ============ */
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  line-height: 1.6;
}

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--accent-hover); }

h1, h2, h3, h4, h5, h6 { color: var(--text-strong); font-weight: 700; line-height: 1.3; }
h1 { font-size: 2.4rem; margin: 0 0 1rem; }
h2 { font-size: 1.7rem; margin: 2.2rem 0 1rem; }
h3 { font-size: 1.3rem; margin: 1.6rem 0 .75rem; }
h4 { font-size: 1.1rem; margin: 1.2rem 0 .5rem; }

p { margin: 0 0 1rem; color: var(--text-dim); }
strong { color: var(--text-strong); }

/* ============ LAYOUT ============ */
/* directory-shell.php GeneratePress sınıfları kullanır; GP CSS yüklenmez. */
.grid-container {
  max-width: 1280px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
  box-sizing: border-box;
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

.screen-reader-text:focus {
  background-color: var(--bg-elev);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  clip: auto !important;
  clip-path: none;
  color: var(--text-strong);
  display: block;
  font-size: .875rem;
  height: auto;
  left: .5rem;
  line-height: normal;
  padding: .75rem 1rem;
  text-decoration: none;
  top: .5rem;
  width: auto;
  z-index: 100000;
}

.site-header {
  background: var(--bg-deep);
  border-bottom: 1px solid var(--border);
  padding: .75rem 0;
  margin-bottom: .5rem;
}

.site-header .main-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}

.site-header .main-title a {
  color: var(--text-dim);
}

.site-header .main-title a:hover {
  color: var(--accent);
}

.site-main, main { max-width: 1200px; margin: 0 auto; padding: 2rem 1rem; }

/* ============ BREADCRUMB ============ */
.crumb {
  font-size: .9rem;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
  padding: .5rem 0;
}
.crumb a { color: var(--accent); }
.crumb a:hover { color: var(--accent-hover); }
.crumb-sep { color: var(--text-dim); margin: 0 .35rem; font-weight: 300; }
.crumb-current { color: var(--text); font-weight: 500; }

/* ============ HOMEPAGE HERO ============ */
.home-hero {
  text-align: center;
  margin: 1rem 0 2.5rem;
  padding: 2rem 1rem;
}
.home-hero h1 {
  font-size: 3rem;
  background: linear-gradient(135deg, var(--accent), #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: .75rem;
}
.home-tagline {
  font-size: 1.15rem;
  color: var(--text-dim);
  max-width: 720px;
  margin: 0 auto;
}

/* ============ HOMEPAGE CONTENT (AI long-form) ============ */
.home-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 2.5rem;
  margin: 2rem 0 3rem;
}
.home-content p { color: var(--text); font-size: 1.02rem; }
.home-content h2 {
  margin-top: 2rem;
  border-bottom: 2px solid var(--border-soft);
  padding-bottom: .5rem;
}
.home-content h3 { color: var(--accent); }
.home-content ul, .home-content ol {
  color: var(--text-dim);
  padding-left: 1.5rem;
}
.home-content a {
  border-bottom: 1px dotted var(--accent);
}

/* ============ YAKA CARDS (anasayfa) ============ */
.home-yakas {
  margin: 3rem 0;
}
.yaka-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.yaka-card {
  display: block;
  background: linear-gradient(135deg, var(--bg-card), var(--bg-elev));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  color: var(--text);
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.yaka-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: var(--shadow-strong);
  color: var(--text);
}
.yaka-card h3 {
  font-size: 1.5rem;
  margin: 0 0 .4rem;
  color: var(--text-strong);
}
.yaka-count {
  display: inline-block;
  font-size: .85rem;
  color: var(--accent);
  background: var(--accent-soft);
  padding: .2rem .7rem;
  border-radius: 12px;
  margin-bottom: .75rem;
}
.yaka-card p {
  color: var(--text-dim);
  margin: .5rem 0 1rem;
  font-size: .95rem;
  line-height: 1.5;
}
.yaka-cta {
  color: var(--accent);
  font-weight: 600;
  font-size: .9rem;
}

/* ============ YAKA-GROUPED İLÇE LIST (anasayfa) ============ */
.home-all-ilceler {
  margin: 3rem 0;
}
.yaka-group {
  margin: 2rem 0;
}
.yaka-group h2,
.yaka-group h3 {
  font-size: 1.4rem;
  border-bottom: 2px solid var(--border-soft);
  padding-bottom: .5rem;
  margin: 0 0 1rem;
}
.yaka-group h2 a,
.yaka-group h3 a {
  color: var(--text-strong);
}
.yaka-group h2 a:hover,
.yaka-group h3 a:hover {
  color: var(--accent);
}

/* ============ İLÇE LIST GRID ============ */
.ilce-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: .5rem;
  margin: 1rem 0 1.5rem;
}
.ilce-list li {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all .2s;
}
.ilce-list li:hover {
  border-color: var(--accent);
  background: var(--bg-elev);
}
.ilce-list a {
  display: block;
  padding: .65rem 1rem;
  color: var(--text);
}

/* ============ ARCHIVE HEADER (yaka pages) ============ */
.archive-header {
  margin-bottom: 1rem;
}
.archive-header h1 {
  font-size: 2.2rem;
}
.cat-description, .tag-description {
  background: var(--bg-card);
  border-left: 4px solid var(--accent);
  padding: 1.5rem 2rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: 1.5rem 0 2rem;
}
.cat-description p, .tag-description p {
  color: var(--text);
}
.cat-description h2, .cat-description h3 {
  color: var(--accent);
  margin-top: 1.2rem;
}

/* ============ POSTS GRID (kategori arşivi) ============ */
.posts-grid {
  margin: 2rem 0;
}
.posts-grid h2 {
  margin-bottom: 1rem;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
  margin: 1.5rem 0;
}
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}
.card a {
  display: block;
  color: inherit;
}
.card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  background: var(--bg-elev);
}
.card a:not(:has(img))::before {
  content: "";
  display: block;
  height: 200px;
  background: linear-gradient(135deg, var(--bg-elev), var(--border));
}
.card h3 {
  padding: .85rem 1rem .25rem;
  font-size: 1.1rem;
  margin: 0;
}
.card p {
  padding: 0 1rem 1rem;
  font-size: .9rem;
  color: var(--text-dim);
  line-height: 1.5;
}

/* ============ SINGLE PILLAR POST ============ */
.pillar-post {
  background: var(--bg-card);
  padding: 2rem 2.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 2rem;
}
.pillar-header h1 {
  font-size: 2.3rem;
  margin-bottom: .8rem;
  line-height: 1.25;
}
.pillar-header .meta {
  color: var(--text-dim);
  font-size: .9rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-soft);
}
.pillar-header .meta a { color: var(--accent); }
.pillar-header .meta-sep { margin: 0 .5rem; opacity: .6; }
.pillar-thumbnail {
  margin: 0 0 2rem;
}
.pillar-thumbnail img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* ============ TOC (otomatik enjekte) ============ */
.post-toc {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  margin: 0 0 2rem;
  font-size: .95rem;
}
.post-toc strong {
  display: block;
  font-size: 1rem;
  color: var(--accent);
  margin-bottom: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.post-toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
  columns: 2;
  column-gap: 1.5rem;
}
.post-toc li {
  margin: .35rem 0;
  break-inside: avoid;
}
.post-toc a {
  color: var(--text);
  border-bottom: 1px dotted transparent;
}
.post-toc a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ============ PILLAR CONTENT TYPOGRAPHY (long-form readability) ============ */
.pillar-content {
  font-size: 1.05rem;
  line-height: 1.85;
}
.pillar-content p {
  color: var(--text);
  margin-bottom: 1.2rem;
}
.pillar-content h2 {
  margin-top: 2.5rem;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--border-soft);
  scroll-margin-top: 1rem;
}
.pillar-content h3 {
  margin-top: 1.8rem;
  color: var(--accent-hover);
}
.pillar-content ul, .pillar-content ol {
  color: var(--text);
  padding-left: 1.5rem;
  margin-bottom: 1.2rem;
}
.pillar-content li {
  margin-bottom: .35rem;
}
.pillar-content a {
  color: var(--accent);
  border-bottom: 1px dotted var(--accent);
  transition: all .2s;
}
.pillar-content a:hover {
  color: var(--accent-hover);
  border-bottom-style: solid;
  border-bottom-color: var(--accent-hover);
}
.pillar-content strong {
  color: var(--text-strong);
}

/* ============ SAME-YAKA RELATED (single altı) ============ */
.related-yaka {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin: 2rem 0;
}
.related-yaka h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  color: var(--accent);
  border-bottom: 1px solid var(--border-soft);
  padding-bottom: .5rem;
}
.related-yaka ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: .5rem;
}
.related-yaka li a {
  display: block;
  padding: .55rem .9rem;
  background: var(--bg-elev);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  color: var(--text);
  transition: all .2s;
}
.related-yaka li a:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--text-strong);
}

.district-areas__group {
  margin-top: 1.25rem;
}
.district-areas__group:first-of-type {
  margin-top: 0;
}
.district-areas__heading {
  margin: 0 0 .65rem;
  font-size: .95rem;
  font-weight: 600;
  color: var(--text-strong);
}
.district-areas__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: .5rem;
}
.district-areas__list a {
  display: block;
  padding: .55rem .9rem;
  background: var(--bg-elev);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  color: var(--text);
  transition: all .2s;
}
.district-areas__list a:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--text-strong);
}

/* ============ BACK-TO-YAKA LINK ============ */
.back-to-yaka {
  text-align: center;
  margin: 2rem 0 1rem;
}
.yaka-link {
  display: inline-block;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .9rem 1.6rem;
  color: var(--accent);
  font-weight: 600;
  transition: all .2s;
}
.yaka-link:hover {
  background: var(--accent);
  color: var(--text-strong);
  border-color: var(--accent);
}

/* ============ PAGINATION ============ */
.pagination, .nav-links {
  display: flex;
  justify-content: center;
  gap: .5rem;
  margin: 3rem 0;
  flex-wrap: wrap;
}
.pagination a, .nav-links a, .pagination .current, .nav-links .current {
  padding: .6rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
}
.pagination .current, .nav-links .current {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

/* ============ FOOTER ============ */
.site-footer, footer {
  background: var(--bg-deep);
  border-top: 1px solid var(--border);
  padding: 2rem 1rem;
  color: var(--text-dim);
}

/* ============ MOBILE ============ */
@media (max-width: 768px) {
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.35rem; }
  .home-hero h1 { font-size: 2.2rem; }
  .pillar-post { padding: 1.25rem; }
  .pillar-header h1 { font-size: 1.7rem; }
  .home-content { padding: 1.5rem 1.25rem; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .75rem; }
  .card img { height: 140px; }
  .card h3 { font-size: .95rem; padding: .5rem .75rem .25rem; }
  .ilce-list { grid-template-columns: repeat(2, 1fr); }
  .related-yaka ul { grid-template-columns: repeat(2, 1fr); }
  .post-toc ul { columns: 1; }
  .pillar-content { font-size: 1rem; line-height: 1.7; }
}

/* ============ GENERATEPRESS FULL-WIDTH OVERRIDES ============ */
html body .site.grid-container,
html body .site-content {
  max-width: 1280px !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
html body .site-content {
  padding: 0 30px !important;
  box-sizing: border-box !important;
}
html body main.home,
html body main.single,
html body main.archive,
html body main {
  width: 100% !important;
  max-width: 1200px !important;
  box-sizing: border-box !important;
}

body.home .content-area,
body.archive .content-area,
body.page .content-area,
body.single .content-area {
  width: 100% !important;
  float: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.home #secondary,
body.archive #secondary,
body.page #secondary,
body.single #secondary {
  display: none !important;
}

.inside-article,
.entry-content,
body.home .inside-article,
body.archive .inside-article,
body.page .inside-article,
body.single .inside-article {
  padding: 1rem 1.5rem !important;
  background: transparent !important;
  border: 0 !important;
}

@media (max-width: 640px) {
  html body .site-content { padding: 0 12px !important; }
  .inside-article, .entry-content { padding: .5rem !important; }
}

/* ============ EMPTY-CONTAINER GUARDS ============ */
.cat-description:empty,
.tag-description:empty,
.home-content:empty {
  display: none !important;
}

/* ============ TAXONOMY ARCHIVE — PARENT CONTEXT ============ */
.archive-parent {
  margin: 0 0 .5rem;
  font-size: .9rem;
  color: var(--text-dim);
  letter-spacing: .02em;
}
.archive-parent a {
  color: var(--accent);
  font-weight: 500;
}
.archive-parent .crumb-sep {
  margin: 0 .35rem;
  opacity: .5;
}

/* ============ TERM CONTENT (rich HTML, term description) ============ */
.term-content-rich {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  padding: 1.75rem 2rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: 1.5rem 0 2.5rem;
  line-height: 1.75;
}
.term-content-rich p {
  color: var(--text);
  margin-bottom: 1.1rem;
}
.term-content-rich h2 {
  margin-top: 2rem;
  font-size: 1.55rem;
  border-bottom: 2px solid var(--border-soft);
  padding-bottom: .4rem;
  scroll-margin-top: 1rem;
}
.term-content-rich h2:first-child {
  margin-top: 0;
}
.term-content-rich h3 {
  color: var(--accent-hover);
  margin-top: 1.5rem;
}
.term-content-rich ul,
.term-content-rich ol {
  color: var(--text);
  padding-left: 1.5rem;
  margin-bottom: 1.2rem;
}
.term-content-rich li {
  margin-bottom: .35rem;
}
.term-content-rich a {
  color: var(--accent);
  border-bottom: 1px dotted var(--accent);
}
.term-content-rich a:hover {
  color: var(--accent-hover);
  border-bottom-style: solid;
}
.term-content-rich strong { color: var(--text-strong); }
.term-content-rich blockquote {
  border-left: 3px solid var(--accent);
  padding: .5rem 0 .5rem 1.25rem;
  margin: 1.25rem 0;
  color: var(--text-dim);
  font-style: italic;
}

/* ============ EMPTY STATE (henüz ilan yok) ============ */
.empty-state {
  margin: 3rem 0;
  text-align: center;
}
.empty-state-inner {
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  max-width: 640px;
  margin: 0 auto;
}
.empty-state-inner h2 {
  margin: 0 0 .75rem;
  font-size: 1.6rem;
  color: var(--accent);
  border: 0;
  padding: 0;
}
.empty-state-inner p {
  color: var(--text-dim);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0 0 1rem;
}
.empty-state-inner p.empty-cta {
  margin-top: 1.5rem;
}

/* ============ MOBİL UYUM (taxonomy archive) ============ */
@media (max-width: 768px) {
  .term-content-rich {
    padding: 1.25rem;
    border-left-width: 3px;
  }
  .term-content-rich h2 { font-size: 1.3rem; }
  .term-content-rich h3 { font-size: 1.1rem; }
  .empty-state-inner {
    padding: 2rem 1.25rem;
  }
  .empty-state-inner h2 { font-size: 1.3rem; }
}
