:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface-soft: #1f2630;
  --text: #e6edf3;
  --muted: #9ca3af;
  --accent: #58a6ff;
  --border: #2d333b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.container {
  width: min(1100px, 92%);
  margin: 0 auto;
}

.site-header {
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #0d1117 0%, #111a27 100%);
  padding: 3rem 0 2rem;
}

.cv-header {
  padding: 1.4rem 0 1rem;
}

.top-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.nav-brand {
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: 0.16em;
  color: #f2f6fb;
  margin-right: 1rem;
  white-space: nowrap;
  margin-right: auto;
}

.nav-brand-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  margin-right: auto; /* linkleri sağa iter */
}

.nav-logo {
  position: absolute;
  left: -250px; /* yazıyı kaydırmadan sola yerleştir */
  top: 50%;
  transform: translateY(-50%);
  width: 200px;
  height: 75px;
  border-radius: 8px;
  object-fit: cover;
  pointer-events: none;
}

.top-nav a {
  text-decoration: none;
  color: var(--text);
  border: 1px solid #384150;
  border-radius: 999px;
  padding: 0.3rem 0.7rem;
  font-size: 0.9rem;
}

.top-nav a:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.social-btn {
  width: auto;
  min-height: 38px;
  padding: 0 0.65rem;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-size: 0.9rem;
  color: var(--text);
  border: 1px solid #384150;
  background: rgba(88, 166, 255, 0.08);
  text-decoration: none;
}

.social-btn svg {
  width: 22px;
  height: 22px;
  display: block;
  fill: currentColor;
}

.social-btn::after {
  content: attr(title);
  font-weight: 900;
  font-size: 0.85rem;
  line-height: 1;
  color: var(--text);
}

.social-btn-after-cv {
  margin-left: 2.8rem;
}

.eyebrow {
  color: var(--accent);
  font-weight: 600;
  margin: 0;
}

h1,
h2 {
  line-height: 1.2;
}

.intro {
  color: var(--muted);
  max-width: 70ch;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 1.25rem;
  padding: 2rem 0 3rem;
}

.post-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 560px;
  position: relative;
}

.post-card:focus {
  outline: 2px solid rgba(88, 166, 255, 0.8);
  outline-offset: 2px;
}

.card-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
}

.card-overlay:focus {
  outline: none;
}

.post-card-body {
  position: relative;
  z-index: 0;
}

.post-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.post-card-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  height: 100%;
}

.chip {
  display: inline-flex;
  width: fit-content;
  font-size: 0.72rem;
  color: #b8c4d2;
  border: 1px solid #3b4450;
  border-radius: 999px;
  padding: 0.2rem 0.6rem;
  margin: 0;
}

.excerpt {
  margin: 0;
  color: #dbe4ee;
}

.preview {
  margin: 0;
  color: var(--muted);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 6;
  line-clamp: 6;
  overflow: hidden;
}

.read-more {
  margin-top: auto;
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
}

.read-more:hover {
  text-decoration: underline;
}

.site-footer {
  border-top: 1px solid var(--border);
  color: var(--muted);
  padding: 1rem 0 2rem;
}

.detail-header {
  padding: 1.25rem 0;
}

.back-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.post-detail {
  width: min(900px, 100%);
  margin: 2rem auto 4rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.25rem;
}

.detail-image {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 1rem;
}

.lead {
  color: #dbe4ee;
  font-size: 1.06rem;
}

.doc-links {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.85rem;
  background: var(--surface-soft);
  margin-bottom: 1rem;
}

.doc-inline {
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem;
  background: #0b1220;
  margin: 1rem 0 1.25rem;
  overflow: hidden;
}

.doc-text {
  margin: 0.75rem 0 0;
  padding: 1rem;
  border-radius: 12px;
  background: #070b10;
  border: 1px solid #263042;
  color: #e6edf3;
  overflow: auto;
  max-height: 70vh;
  white-space: pre-wrap;
  word-break: break-word;
}

.doc-html {
  margin-top: 0.75rem;
  overflow-x: auto;
}

.doc-html p {
  color: #dbe4ee;
}

.doc-html,
.doc-html li,
.doc-html span {
  color: #dbe4ee;
}

.doc-html h1,
.doc-html h2,
.doc-html h3,
.doc-html h4,
.doc-html h5,
.doc-html h6 {
  color: #f2f6fb;
}

.doc-html pre {
  background: #070b10;
  border: 1px solid #263042;
  border-radius: 12px;
  padding: 0.9rem;
  overflow: auto;
}

.doc-html code {
  background: rgba(88, 166, 255, 0.12);
  border: 1px solid rgba(88, 166, 255, 0.25);
  border-radius: 8px;
  padding: 0.1rem 0.35rem;
}

.doc-html pre code {
  background: transparent;
  border: 0;
  padding: 0;
}

.doc-html a {
  color: #8cc8ff;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 700;
}

.doc-html a:visited {
  color: #b7a8ff;
}

.doc-html a:hover {
  color: #c8e5ff;
}

.doc-html img,
.doc-html svg,
.doc-html canvas,
.doc-html table {
  max-width: 100%;
  height: auto;
}

.pdf-pages {
  margin-top: 0.75rem;
  display: grid;
  gap: 0.9rem;
}

.pdf-canvas {
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid #263042;
  background: #fff;
  display: block;
}

.doc-error {
  border: 1px solid #5b2b2b;
  background: rgba(255, 71, 87, 0.08);
  color: #ffb4b4;
  border-radius: 12px;
  padding: 0.8rem 0.9rem;
}

.doc-links h3 {
  margin-top: 0;
  margin-bottom: 0.7rem;
}

.doc-links-wrap {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.doc-link {
  text-decoration: none;
  color: var(--text);
  border: 1px solid #3c4652;
  border-radius: 999px;
  padding: 0.3rem 0.7rem;
  font-size: 0.85rem;
}

.doc-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.pdf-viewer {
  border: none;
  background: var(--surface);
  border-radius: 0;
  overflow: hidden;
}

.pdf-frame {
  width: 100%;
  height: calc(100vh - 170px);
  border: 0;
  display: block;
  background: #fff;
}

.cv-main {
  padding: 0;
}

.cv-footer {
  padding: 0.35rem 0 0.9rem;
}

.footnote {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.contact-form {
  margin-top: 1rem;
}

.contact-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.contact-form textarea {
  width: 100%;
  background: var(--surface-soft);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.8rem 0.9rem;
  font-family: inherit;
  min-height: 320px;
  height: clamp(260px, 40vh, 520px);
  resize: vertical;
}

.contact-form input {
  width: 100%;
  background: var(--surface-soft);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.65rem 0.9rem;
  font-family: inherit;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  margin-top: 0.9rem;
}

.contact-page .post-detail {
  min-height: 620px;
  padding-bottom: 2rem;
}

.contact-hint {
  margin: 0.7rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(88, 166, 255, 0.5);
  background: rgba(88, 166, 255, 0.12);
  color: var(--accent);
  font-weight: 800;
  cursor: pointer;
}

.btn-primary:hover {
  background: rgba(88, 166, 255, 0.2);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  border: 1px solid #384150;
  background: transparent;
  color: var(--text);
  font-weight: 800;
  cursor: pointer;
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}
