/* Design system */
:root {
  --bg: #0b1220;
  --card: #0f172a;
  --muted: #94a3b8;
  --text: #e2e8f0;
  --primary: #22c55e;
  --accent: #38bdf8;
  --ring: rgba(56,189,248,.35);
  --radius: 16px;
  --container: 1120px;
  --shadow: 0 10px 30px rgba(0,0,0,.4);
}

* { box-sizing: border-box }
html, body { padding:0; margin:0; overflow-x: hidden; }
html { width: 100%; }
body { width: 100%; min-width: 0; }
body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background: radial-gradient(1200px 600px at 50% -10%, #0b2a3a 0%, var(--bg) 40%);
  line-height: 1.6;
}

.container { max-width: var(--container); padding: 0 20px; margin: 0 auto }
.container.narrow { max-width: 800px }

/* Header */
.site-header { position: sticky; top:0; backdrop-filter: blur(10px); background: rgba(11,18,32,.6); border-bottom: 1px solid rgba(148,163,184,.15); z-index: 50 }
.site-header .nav { display:flex; align-items:center; justify-content:space-between; min-height:72px }
.logo { display:flex; align-items:center; gap:10px; font-weight:800; color:var(--text); text-decoration:none }
.logo img { width:28px; height:28px }
nav a { color: var(--muted); text-decoration:none; margin: 0 10px; font-weight:600 }
nav a:hover { color: var(--text) }
nav .btn { margin-left: 6px }

/* Hero */
.hero { padding: 96px 0 40px; text-align:center }
.hero h1 { font-size: clamp(28px, 4vw, 58px); line-height:1.1; margin: 0 0 14px }
.hero .sub { color:var(--muted); font-size: clamp(16px, 2vw, 20px); margin-bottom: 24px }
.cta { display:flex; gap:12px; justify-content:center; flex-wrap:wrap }
.btn { display:inline-block; padding:12px 18px; border-radius: 999px; border: 1px solid rgba(56,189,248,.3); text-decoration:none; font-weight:700; box-shadow: var(--shadow); transition:.2s }
.btn-primary { background: linear-gradient(135deg, var(--primary), #16a34a); color:#04131b; border: none }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 20px 40px rgba(34,197,94,.3) }
.btn-ghost { background: rgba(148,163,184,.07); color: var(--text) }
.btn-ghost:hover { background: rgba(148,163,184,.12) }

/* Stats */
.stats { display:grid; grid-template-columns: repeat(4,1fr); gap:14px; margin: 28px auto 0; max-width:900px }
.stats div { background: linear-gradient(135deg, rgba(56,189,248,.08), rgba(34,197,94,.08)); border:1px solid rgba(148,163,184,.15); padding:16px; border-radius: var(--radius) }
.stats span { display:block; font-weight:800; font-size: 22px }
.stats small { color: var(--muted) }

/* Sections */
section.container { padding: 60px 0 }
h2 { font-size: clamp(22px, 2.6vw, 36px); margin: 0 0 18px }
h3 { font-size: 20px; margin: 0 0 8px }
.features .grid { display:grid; grid-template-columns: repeat(4,1fr); gap:16px }
.features article, .card, .post-card { background: linear-gradient(135deg, rgba(56,189,248,.06), rgba(34,197,94,.06)); border:1px solid rgba(148,163,184,.15); border-radius: var(--radius); padding:18px }

/* Services cards */
.cards { display:grid; grid-template-columns: repeat(3,1fr); gap:16px }
.card ul { margin: 10px 0 12px 18px }
.card li { margin: 6px 0 }

/* Proof */
.proof .logos { display:flex; flex-wrap:wrap; gap:10px; opacity:.8 }
.proof .logos span { background: rgba(148,163,184,.08); border:1px solid rgba(148,163,184,.15); border-radius: 8px; padding: 6px 10px }
.proof blockquote { margin: 18px 0; padding: 12px 16px; border-left: 3px solid var(--accent); background: rgba(56,189,248,.06); border-radius: 6px }

/* Page layout */
.page { padding-top: 64px }
.page p.meta { color: var(--muted); margin: -6px 0 16px }

/* Services */
.service-list { display:grid; grid-template-columns: repeat(2,1fr); gap:16px }
.service-list ul { margin: 10px 0 12px 18px }

/* Pricing */
.price-grid { display:grid; grid-template-columns: repeat(3,1fr); gap:16px }
.price-card { text-align:center }
.price-card .price { font-size:32px; font-weight:800; margin: 6px 0 10px; color: var(--accent) }
.note { color: var(--muted); margin-top: 12px }

/* Blog */
.post-card .meta { color: var(--muted) }
.post-card a { color: var(--text) }
.post-card a:hover { text-decoration: underline }

/* Contact */
form.contact { display:grid; gap:12px }
form.contact label { display:grid; gap:6px; color: var(--muted) }
form.contact input, form.contact select, form.contact textarea {
  background: rgba(2,6,23,.6); border:1px solid rgba(148,163,184,.2); color: var(--text);
  padding: 12px 14px; border-radius: 10px; outline: none;
}
form.contact input:focus, form.contact textarea:focus, form.contact select:focus { box-shadow: 0 0 0 4px var(--ring) }

/* Footer */
.site-footer { margin-top: 60px; padding: 28px 0 36px; background: linear-gradient(180deg, rgba(148,163,184,.06), rgba(2,6,23,.6)) }
.footer-grid { display:grid; grid-template-columns: 2fr 1fr 1fr; gap:16px }
.footer-grid h4 { margin: 0 0 8px }
.footer-grid ul { list-style: none; padding:0; margin:0 }
.footer-grid a { color: var(--muted); text-decoration:none }
.footer-grid a:hover { color: var(--text) }
.copyright { margin-top: 18px; color: var(--muted); text-align:center; border-top:1px solid rgba(148,163,184,.15); padding-top: 14px }

/* ===== TAWK.TO WIDGET STYLING ===== */
#tawk-bubble-container {
  bottom: 20px !important;
  right: 20px !important;
  z-index: 9999 !important;
}

@keyframes tawkSlideIn {
  from { transform: translateY(100px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

#tawk-bubble-container {
  animation: tawkSlideIn 0.5s ease-out 1s both;
}

/* ===== Responsive ===== */
@media (max-width: 900px){
  .features .grid, .cards, .price-grid, .service-list, .stats { grid-template-columns: 1fr 1fr }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}

@media (max-width: 768px){
  /* Overflow fix */
  html, body { overflow-x: hidden; width: 100%; }
  *, *::before, *::after { max-width: 100%; }
  
  .container { padding: 0 16px; width: 100%; max-width: 100%; overflow-x: hidden; }
  .container.narrow { padding: 0 16px; max-width: 100%; }
  
  /* Header & Navigation */
  .site-header { width: 100%; }
  .site-header .nav { min-height: auto; flex-wrap: wrap; gap: 8px; padding: 10px 0; }
  .logo { font-size: 0.9rem; }
  .logo img { width: 24px; height: 24px; }
  nav { width: 100%; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
  nav a { margin: 0 6px; font-size: 0.85rem; padding: 6px 8px; }
  nav .btn { margin-left: 0; padding: 10px 14px; width: auto; }
  
  /* Hero */
  .hero { padding: 60px 0 30px; width: 100%; }
  .hero h1 { font-size: clamp(24px, 6vw, 36px); word-wrap: break-word; }
  .hero .sub { font-size: 1rem; }
  .cta { flex-direction: column; align-items: center; gap: 10px; width: 100%; }
  .cta .btn { width: 100%; max-width: 100%; text-align: center; box-sizing: border-box; }
  
  /* Stats */
  .stats { grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; }
  .stats div { padding: 12px; }
  .stats span { font-size: 18px; }
  
  /* Sections */
  section.container { padding: 40px 16px; }
  section { width: 100%; }
  h1 { font-size: clamp(1.4rem, 5vw, 1.8rem); line-height: 1.3; word-wrap: break-word; }
  h2 { font-size: clamp(1.2rem, 4vw, 1.5rem); word-wrap: break-word; }
  h3 { font-size: 1.1rem; }
  
  /* Cards */
  .features .grid, .cards, .price-grid, .service-list { grid-template-columns: 1fr; gap: 14px; }
  .features .grid { grid-template-columns: 1fr; }
  .card, .features article { padding: 16px; width: 100%; box-sizing: border-box; }
  
  /* Page */
  .page { padding-top: 40px; padding-left: 0; padding-right: 0; width: 100%; }
  .page p.meta { font-size: 0.85rem; }
  
  /* Pricing */
  .price-card .price { font-size: 26px; }
  
  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 20px; text-align: center; }
  .site-footer { padding: 24px 0 28px; width: 100%; }
  
  /* Buttons - önemli fix */
  .btn { 
    padding: 14px 16px; 
    font-size: 0.95rem; 
    width: 100%; 
    max-width: 100%;
    text-align: center; 
    box-sizing: border-box; 
    white-space: normal;
    word-wrap: break-word;
  }
  
  /* Lists */
  ul, ol { padding-left: 20px; max-width: 100%; }
  li { margin-bottom: 8px; word-wrap: break-word; }
  
  /* Images - taşma önleme */
  img { 
    max-width: 100%; 
    height: auto; 
    border-radius: 10px; 
  }
  figure { margin: 16px 0; width: 100%; max-width: 100%; }
  figcaption { font-size: 0.85rem; }
  
  /* Video embed responsive */
  figure > div[style*="padding-bottom"] { border-radius: 10px !important; width: 100%; }
  iframe { max-width: 100%; }
  
  /* Details/FAQ */
  details { margin: 10px 0; width: 100%; }
  details summary { padding: 12px 0; font-size: 1rem; cursor: pointer; }
  details p { font-size: 0.95rem; }
  
  /* Table overflow fix */
  table { display: block; overflow-x: auto; max-width: 100%; }
  
  /* Pre/code overflow */
  pre, code { max-width: 100%; overflow-x: auto; word-wrap: break-word; }
  
  /* HR */
  hr { max-width: 100%; }
  
  /* Tawk.to mobile */
  #tawk-bubble-container { bottom: 15px !important; right: 15px !important; }
}

@media (max-width: 480px){
  /* Global overflow fix */
  *, *::before, *::after { max-width: 100%; box-sizing: border-box; }
  
  .container { padding: 0 12px; }
  
  /* Header */
  .site-header .nav { padding: 8px 0; flex-direction: column; align-items: center; }
  .logo { font-size: 0.85rem; gap: 6px; }
  nav { flex-wrap: wrap; justify-content: center; }
  nav a { margin: 4px; font-size: 0.8rem; padding: 8px 10px; }
  
  /* Hero */
  .hero { padding: 40px 0 24px; }
  .hero h1 { font-size: 1.4rem; }
  .hero .sub { font-size: 0.9rem; }
  
  /* Stats */
  .stats { grid-template-columns: 1fr; }
  .stats div { padding: 10px; }
  .stats span { font-size: 16px; }
  
  /* Content */
  h1 { font-size: 1.25rem; line-height: 1.3; }
  h2 { font-size: 1.1rem; }
  h3 { font-size: 1rem; }
  p, li { font-size: 0.95rem; line-height: 1.5; }
  
  /* Cards */
  .card, .features article { padding: 14px; border-radius: 12px; }
  .card ul { margin-left: 14px; }
  
  /* Pricing */
  .price-card .price { font-size: 22px; }
  
  /* Buttons */
  .btn { 
    padding: 12px 14px; 
    font-size: 0.9rem; 
    border-radius: 12px; 
    width: 100%;
    white-space: normal;
  }
  
  /* Footer */
  .footer-grid { gap: 16px; }
  .copyright { font-size: 0.85rem; }
  
  /* Form */
  form.contact input, form.contact select, form.contact textarea { padding: 10px 12px; font-size: 0.95rem; }
  
  /* Meta text */
  .meta { font-size: 0.8rem; word-wrap: break-word; }
  
  /* Breadcrumb */
  nav[aria-label="Breadcrumb"] { font-size: 0.75rem; word-wrap: break-word; }
  
  /* Features grid force single column */
  .features .grid { grid-template-columns: 1fr !important; }
  
  /* Tawk.to mobile small */
  #tawk-bubble-container { bottom: 10px !important; right: 10px !important; }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
  .btn { min-height: 48px; display: flex; align-items: center; justify-content: center; }
  nav a { min-height: 44px; display: inline-flex; align-items: center; }
  details summary { min-height: 48px; display: flex; align-items: center; }
  a { padding: 2px 0; }
}

/* Print mode - hide Tawk.to */
@media print {
  #tawk-bubble-container { display: none !important; }
}