/*
  AK World - Pricing Enhancements
  - Mobile-friendly tweaks
  - Currency auto-detection + manual selector styling
  - Add-to-cart + WhatsApp checkout drawer
*/

/* Small mobile improvements */
.ak-feature-scroll{
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 900px){
  .ak-feature-table{ min-width: 720px; }
}
@media (max-width: 600px){
  .ak-container{ padding: 0 12px; }
  .ak-feature-box{ padding: 18px 14px; }
  .ak-card{ padding: 18px 14px; }
  .ak-top-actions{ gap: 10px; }
}

/* Table tools (search / count) */
.ak-table-tools{
  display:flex;
  gap:12px;
  justify-content:space-between;
  align-items:center;
  flex-wrap:wrap;
  margin: 14px 0 10px;
}
.ak-search{
  flex: 1;
  min-width: 220px;
}
.ak-search input{
  width:100%;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid #e5e5e5;
  font-family: inherit;
  font-size: 13px;
  outline: none;
}
.ak-search input:focus{
  border-color: rgba(165,214,92,.9);
  box-shadow: 0 0 0 4px rgba(165,214,92,.18);
}
.ak-tool-right{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.ak-clear-btn{
  background: #141414;
  color:#fff;
  border:none;
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 800;
  cursor:pointer;
  font-size: 12px;
}
.ak-clear-btn:hover{ filter: brightness(.98); }
.ak-results{
  font-size: 12px;
  color:#444;
}

/* Currency selector */
.ak-currency-pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border:1px solid #e7e7e7;
  border-radius:999px;
  background: rgba(255,255,255,.86);
  backdrop-filter: blur(6px);
}
.ak-currency-pill label{
  font-weight: 900;
  font-size: 12px;
  color:#141414;
  margin: 0;
}
.ak-currency-pill select{
  border:none;
  background: transparent;
  font-weight: 900;
  font-size: 12px;
  outline: none;
  cursor: pointer;
}
.ak-currency-note{
  font-size: 11px;
  color:#555;
  margin-top: 6px;
}

/* Add to cart buttons inside price cells */
.ak-price-actions{
  margin-top: 8px;
  display:flex;
  gap:8px;
  justify-content:center;
  flex-wrap:wrap;
}
.ak-add-btn{
  background:#A5D65C;
  color:#141414;
  border:none;
  padding:8px 10px;
  border-radius:999px;
  font-weight: 900;
  font-size: 12px;
  cursor:pointer;
}
.ak-add-btn:hover{ filter: brightness(.97); }
.ak-add-btn:active{ transform: translateY(1px); }
.ak-quote-btn{
  background: transparent;
  color:#141414;
  border:1px solid rgba(20,20,20,.22);
  padding:8px 10px;
  border-radius:999px;
  font-weight: 900;
  font-size: 12px;
  cursor:pointer;
}
.ak-quote-btn:hover{ background: rgba(165,214,92,.12); }

/* Cart floating button */
.ak-cart-fab{
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 9999;
  display:flex;
  gap:10px;
  align-items:center;
  background:#141414;
  color:#fff;
  border:none;
  border-radius:999px;
  padding: 12px 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
  cursor:pointer;
}
.ak-cart-fab:active{ transform: translateY(1px); }
.ak-cart-badge{
  background:#A5D65C;
  color:#141414;
  border-radius:999px;
  padding:2px 8px;
  font-weight: 900;
  min-width: 22px;
  text-align:center;
}
@media (max-width: 600px){
  .ak-cart-fab{
    right: 14px;
    bottom: 14px;
    padding: 10px 12px;
  }
}

/* Cart drawer + backdrop */
.ak-cart-backdrop{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  opacity: 0;
  pointer-events: none;
  z-index: 9998;
  transition: opacity .2s ease;
}
.ak-cart-drawer{
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 380px;
  max-width: 92vw;
  background: #fff;
  z-index: 9999;
  transform: translateX(105%);
  transition: transform .25s ease;
  box-shadow: -20px 0 60px rgba(0,0,0,.25);
  display:flex;
  flex-direction:column;
}
.ak-cart-open .ak-cart-backdrop{
  opacity: 1;
  pointer-events: auto;
}
.ak-cart-open .ak-cart-drawer{
  transform: translateX(0);
}

.ak-cart-header{
  padding: 16px 18px;
  border-bottom: 1px solid #eee;
  display:flex;
  justify-content: space-between;
  align-items:center;
  gap: 10px;
}
.ak-cart-header h3{
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  color: #141414;
}
.ak-cart-close{
  background: transparent;
  border: none;
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
}

.ak-cart-body{
  padding: 14px 18px;
  overflow: auto;
  flex: 1;
}
.ak-cart-empty{
  padding: 12px;
  border: 1px dashed #ddd;
  border-radius: 12px;
  color: #444;
  text-align: center;
}

.ak-cart-item{
  border: 1px solid #eee;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 10px;
}
.ak-cart-item-top{
  display:flex;
  justify-content: space-between;
  gap: 10px;
}
.ak-cart-item-title{
  font-weight: 900;
  font-size: 14px;
  color: #141414;
}
.ak-cart-item-meta{
  font-size: 12px;
  color: #555;
  margin-top: 4px;
}
.ak-cart-item-price{
  font-weight: 900;
  color: #141414;
  white-space: nowrap;
}
.ak-cart-item-actions{
  margin-top: 10px;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.ak-qty{
  display:flex;
  align-items:center;
  gap: 8px;
}
.ak-qty button{
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid #e5e5e5;
  background: #fafafa;
  cursor: pointer;
  font-size: 16px;
}
.ak-qty span{
  min-width: 22px;
  text-align: center;
  font-weight: 900;
}
.ak-remove{
  background: transparent;
  border: none;
  color: #c0392b;
  cursor: pointer;
  font-weight: 900;
}

.ak-cart-footer{
  padding: 16px 18px;
  border-top: 1px solid #eee;
}
.ak-cart-summary{
  display:flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}
.ak-cart-summary div{
  font-size: 13px;
  color: #444;
}
.ak-cart-total{
  font-weight: 900;
  color: #141414;
}

.ak-cart-form{
  display: grid;
  gap: 10px;
}
.ak-cart-form input,
.ak-cart-form textarea,
.ak-cart-form select{
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #e5e5e5;
  font-family: inherit;
  font-size: 13px;
  outline: none;
}
.ak-cart-form input:focus,
.ak-cart-form textarea:focus,
.ak-cart-form select:focus{
  border-color: rgba(165,214,92,.9);
  box-shadow: 0 0 0 4px rgba(165,214,92,.18);
}
.ak-cart-form textarea{
  min-height: 72px;
  resize: vertical;
}

.ak-wa-btn{
  background: #25D366;
  color: #fff;
  border: none;
  padding: 12px 14px;
  border-radius: 14px;
  font-weight: 900;
  cursor: pointer;
  width: 100%;
}
.ak-wa-btn:hover{ filter: brightness(.98); }

.ak-email-btn{
  background:#0b1b4d;
  color:#fff;
  border:none;
  padding:12px 14px;
  border-radius:14px;
  font-weight:900;
  cursor:pointer;
  width:100%;
}
.ak-email-btn:hover{ filter: brightness(.98); }

.ak-copy-btn{
  background: transparent;
  color:#141414;
  border:1px solid #e5e5e5;
  padding:12px 14px;
  border-radius:14px;
  font-weight:900;
  cursor:pointer;
  width:100%;
}
.ak-copy-btn:hover{ background: rgba(0,0,0,.03); }

.ak-secondary-btn{
  background: #141414;
  color:#fff;
  border: none;
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 900;
  cursor: pointer;
  width: 100%;
}
.ak-secondary-btn:hover{ filter: brightness(.98); }
