/**
 * Theme v2 — Kurumsal frontend yenileme
 * Mobil öncelikli, modern cam efektleri, gelişmiş kartlar
 */

:root {
  --v2-radius: 20px;
  --v2-radius-sm: 12px;
  --v2-glass: rgba(255, 255, 255, 0.72);
  --v2-glass-border: rgba(255, 255, 255, 0.45);
  --v2-header-shadow: 0 4px 24px rgba(12, 18, 34, 0.08);
  --v2-section-pad: clamp(3rem, 6vw, 5.5rem);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ─── Utilities ─── */
.hide-desktop { display: none !important; }

@media (max-width: 991px) {
  .hide-desktop { display: flex !important; }
  .hide-mobile-v2 { display: none !important; }
}

/* ─── Header ─── */
.site-header {
  transition: box-shadow 0.3s var(--ease), backdrop-filter 0.3s var(--ease);
}

.site-header.scrolled {
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  box-shadow: var(--v2-header-shadow);
}

.site-header.scrolled .top-bar {
  max-height: 0;
  padding: 0;
  opacity: 0;
  overflow: hidden;
  border: none;
}

.site-header.scrolled .nav-wrap {
  padding-top: 0.65rem;
  padding-bottom: 0.65rem;
}

.top-bar {
  transition: max-height 0.35s var(--ease), opacity 0.25s var(--ease), padding 0.35s var(--ease);
  max-height: 48px;
}

.logo img {
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.logo strong {
  font-family: var(--display);
  letter-spacing: -0.03em;
  font-size: 1.05rem;
}

.main-nav a {
  position: relative;
  font-weight: 500;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  transition: color 0.2s, background 0.2s;
}

.main-nav a.active,
.main-nav a:hover {
  color: var(--brand);
  background: var(--brand-soft);
}

.menu-toggle {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
}

.menu-toggle.open {
  background: var(--brand-soft);
  border-color: var(--brand-muted);
}

@media (max-width: 991px) {
  .main-nav {
    width: min(320px, 88vw);
    padding: 5rem 1.25rem 2rem;
    background: linear-gradient(165deg, var(--dark) 0%, var(--dark-soft) 100%);
    box-shadow: 8px 0 40px rgba(0, 0, 0, 0.25);
  }

  .main-nav a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
  }

  .main-nav a.active,
  .main-nav a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
  }
}

/* ─── Hero ─── */
.hero {
  min-height: clamp(520px, 85vh, 720px);
  padding-bottom: 2rem;
}

.hero-inner {
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
}

.hero-content h1 {
  font-size: clamp(2rem, 5.5vw, 3.35rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.badge {
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.hero-pills {
  display: none;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
  justify-content: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.8125rem;
  font-weight: 600;
  backdrop-filter: blur(6px);
}

.hero-float-card {
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.stats {
  margin-top: 2rem;
  padding: 1rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item strong {
  font-family: var(--display);
  font-size: 1.35rem;
}

@media (max-width: 991px) {
  .hero-visual { display: none !important; }
  .hero-pills { display: flex; }
  .hero { min-height: auto; padding: 3.5rem 0 2.5rem; }
  .stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    text-align: center;
  }
}

@media (max-width: 479px) {
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .stats { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
}

/* ─── Trust bar ─── */
.trust-bar {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-alt) 100%);
  position: relative;
  z-index: 2;
}

.trust-items {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  justify-items: center;
}

.trust-item {
  width: 100%;
  justify-content: center;
  padding: 0.65rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s, box-shadow 0.2s;
}

.trust-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

@media (max-width: 767px) {
  .trust-items {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.65rem;
  }
  .trust-item {
    font-size: 0.8125rem;
    padding: 0.55rem 0.65rem;
  }
}

/* ─── Sections & cards ─── */
.section {
  padding: var(--v2-section-pad) 0;
}

.section-head h2 {
  font-size: clamp(1.65rem, 4vw, 2.35rem);
  letter-spacing: -0.025em;
}

.section-label::before {
  width: 28px;
  height: 3px;
  border-radius: 2px;
}

.feature-card,
.product-card,
.article-card,
.testimonial-card {
  border-radius: var(--v2-radius);
  border: 1px solid var(--border-light);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
}

.feature-card:hover,
.product-card:hover,
.article-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--brand-muted);
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--brand-soft), var(--brand-muted));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.features {
  gap: 1.25rem;
}

@media (max-width: 991px) {
  .features {
    margin-top: 0 !important;
  }
  .section-tight-top {
    padding-top: 2.5rem !important;
  }
}

.product-card .card-img,
.article-card .card-img {
  aspect-ratio: 16/10;
  overflow: hidden;
}

.product-card .card-img img,
.product-card .card-img .placeholder {
  transition: transform 0.5s var(--ease);
}

.product-card:hover .card-img img,
.product-card:hover .card-img .placeholder {
  transform: scale(1.05);
}

/* ─── CTA ─── */
.cta-section {
  border-radius: var(--v2-radius);
  margin: 0 1rem;
  max-width: calc(1240px - 2rem);
  margin-left: auto;
  margin-right: auto;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

@media (max-width: 767px) {
  .cta-section {
    margin: 0 1rem;
    border-radius: var(--v2-radius-sm);
  }
  .cta-actions {
    flex-direction: column;
    width: 100%;
  }
  .cta-actions .btn { width: 100%; }
}

/* ─── Footer ─── */
.site-footer {
  background: linear-gradient(180deg, var(--dark-soft) 0%, var(--dark) 100%);
  padding-top: 3.5rem;
}

.footer-grid {
  gap: 2.5rem;
}

.footer-brand-wrap img {
  border-radius: 12px;
}

.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.85);
  transition: background 0.2s, transform 0.2s, color 0.2s;
}

.footer-social a:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  transform: translateY(-2px);
}

.footer-social svg {
  width: 18px;
  height: 18px;
}

.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 767px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }
}

/* ─── Mobile sticky CTA ─── */
.mobile-cta-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 900;
  grid-template-columns: 1fr 1fr;
  padding: 0.65rem 1rem calc(0.65rem + var(--safe-bottom));
  background: var(--v2-glass);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  border-top: 1px solid var(--v2-glass-border);
  box-shadow: 0 -8px 32px rgba(15, 23, 42, 0.12);
  gap: 0.5rem;
}

.mobile-cta-bar .btn {
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  border-radius: var(--radius-sm);
}

.mobile-cta-bar .btn-whatsapp {
  background: #25d366;
  color: #fff;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.35);
}

@media (max-width: 991px) {
  .mobile-cta-bar {
    display: grid;
  }

  body.has-mobile-cta {
    padding-bottom: calc(72px + var(--safe-bottom));
  }
  body.has-mobile-cta.has-cookie-banner {
    padding-bottom: calc(72px + var(--safe-bottom));
  }
  body.has-mobile-cta .whatsapp-btn {
    bottom: calc(76px + var(--safe-bottom));
  }
  body.has-mobile-cta .scroll-top {
    bottom: calc(140px + var(--safe-bottom));
  }
  body.has-mobile-cta.has-cookie-banner .scroll-top {
    bottom: calc(200px + var(--safe-bottom));
  }
}

/* ─── Page templates ─── */
.page-hero,
.contact-hero,
.products-hero {
  padding: clamp(2.5rem, 6vw, 4rem) 0;
}

.page-hero h1,
.contact-hero h1,
.products-hero h1 {
  font-size: clamp(1.75rem, 4.5vw, 2.5rem);
}

.grid-3 {
  gap: 1.25rem;
}

@media (max-width: 991px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 599px) {
  .grid-3 { grid-template-columns: 1fr; }
}

.split {
  gap: clamp(1.5rem, 4vw, 3rem);
}

@media (max-width: 991px) {
  .split { grid-template-columns: 1fr; }
}

/* ─── Forms ─── */
.contact-form input,
.contact-form textarea,
.contact-form select {
  border-radius: var(--v2-radius-sm);
  border: 1.5px solid var(--border);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-glow);
}

/* ─── FAQ ─── */
.faq-item {
  border-radius: var(--v2-radius-sm);
  border: 1px solid var(--border-light);
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.faq-item[open] {
  box-shadow: var(--shadow);
  border-color: var(--brand-muted);
}

/* ─── Floating UI polish ─── */
.whatsapp-btn {
  width: 56px;
  height: 56px;
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.45);
}

.scroll-top {
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--v2-glass);
  backdrop-filter: blur(12px);
}

/* ─── Reduced motion ─── */
@media (prefers-reduced-motion: reduce) {
  .feature-card:hover,
  .product-card:hover,
  .article-card:hover,
  .trust-item:hover {
    transform: none;
  }
}
