/* ==========================================================
   GOYVTECH THEME - Blue Base + Orange Dominant Accent
   ========================================================== */

/* ===== Theme Tokens ===== */
:root{
  --bg: #f6f9ff;
  --surface: #ffffff;
  --surface2: #f1f6ff;

  --text: #0f172a;
  --muted: #52637a;

  /* Blue base */
  --blue: #2f80ed;
  --blue2: #5aa6ff;
  --blueSoft: rgba(47,128,237,.14);

  /* Orange dominant */
  --accent: #ff7a18;
  --accent2: #ff9a4a;
  --accentSoft: rgba(255,122,24,.18);

  --border: rgba(15,23,42,.12);
  --shadow: 0 14px 28px rgba(15,23,42,.08);

  --radius: 16px;
  --container: 1120px;
}

/* ===== Base Reset ===== */
*{ box-sizing:border-box; }
html,body{ margin:0; padding:0; }
body{
  background:
    radial-gradient(900px 520px at 12% 0%, rgba(90,166,255,.22), transparent 60%),
    radial-gradient(900px 520px at 88% 0%, rgba(255,122,24,.20), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
a{ color: inherit; text-decoration:none; }
img{ max-width:100%; display:block; }

.container{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
}

.section{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.muted{ color: var(--muted); }

/* ===== Headings (orange highlight) ===== */
h1,h2,h3{
  letter-spacing: -0.2px;
}
h1{
  margin: 0 0 8px 0;
}
h2{
  margin: 0 0 10px 0;
  position: relative;
  padding-bottom: 8px;
}
h2::after{
  content:"";
  position:absolute;
  left:0;
  bottom:0;
  width: 78px;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  opacity: .95;
}

/* ===== Buttons (ORANGE dominant) ===== */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;

  padding: 10px 14px;
  border-radius: 12px;

  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff;

  border: 1px solid rgba(255,122,24,.35);
  font-weight: 700;
  transition: transform .12s ease, filter .12s ease, box-shadow .12s ease;
  box-shadow: 0 10px 18px rgba(255,122,24,.18);
}
.btn:hover{
  filter: brightness(1.03);
  transform: translateY(-1px);
  box-shadow: 0 14px 24px rgba(255,122,24,.24);
}

/* Secondary button (blue outline) */
.btn.btn-soft{
  background: var(--surface2);
  color: var(--text);
  border: 1px solid rgba(47,128,237,.25);
  box-shadow: none;
}
.btn.btn-soft:hover{
  border-color: rgba(255,122,24,.40);
}

/* ===== Header ===== */
.site-header{
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(246,249,255,.80);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.topbar{
  border-bottom: 1px solid var(--border);
}

.topbar-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
  padding: 10px 0;
}

.lang{
  display:flex;
  gap: 8px;
}

.lang-item{
  width: 36px;
  height: 28px;
  border-radius: 10px;

  display:flex;
  align-items:center;
  justify-content:center;

  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 6px 14px rgba(15,23,42,.06);
  transition: transform .12s ease, border-color .12s ease;
}
.lang-item:hover{
  transform: translateY(-1px);
  border-color: rgba(255,122,24,.35);
}
.lang-item.is-active{
  outline: 2px solid rgba(255,122,24,.35);
}

.topnav{
  display:flex;
  gap: 10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}

.nav-link{
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid transparent;
  color: var(--muted);
  transition: background .12s ease, color .12s ease, border-color .12s ease;
}
.nav-link:hover{
  background: rgba(255,122,24,.10);
  border-color: rgba(255,122,24,.22);
  color: var(--text);
}

/* Active menu ORANGE */
.nav-link.is-active{
  background: linear-gradient(135deg, rgba(255,122,24,.16), rgba(255,154,74,.12));
  border-color: rgba(255,122,24,.35);
  color: var(--text);
  font-weight: 700;
}

.brandbar{
  padding: 10px 0;
}

.brandbar-inner{
  display:flex;
  align-items:center;
}

.brand-logo{
  height: 40px;
  width: auto;
  object-fit: contain;
}

/* ===== Main spacing ===== */
.site-main{
  padding: 18px 0 0;
}

/* ===== Slider ===== */
.slider{
  margin-top: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface), var(--surface2));
  box-shadow: var(--shadow);
  overflow:hidden;
}

.slides{
  display:flex;
  transition: transform .45s ease;
}

.slide{
  min-width: 100%;
  display:grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 14px;
  padding: 18px;
}

.slide h2{
  margin: 0 0 8px 0;
  font-size: 22px;
}

.slide p{
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

/* Orange + blue card */
.slide-card{
  border-radius: 14px;
  border: 1px solid rgba(255,122,24,.22);
  background:
    radial-gradient(900px 280px at 20% 10%, rgba(90,166,255,.18), transparent 55%),
    radial-gradient(700px 260px at 90% 20%, rgba(255,122,24,.22), transparent 55%),
    var(--surface);
  padding: 14px;
}

.dots{
  display:flex;
  justify-content:center;
  gap: 8px;
  padding: 10px 0 14px;
}

/* Dot: inactive grey, active ORANGE (dominant) */
.dot{
  width: 9px;
  height: 9px;
  border-radius: 99px;
  background: #cfd7e6;
  border: 1px solid rgba(15,23,42,.18);
  opacity: .9;
}
.dot.is-active{
  background: var(--accent);
  border-color: rgba(255,122,24,.55);
  opacity: 1;
}

/* ===== Products (Index 5 items layout) ===== */
.product-stack{
  display:flex;
  flex-direction:column;
  gap: 12px;
  margin-top: 14px;
}

.product-row{
  display:grid;
  grid-template-columns: 250px 1fr;
  gap: 12px;

  padding: 12px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform .12s ease, border-color .12s ease;
}
.product-row:hover{
  transform: translateY(-2px);
  border-color: rgba(255,122,24,.30);
}

.product-img img{
  width: 250px;
  height: 190px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid rgba(15,23,42,.10);
}

.tech-wrap{
  display:flex;
  flex-direction:column;
  gap: 10px;
}

.tech-title{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
}

.tech-title h3{
  margin: 0;
  font-size: 18px;
}

/* Badge ORANGE dominant */
.badge{
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255,122,24,.22), rgba(255,154,74,.16));
  border: 1px solid rgba(255,122,24,.35);
  color: var(--text);
  font-weight: 700;
}

.tech-table{
  width: 100%;
  border-collapse: collapse;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(15,23,42,.10);
}

.tech-table th{
  text-align:left;
  padding: 10px;
  background: linear-gradient(135deg, rgba(255,122,24,.16), rgba(47,128,237,.10));
  border-bottom: 1px solid rgba(15,23,42,.10);
}

.tech-table td{
  padding: 9px 10px;
  border-top: 1px solid rgba(15,23,42,.08);
  color: var(--muted);
}

.tech-table tr td:first-child{
  width: 45%;
  color: var(--text);
  font-weight: 650;
}

/* ===== Grid (urunler/blog list) ===== */
.grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.card{
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow:hidden;
  transition: transform .12s ease, border-color .12s ease;
}
.card:hover{
  transform: translateY(-2px);
  border-color: rgba(255,122,24,.28);
}

.card-media img{
  width: 100%;
  height: 170px;
  object-fit: cover;
}

.card-body{
  padding: 12px;
  display:flex;
  flex-direction:column;
  gap: 10px;
}

.card-title{
  margin: 0;
  font-size: 16px;
}

.card-meta{
  color: var(--muted);
  font-size: 13px;
}

/* ===== Detail pages ===== */
.detail{
  display:grid;
  grid-template-columns: 420px 1fr;
  gap: 14px;
}

.detail .media img{
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid rgba(15,23,42,.10);
  box-shadow: var(--shadow);
}

.detail .content h1{
  margin: 0 0 8px 0;
  font-size: 24px;
}

/* ===== Footer ===== */
.site-footer{
  margin-top: 18px;
  background: rgba(255,255,255,.70);
  border-top: 1px solid var(--border);
}

.footer-grid{
  display:grid;
  grid-template-columns: 1.2fr 1fr .8fr;
  gap: 12px;
  padding: 18px 0;
}

.footer-logo{
  height: 34px;
  width: auto;
  object-fit: contain;
  margin-bottom: 10px;
}

.footer-contact,
.footer-links{
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.8;
}

.footer-col h4{
  margin: 0 0 10px 0;
  font-size: 15px;
}

.social-row{
  display:flex;
  gap: 8px;
}

.social{
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display:flex;
  align-items:center;
  justify-content:center;

  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 6px 14px rgba(15,23,42,.06);
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}
.social:hover{
  transform: translateY(-1px);
  border-color: rgba(255,122,24,.35);
  background: rgba(255,122,24,.08);
}

/* ===== Responsive ===== */
@media (max-width: 980px){
  .slide{ grid-template-columns: 1fr; }
  .product-row{ grid-template-columns: 1fr; }
  .product-img img{ width: 100%; height: 190px; }
  .detail{ grid-template-columns: 1fr; }
  .grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid{ grid-template-columns: 1fr; }
}

@media (max-width: 560px){
  .grid{ grid-template-columns: 1fr; }
  .topbar-inner{ flex-direction: column; align-items: flex-start; }
  .topnav{ justify-content: flex-start; }
}
/* ===========================
   Footer Social Fix (Visible)
   =========================== */

.footer-socials .social-row{
  display:flex;
  align-items:center;
  gap: 10px;
}

.footer-socials .social{
  width: 40px;
  height: 40px;
  display:flex;
  align-items:center;
  justify-content:center;

  border-radius: 12px;

  /* kutu rengi düzeltildi */
  background: linear-gradient(135deg, rgba(255,122,24,.18), rgba(47,128,237,.12));
  border: 1px solid rgba(255,122,24,.35);

  box-shadow: 0 10px 20px rgba(15,23,42,.10);
}

.footer-socials .social img{
  width: 18px;
  height: 18px;
  display:block;

  /* SVG görünür olsun */
  opacity: 1;
  filter: brightness(0) saturate(100%) invert(18%) sepia(86%) saturate(3500%) hue-rotate(8deg) brightness(105%) contrast(98%);
}

.footer-socials .social:hover{
  transform: translateY(-1px);
  background: linear-gradient(135deg, rgba(255,122,24,.28), rgba(47,128,237,.16));
  border-color: rgba(255,122,24,.55);
}/* Upload kutusu: kutunun tamamı tıklanabilir olsun */
.upload-square{
  position: relative;
  display: block;
  width: 260px;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  border: 1px dashed var(--border);         /* ❗️beyaz yerine temaya uyumlu */
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface2);              /* daha görünür */
}

/* Input görünmez ama tıklanabilir */
.upload-input{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
}

/*
  ❗️ÖNEMLİ:
  pointer-events:none label üzerinde kalırsa,
  bazen input click yakalayamaz (özellikle bazı kombinasyonlarda).
  Bu yüzden label tıklanabilir kalsın.
*/
.upload-label{
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 8px;
  text-align: center;
  z-index: 2;
  cursor: pointer;                  /* ✅ label tıklanabilir */
  pointer-events: auto;             /* ✅ label çalışsın */
}

/*
  Input en üstte (z-index:5) olduğu için yine input click alır.
  Label sadece görsel ve alternatif klik alanı olur.
*/

/* Önizleme katmanı */
.upload-preview{
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

.upload-img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* kaldır butonu tıklanabilir olsun */
.upload-remove{
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 6;
  pointer-events: auto;
  cursor: pointer;
}
/* Index - Featured Blogs */
.blog-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

@media (max-width: 980px){
  .blog-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px){
  .blog-grid{ grid-template-columns: 1fr; }
}

.blog-card{
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  overflow: hidden;
}

.blog-card a{ text-decoration:none; color: inherit; display:block; }

.blog-cover{
  width: 100%;
  height: 160px;          /* göze batmayacak, yer kaplamayacak */
  object-fit: cover;      /* kırpmayı güzel yapar */
  display:block;
  background: rgba(0,0,0,.15);
}

.blog-body{ padding: 12px 12px 14px; }

.blog-title{
  font-weight: 700;       /* bold */
  margin: 0 0 8px 0;
  line-height: 1.25;
}

.blog-excerpt{
  margin: 0;
  line-height: 1.6;
}

.blog-readmore{
  font-weight: 600;
  text-decoration: underline;
  margin-left: 6px;
  white-space: nowrap;
}
.blog-readmore{
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  font-weight: 700;
  text-decoration: underline;
  margin-left: 6px;
}

.blog-more{
  margin: 10px 0 0 0;
  line-height: 1.7;
  opacity: .95;
}
/* ===========================
   Admin/Form Overflow Fix
   =========================== */

/* Form elemanları asla kutudan taşmasın */
input, select, textarea, button {
  max-width: 100%;
}

/* Özellikle text alanları tam otursun */
input[type="text"],
input[type="number"],
input[type="url"],
input[type="email"],
input[type="search"],
textarea,
select {
  width: 100%;
}

/* Uzun metinler satır kırabilsin (tablo hücresinde taşmayı engeller) */
td, th, .card, .section {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Flex/grid satırlarında taşmayı engelle */
.row, .form-row, .grid-row, .flex-row, .field-row {
  min-width: 0;
}
.row > *, .form-row > *, .grid-row > *, .flex-row > *, .field-row > * {
  min-width: 0;
}

/* Tablet */
@media (min-width: 768px){
  .container{ padding-left: 20px; padding-right: 20px; }
}

/* Desktop */
@media (min-width: 1024px){
  .container{ padding-left: 24px; padding-right: 24px; }
}


.topbar-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}

.topnav{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

/* Mobilde menü alt satıra insin ve daha okunur olsun */
@media (max-width: 640px){
  .topnav{
    width:100%;
    justify-content:flex-start;
  }
  .nav-link{
    padding:10px 10px;
    font-size:14px;
  }
}
.grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 768px){
  .grid{ grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px){
  .grid{ grid-template-columns: repeat(3, 1fr); }
}

/* ==========================================================
   RESPONSIVE SYSTEM (FINAL OVERRIDE)
   Mobile-first: 0-767 / Tablet: 768-1023 / Desktop: 1024+
   Bu blok EN ALTTA olmalı.
   ========================================================== */

/* 0) Güvenli taşma engeller */
html, body { overflow-x: hidden; }
img, video { max-width: 100%; height: auto; }

/* 1) Container */
.container{
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

/* 2) Header / Topbar */
.topbar-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}

.lang{ flex: 0 0 auto; }

.topnav{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}

/* 3) Grid (urunler/blog list) — tek kaynak */
.grid{
  display:grid;
  grid-template-columns: 1fr; /* mobile */
  gap: 14px;
}

/* 4) Blog grid (index featured blog) — tek kaynak */
.blog-grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

/* 5) Detail (urun.php) — mobile */
.detail{
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

/* 6) Index product row — mobile */
.product-row{
  display:grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.product-img img{
  width: 100%;
  height: 190px;
  object-fit: cover;
}

/* 7) Slider — mobile */
.slide{
  grid-template-columns: 1fr;
}

/* 8) Footer — mobile */
.footer-grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

/* 9) Mobil menü okunabilirliği */
@media (max-width: 640px){
  .topbar-inner{ flex-direction: column; align-items: flex-start; }
  .topnav{ width:100%; justify-content:flex-start; }
  .nav-link{ padding:10px 10px; font-size:14px; }
  .brand-logo{ height: 36px; }
}

/* ==========================
   TABLET (>=768px)
   ========================== */
@media (min-width: 768px){
  .container{
    padding-left: 20px;
    padding-right: 20px;
  }

  /* grid 2 kolon */
  .grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* blog grid 2 kolon */
  .blog-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* detail hâlâ 1 kolon (daha iyi okunur); istersen 2 yapabiliriz */
  .detail{ grid-template-columns: 1fr; }

  /* footer 2 kolon istersen: (şimdilik 1 bırakıyorum, istersek açarız) */
}

/* ==========================
   DESKTOP (>=1024px)
   ========================== */
@media (min-width: 1024px){
  .container{
    padding-left: 24px;
    padding-right: 24px;
  }

  /* grid 3 kolon */
  .grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }

  /* blog grid 3 kolon */
  .blog-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }

  /* detail desktop 2 kolon */
  .detail{ grid-template-columns: 420px 1fr; align-items: start; }

  /* index product row desktop 2 kolon */
  .product-row{ grid-template-columns: 250px 1fr; }

  .product-img img{
    width: 250px;
    height: 190px;
  }

  /* slider desktop 2 kolon */
  .slide{
    grid-template-columns: 1.15fr .85fr;
  }

  /* footer desktop 3 kolon */
  .footer-grid{
    grid-template-columns: 1.2fr 1fr .8fr;
  }
}
