/* =====================================================================
   ENDLINE — Modern katman (2026-11-15)
   style.css'in ÜSTÜNE biner; içerik, başlık, bağlantı, şema DEĞİŞMEZ.
   Yalnız görünüş: odak halkası, kart ışığı, buton parıltısı, rehber
   sayfa tipografisi, ilerleme çubuğu, sayfa geçişi.
   Kapatmak için header.php'deki <link ... modern.css> satırını silmek yeter.
   Esinlenilen kalıplar: Magic UI (Magic Card, Shine Border, Shimmer
   Button, Dot Pattern), Aceternity (Spotlight), motion-primitives
   (Magnetic), shadcn/ui (odak halkası, tablo/tipografi düzeni).
   ===================================================================== */

:root {
  --mx-cyan: #4fd1ff;
  --mx-blue: #00a3ff;
  --mx-teal: #00c7b7;
  --mx-line: rgba(103, 232, 249, 0.14);
  --mx-line-strong: rgba(103, 232, 249, 0.32);
  --mx-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* Animasyonlu gradyan açısı (Shine Border için) */
@property --mx-a {
  syntax: '<angle>';
  inherits: false;
  initial-value: 0deg;
}

/* ---------------------------------------------------------------------
   1) Genel incelik: odak, seçim, satır kırılımı, kaydırma payı
   --------------------------------------------------------------------- */
html { scroll-padding-top: 96px; }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--mx-cyan);
  outline-offset: 3px;
  border-radius: 6px;
}
:where(input, select, textarea):focus-visible { outline-offset: 1px; }

:where(h1, h2, h3, .answer-question, .spc-title-row) { text-wrap: balance; }
:where(p, li, dd, .answer-summary) { text-wrap: pretty; }

html { scrollbar-color: rgba(79, 209, 255, 0.35) #070b10; scrollbar-width: thin; }

/* Rakamlar aynı genişlikte (hizalı istatistik ve fiyatlar) */
:where(table, .spc-content, .contact-info, time) { font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------------
   2) Sayfa geçişi (tarayıcı destekliyorsa yumuşak geçiş, yoksa yok)
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  ::view-transition-old(root),
  ::view-transition-new(root) { animation-duration: 0.22s; animation-timing-function: ease-out; }
}

/* ---------------------------------------------------------------------
   3) Okuma ilerleme çubuğu (yalnız destekleyen tarayıcı; JS yok)
   --------------------------------------------------------------------- */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    body::after {
      content: '';
      position: fixed;
      inset: 0 0 auto 0;
      height: 2px;
      z-index: 10001;
      pointer-events: none;
      background: linear-gradient(90deg, var(--mx-teal), var(--mx-cyan) 45%, var(--mx-blue));
      box-shadow: 0 0 10px rgba(79, 209, 255, 0.55);
      transform-origin: 0 50%;
      transform: scaleX(0);
      animation: mx-progress linear both;
      animation-timeline: scroll(root block);
    }
  }
}
@keyframes mx-progress { to { transform: scaleX(1); } }

/* ---------------------------------------------------------------------
   4) Kart ışığı (Magic Card / Spotlight): imleci takip eden yumuşak ışık
      + imlecin yakınında parlayan ince kenar. Yalnız fare olan cihazda.
      --mx-x / --mx-y değerlerini modern.js verir.
   --------------------------------------------------------------------- */
.service-photo-card,
.reference-card,
.partner-item,
.tech-item,
.answer-block,
.faq-item,
.glass-card,
.contact-info-item {
  --mx-x: 50%;
  --mx-y: -200px;
}

@media (hover: hover) and (pointer: fine) {
  .service-photo-card,
  .reference-card,
  .partner-item,
  .faq-item.glass-card,
  .answer-block {
    position: relative;
    isolation: isolate;
  }

  .service-photo-card::after,
  .reference-card::after,
  .partner-item::after,
  .faq-item.glass-card::after,
  .answer-block::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    z-index: -1; /* yazının ve görselin altında, kart zemininin üstünde */
    opacity: 0;
    transition: opacity 0.35s var(--mx-ease);
    background: radial-gradient(420px circle at var(--mx-x) var(--mx-y), rgba(79, 209, 255, 0.11), transparent 45%);
  }
  /* kenar ışığı ayrı katman: gradyan kenar yalnız 1px halkada görünür */
  .service-photo-card::before,
  .reference-card::before,
  .partner-item::before,
  .faq-item.glass-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    pointer-events: none;
    z-index: 3;
    opacity: 0;
    transition: opacity 0.35s var(--mx-ease);
    background: radial-gradient(260px circle at var(--mx-x) var(--mx-y), rgba(103, 232, 249, 0.75), transparent 60%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  }

  .service-photo-card:hover::after,
  .service-photo-card:hover::before,
  .reference-card:hover::after,
  .reference-card:hover::before,
  .partner-item:hover::after,
  .partner-item:hover::before,
  .faq-item.glass-card:hover::after,
  .faq-item.glass-card:hover::before,
  .answer-block:hover::after { opacity: 1; }
}

/* ---------------------------------------------------------------------
   5) Hizmet kartları: fotoğraflar biraz daha canlı, üzerine gelince tam renk
   --------------------------------------------------------------------- */
.endline-services-grid .spc-image img {
  filter: saturate(0.9) contrast(1.06) brightness(0.95);
  transition: transform 0.7s var(--mx-ease), filter 0.5s var(--mx-ease);
}
.service-photo-card:hover .spc-image img,
.endline-services-grid .service-photo-card:hover .spc-image img {
  filter: saturate(1.05) contrast(1.04) brightness(1.02);
}
.service-photo-card { transition: transform 0.45s var(--mx-ease), border-color 0.35s ease, box-shadow 0.45s var(--mx-ease); }
.service-photo-card .spc-link i { transition: transform 0.3s var(--mx-ease); }
.service-photo-card:hover .spc-link i { transform: translateX(4px); }

/* ---------------------------------------------------------------------
   6) Teknoloji, iş ortağı, referans ve bölge öğeleri: sakin yükselme
   --------------------------------------------------------------------- */
.tech-item,
.partner-item,
.reference-card {
  transition: transform 0.35s var(--mx-ease), border-color 0.3s ease, box-shadow 0.35s var(--mx-ease), background-color 0.3s ease;
}
@media (hover: hover) and (pointer: fine) {
  .tech-item:hover,
  .partner-item:hover {
    transform: translateY(-3px);
    border-color: var(--mx-line-strong);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(79, 209, 255, 0.08), 0 0 24px rgba(79, 209, 255, 0.10);
  }
  .tech-item img,
  .partner-item img { transition: transform 0.35s var(--mx-ease); }
  .tech-item:hover img,
  .partner-item:hover img { transform: scale(1.08); }
}

/* ---------------------------------------------------------------------
   7) Butonlar: parıltı süpürmesi (Shimmer Button) + basınca hafif çökme.
      Mıknatıs etkisi (Magnetic) modern.js ile, `translate` özelliğiyle;
      mevcut transform hover'larıyla çakışmaz.
   --------------------------------------------------------------------- */
.btn-discover-primary,
.btn-discover-whatsapp,
.btn-submit-whatsapp,
.btn-outline-primary {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: translate 0.25s var(--mx-ease), transform 0.3s var(--mx-ease), box-shadow 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}
.btn-discover-primary::after,
.btn-discover-whatsapp::after,
.btn-submit-whatsapp::after,
.btn-outline-primary::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 45%;
  pointer-events: none;
  z-index: 1;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  transform: skewX(-18deg) translateX(0);
  opacity: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .btn-discover-primary:hover::after,
  .btn-discover-whatsapp:hover::after,
  .btn-submit-whatsapp:hover::after,
  .btn-outline-primary:hover::after {
    opacity: 1;
    animation: mx-shine 0.9s var(--mx-ease);
  }
  /* Ana çağrı butonu: 7 saniyede bir kendiliğinden kısa bir parıltı */
  .btn-discover-primary::after {
    opacity: 1;
    animation: mx-shine-idle 7s ease-in-out 2.5s infinite;
  }
}
@keyframes mx-shine { from { left: -60%; } to { left: 130%; } }
@keyframes mx-shine-idle { 0%, 78% { left: -60%; } 92%, 100% { left: 130%; } }

.btn-discover-primary:active,
.btn-discover-whatsapp:active,
.btn-submit-whatsapp:active,
.btn-outline-primary:active,
.btn-all-services:active { transform: scale(0.98); }

/* ---------------------------------------------------------------------
   8) Parlayan kenar (Shine Border): iletişim formu ve tarayıcı maketi.
      Ekranda değilken durur (modern.js .mx-on sınıfı).
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  .mx-beam { position: relative; isolation: isolate; }
  .mx-beam > .mx-beam-ring {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    pointer-events: none;
    z-index: 4;
    background: conic-gradient(from var(--mx-a), transparent 0 72%, rgba(79, 209, 255, 0.0) 74%, var(--mx-cyan) 86%, var(--mx-teal) 92%, transparent 96%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
    animation: mx-spin 7s linear infinite;
    animation-play-state: paused;
    opacity: 0.85;
  }
  .mx-beam.mx-on > .mx-beam-ring { animation-play-state: running; }
}
@keyframes mx-spin { to { --mx-a: 360deg; } }

/* ---------------------------------------------------------------------
   9) Bölüm zemini: kenarlara doğru kaybolan ince nokta deseni (Dot Pattern)
   --------------------------------------------------------------------- */
.endline-tech-section,
.endline-references,
.endline-regions {
  position: relative;
  isolation: isolate;
}
.endline-tech-section > .mx-dots,
.endline-references > .mx-dots,
.endline-regions > .mx-dots {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(rgba(103, 232, 249, 0.16) 1px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 60% 55% at 50% 40%, #000 10%, transparent 75%);
          mask-image: radial-gradient(ellipse 60% 55% at 50% 40%, #000 10%, transparent 75%);
}

/* ---------------------------------------------------------------------
   10) Form alanları: daha net odak
   --------------------------------------------------------------------- */
.endline-contact :is(input, select, textarea) {
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}
.endline-contact :is(input, select, textarea):focus {
  border-color: rgba(79, 209, 255, 0.55) !important;
  box-shadow: 0 0 0 4px rgba(79, 209, 255, 0.12) !important;
}

/* ---------------------------------------------------------------------
   11) Rehber sayfaları (ENDLINE nedir?, ajans/yazılım firması seçimi,
       WordPress mi özel yazılım mı?, sözlük). Yalnız tipografi ve aralık;
       metin ve sıra aynı.
   --------------------------------------------------------------------- */
section.section > .container[style*="max-width:900px"]:has(> h1) {
  --mx-g-text: rgba(226, 239, 248, 0.86);
  --mx-g-muted: rgba(160, 182, 199, 0.85);
  color: var(--mx-g-text);
  font-size: 1.02rem;
  line-height: 1.75;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > .breadcrumb {
  font-size: 0.85rem;
  color: var(--mx-g-muted);
  margin-bottom: 1.1rem;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.3rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 1.1rem;
  background: linear-gradient(180deg, #ffffff 30%, #b9e8fb);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > .lead {
  color: rgba(226, 239, 248, 0.92);
  margin-bottom: 0.6rem;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > h2 {
  position: relative;
  font-size: clamp(1.4rem, 2.6vw, 1.85rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 3.2rem 0 1.1rem;
  padding-top: 1.6rem;
  border-top: 1px solid var(--mx-line);
  color: #fff;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > h2::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 0;
  width: 56px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--mx-teal), var(--mx-cyan));
}
section.section > .container[style*="max-width:900px"]:has(> h1) > h3 {
  font-size: 1.15rem;
  margin: 1.8rem 0 0.6rem;
  color: #fff;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > p { margin: 0 0 1rem; }
section.section > .container[style*="max-width:900px"]:has(> h1) a:not([class]) {
  color: var(--mx-cyan);
  text-decoration: underline;
  text-decoration-color: rgba(79, 209, 255, 0.35);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s ease;
}
section.section > .container[style*="max-width:900px"]:has(> h1) a:not([class]):hover { text-decoration-color: currentColor; }

/* Tablolar: çerçeveli, satır çizgili kart */
section.section > .container[style*="max-width:900px"]:has(> h1) > table {
  display: table;
  width: 100%;
  margin: 0.4rem 0 1.4rem;
  border: 1px solid var(--mx-line);
  border-radius: 14px;
  border-collapse: separate !important;
  border-spacing: 0;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.55), rgba(7, 13, 22, 0.7));
  font-size: 0.95rem;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > table :is(th, td) {
  padding: 0.8rem 1.1rem !important;
  text-align: left;
  vertical-align: top;
  border: 0 !important;
  border-bottom: 1px solid rgba(103, 232, 249, 0.08) !important;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > table tr:last-child > :is(th, td) { border-bottom: 0 !important; }
section.section > .container[style*="max-width:900px"]:has(> h1) > table thead :is(th, td) {
  background: rgba(79, 209, 255, 0.07);
  color: #fff;
  font-weight: 600;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > table tbody tr:hover > :is(th, td) { background: rgba(79, 209, 255, 0.035); }
section.section > .container[style*="max-width:900px"]:has(> h1) > table tbody :is(th, td):first-child {
  color: #fff;
  font-weight: 600;
  width: 34%;
}

/* Tanım listeleri: iki sütunlu, ince ayraçlı */
section.section > .container[style*="max-width:900px"]:has(> h1) > dl {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 0.4rem 0 1.2rem;
  border: 1px solid var(--mx-line);
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.45), rgba(7, 13, 22, 0.6));
}
section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dt {
  padding: 0.95rem 1.2rem 0.15rem;
  color: #fff;
  font-weight: 600;
  border-top: 1px solid rgba(103, 232, 249, 0.08);
}
section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dt:first-child { border-top: 0; }
section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dd {
  margin: 0;
  padding: 0 1.2rem 0.95rem;
  color: var(--mx-g-text);
  font-size: 0.96rem;
}
@media (min-width: 768px) {
  section.section > .container[style*="max-width:900px"]:has(> h1) > dl { grid-template-columns: minmax(180px, 32%) 1fr; }
  section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dt { padding: 0.9rem 1.2rem; }
  section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dd {
    padding: 0.9rem 1.2rem;
    border-top: 1px solid rgba(103, 232, 249, 0.08);
  }
  section.section > .container[style*="max-width:900px"]:has(> h1) > dl > dd:nth-child(2) { border-top: 0; }
}

/* Madde listeleri: marka renkli işaret */
section.section > .container[style*="max-width:900px"]:has(> h1) > :is(ul, ol) {
  margin: 0.2rem 0 1.2rem;
  padding-left: 0;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > ul { list-style: none; }
section.section > .container[style*="max-width:900px"]:has(> h1) > ol { padding-left: 1.4rem; }
section.section > .container[style*="max-width:900px"]:has(> h1) > :is(ul, ol) > li {
  position: relative;
  margin: 0 0 0.55rem;
}
section.section > .container[style*="max-width:900px"]:has(> h1) > ul > li { padding-left: 1.5rem; }
section.section > .container[style*="max-width:900px"]:has(> h1) > ul > li::before {
  content: '';
  position: absolute;
  left: 0.15rem;
  top: 0.72em;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  transform: rotate(45deg);
  background: linear-gradient(135deg, var(--mx-teal), var(--mx-cyan));
  box-shadow: 0 0 8px rgba(79, 209, 255, 0.45);
}
section.section > .container[style*="max-width:900px"]:has(> h1) > ol > li::marker { color: var(--mx-cyan); font-weight: 600; }

/* Rehber sayfalarındaki SSS kartları */
section.section > .container[style*="max-width:900px"]:has(> h1) .faq-item.glass-card {
  border-radius: 14px;
  margin-bottom: 0.9rem;
}

@media (max-width: 767px) {
  section.section > .container[style*="max-width:900px"]:has(> h1) { font-size: 0.98rem; }
  section.section > .container[style*="max-width:900px"]:has(> h1) > table { display: block; overflow-x: auto; }
  section.section > .container[style*="max-width:900px"]:has(> h1) > table tbody :is(th, td):first-child { width: auto; }
  section.section > .container[style*="max-width:900px"]:has(> h1) > h2 { margin-top: 2.4rem; }
}

/* ---------------------------------------------------------------------
   12) Hareket istemeyen kullanıcı: bu katmandaki tüm hareketler kapalı
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .service-photo-card,
  .tech-item,
  .partner-item,
  .reference-card,
  .btn-discover-primary,
  .btn-discover-whatsapp,
  .btn-submit-whatsapp,
  .btn-outline-primary { translate: none !important; }
  .tech-item:hover img,
  .partner-item:hover img { transform: none; }
}
