/* ========== style.css (Tamamen optimize edilmiş) ========== */

/* ========== Variables ========== */
:root{
  --bg: #fffaf2;
  --card: #ffffff;
  --accent: #eda52a;
  --accent-600: #d08d1a;
  --muted: #897b61;
  --text: #181511;
  --danger: #ff6b6b;
  --muted-2: #f1da8a;
  --shadow: rgba(23,21,18,0.06);
  --container-max: 1100px;
  --radius-lg: 16px;
  --radius-md: 8px;
  --gap: 18px;
}

/* ========== Reset & Base ========== */
*,
*::before,
*::after { box-sizing: border-box; }

html,body {
  height: 100%;
}

body {
  margin: 0;
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
  -webkit-tap-highlight-color: transparent;
}

/* Keep the page-body class as main page container for inner pages */
body.page-body { min-height: 100vh; }

/* Tiny helpers */
.hidden { display:none !important; }
.center { text-align:center; }
.sr-only { position: absolute !important; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0 0 0 0); border:0; }

/* ========== Container ========== */
.container {
  max-width: var(--container-max);
  margin: 28px auto;
  padding: 0 16px;
  width: 100%;
}

/* ========== NAVBAR (support component markup variations) ========== */
/* Accepts: <nav class="site-nav">, <nav> (component), or injected raw markup */
nav.site-nav,
nav, /* fallback for injected component markup */
nav[class*="site"],
/* fallback if navbar wrapped inside a div#navbar */
#navbar > nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background: var(--card);
  border-bottom: 1px solid rgba(0,0,0,0.04);
  box-shadow: 0 2px 10px var(--shadow);
  position: sticky;
  top: 0;
  z-index: 60;
}

/* Brand */
nav .brand,
nav .flex { display:flex; align-items:center; gap:10px; }
nav img.logo { width:36px; height:36px; object-fit:contain; display:block; }
nav .brand .site-title { font-weight:700; font-size:1.05rem; color:var(--text); }

/* Links area */
nav ul {
  display:flex;
  gap:16px;
  list-style:none;
  margin:0;
  padding:0;
  align-items:center;
}
nav a {
  color: var(--text);
  text-decoration: none;
  font-weight:600;
  font-size:0.95rem;
  padding:8px 10px;
  border-radius:8px;
}
nav a:hover,
nav a:focus { background: rgba(237,165,42,0.08); outline: none; }

/* right actions */
nav .nav-actions { display:flex; gap:8px; align-items:center; }

/* Mobile collapse button (simple) */
nav .nav-toggle { display:none; background:transparent; border:0; font-size:1.1rem; }

/* ========== Buttons ========== */
.btn,
button,
input[type="submit"],
a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap:8px;
  cursor: pointer;
  border-radius: 10px;
  border: 1px solid transparent;
  padding: 8px 14px;
  font-weight:700;
  background: transparent;
  color: var(--text);
  text-decoration: none;
  transition: transform .12s ease, box-shadow .12s ease, opacity .12s ease;
}
.btn:active { transform: translateY(1px); }

.btn.primary {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-600) 100%);
  color: #111;
  border-color: transparent;
  box-shadow: 0 6px 18px rgba(208,141,26,0.12);
}
.btn.secondary {
  background: transparent;
  border: 1px solid rgba(24,21,17,0.06);
}
.btn.ghost { background: transparent; border:1px dashed rgba(0,0,0,0.04); }

/* small variant */
.btn-small {
  padding:6px 10px;
  border-radius:6px;
  border:1px solid rgba(0,0,0,0.06);
  background:#fafafa;
  font-weight:600;
}

/* accessibility focus */
a:focus, button:focus, input:focus, textarea:focus {
  outline: 3px solid rgba(237,165,42,0.18);
  outline-offset: 2px;
}

/* ========== HERO (homepage) ========== */
.hero {
  width: 100%;
  max-width: 1200px;
  margin: 40px auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background-position: center;
  background-size: cover;
  padding: 60px 20px;
  text-align: center;
  display:flex;
  align-items:center;
  justify-content:center;
  position:relative;
  min-height: 260px;
}

/* if image path used as in original file */
.hero { background: url('../images/honeycomb-bg.jpg') center/cover no-repeat; }

/* semi-opaque overlay for readability */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.72), rgba(255,255,255,0.5));
  pointer-events: none;
}

/* hero content card */
.hero-content {
  position: relative;
  z-index: 2;
  background: rgba(255,255,255,0.85);
  padding: 28px 36px;
  border-radius: 14px;
  max-width: 900px;
  width: 100%;
}
.hero-content h1 {
  margin: 0 0 10px;
  font-size: clamp(20px, 3.2vw, 34px);
  color: var(--text);
  line-height: 1.1;
}
.hero-content p { margin: 0 0 16px; color: var(--muted); }

/* small hero button */
.btn-primary { display:inline-block; background: var(--accent); color:#111; padding:10px 18px; border-radius:10px; font-weight:700; }

/* ========== Explore Section ========== */
.explore { text-align:center; margin:60px auto; max-width:1100px; padding:0 16px; }
.explore-grid { display:grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--gap); }
.explore-card { background: var(--card); padding:18px; border-radius:12px; box-shadow: 0 6px 18px var(--shadow); display:flex; flex-direction:column; align-items:center; gap:12px; }
.explore-card img { width:64px; height:64px; object-fit:contain; }

/* highlight variant */
.explore-card.highlight { background: linear-gradient(180deg,#fff8e6,#fff5d8); text-align:center; }

/* ========== PRODUCTS GRID & CARD ========== */
.products-grid {
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--gap);
  margin-top: 18px;
}

/* card */
.product-card {
  background: var(--card);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 6px 20px var(--shadow);
  transition: transform .18s ease, box-shadow .18s ease;
  border: 1px solid rgba(0,0,0,0.04);
  display:flex;
  flex-direction:column;
  gap:12px;
  min-height: 320px;
}
.product-card:hover { transform: translateY(-6px); box-shadow: 0 10px 26px rgba(23,21,18,0.08); }

.product-card img { width:100%; height:350px; object-fit:cover; border-radius:10px; background:#f6f2ec; }
.product-title { font-size:1.05rem; font-weight:700; margin:0; color:var(--text); }
.product-desc { color:var(--muted); font-size:0.95rem; min-height:56px; overflow:hidden; }
.product-price { font-size:1.05rem; font-weight:800; color:var(--text); }

/* card bottom actions area */
.product-card .card-footer {
  margin-top: auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
}

/* add to cart button override */
.add-btn { background: linear-gradient(180deg, var(--accent), var(--accent-600)); color:#111; padding:10px 14px; border-radius:10px; border:none; font-weight:700; cursor:pointer; }

/* quantity badge (hidden by default) */
/* Use JS to toggle .visible on .quantity-badge when product exists in cart */
.quantity-badge {
  font-size: 0.95rem;
  background: #fff7dc;
  padding: 6px 12px;
  border-radius: 999px;
  color: #4b3a12;
  border: 1px solid var(--muted-2);
  display: inline-block;
  font-weight:600;
  transition: transform .12s ease, opacity .12s ease;
  opacity: 0;
  transform: scale(.96);
  pointer-events: none;
}
.quantity-badge.visible { opacity:1; transform: scale(1); pointer-events:auto; }

/* ========== CART PAGE ========== */
.cart-items { display:flex; flex-direction:column; gap:12px; margin-bottom:20px; padding: 6px 0; }

/* single item */
.cart-item {
  display:flex;
  gap:12px;
  align-items:center;
  padding:12px;
  border-radius:10px;
  border:1px solid rgba(0,0,0,0.04);
  background: var(--card);
  box-shadow: 0 6px 14px var(--shadow);
  position: relative;
}

/* image */
.cart-item img {
  width:80px;
  height:80px;
  object-fit:cover;
  border-radius:8px;
  background: #faf7f2;
  flex-shrink: 0;
}

/* details */
.cart-item .cart-item-details {
  flex:1;
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width: 0;
}
.cart-item h4 { margin:0; font-size:1rem; font-weight:700; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.cart-item p { margin:0; color:var(--muted); font-size:0.92rem; }

/* price block */
.cart-item .cart-right {
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:8px;
}
.cart-item .cart-item-price { font-weight:800; color:var(--text); }

/* actions: qty +/- and remove */
.cart-item .cart-item-actions {
  display:flex;
  align-items:center;
  gap:8px;
  margin-top:6px;
}
.cart-item .cart-item-actions .btn-small { padding:6px 10px; border-radius:8px; }

/* remove button styled */
.btn-remove {
  padding:8px 10px;
  background: var(--danger);
  color:#fff;
  border:none;
  border-radius:8px;
  cursor:pointer;
  font-weight:700;
}

/* helper: quantity badge inside cart (if used) */
.cart-qty-bubble {
  padding:6px 10px;
  border-radius:8px;
  background:#fff9e6;
  border:1px solid var(--muted-2);
  font-weight:700;
}

/* hide any stray progress bars from third party or mistakes */
.cart-item .progress,
.cart-item .progress-bar,
.cart-item .bar,
.cart-item .delete-bar,
.cart-item .wide-bar { display:none !important; }

/* cart totals area */
.cart-total {
  margin-top: 12px;
  font-weight:800;
  font-size:1.05rem;
  display:flex;
  justify-content:flex-end;
  gap:8px;
}

/* checkout form */
.checkout-form {
  display:flex;
  flex-direction:column;
  gap:12px;
  max-width:520px;
  margin-top:18px;
}
.checkout-form input, .checkout-form textarea {
  padding:12px;
  border-radius:10px;
  border:1px solid #e6e2db;
  background: #fff;
  font-size:0.95rem;
}

/* whatsapp order button standout */
#whatsapp-order { background: #25D366; color:#fff; border:none; font-weight:800; padding:12px 16px; }

/* ========== ABOUT/CONTACT page specific small fixes ========== */
.contact-page .contact-form { background: var(--card); padding:18px; border-radius:12px; box-shadow:0 6px 18px var(--shadow); }
.contact-info { display:flex; flex-direction:column; gap:8px; color:var(--muted); }

/* ========== FOOTER (supports different markup variants) ========== */
footer.site-footer,
footer,
footer[class*="site"],
#footer > footer,
#footer {
  background: #fdfaf5;
  color: var(--text);
  padding: 28px 16px;
  border-top:1px solid #e6e2db;
  margin-top: 40px;
}
footer .small { color:var(--muted); font-size:13px; text-align:center; margin-top:16px; }

/* footer inner layout */
footer > div,
footer .container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 16px;
  display:flex;
  gap:18px;
  align-items:flex-start;
  justify-content:space-between;
  flex-wrap:wrap;
}
footer h3, footer h4 { margin:0 0 8px 0; font-weight:700; }
footer ul { list-style:none; padding:0; margin:0; display:flex; flex-direction:column; gap:6px; }

/* ========== Responsive ========== */
@media (max-width: 980px) {
  .container { max-width: 900px; padding: 0 14px; }
  .hero { padding: 48px 16px; }
  nav ul { gap:12px; }
  .product-card { min-height: 320px; }
}

@media (max-width: 768px) {
  nav .nav-toggle { display:inline-flex; }
  nav ul { display:none; } /* simple mobile hide for injected nav - JS can toggle */
  .hero { min-height: 220px; margin: 26px 12px; }
  .explore-grid { grid-template-columns: 1fr; }
  .products-grid { grid-template-columns: repeat(2, 1fr); gap:12px; }
  .product-card img { height:160px; }
  .cart-item { align-items:flex-start; }
  .cart-item img { width:100%; height:auto; border-radius:8px; }
  .cart-item { flex-direction: column; }
  .cart-item .cart-right { align-items:flex-start; width:100%; }
}

@media (max-width: 480px) {
  .container { margin: 18px auto; padding:0 12px; }
  .product-card { min-height: auto; padding:12px; }
  .products-grid { grid-template-columns: 1fr; }
  .hero-content { padding:16px; }
  .hero { padding: 22px 12px; border-radius:12px; }
  nav { padding:10px 12px; }
}

/* ========== Misc tidy-ups ========== */
a:hover { opacity:0.95; }
img { display:block; max-width:100%; height:auto; }

/* ========== Notes for integration (non-functional comments) ========== */
/*
 - To show quantity on a product card after JS updates cart, add the "visible" class to the .quantity-badge element:
   document.querySelector('.quantity-badge').classList.add('visible');

 - For responsive mobile nav toggling, keep nav ul hidden by default on small screens and toggle via JS to add a class like .open:
   nav ul.open { display:flex; flex-direction:column; gap:10px; }

 - CSS purposely keeps animations/subtle shadows conservative for performance on mobile.
*/
/* ABOUT HERO */
.about-hero {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 40px auto;
  border-radius: 18px;
  overflow: hidden;
  height: 420px;
}

/* Arka plandaki görsel */
.about-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.75); /* Transparan etki */
}

/* Şeffaf beyaz overlay (mevcut görünüm korunur) */
.about-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.35);
  backdrop-filter: blur(2px);
}

/* Yazı kutusu */
.about-hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: #333;
  padding: 20px 40px;
}

.about-hero-content h1 {
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 14px;
  color: #333;
}

.about-hero-content p {
  max-width: 700px;
  font-size: 18px;
  line-height: 1.5;
  color: #444;
}

/* Mobil görünüm */
@media (max-width: 768px) {
  .about-hero {
    height: 330px;
  }
  .about-hero-content h1 {
    font-size: 28px;
  }
  .about-hero-content p {
    font-size: 15px;
  }
}

/* ============================
   İLETİŞİM FORMU (MODERN TASARIM)
   ============================ */
.contact-section {
    margin-top: 40px;
}

.contact-form-container {
    background: #ffffff;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0px 4px 20px rgba(0,0,0,0.05);
    margin: 20px 0 40px;
}

.contact-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}

/* Etiketler */
.contact-form label {
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
}

/* Input & Textarea */
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    font-size: 15px;
    background: #fffaf2;
    transition: border 0.2s ease;
}

.contact-form textarea {
    resize: vertical;
    height: 120px;
}

/* Hover & focus */
.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--accent);
    outline: none;
}

/* Gönder Butonu */
.contact-submit {
    grid-column: 1 / 3;
    justify-self: start;
    background: var(--accent);
    color: #181511;
    padding: 12px 26px;
    font-size: 16px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
    transition: background 0.2s ease;
}

.contact-submit:hover {
    background: var(--accent-600);
}

/* Responsive */
@media (max-width: 768px) {
    .contact-form {
        grid-template-columns: 1fr;
    }

    .contact-submit {
        grid-column: 1 / 2;
        justify-self: stretch;
    }
}
