/* =====================================================
   TANE THEME - PAGE STYLES (Cart, Checkout, Account, 404)
   ===================================================== */

/* === GENERIC PAGE CONTENT === */
.tane-page-content { padding: 40px 0 60px; }
.tane-page-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 40px;
  align-items: start;
}
.tane-page-layout:not(:has(.tane-sidebar)) { grid-template-columns: 1fr; }
.page-title-block { margin-bottom: 28px; padding-bottom: 16px; border-bottom: 1px solid var(--clr-border); }
.page-title {
  font-family: var(--ff-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 400;
  color: var(--clr-secondary);
}
.page-entry-content { line-height: 1.8; }
.page-entry-content p { margin-bottom: 1em; }
.page-entry-content h2,h3,h4 { font-family: var(--ff-display); font-weight: 400; margin: 1.5em 0 .5em; }
.page-entry-content a { color: var(--clr-primary); text-decoration: underline; }

/* === CART PAGE === */
.tane-cart-page .cart-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
  align-items: start;
}

/* Cart Actions Row */
.cart-main .actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px 0 0;
  border-top: 2px solid var(--clr-border);
}
.cart-main .coupon {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.cart-main .coupon label { font-size: var(--fs-sm); font-weight: 500; }
.cart-main .coupon .input-text {
  padding: 9px 14px; border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-full); font-size: var(--fs-sm); outline: none;
  transition: border-color var(--transition); width: 180px;
}
.cart-main .coupon .input-text:focus { border-color: var(--clr-accent); }
.tane-btn-outline-dark {
  background: transparent; color: var(--clr-text);
  border: 1.5px solid var(--clr-border) !important;
  padding: 9px 18px !important;
  border-radius: var(--radius-full) !important;
  font-size: var(--fs-sm) !important; font-weight: 500 !important;
  transition: all var(--transition) !important;
  display: inline-flex !important; align-items: center !important;
}
.tane-btn-outline-dark:hover {
  border-color: var(--clr-primary) !important;
  color: var(--clr-primary) !important;
}

/* Cart Totals Sidebar */
.cart-sidebar .cart_totals {
  position: sticky;
  top: calc(var(--header-h) + var(--topbar-h) + 16px);
}
.cart-sidebar .wc-proceed-to-checkout { margin-top: 0; }

/* Empty Cart */
.woocommerce-cart-form .woocommerce-message--info {
  text-align: center; padding: 60px 20px;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}

/* === CHECKOUT PAGE === */
.tane-checkout-page .checkout-steps {
  display: flex; align-items: center; justify-content: center;
  gap: 0; margin-bottom: 32px; flex-wrap: wrap;
}
.checkout-steps .step {
  display: flex; align-items: center; gap: 8px;
  font-size: var(--fs-sm); color: var(--clr-text-muted);
}
.checkout-steps .step.active { color: var(--clr-primary); font-weight: 600; }
.checkout-steps .step.completed { color: var(--clr-success); }
.step-num {
  width: 28px; height: 28px; border-radius: 50%;
  border: 2px solid currentColor;
  display: flex; align-items: center; justify-content: center;
  font-size: var(--fs-xs); font-weight: 700;
}
.step.active .step-num { background: var(--clr-primary); color: #fff; border-color: var(--clr-primary); }
.step.completed .step-num { background: var(--clr-success); color: #fff; border-color: var(--clr-success); }
.step-line { height: 2px; width: 60px; background: var(--clr-border); margin: 0 8px; }

.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 40px;
  align-items: start;
}
.checkout-section {
  background: #fff; border: 1px solid var(--clr-border);
  border-radius: var(--radius-md); padding: 28px; margin-bottom: 20px;
}
.checkout-section h3 {
  font-family: var(--ff-display); font-size: var(--fs-xl);
  font-weight: 400; margin-bottom: 20px;
  padding-bottom: 12px; border-bottom: 1px solid var(--clr-border);
}
.order-review-section {
  position: sticky; top: calc(var(--header-h) + var(--topbar-h) + 16px);
  margin-bottom: 0;
}

/* WooCommerce Order Review Table */
.woocommerce-checkout-review-order-table {
  width: 100%; border-collapse: collapse; font-size: var(--fs-sm);
}
.woocommerce-checkout-review-order-table thead th {
  padding: 10px 0; border-bottom: 2px solid var(--clr-border);
  text-transform: uppercase; letter-spacing: .06em;
  font-size: var(--fs-xs); color: var(--clr-text-muted);
}
.woocommerce-checkout-review-order-table tbody tr td {
  padding: 12px 0; border-bottom: 1px solid var(--clr-border); vertical-align: middle;
}
.woocommerce-checkout-review-order-table tfoot tr th,
.woocommerce-checkout-review-order-table tfoot tr td {
  padding: 10px 0; border-bottom: 1px solid var(--clr-border);
  font-size: var(--fs-sm);
}
.woocommerce-checkout-review-order-table tfoot .order-total th,
.woocommerce-checkout-review-order-table tfoot .order-total td {
  font-size: var(--fs-lg); font-weight: 700; color: var(--clr-primary); border-bottom: none;
}

/* Payment Methods */
.woocommerce-checkout #payment { margin-top: 0; padding: 0; background: none; border-radius: 0; }
.woocommerce-checkout #payment ul.payment_methods { padding: 0; margin: 0 0 16px; list-style: none; }
.woocommerce-checkout #payment ul.payment_methods li {
  padding: 12px 14px; border: 1.5px solid var(--clr-border);
  border-radius: var(--radius); margin-bottom: 8px; background: #fff;
  transition: border-color var(--transition);
}
.woocommerce-checkout #payment ul.payment_methods li:has(input:checked) { border-color: var(--clr-primary); }
.woocommerce-checkout #payment ul.payment_methods li label {
  font-size: var(--fs-sm); font-weight: 500; cursor: pointer;
  display: flex; align-items: center; gap: 10px;
}
.woocommerce-checkout #payment div.payment_box {
  padding: 12px 14px; background: var(--clr-bg);
  border-radius: 0 0 var(--radius) var(--radius);
  font-size: var(--fs-sm); margin-top: -8px;
}
.woocommerce-checkout #payment .place-order { padding: 0; background: none; }

/* === MY ACCOUNT === */
.tane-account-page .account-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 40px;
  align-items: start;
}
.account-nav {
  background: #fff; border: 1px solid var(--clr-border);
  border-radius: var(--radius-md); overflow: hidden;
  position: sticky; top: calc(var(--header-h) + var(--topbar-h) + 16px);
}
.account-nav-list { padding: 8px 0; }
.account-nav-list li a {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 20px; font-size: var(--fs-sm); font-weight: 500;
  color: var(--clr-text); transition: all var(--transition);
}
.account-nav-list li a:hover { background: var(--clr-bg); color: var(--clr-primary); }
.account-nav-list li.is-active a { background: var(--clr-primary); color: #fff; }
.nav-icon svg { width: 16px; height: 16px; flex-shrink: 0; }
.account-content {
  background: #fff; border: 1px solid var(--clr-border);
  border-radius: var(--radius-md); padding: 28px;
}

/* Orders Table in Account */
.woocommerce-orders-table {
  width: 100%; border-collapse: collapse; font-size: var(--fs-sm);
}
.woocommerce-orders-table th {
  padding: 10px 12px; border-bottom: 2px solid var(--clr-border);
  text-align: left; font-size: var(--fs-xs); text-transform: uppercase;
  letter-spacing: .06em; color: var(--clr-text-muted);
}
.woocommerce-orders-table td {
  padding: 14px 12px; border-bottom: 1px solid var(--clr-border); vertical-align: middle;
}
.woocommerce-orders-table tr:last-child td { border-bottom: none; }
.woocommerce-orders-table .button {
  padding: 6px 14px; background: var(--clr-primary); color: #fff;
  border-radius: var(--radius-full); font-size: var(--fs-xs); font-weight: 600;
}
.woocommerce-orders-table .button:hover { background: var(--clr-accent); }

/* Order Status Badges */
.woocommerce-order-status {
  display: inline-block; padding: 3px 10px; border-radius: var(--radius-full);
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: .04em;
}
.order-status-processing { background: #e8f4fd; color: #1a6fa0; }
.order-status-completed  { background: #e8f8ee; color: #2a7a4b; }
.order-status-on-hold    { background: #fff8e1; color: #a07a00; }
.order-status-cancelled,
.order-status-failed     { background: #fde8e8; color: #a02a2a; }
.order-status-pending    { background: #f5f5f5; color: #666; }

/* Account Forms */
.woocommerce-EditAccountForm .form-row,
.woocommerce-address-fields .form-row { margin-bottom: 16px; }
.woocommerce-EditAccountForm .form-row label,
.woocommerce-address-fields .form-row label {
  display: block; font-size: var(--fs-sm); font-weight: 500; margin-bottom: 6px;
}
.woocommerce-EditAccountForm input,
.woocommerce-address-fields input,
.woocommerce-address-fields select {
  width: 100%; padding: 10px 14px; border: 1.5px solid var(--clr-border);
  border-radius: var(--radius); font-size: var(--fs-sm); outline: none;
  transition: border-color var(--transition);
}
.woocommerce-EditAccountForm input:focus,
.woocommerce-address-fields input:focus,
.woocommerce-address-fields select:focus { border-color: var(--clr-accent); }
.woocommerce-EditAccountForm .button,
.woocommerce-address-fields .button {
  padding: 11px 24px; background: var(--clr-primary); color: #fff;
  border: none; border-radius: var(--radius-full); font-size: var(--fs-sm); font-weight: 600;
  cursor: pointer; transition: background var(--transition);
}
.woocommerce-EditAccountForm .button:hover,
.woocommerce-address-fields .button:hover { background: var(--clr-accent); }

/* === 404 PAGE === */
.tane-404 {
  text-align: center; padding: 80px 20px;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.tane-404-visual {
  display: flex; align-items: center; justify-content: center;
  gap: 8px; margin-bottom: 8px;
}
.err-num {
  font-family: var(--ff-display); font-size: 8rem;
  font-weight: 300; color: var(--clr-accent); line-height: 1;
  letter-spacing: -.04em;
}
.err-icon svg { width: 80px; height: 80px; }
.tane-404 h1 {
  font-family: var(--ff-display); font-size: var(--fs-3xl);
  font-weight: 400; color: var(--clr-secondary);
}
.tane-404 p { font-size: var(--fs-md); color: var(--clr-text-muted); max-width: 400px; }
.err-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }
.err-search {
  display: flex; gap: 0; max-width: 440px; width: 100%; margin-top: 8px;
  border: 1.5px solid var(--clr-border); border-radius: var(--radius-full); overflow: hidden;
}
.err-search input[type="search"] {
  flex: 1; padding: 12px 20px; border: none; outline: none; font-size: var(--fs-sm);
}
.err-search .tane-btn { border-radius: 0 var(--radius-full) var(--radius-full) 0; padding: 12px 20px; }

/* === RESPONSIVE === */
@media (max-width: 1024px) {
  .tane-cart-page .cart-layout { grid-template-columns: 1fr; }
  .checkout-layout { grid-template-columns: 1fr; }
  .order-review-section { position: static; }
  .tane-account-page .account-layout { grid-template-columns: 1fr; }
  .account-nav { position: static; }
  .account-nav-list { display: flex; flex-wrap: wrap; gap: 4px; padding: 12px; }
  .account-nav-list li a { padding: 8px 14px; border-radius: var(--radius); }
  .tane-page-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .err-num { font-size: 5rem; }
  .err-icon svg { width: 60px; height: 60px; }
  .tane-cart-page .woocommerce table.cart th:nth-child(1),
  .tane-cart-page .woocommerce table.cart th:nth-child(2) { display: none; }
}

/* =====================================================
   GİRİŞ / KAYIT SAYFASI
   ===================================================== */

/* Auth page layout — iki kolon */
.tane-auth-page {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: calc(100vh - var(--header-h) - var(--topbar-h) - 80px);
}

/* Sol dekoratif panel */
.auth-deco {
  background: linear-gradient(145deg, #1a1208 0%, #3D2B0E 50%, #1a1208 100%);
  display: flex; align-items: center; justify-content: center;
  padding: 60px 40px;
  position: relative; overflow: hidden;
}
.auth-deco::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(201,168,76,.15) 0%, transparent 60%);
}
.auth-deco-inner {
  position: relative; z-index: 1;
  color: #fff; max-width: 360px;
}
.auth-brand { margin-bottom: 32px; }
.auth-brand img, .auth-brand .custom-logo { height: 60px; width: auto; }
.auth-brand .logo-text {
  font-family: var(--ff-display); font-size: 2rem;
  font-weight: 400; color: var(--clr-accent);
}
.auth-deco h2 {
  font-family: var(--ff-display); font-size: clamp(1.5rem, 2.5vw, 2.2rem);
  font-weight: 300; line-height: 1.2; margin-bottom: 12px;
  color: #fff;
}
.auth-deco p { color: rgba(255,255,255,.65); line-height: 1.7; margin-bottom: 32px; }
.auth-deco-beads {
  position: absolute; right: -20px; top: 50%; transform: translateY(-50%);
  width: 200px;
}
.auth-features { display: flex; flex-direction: column; gap: 10px; }
.auth-feat {
  display: flex; align-items: center; gap: 10px;
  font-size: var(--fs-sm); color: rgba(255,255,255,.8);
}
.auth-feat span {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--clr-primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; flex-shrink: 0;
}

/* Sağ form alanı */
.auth-forms {
  background: var(--clr-bg);
  display: flex; flex-direction: column;
  justify-content: center;
  padding: 60px clamp(24px, 6vw, 80px);
}

/* Tab butonları */
.auth-tabs {
  display: flex; gap: 0;
  background: #fff; border-radius: var(--radius-full);
  padding: 4px; border: 1px solid var(--clr-border);
  margin-bottom: 32px; width: fit-content;
}
.auth-tab {
  padding: 9px 24px; border-radius: var(--radius-full);
  font-size: var(--fs-sm); font-weight: 500;
  border: none; background: none; cursor: pointer;
  color: var(--clr-text-muted); transition: all var(--transition);
}
.auth-tab.active { background: var(--clr-primary); color: #fff; }

/* Form panelleri */
.auth-form-panel { display: none; }
.auth-form-panel.active { display: block; }
.auth-title {
  font-family: var(--ff-display); font-size: var(--fs-2xl);
  font-weight: 400; margin-bottom: 6px;
}
.auth-subtitle { color: var(--clr-text-muted); font-size: var(--fs-sm); margin-bottom: 28px; }

/* Form alanları */
.auth-field { margin-bottom: 18px; }
.auth-field label {
  display: flex; align-items: center; justify-content: space-between;
  font-size: var(--fs-sm); font-weight: 500; margin-bottom: 7px;
  color: var(--clr-text);
}
.forgot-link { font-size: var(--fs-xs); color: var(--clr-primary); font-weight: 400; }
.forgot-link:hover { text-decoration: underline; }

.field-wrap {
  position: relative; display: flex; align-items: center;
  border: 1.5px solid var(--clr-border); border-radius: var(--radius-md);
  background: #fff; transition: border-color var(--transition);
  overflow: hidden;
}
.field-wrap:focus-within { border-color: var(--clr-primary); box-shadow: 0 0 0 3px rgba(139,105,20,.1); }
.field-wrap > svg {
  width: 16px; height: 16px; color: var(--clr-text-muted);
  margin-left: 14px; flex-shrink: 0;
}
.field-wrap input {
  flex: 1; padding: 12px 14px; border: none; outline: none;
  background: transparent; font-size: var(--fs-sm); color: var(--clr-text);
}
.field-wrap input::placeholder { color: var(--clr-text-muted); }
.toggle-pass {
  padding: 0 14px; background: none; border: none; cursor: pointer;
  color: var(--clr-text-muted); display: flex; align-items: center;
  transition: color var(--transition);
}
.toggle-pass:hover { color: var(--clr-primary); }
.toggle-pass svg { width: 16px; height: 16px; }

/* Beni hatırla */
.auth-remember {
  display: flex; align-items: center; gap: 8px;
  font-size: var(--fs-sm); color: var(--clr-text-muted);
  cursor: pointer; margin-bottom: 22px;
}
.auth-remember input[type="checkbox"] {
  width: 16px; height: 16px; accent-color: var(--clr-primary);
}

/* Giriş / Kayıt butonu */
.auth-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 14px 24px;
  background: var(--clr-primary); color: #fff;
  border: none; border-radius: var(--radius-md);
  font-size: var(--fs-md); font-weight: 600; cursor: pointer;
  transition: all var(--transition); letter-spacing: .02em;
}
.auth-btn:hover { background: var(--clr-secondary); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.auth-btn svg { width: 18px; height: 18px; }

/* Alt linkler */
.auth-switch {
  text-align: center; margin-top: 20px;
  font-size: var(--fs-sm); color: var(--clr-text-muted);
}
.switch-tab {
  background: none; border: none; cursor: pointer;
  color: var(--clr-primary); font-weight: 600; font-size: var(--fs-sm);
  text-decoration: underline;
}
.auth-terms {
  text-align: center; font-size: var(--fs-xs); color: var(--clr-text-muted);
  margin-top: 14px;
}
.auth-terms a { color: var(--clr-primary); }

/* ── Giriş Yapılmış — Hesap Paneli ── */
.tane-account-wrap { padding: 40px 0 60px; }
.account-welcome {
  display: flex; align-items: center; gap: 16px;
  padding: 24px 28px; background: #fff;
  border-radius: var(--radius-md); border: 1px solid var(--clr-border);
  margin-bottom: 28px; box-shadow: var(--shadow-sm);
}
.welcome-avatar .avatar-img {
  width: 64px; height: 64px; border-radius: 50%;
  border: 3px solid var(--clr-accent); object-fit: cover;
}
.welcome-text h1 {
  font-family: var(--ff-display); font-size: var(--fs-2xl); font-weight: 400;
  margin-bottom: 2px;
}
.welcome-text h1 span { color: var(--clr-primary); }
.welcome-text p { font-size: var(--fs-sm); color: var(--clr-text-muted); }

.account-layout { display: grid; grid-template-columns: 220px 1fr; gap: 28px; align-items: start; }
.account-nav {
  background: #fff; border: 1px solid var(--clr-border);
  border-radius: var(--radius-md); overflow: hidden;
  position: sticky; top: calc(var(--header-h) + var(--topbar-h) + 16px);
}
.account-nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 18px; font-size: var(--fs-sm); font-weight: 500;
  color: var(--clr-text); text-decoration: none;
  border-bottom: 1px solid var(--clr-border);
  transition: all var(--transition); position: relative;
}
.account-nav-item:last-child { border-bottom: none; }
.account-nav-item svg { width: 17px; height: 17px; flex-shrink: 0; }
.account-nav-item:hover { background: var(--clr-bg); color: var(--clr-primary); padding-left: 22px; }
.account-nav-item.active { background: var(--clr-primary); color: #fff; }
.account-nav-item.active:hover { padding-left: 18px; }
.nav-badge {
  margin-left: auto; background: var(--clr-accent); color: #fff;
  font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 9px;
}
.account-nav-item.active .nav-badge { background: rgba(255,255,255,.3); }
.account-content-area {
  background: #fff; border: 1px solid var(--clr-border);
  border-radius: var(--radius-md); padding: 28px; min-height: 300px;
}

/* Responsive */
@media (max-width: 900px) {
  .tane-auth-page { grid-template-columns: 1fr; }
  .auth-deco { display: none; }
  .auth-forms { padding: 40px 24px; min-height: 100vh; }
  .account-layout { grid-template-columns: 1fr; }
  .account-nav { position: static; }
  .account-nav-item { padding: 11px 14px; }
}
@media (max-width: 480px) {
  .account-welcome { flex-direction: column; text-align: center; }
}

/* Checkout yasal linkler */
.tane-checkout-legal {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    padding: 16px 0 0;
    border-top: 1px solid var(--clr-border);
    margin-top: 16px;
}
.tane-checkout-legal a {
    font-size: var(--fs-xs);
    color: var(--clr-text-muted);
    text-decoration: underline;
    transition: color var(--transition);
}
.tane-checkout-legal a:hover { color: var(--clr-primary); }
