﻿/*
Theme Name: Vip Art Optik
Theme URI: https://vipartoptik.com
Author: Vip Art Optik
Author URI: https://vipartoptik.com
Description: Vip Art Optik için WooCommerce uyumlu, modern ve responsive optik mağaza teması.
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: vipart-optik
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/
:root {
  --ink: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --paper: #ffffff;
  --soft: #f6f8fb;
  --blue: #0f766e;
  --blue-2: #0ea5a4;
  --gold: #b88936;
  --danger: #dc2626;
  --ok: #15803d;
  --shadow: 0 18px 55px rgba(15, 23, 42, 0.11);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--soft);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
img { max-width: 100%; display: block; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px clamp(16px, 4vw, 46px);
  background: rgba(255,255,255,.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.brand { display: flex; align-items: center; gap: 12px; min-width: max-content; }
.brand-logo,
.custom-logo {
  width: 66px;
  height: 48px;
  object-fit: contain;
  border-radius: 6px;
  background: white;
}
.brand-mark {
  width: 44px; height: 44px; border-radius: 8px;
  display: grid; place-items: center;
  color: white; font-weight: 800; letter-spacing: .04em;
  background: linear-gradient(135deg, var(--ink), var(--blue));
}
.brand strong { font-size: 18px; letter-spacing: .02em; }
.brand small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.main-nav { display: flex; gap: 4px; align-items: center; margin-left: auto; }
.main-nav a { padding: 10px 12px; border-radius: 7px; color: #334155; font-weight: 650; }
.main-nav a:hover, .main-nav a.active { background: #eef7f6; color: var(--blue); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.header-link {
  color: #334155;
  font-weight: 750;
  font-size: 14px;
  white-space: nowrap;
}
.header-link:hover { color: var(--blue); }
.header-link.strong {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 9px 11px;
  background: white;
}
.cart-pill, .primary, .secondary, .danger, .ghost {
  border: 0; border-radius: 7px; padding: 11px 14px; cursor: pointer; font-weight: 750;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.cart-pill { background: var(--ink); color: white; }
.cart-pill strong { background: var(--gold); min-width: 24px; height: 24px; border-radius: 99px; display: grid; place-items: center; }
.primary { background: var(--blue); color: white; }
.secondary { background: #e6f5f4; color: var(--blue); }
.danger { background: #fee2e2; color: var(--danger); }
.ghost { background: white; color: var(--ink); border: 1px solid var(--line); }
.primary:disabled, .secondary:disabled { opacity: .45; cursor: not-allowed; }
.icon-button { border: 1px solid var(--line); background: white; border-radius: 7px; width: 42px; height: 42px; cursor: pointer; }
.menu-toggle { display: none; margin-left: auto; }

.app-shell { min-height: 72vh; }
.retail-search {
  background: white;
  border-bottom: 1px solid var(--line);
  padding: 14px clamp(16px, 4vw, 46px);
}
.search-wrap {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 16px;
  align-items: center;
}
.search-wrap label {
  display: grid;
  gap: 6px;
}
.search-wrap label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}
.search-wrap input {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  background: #f8fafc;
}
.retail-hero {
  padding: 20px clamp(16px, 4vw, 46px) 0;
  background: white;
}
.retail-slide {
  max-width: 1180px;
  min-height: 430px;
  margin: 0 auto;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  padding: clamp(28px, 5vw, 64px);
  background:
    linear-gradient(90deg, rgba(245,238,229,.98) 0%, rgba(245,238,229,.88) 34%, rgba(245,238,229,.42) 58%, rgba(245,238,229,.03) 100%),
    url("../images/hero-luxury.png") center right/cover;
  border: 1px solid var(--line);
}
.retail-slide div { max-width: 520px; padding-top: 10px; }
.retail-slide .eyebrow {
  display: block;
  margin-bottom: 18px;
  transform: translateY(-8px);
}
.retail-slide h1 {
  font-family: Didot, "Bodoni 72", "Bodoni MT", "Libre Bodoni", Georgia, "Times New Roman", serif;
  font-size: clamp(52px, 7vw, 86px);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: .035em;
  text-transform: uppercase;
}
.retail-slide p {
  max-width: 500px;
  color: #4b5563;
  font-size: 18px;
  letter-spacing: .01em;
}
.home-categories {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  padding-top: 26px;
  padding-bottom: 20px;
}
.home-categories a {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 108px;
  display: grid;
  place-items: center;
  gap: 8px;
  text-align: center;
  box-shadow: 0 8px 18px rgba(15,23,42,.04);
}
.home-categories span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #eef7f6;
  color: var(--blue);
  font-weight: 900;
  font-size: 22px;
}
.promo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.promo-card {
  min-height: 245px;
  border-radius: 8px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  border: 1px solid var(--line);
  overflow: hidden;
  background-size: cover;
  background-position: center;
}
.promo-card span {
  color: var(--gold);
  font-weight: 850;
  text-transform: uppercase;
  font-size: 13px;
}
.promo-card.dark {
  color: white;
  background:
    linear-gradient(180deg, rgba(15,23,42,.08), rgba(15,23,42,.82)),
    url("../images/hero-luxury.png") center/cover;
}
.promo-card.dark p { color: #e2e8f0; }
.promo-card.light {
  background:
    linear-gradient(90deg, rgba(255,255,255,.96), rgba(255,255,255,.62)),
    url("../images/hero-luxury.png") center/cover;
}
.service-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}
.service-strip div {
  background: white;
  padding: 18px;
}
.service-strip strong,
.service-strip span {
  display: block;
}
.service-strip span {
  color: var(--muted);
  margin-top: 5px;
  font-size: 14px;
}
.section { padding: clamp(30px, 5vw, 72px) clamp(16px, 4vw, 46px); }
.narrow { max-width: 1180px; margin: 0 auto; }
.hero {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(320px, 1.05fr);
  align-items: center;
  gap: clamp(22px, 4vw, 54px);
  padding: clamp(28px, 5vw, 58px) clamp(16px, 4vw, 46px);
  background: #f7fafc;
  border-bottom: 1px solid var(--line);
}
.eyebrow { color: var(--gold); font-weight: 850; text-transform: uppercase; font-size: 13px; letter-spacing: .08em; }
h1, h2, h3 { margin: 0; line-height: 1.05; }
h1 { font-size: clamp(38px, 5.6vw, 68px); max-width: 760px; }
h2 { font-size: clamp(28px, 4vw, 46px); }
h3 { font-size: 20px; }
p { color: var(--muted); line-height: 1.7; }
.hero p { max-width: 610px; font-size: 18px; }
.hero-actions, .toolbar, .button-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-panel {
  align-self: stretch;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.hero-tile {
  min-height: 205px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: end;
}
.hero-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(15,23,42,.72));
}
.hero-tile > * { position: relative; color: white; }
.hero-tile.wide { grid-column: 1 / -1; min-height: 230px; }
.quick-cats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 26px;
}
.quick-cats a {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  font-weight: 800;
  text-align: center;
}
.metric-strip, .grid, .product-grid, .admin-grid, .form-grid { display: grid; gap: 18px; }
.metric-strip { grid-template-columns: repeat(4, 1fr); margin-top: 28px; }
.metric, .card, .product-card, .panel {
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 22px rgba(15,23,42,.04);
}
.metric { padding: 18px; }
.metric strong { display: block; font-size: 25px; }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.card, .panel { padding: 20px; }
.category-card { min-height: 190px; display: flex; flex-direction: column; justify-content: end; background-size: cover; background-position: center; color: white; overflow: hidden; position: relative; }
.category-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent, rgba(0,0,0,.72)); }
.category-card > * { position: relative; color: white; }

.split-head { display: flex; justify-content: space-between; gap: 18px; align-items: end; margin-bottom: 22px; }
.product-layout { display: grid; grid-template-columns: 280px 1fr; gap: 22px; }
.filters { position: sticky; top: 84px; height: max-content; }
.field { display: grid; gap: 7px; margin-bottom: 12px; }
.field label { font-size: 13px; color: #475569; font-weight: 750; }
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 7px; background: white; padding: 11px 12px;
}
.product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.product-card { overflow: hidden; display: flex; flex-direction: column; }
.product-media { position: relative; display: block; background: #eef2f7; }
.product-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; background: #eef2f7; }
.favorite-heart {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(226,232,240,.9);
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.94);
  color: #64748b;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  box-shadow: 0 10px 24px rgba(15,23,42,.14);
}
.favorite-heart.active {
  color: #dc2626;
  border-color: rgba(220,38,38,.22);
  background: #fff5f5;
}
.favorite-heart:hover { transform: translateY(-1px); }
.product-body { padding: 16px; display: grid; gap: 10px; flex: 1; }
.badge-row { display: flex; gap: 7px; flex-wrap: wrap; }
.badge { display: inline-flex; width: max-content; border-radius: 999px; padding: 5px 9px; font-size: 12px; font-weight: 800; background: #eef7f6; color: var(--blue); }
.badge.gold { background: #fff7e8; color: #8a5b13; }
.badge.danger-badge { background: #fee2e2; color: var(--danger); }
.price { display: flex; gap: 9px; align-items: baseline; font-weight: 850; font-size: 20px; }
.price del { color: #94a3b8; font-size: 14px; }
.stock-ok { color: var(--ok); font-weight: 800; }
.stock-no { color: var(--danger); font-weight: 800; }

.detail { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: start; }
.gallery-main { border-radius: 8px; overflow: hidden; border: 1px solid var(--line); background: white; }
.gallery-main img { aspect-ratio: 1/1; object-fit: cover; width: 100%; }
.thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 12px; }
.thumbs button { border: 2px solid transparent; padding: 0; border-radius: 7px; overflow: hidden; cursor: pointer; }
.thumbs button.active { border-color: var(--blue); }
.thumbs img { aspect-ratio: 1/1; object-fit: cover; }
.spec-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.spec-list div { border: 1px solid var(--line); background: white; padding: 12px; border-radius: 7px; }
.spec-list span { display: block; color: var(--muted); font-size: 12px; margin-bottom: 3px; }

.cart-line { display: grid; grid-template-columns: 80px 1fr auto auto; gap: 16px; align-items: center; border-bottom: 1px solid var(--line); padding: 14px 0; }
.cart-line img { aspect-ratio: 1; object-fit: cover; border-radius: 7px; }
.qty { display: inline-flex; border: 1px solid var(--line); border-radius: 7px; overflow: hidden; }
.qty button { width: 34px; border: 0; background: white; cursor: pointer; }
.qty span { min-width: 36px; display: grid; place-items: center; border-inline: 1px solid var(--line); }

.admin-shell { display: grid; grid-template-columns: 280px 1fr; min-height: 76vh; }
.admin-sidebar { background: #0b1220; color: white; padding: 18px; }
.admin-sidebar a { display: block; color: #cbd5e1; padding: 10px 11px; border-radius: 7px; font-weight: 650; }
.admin-sidebar a:hover, .admin-sidebar a.active { background: rgba(255,255,255,.09); color: white; }
.admin-main { padding: 24px; min-width: 0; }
.admin-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 20px; }
.admin-grid { grid-template-columns: repeat(5, 1fr); }
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 8px; background: white; }
table { width: 100%; border-collapse: collapse; min-width: 760px; }
th, td { padding: 13px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
th { background: #f8fafc; color: #475569; font-size: 13px; }
.state { min-height: 150px; display: grid; place-items: center; text-align: center; color: var(--muted); border: 1px dashed #cbd5e1; border-radius: 8px; background: white; padding: 24px; }
.chart { height: 220px; display: flex; align-items: end; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: white; }
.bar { flex: 1; background: linear-gradient(180deg, var(--blue-2), var(--blue)); border-radius: 6px 6px 0 0; min-height: 18px; position: relative; }
.bar span { position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); color: var(--muted); font-size: 11px; margin-bottom: 4px; }
.form-grid { grid-template-columns: repeat(2, 1fr); }
.full { grid-column: 1 / -1; }
.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.tabs button { border: 1px solid var(--line); background: white; padding: 10px 12px; border-radius: 7px; cursor: pointer; font-weight: 750; }
.tabs button.active { background: var(--ink); color: white; }
.toast { position: fixed; right: 18px; bottom: 18px; z-index: 99; background: var(--ink); color: white; padding: 12px 16px; border-radius: 8px; opacity: 0; transform: translateY(12px); transition: .2s; box-shadow: var(--shadow); }
.toast.show { opacity: 1; transform: translateY(0); }
.muted-note { color: var(--muted); font-size: 13px; margin-top: 16px; }
.admin-login { max-width: 520px; margin: 0 auto; }
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(15, 23, 42, .58);
}
.modal-card {
  width: min(920px, 100%);
  max-height: 88vh;
  overflow: auto;
  position: relative;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  box-shadow: var(--shadow);
}
.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: white;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}
.modal-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  align-items: center;
  margin-top: 8px;
}
.site-footer {
  display: grid;
  gap: 22px;
  padding: 36px clamp(16px,4vw,46px) 22px;
  background: #0b1220;
  color: white;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1fr;
  gap: 24px;
}
.site-footer p, .site-footer span, .site-footer a {
  color: #cbd5e1;
  display: block;
  margin: 7px 0;
  line-height: 1.55;
  font-size: 14px;
}
.site-footer a:hover { color: white; }
.footer-legal-note {
  color: #cbd5e1;
  border-top: 1px solid rgba(255,255,255,.12);
  padding-top: 18px;
  line-height: 1.65;
  font-size: 13px;
}
.footer-bottom {
  color: #94a3b8;
  font-size: 13px;
}
.legal-page > p { max-width: 900px; }
.legal-list {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}
.whatsapp-float { position: fixed; right: 18px; bottom: 76px; z-index: 40; background: #16a34a; color: white; border-radius: 999px; padding: 12px 16px; font-weight: 850; box-shadow: var(--shadow); }

.woocommerce-section .woocommerce-products-header,
.woocommerce-section .woocommerce-result-count,
.woocommerce-section .woocommerce-ordering {
  margin-bottom: 18px;
}
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 0;
  padding: 0;
}
.woocommerce ul.products::before,
.woocommerce ul.products::after {
  display: none;
}
.woocommerce ul.products li.product {
  width: auto;
  margin: 0;
  float: none;
}
.woocommerce .product-card .button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
  border: 0;
  border-radius: 7px;
  padding: 11px 14px;
  background: var(--blue);
  color: white;
  font-weight: 750;
  line-height: 1.2;
}
.woocommerce .product-card .button:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover {
  background: var(--ink);
  color: white;
}
.woocommerce span.onsale {
  min-height: auto;
  min-width: auto;
  border-radius: 999px;
  padding: 6px 10px;
  background: var(--gold);
  color: white;
  line-height: 1;
}
.woocommerce div.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}
.woocommerce div.product div.images,
.woocommerce div.product div.summary {
  width: auto;
  float: none;
}
.woocommerce div.product div.images img {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.woocommerce div.product p.price,
.woocommerce div.product span.price {
  color: var(--ink);
  font-size: 24px;
  font-weight: 850;
}
.woocommerce div.product form.cart,
.woocommerce div.product .woocommerce-tabs,
.woocommerce-cart-form,
.cart_totals,
.woocommerce-checkout #customer_details,
.woocommerce-checkout #order_review,
.woocommerce-MyAccount-navigation,
.woocommerce-MyAccount-content,
.vipart-tracking-panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(15,23,42,.04);
  padding: 20px;
}
.woocommerce table.shop_table {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: white;
}
.woocommerce table.shop_table th,
.woocommerce table.shop_table td {
  border-color: var(--line);
}
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce .select2-container .select2-selection--single {
  border: 1px solid var(--line);
  border-radius: 7px;
  min-height: 44px;
  padding: 9px 12px;
}
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  border-top-color: var(--blue);
  background: white;
  border-radius: 8px;
}
.woocommerce-account .woocommerce-MyAccount-navigation ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.woocommerce-account .woocommerce-MyAccount-navigation a {
  display: block;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 10px 12px;
  font-weight: 750;
}
.vipart-favorite-toggle:disabled {
  opacity: .6;
  cursor: wait;
}

@media (max-width: 1060px) {
  .hero, .detail, .product-layout, .admin-shell { grid-template-columns: 1fr; }
  .metric-strip, .admin-grid { grid-template-columns: repeat(2, 1fr); }
  .product-grid, .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .woocommerce ul.products { grid-template-columns: repeat(2, 1fr); }
  .woocommerce div.product { grid-template-columns: 1fr; }
  .home-categories { grid-template-columns: repeat(3, 1fr); }
  .service-strip, .promo-grid { grid-template-columns: 1fr 1fr; }
  .filters { position: static; }
  .admin-sidebar { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; }
  .header-actions { display: none; }
}
@media (max-width: 760px) {
  .menu-toggle { display: grid; place-items: center; }
  .main-nav { display: none; position: absolute; top: 74px; left: 12px; right: 12px; background: white; border: 1px solid var(--line); border-radius: 8px; padding: 8px; box-shadow: var(--shadow); }
  .main-nav.open { display: grid; }
  .cart-pill span { display: none; }
  .brand-logo, .custom-logo { width: 54px; height: 40px; }
  .brand strong { font-size: 15px; }
  .hero { min-height: auto; padding-top: 34px; }
  .hero-panel, .quick-cats { grid-template-columns: 1fr; }
  .search-wrap, .home-categories, .service-strip, .promo-grid { grid-template-columns: 1fr; }
  .retail-slide { min-height: 330px; }
  .product-grid, .grid.cols-2, .grid.cols-3, .grid.cols-4, .form-grid, .metric-strip, .admin-grid, .spec-list { grid-template-columns: 1fr; }
  .woocommerce ul.products { grid-template-columns: 1fr; }
  .split-head, .admin-top { align-items: stretch; flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
  .cart-line { grid-template-columns: 64px 1fr; }
  .cart-line > .qty, .cart-line > strong { grid-column: 2; }
  .admin-main { padding: 16px; }
  .admin-sidebar { grid-template-columns: 1fr; }
}

