@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Manrope:wght@500;600;700&display=swap");

:root {
  --bg: #d9dde2;
  --surface: #ffffff;
  --surface-muted: #eceff1;
  --text: #1f2933;
  --text-soft: #5a6672;
  --border: #d9dde1;
  --dark: #111827;
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-weight: 400;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--border);
  background: rgba(217, 221, 226, 0.95);
  backdrop-filter: blur(6px);
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
}

.brand img {
  height: 50px;
  width: auto;
  display: block;
}

.site-nav {
  display: flex;
  gap: 22px;
}

.site-nav a {
  color: var(--text-soft);
  font-weight: 500;
}

.site-nav a.active,
.site-nav a:hover {
  color: var(--dark);
}

.menu-toggle {
  display: none;
}

.hero {
  background-image:
    linear-gradient(rgba(35, 39, 43, 0.68), rgba(35, 39, 43, 0.68)),
    url("../images/hero.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-bottom: 1px solid var(--border);
}

.hero-content {
  position: relative;
  padding: 60px 0;
  padding-right: 180px;
  min-height: 300px;
}

.hero-logo {
  position: absolute;
  right: 0;
  bottom: 20px;
  height: 108px;
  width: auto;
  display: block;
}

.eyebrow {
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-soft);
}

h1, h2, h3 {
  margin-top: 0;
  line-height: 1.2;
  font-family: "Manrope", "Inter", "Segoe UI", Arial, sans-serif;
  font-weight: 600;
  letter-spacing: 0.2px;
}

h1 {
  font-size: clamp(2rem, 4.3vw, 3.2rem);
  margin-bottom: 16px;
}

.hero p {
  max-width: 700px;
}

.hero h1,
.hero p,
.hero .eyebrow {
  color: #ffffff;
}

.hero .btn-primary {
  background: #ffffff;
  border-color: #ffffff;
  color: var(--dark);
}

.hero .btn-outline {
  border-color: #ffffff;
  color: #ffffff;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 26px;
  flex-wrap: wrap;
}

.btn {
  border: 1px solid var(--dark);
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  display: inline-flex;
}

.btn-primary {
  background: var(--dark);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--dark);
}

.section {
  padding: 56px 0;
}

body[data-page="project-detail"] .section {
  padding-top: 40px;
}

.section-muted {
  background: var(--surface-muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  gap: 12px;
}

.section-head-stack {
  display: block;
}

.card-grid,
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.service-card,
.stat-card,
.project-card,
.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

/* Gentle hover micro-interaction (overdoing yok) */
.service-card,
.project-card {
  transition: transform 160ms ease;
  will-change: transform;
}

@media (hover: hover) {
  .service-card:hover,
  .project-card:hover {
    transform: translateY(-2px);
  }
}

.project-card {
  overflow: hidden;
  padding: 0;
}

.project-image {
  aspect-ratio: 16 / 10;
  object-fit: cover;
  width: 100%;
}

.project-image-missing {
  display: grid;
  place-items: center;
  background: #e5e7eb;
  color: #4b5563;
  font-weight: 600;
}

.project-image.image-fit-contain {
  object-fit: contain;
  background: #f2f4f6;
}

.project-body {
  padding: 18px;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 5px 10px;
  border-radius: 999px;
  background: #e5e7eb;
  color: #374151;
  margin-bottom: 10px;
}

.tabs {
  display: flex;
  gap: 10px;
  margin: 18px 0 24px;
  flex-wrap: wrap;
}

.tab-btn {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
}

.tab-btn.active {
  background: var(--dark);
  border-color: var(--dark);
  color: #fff;
}

.back-link {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--text-soft);
}

.project-cover {
  position: relative;
  margin-bottom: 22px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: #fff;
}

.project-cover-image {
  width: 100%;
  aspect-ratio: 16 / 6;
  object-fit: cover;
}

.project-cover-image.image-fit-contain {
  object-fit: contain;
  background: #f2f4f6;
}

.project-cover-missing {
  min-height: 220px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 8px;
  padding: 18px;
  background: #e5e7eb;
  color: #374151;
}

.project-cover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(35, 39, 43, 0.18), rgba(35, 39, 43, 0.68));
  z-index: 1;
}

.project-cover-title {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 18px;
  margin: 0;
  color: #ffffff;
  z-index: 2;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.project-cover-title-static {
  position: static;
  margin: 0;
  color: #111827;
  text-shadow: none;
}

@media (max-width: 768px) {
  .project-cover-title {
    left: 14px;
    right: 14px;
    bottom: 12px;
    font-size: 1.5rem;
  }
}

.project-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 22px;
  align-items: start;
}

.project-detail-main,
.project-detail-aside {
  min-width: 0;
}

.project-panel,
.project-info-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
}

.project-panel-full {
  grid-column: 1 / -1;
  margin-bottom: 0;
}

.project-section-title {
  font-size: 1.45rem;
  margin-bottom: 12px;
}

.project-summary {
  color: var(--text-soft);
  margin: 0;
}

.project-feature-list {
  margin: 0;
  padding-left: 18px;
  color: var(--text-soft);
  display: grid;
  gap: 8px;
}

.project-feature-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.project-feature-group {
  min-width: 0;
}

.project-subsection-title {
  margin: 14px 0 10px;
  font-size: 1.12rem;
  font-weight: 700;
  color: #1f2933;
}

.project-map-box {
  background: #f8fafb;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  align-self: stretch;
}

.project-map-title {
  font-size: 1rem;
  margin: 0 0 8px;
}

.project-map-frame {
  width: 100%;
  height: 110px;
  border: 0;
  border-radius: 8px;
}

.gallery-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
}

.gallery-tab-btn {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
}

.gallery-tab-btn.active {
  background: var(--dark);
  color: #fff;
  border-color: var(--dark);
}

.project-info-list {
  display: grid;
  gap: 8px;
}

.project-info-row {
  display: grid;
  gap: 4px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border);
}

.project-info-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.project-info-row span {
  color: var(--text-soft);
  font-size: 0.9rem;
}

.project-contact-btn {
  width: 100%;
  justify-content: center;
  margin-top: 16px;
}

.project-detail-actions {
  margin-top: 14px;
}

.slider {
  position: relative;
  background: #fff;
  border: 0;
  border-radius: var(--radius);
  overflow: hidden;
  touch-action: pan-y;
  margin-bottom: 14px;
  /* Altındaki nokta alanının üst boşluğuna denk gelecek şekilde */
  padding-top: 28px;
}

button,
input,
textarea {
  -webkit-appearance: none;
  appearance: none;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.slide-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  /* `contain` olduğunda kutu içinde kalan boşluk beyaz görünsün */
  background: #fff;
}

.slider-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
}

.slider-arrow {
  position: absolute;
  top: calc(50% - 24px);
  width: 40px;
  height: 48px;
  border: 0;
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.58);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.slider-arrow-left {
  left: 10px;
}

.slider-arrow-right {
  right: 10px;
}

.slider-arrow:hover {
  background: rgba(17, 24, 39, 0.78);
}

.slider-dots {
  display: flex;
  gap: 7px;
}

.slider-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 0;
  background: #c7cdd3;
  cursor: pointer;
}

.slider-dot.active {
  background: var(--dark);
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 22px;
}

.meta-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
}

.prose {
  max-width: 760px;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.contact-list {
  padding-left: 18px;
}

.contact-map-frame {
  width: 100%;
  height: 320px;
  border: 0;
  border-radius: 8px;
}

.contact-map-card h2 {
  margin-bottom: 12px;
}

form {
  display: grid;
  gap: 10px;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
}

.site-footer {
  border-top: 1px solid #3a4046;
  background: #2a2f35;
  color: #f3f4f6;
}

.footer-wrap {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 26px 0;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
}

.footer-logo img {
  height: 40px;
  width: auto;
  display: block;
}

.site-footer #copyrightText {
  color: #d1d5db;
}

@media (max-width: 1024px) {
  .card-grid,
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .brand img {
    height: 42px;
  }

  .hero-content {
    padding-right: 110px;
    min-height: 260px;
  }

  .hero-logo {
    height: 78px;
    right: 0;
    bottom: 16px;
  }

  .menu-toggle {
    display: inline-flex;
    border: 1px solid var(--border);
    background: #fff;
    border-radius: 8px;
    padding: 8px 10px;
  }

  .site-nav {
    position: absolute;
    left: 0;
    top: 70px;
    width: 100%;
    padding: 16px;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    display: none;
    flex-direction: column;
    gap: 12px;
    max-height: calc(100vh - 82px);
    overflow: auto;
  }

  .site-nav.open {
    display: flex;
  }

  .card-grid,
  .stats-grid,
  .contact-layout,
  .detail-meta,
  .project-feature-columns {
    grid-template-columns: 1fr;
  }

  .footer-wrap {
    flex-direction: column;
  }
}

/* Scroll reveal system (opacity + transform only) */
.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 450ms ease, transform 450ms ease;
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (hover: hover) {
  /* `.reveal` kuralı `transition`'ı override ettiği için hover süresini tekrar kısa tutuyoruz. */
  .service-card.reveal:hover,
  .project-card.reveal:hover {
    transition: transform 160ms ease;
  }
}
