:root { --drawer-width: 400px; }

/* IMPORTANT: jis wrapper me aapka page ka content hai */
#site-content{
  transition: width .35s ease, margin-right .35s ease;
  width: 100%;
  margin-right: 0;
}

/* drawer open par: content ki width kam + right space reserve */
body.drawer-open #site-content{
  width: calc(100% - var(--drawer-width));
  margin-right: var(--drawer-width);
}

/* drawer width sync */
.checkout-drawer{
  max-width: var(--drawer-width);
}



/* Checkout Drawer - Right Side Panel */

/* Floating mini-cart / trigger button - dark grey/black to match image */
.checkout-trigger-btn {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: #252525;
  color: #fff;
  border: none;
  border-radius: 999px;
  font-family: var(--font-family-one, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transition: background 0.2s, transform 0.2s;
}

.checkout-btn-text {
  color: #ffffff !important;
}

.checkout-trigger-btn:hover {
  background: #1a1a1a;
  transform: translateX(-50%) scale(1.02);
}
.checkout-trigger-btn .trigger-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: #FF385C;
  border-radius: 50%;
}
.checkout-trigger-btn .trigger-arrow svg {
  width: 14px;
  height: 14px;
  color: #ffffff;
  stroke: #ffffff;
}

/* Drawer overlay */
.checkout-drawer-overlay {
  position: fixed;
  inset: 0;
  /* background: rgba(0, 0, 0, 0.4); */
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}
.checkout-drawer-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

/* Drawer panel */
.checkout-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 400px;
  height: 100%;
  background: #fff;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  /* box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12); */
  transform: translateX(100%);
  transition: transform 0.35s ease;
}
.checkout-drawer.is-open {
  transform: translateX(0);
      border-left: 4px solid #efefef;
}

/* Drawer header */
.checkout-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px 16px;
  border-bottom: 1px solid #e6e6ea;
  flex-shrink: 0;
}
.checkout-drawer-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #151618;
}
.checkout-drawer-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 50%;
  color: #797c82;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.checkout-drawer-close:hover {
  background: #f2f0f2;
  color: #151618;
}
.checkout-drawer-close svg {
  width: 20px;
  height: 20px;
}

/* Drawer body - scrollable items */
.checkout-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}

/* Cart item */
.checkout-drawer-item {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #efeef0;
}
.checkout-drawer-item:last-child {
  border-bottom: none;
}
.checkout-drawer-item-img {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #f8f8f8;
}
.checkout-drawer-item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.checkout-drawer-item-img .no-img {
  width: 100%;
  height: 100%;
  background: #e8e8e8;
}
.checkout-drawer-item-info {
  flex: 1;
  min-width: 0;
}
.checkout-drawer-item-title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 500;
  color: #151618;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.checkout-drawer-item-meta {
  font-size: 14px;
  color: #6b7280;
}
.checkout-drawer-item-price,
.checkout-drawer-item-qty {
  display: none;
}
.checkout-drawer-item-remove {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  padding: 0;
  background: transparent;
  border: none;
  color: #9ca3af;
  cursor: pointer;
  transition: color 0.2s;
}
.checkout-drawer-item-remove:hover {
  color: #dc2626;
}
.checkout-drawer-item-remove svg {
  width: 20px;
  height: 20px;
}

/* Summary section */
.checkout-drawer-summary {
  padding: 16px 20px;
  border-top: 1px solid #e6e6ea;
  flex-shrink: 0;
  background: #fff;
}
.checkout-drawer-summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  font-size: 14px;
  color: #151618;
}
.checkout-drawer-summary-row:last-child {
  margin-bottom: 0;
}
.checkout-drawer-summary-label {
  color: #797c82;
}
.checkout-drawer-summary-value {
  font-weight: 500;
}

/* Checkout button - dark grey/black to match image */
.checkout-drawer-footer {
  padding: 16px 20px 24px;
  flex-shrink: 0;
}
.checkout-drawer-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  background: #252525;
  color: #fff;
  border: none;
  border-radius: 999px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
.checkout-drawer-btn:hover {
  background: #1a1a1a;
}
.checkout-drawer-btn .btn-arrow {
  width: 18px;
  height: 18px;
  color: #FF385C;
  stroke: #FF385C;
}

@media (max-width: 480px) {
  .checkout-drawer {
    max-width: 100%;
  }
  .checkout-trigger-btn {
    font-size: 14px;
    padding: 10px 16px;
  }
}
/* Empty cart state */
.checkout-drawer-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #797c82;
  font-size: 15px;
  text-align: center;
  padding: 40px 20px;
}

.checkout-drawer-empty p {
  margin: 0;
}

/* Cart item highlight animation when added */
.checkout-drawer-item {
  animation: fadeInSlide 0.3s ease;
}

@keyframes fadeInSlide {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===========================
   FIX: PUSH HEADER + HIDE LINKS + SHOW HAMBURGER
   Paste this at the VERY END of your CSS
=========================== */

:root { --drawer-width: 400px; }

/* (optional but helps) */
*, *::before, *::after { box-sizing: border-box; }

/* ✅ CONTENT push (keep simple, less jitter than width calc) */
/* #site-content{
  transition: margin-right .35s ease;
  margin-right: 0;
} */
body.drawer-open #site-content{
  margin-right: var(--drawer-width);
}

/* ✅ HEADER - add smooth transitions */
header.header-section{
  transition: margin-right .35s ease;
  margin-right: 0;
}

/* ✅ Floating navbar - add transitions */
header.header-section .navbar_floating-component.w-nav{
  transition: right .35s ease, width .35s ease;
  right: 0;
}

/* ✅ When drawer is open - push navbar */
body.drawer-open header.header-section{
  margin-right: var(--drawer-width);
}

body.drawer-open header.header-section .navbar_floating-component.w-nav{
  right: var(--drawer-width) !important;
  width: calc(100% - var(--drawer-width)) !important;
}

/* ✅ Keep nav menu visible - just adjust container */
body.drawer-open header.header-section .navbar_floating-container{
  position: relative;
}

/* ✅ Mobile: drawer full width => no push */
@media (max-width: 991px){
  body.drawer-open #site-content,
  body.drawer-open header.header-section{
    margin-right: 0 !important;
  }
  body.drawer-open header.header-section .navbar_floating-component.w-nav{
    right: 0 !important;
    width: 100% !important;
  }
}

/* ===========================
   CHECKOUT BUTTON STATES
=========================== */

.checkout-drawer-btn:disabled {
  background: #6b6b6b;
  cursor: not-allowed;
  opacity: 0.8;
}
.checkout-drawer-btn:disabled:hover {
  background: #6b6b6b;
}

/* ===========================
   CHECKOUT VIEWS
=========================== */

.checkout-view {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.checkout-cart-view {
  display: flex;
}

.checkout-shipping-view {
  display: none;
}

/* Back button */
.checkout-back-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  color: #151618;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 0;
  transition: color 0.2s;
}
.checkout-back-btn:hover {
  color: #FF385C;
}
.checkout-back-btn svg {
  width: 20px;
  height: 20px;
}

/* Shipping view header */
.checkout-shipping-view .checkout-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid #e6e6ea;
  flex-shrink: 0;
}

/* ===========================
   SHIPPING FORM STYLES
=========================== */

.checkout-shipping-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.checkout-section-title {
  font-size: 14px;
  font-weight: 600;
  color: #151618;
  margin: 0 0 16px 0;
  padding-bottom: 8px;
  border-bottom: 1px solid #e6e6ea;
}

.checkout-section-title:not(:first-child) {
  margin-top: 24px;
}

.checkout-form-group {
  margin-bottom: 16px;
}

.checkout-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #151618;
  margin-bottom: 6px;
}

.checkout-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  color: #151618;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.checkout-input:focus {
  outline: none;
  border-color: #FF385C;
  box-shadow: 0 0 0 3px rgba(255, 56, 92, 0.1);
}

.checkout-input::placeholder {
  color: #9ca3af;
}

.checkout-input.error {
  border-color: #ef4444;
}

select.checkout-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
  padding-right: 40px;
}

.checkout-form-row {
  display: flex;
  gap: 12px;
}

.checkout-form-half {
  flex: 1;
}

/* Error message */
.checkout-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 12px;
}

/* Pay button */
.checkout-pay-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #FF385C;
}

.checkout-pay-btn:hover {
  background: #e0314f;
}

.checkout-pay-btn .btn-arrow {
  width: 18px;
  height: 18px;
}

/* Secure note */
.checkout-secure-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 12px 0 0 0;
  font-size: 12px;
  color: #6b7280;
}

.checkout-secure-note svg {
  color: #10b981;
  stroke: #10b981;
}

/* Shipping view footer */
.checkout-shipping-view .checkout-drawer-footer {
  padding: 16px 20px 24px;
  border-top: 1px solid #e6e6ea;
  background: #fff;
}
