/* FPV Checkout CSS v1.0.5 */
:root {
  --fpv-orange: #ff6a00;
  --fpv-green: #22c55e;
  --fpv-green-dark: #16a34a;
  --fpv-green-bg: #f0fdf4;
  --fpv-black: #0a0a0b;
  --fpv-gray-bg: #fafaf8;
  --fpv-border: #e8e8e4;
  --fpv-text: #1a1a1b;
  --fpv-muted: #6b6b6b;
  --fpv-radius: 16px;
}

#fpv-checkout { background: var(--fpv-gray-bg); min-height: 100vh; }

/* HEADER */
.fpv-co-header {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 32px; background: #fff; border-bottom: 1px solid var(--fpv-border);
  position: sticky; top: 0; z-index: 100;
}
.fpv-co-logo { font-weight: 800; font-size: 20px; text-decoration: none; color: var(--fpv-black); }
.fpv-co-logo__fpv { color: var(--fpv-orange); }
.fpv-co-logo__drones, .fpv-co-logo__eu { color: var(--fpv-black); }
.fpv-co-back { margin-left: 16px; font-size: 14px; color: var(--fpv-muted); text-decoration: none; }
.fpv-co-back:hover { color: var(--fpv-black); }
.fpv-co-secure { margin-left: auto; font-size: 13px; color: var(--fpv-green-dark); font-weight: 600; }

/* PROGRESS */
.fpv-co-progress {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 32px; background: #fff; border-bottom: 1px solid var(--fpv-border);
  font-size: 13px;
}
.fpv-co-progress__step { color: var(--fpv-muted); }
.fpv-co-progress__step.active { color: var(--fpv-black); font-weight: 600; }
.fpv-co-progress__step.done { color: var(--fpv-orange); }
.fpv-co-progress__sep { color: var(--fpv-border); }

/* BODY LAYOUT */
.fpv-co-form { max-width: 100%; padding: 24px 0; }
form.fpv-co-form.woocommerce-checkout { display: block !important; }
.fpv-co-body { display: grid !important; grid-template-columns: 1fr 380px !important; gap: 24px !important; align-items: start; width: 100%; }

/* TITLE */
.fpv-co-title { font-size: 28px; font-weight: 800; margin-bottom: 24px; }

/* EXPRESS */
.fpv-co-express {
  background: #fff; border: 1.5px solid var(--fpv-border); border-radius: var(--fpv-radius);
  padding: 20px; margin-bottom: 16px;
}
.fpv-co-express__label { font-size: 11px; letter-spacing: .08em; color: var(--fpv-muted); margin-bottom: 12px; text-transform: uppercase; }
.fpv-co-express__buttons { display: flex; gap: 10px; }

/* STEPS */
.fpv-co-step {
  background: #fff; border: 1.5px solid var(--fpv-border); border-radius: var(--fpv-radius);
  margin-bottom: 12px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.fpv-co-step__head {
  display: flex; align-items: center; gap: 12px;
  padding: 18px 20px;
}
.fpv-co-step__num {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--fpv-green); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; flex-shrink: 0;
}
.fpv-co-step__title { font-weight: 700; font-size: 16px; }
.fpv-co-step__summary { margin-left: auto; font-size: 13px; color: var(--fpv-muted); }
.fpv-co-step__body { padding: 0 20px 20px; border-top: 1.5px solid var(--fpv-border); }

/* FORM FIELDS */
.fpv-co-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.fpv-co-step__body .form-row { margin-bottom: 12px; }
.fpv-co-step__body .form-row label { font-size: 13px; font-weight: 500; color: var(--fpv-muted); margin-bottom: 4px; display: block; }
.fpv-co-step__body .form-row input,
.fpv-co-step__body .form-row select,
.fpv-co-step__body .form-row textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--fpv-border);
  border-radius: 8px; font-size: 15px; background: #fff; color: var(--fpv-black);
  transition: border-color .15s; box-sizing: border-box;
}
.fpv-co-step__body .form-row input:focus,
.fpv-co-step__body .form-row select:focus { border-color: var(--fpv-green); outline: none; }
.fpv-co-step__body .form-row-wide { grid-column: 1 / -1; }

/* ADDRESS FIELDS */
.fpv-co-address-fields .form-row { margin-bottom: 10px; }
.fpv-co-address-fields .form-row input,
.fpv-co-address-fields .form-row select {
  width: 100%; padding: 11px 14px; border: 1.5px solid var(--fpv-border);
  border-radius: 8px; font-size: 14px; box-sizing: border-box;
}
.fpv-co-address-fields .form-row input:focus,
.fpv-co-address-fields .form-row select:focus { border-color: var(--fpv-green); outline: none; }
.fpv-co-address-fields .form-row label { font-size: 12px; color: var(--fpv-muted); font-weight: 500; display: block; margin-bottom: 4px; }

/* CHECKBOX */
.fpv-co-checkbox {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; cursor: pointer; color: var(--fpv-text); margin: 8px 0;
}
.fpv-co-checkbox input { width: 18px; height: 18px; accent-color: var(--fpv-green); }

/* SHIPPING OPTIONS */
.fpv-co-delivery { margin: 16px 0; }
.fpv-co-delivery__label { font-size: 11px; letter-spacing: .08em; color: var(--fpv-muted); margin-bottom: 10px; text-transform: uppercase; }
.fpv-co-shipping-option {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px; border: 1.5px solid var(--fpv-border);
  border-radius: 10px; margin-bottom: 8px; cursor: pointer; transition: border-color .15s;
}
.fpv-co-shipping-option:has(input:checked),
.fpv-co-shipping-option.selected { border-color: var(--fpv-green); background: var(--fpv-green-bg); }
.fpv-co-shipping-option input { accent-color: var(--fpv-green); }
.fpv-co-shipping-option__info { flex: 1; }
.fpv-co-shipping-option__info strong { display: block; font-size: 14px; }
.fpv-co-shipping-option__info span { font-size: 12px; color: var(--fpv-muted); }
.fpv-co-shipping-option__price { font-weight: 700; font-size: 15px; }

/* PAYMENT */
.fpv-co-step__body #payment { border: none; background: none; }
.fpv-co-step__body #payment ul.payment_methods { list-style: none; padding: 0; margin: 0; }
.fpv-co-step__body #payment ul.payment_methods li {
  border: 1.5px solid var(--fpv-border); border-radius: 10px;
  padding: 14px 16px; margin-bottom: 8px; cursor: pointer;
}
.fpv-co-step__body #payment ul.payment_methods li:has(input:checked) {
  border-color: var(--fpv-green); background: var(--fpv-green-bg);
}
.fpv-co-step__body #payment ul.payment_methods li input { accent-color: var(--fpv-green); }
.fpv-co-step__body #payment .place-order.form-row { display: none; }
.fpv-co-step__body .payment_box { background: #f8f8f8; border-radius: 8px; padding: 14px; margin-top: 10px; }
.fpv-co-step__body .woocommerce-checkout-review-order-table { display: none; }

/* NOTE */
.fpv-co-note { background: #fff; border: 1.5px solid var(--fpv-border); border-radius: var(--fpv-radius); padding: 16px 20px; margin-bottom: 20px; }

/* PLACE ORDER BUTTON */
.fpv-co-btn-place-order {
  width: 100%; padding: 18px; background: var(--fpv-green); color: #fff;
  border: none; border-radius: 12px; font-size: 17px; font-weight: 700;
  cursor: pointer; transition: background .15s, transform .1s;
  box-shadow: 0 4px 16px rgba(34,197,94,0.25);
}
.fpv-co-btn-place-order:hover { background: var(--fpv-green-dark); transform: translateY(-1px); }
.fpv-co-place-order-mobile { display: none; }

/* ORDER SUMMARY */
.fpv-co-summary {
  background: #fff; border: 1.5px solid var(--fpv-border); border-radius: var(--fpv-radius);
  padding: 24px; position: sticky; top: 130px;
}
.fpv-co-summary__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; font-size: 16px; font-weight: 700; }
.fpv-co-summary__edit { font-size: 13px; color: var(--fpv-orange); text-decoration: none; font-weight: 400; }

/* ITEMS */
.fpv-co-item { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.fpv-co-item__img { position: relative; width: 60px; height: 60px; flex-shrink: 0; }
.fpv-co-item__img img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; border: 1px solid var(--fpv-border); }
.fpv-co-item__qty {
  position: absolute; top: -8px; right: -8px;
  background: var(--fpv-muted); color: #fff; border-radius: 50%;
  width: 20px; height: 20px; font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.fpv-co-item__info { flex: 1; }
.fpv-co-item__name { font-size: 13px; font-weight: 600; line-height: 1.3; }
.fpv-co-item__variant { font-size: 12px; color: var(--fpv-muted); }
.fpv-co-item__price { font-size: 14px; font-weight: 700; }

/* COUPON */
.fpv-co-coupon { display: flex; gap: 8px; margin: 16px 0 4px; }
.fpv-co-coupon input {
  flex: 1; padding: 10px 14px; border: 1.5px solid var(--fpv-border);
  border-radius: 8px; font-size: 14px; box-sizing: border-box;
}
.fpv-co-coupon input:focus { border-color: var(--fpv-black); outline: none; }
.fpv-co-coupon button {
  padding: 10px 18px; background: var(--fpv-orange); color: #fff;
  border: none; border-radius: 8px; font-size: 14px; font-weight: 700;
  cursor: pointer; transition: background .15s;
}
.fpv-co-coupon button:hover { background: #e55f00; }
#fpv-coupon-msg { font-size: 12px; color: var(--fpv-muted); margin-bottom: 8px; }

/* TOTALS */
.fpv-co-totals { border-top: 1px solid var(--fpv-border); padding-top: 14px; margin-top: 14px; }
.fpv-co-totals__row { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 8px; color: var(--fpv-muted); }
.fpv-co-totals__row--discount { color: var(--fpv-green-dark); }
.fpv-co-total { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; border-top: 1px solid var(--fpv-border); margin-top: 6px; font-weight: 700; font-size: 15px; }
.fpv-co-total__amount { font-size: 24px; font-weight: 800; }

/* TRUST BADGES */
.fpv-co-trust {
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px;
  margin: 16px 0;
}
.fpv-co-trust__item {
  background: #f6f5f1; border: 1px solid var(--fpv-border); border-radius: 10px;
  padding: 12px 8px; font-size: 11px; font-weight: 700; color: var(--fpv-black);
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px;
}
.fpv-co-trust__item span { font-size: 10px; color: var(--fpv-muted); font-weight: 400; }

/* PEIDA WC coupon banner */
.woocommerce-info.woocommerce-checkout-coupon { display: none !important; }

/* RESPONSIVE */
@media (max-width: 768px) {
  .fpv-co-body { grid-template-columns: 1fr !important; }
  .fpv-co-right { order: -1; }
  .fpv-co-place-order-mobile { display: block; margin-top: 20px; }
  .fpv-co-btn-place-order--desktop { display: none; }
  .fpv-co-header { padding: 12px 16px; }
  .fpv-co-form { padding: 16px; }
  .fpv-co-row { grid-template-columns: 1fr; }
  .fpv-co-trust { grid-template-columns: 1fr 1fr 1fr; }
}

/* Peida WC duplikaadid */
.woocommerce-info { display: none !important; }
.woocommerce-form-coupon-toggle { display: none !important; }
.checkout_coupon { display: none !important; }
/* Peida Express checkout kui tühi */
.fpv-co-express__buttons:empty { display: none; }
.fpv-co-express__buttons:empty ~ * { display: none; }

/* Right veerg venib left veeruga - sticky töötab */
.fpv-co-right { align-self: stretch; }
.fpv-co-body { align-items: start; } /* override */




/* ===== CART PAGE ===== */
.fpv-cart-wrap {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
  max-width: 1100px;
  margin: 0 auto;
}

/* Cart tabel */
.fpv-cart-wrap .shop_table.cart {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1.5px solid #e8e8e4;
  border-radius: 16px;
  overflow: hidden;
}
.fpv-cart-wrap .shop_table.cart thead th {
  padding: 12px 16px;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #6b6b6b;
  border-bottom: 1.5px solid #e8e8e4;
  text-align: left;
  background: #fafaf8;
}
.fpv-cart-wrap .shop_table.cart td {
  padding: 16px;
  border-bottom: 1px solid #f0f0ee;
  vertical-align: middle;
  font-size: 14px;
}
.fpv-cart-wrap .shop_table.cart tr:last-child td { border-bottom: none; }
.fpv-cart-wrap .shop_table.cart .product-thumbnail img {
  width: 72px; height: 72px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #e8e8e4;
  display: block;
}
.fpv-cart-wrap .shop_table.cart .product-name a {
  font-weight: 600; font-size: 14px; color: #0a0a0b;
  text-decoration: none; line-height: 1.4;
}
.fpv-cart-wrap .shop_table.cart .product-name a:hover { color: #22c55e; }
.fpv-cart-wrap .shop_table.cart .product-name .variation {
  font-size: 12px; color: #6b6b6b; margin-top: 4px;
}
.fpv-cart-wrap .shop_table.cart .product-price,
.fpv-cart-wrap .shop_table.cart .product-subtotal {
  font-weight: 700; font-size: 14px;
}
.fpv-cart-wrap .shop_table.cart .product-remove a {
  color: #aaa !important; font-size: 22px; line-height: 1;
  text-decoration: none;
}
.fpv-cart-wrap .shop_table.cart .product-remove a:hover { color: #e00 !important; }

/* Qty */
.fpv-cart-wrap .quantity { display: flex; align-items: center; gap: 4px; }
.fpv-cart-wrap .quantity .qty {
  width: 56px; padding: 8px; text-align: center;
  border: 1.5px solid #e8e8e4; border-radius: 8px;
  font-size: 14px; font-weight: 600;
}

/* Cart actions */
.fpv-cart-wrap .actions {
  display: flex; gap: 10px; align-items: center;
  padding: 16px; border-top: 1.5px solid #e8e8e4;
}
.fpv-cart-wrap .coupon { display: flex; gap: 8px; flex: 1; }
.fpv-cart-wrap .coupon input[type=text] {
  padding: 10px 14px; border: 1.5px solid #e8e8e4;
  border-radius: 8px; font-size: 14px; flex: 1;
}
.fpv-cart-wrap .coupon input:focus { border-color: #22c55e; outline: none; }
.fpv-cart-wrap .coupon .button {
  padding: 10px 18px; background: #ff6a00; color: #fff;
  border: none; border-radius: 8px; font-size: 14px; font-weight: 700;
  cursor: pointer;
}
.fpv-cart-wrap .coupon .button:hover { background: #e55f00; }
.fpv-cart-wrap .actions .button[name=update_cart] {
  padding: 10px 18px; background: #fff;
  border: 1.5px solid #e8e8e4; border-radius: 8px;
  font-size: 13px; font-weight: 600; cursor: pointer;
  margin-left: auto;
}
.fpv-cart-wrap .actions .button[name=update_cart]:hover { border-color: #0a0a0b; }

/* Cart totals */
.fpv-cart-wrap .cart_totals {
  background: #fff; border: 1.5px solid #e8e8e4;
  border-radius: 16px; padding: 24px;
  position: sticky; top: 130px;
}
.fpv-cart-wrap .cart_totals h2 {
  font-size: 16px; font-weight: 700; margin: 0 0 16px;
}
.fpv-cart-wrap .cart_totals table {
  width: 100%; border-collapse: collapse; margin-bottom: 16px;
}
.fpv-cart-wrap .cart_totals table th,
.fpv-cart-wrap .cart_totals table td {
  padding: 10px 0; font-size: 14px;
  border-bottom: 1px solid #f0f0ee; text-align: left;
}
.fpv-cart-wrap .cart_totals table tr:last-child th,
.fpv-cart-wrap .cart_totals table tr:last-child td { border-bottom: none; }
.fpv-cart-wrap .cart_totals .order-total th,
.fpv-cart-wrap .cart_totals .order-total td {
  font-size: 20px; font-weight: 800; padding-top: 14px;
}
.fpv-cart-wrap .cart_totals .order-total td { color: #0a0a0b; }

/* Proceed to checkout nupp */
.fpv-cart-wrap .wc-proceed-to-checkout { padding: 0; }
.fpv-cart-wrap a.checkout-button {
  display: block !important; width: 100% !important;
  padding: 16px !important; background: #22c55e !important;
  color: #fff !important; border: none !important;
  border-radius: 12px !important; font-size: 16px !important;
  font-weight: 700 !important; text-align: center !important;
  text-decoration: none !important; cursor: pointer !important;
  box-shadow: 0 4px 16px rgba(34,197,94,0.25) !important;
  transition: background .15s !important;
  box-sizing: border-box !important;
}
.fpv-cart-wrap a.checkout-button:hover { background: #16a34a !important; }

/* Responsive */
@media (max-width: 768px) {
  .fpv-cart-wrap { grid-template-columns: 1fr; }
  .fpv-cart-wrap .cart_totals { position: static; }
}

/* CART FIXES */
.fpv-cart-wrap { max-width: 100%; }

/* Laiemad veerud */
.fpv-cart-wrap .shop_table.cart col.product-thumbnail { width: 80px; }
.fpv-cart-wrap .shop_table.cart col.product-name { width: auto; }

/* Toote pilt - forsi nähtavaks */
.fpv-cart-wrap .shop_table.cart .product-thumbnail { width: 80px; min-width: 80px; }
.fpv-cart-wrap .shop_table.cart .product-thumbnail img {
  width: 72px !important; height: 72px !important;
  object-fit: cover !important; border-radius: 10px !important;
  border: 1px solid #e8e8e4 !important; display: block !important;
}

/* Toote nimi - eira murdumist */
.fpv-cart-wrap .shop_table.cart .product-name {
  min-width: 200px;
}
.fpv-cart-wrap .shop_table.cart .product-name a {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  display: block; max-width: 300px;
}

/* Cart totals - peida shipment details */
.fpv-cart-wrap .cart_totals .woocommerce-shipping-destination { display: none; }
.fpv-cart-wrap .cart_totals .shipping-calculator-button { font-size: 12px; color: #6b6b6b; }

/* Cart img override */
body.woocommerce-cart table.cart td.product-thumbnail img {
  width: 80px !important;
  height: 80px !important;
  min-width: 80px !important;
  object-fit: cover !important;
  border-radius: 10px !important;
  border: 1px solid #e8e8e4 !important;
}
body.woocommerce-cart table.cart td.product-thumbnail {
  width: 90px !important;
  min-width: 90px !important;
}

/* Cart layout fixes */
/* Eemalda vasak tühi ala - remove cell */
body.woocommerce-cart table.cart td.product-remove {
  width: 32px !important;
  padding: 16px 8px 16px 16px !important;
}
body.woocommerce-cart table.cart td.product-remove a {
  font-size: 18px !important;
}

/* Shipping tekst fix */
.fpv-cart-wrap .cart_totals .shipping ul { list-style: none; padding: 0; margin: 0; }
.fpv-cart-wrap .cart_totals .shipping ul li { font-size: 13px; color: #0a0a0b; }
.fpv-cart-wrap .cart_totals .woocommerce-shipping-destination {
  display: block !important; font-size: 12px; color: #6b6b6b; margin-top: 4px;
}
.fpv-cart-wrap .cart_totals table th { white-space: nowrap; }

/* Cart totals table parandus */
.fpv-cart-wrap .cart_totals .shop_table th,
.fpv-cart-wrap .cart_totals .shop_table td {
  vertical-align: top;
}

/* Fix product-remove veerg */
body.woocommerce-cart table.cart th.product-remove,
body.woocommerce-cart table.cart td.product-remove {
  width: 36px !important;
  max-width: 36px !important;
  padding: 16px 4px 16px 12px !important;
}
/* Fix shipment tekst */
.fpv-cart-wrap .cart_totals td {
  font-size: 13px;
  line-height: 1.5;
}
.fpv-cart-wrap .cart_totals th {
  font-size: 13px;
  padding-right: 12px;
  white-space: nowrap;
  vertical-align: top;
  padding-top: 12px;
}

/* Fix tabel fixed layout */
body.woocommerce-cart table.cart {
  table-layout: fixed !important;
  width: 100% !important;
}
body.woocommerce-cart table.cart th.product-remove,
body.woocommerce-cart table.cart td.product-remove {
  width: 36px !important;
  padding: 16px 4px 16px 12px !important;
  overflow: hidden;
}
body.woocommerce-cart table.cart th.product-thumbnail,
body.woocommerce-cart table.cart td.product-thumbnail {
  width: 90px !important;
}
body.woocommerce-cart table.cart th.product-price,
body.woocommerce-cart table.cart td.product-price {
  width: 90px !important;
}
body.woocommerce-cart table.cart th.product-quantity,
body.woocommerce-cart table.cart td.product-quantity {
  width: 90px !important;
}
body.woocommerce-cart table.cart th.product-subtotal,
body.woocommerce-cart table.cart td.product-subtotal {
  width: 90px !important;
}
body.woocommerce-cart table.cart th.product-name,
body.woocommerce-cart table.cart td.product-name {
  width: auto !important;
}

/* Shipment fix */
.fpv-cart-wrap .cart_totals table { table-layout: auto !important; }
.fpv-cart-wrap .cart_totals tr.shipping th {
  padding-right: 16px;
  white-space: nowrap;
  vertical-align: top;
  padding-top: 10px;
}
.fpv-cart-wrap .cart_totals tr.shipping td {
  vertical-align: top;
}
.fpv-cart-wrap .cart_totals tr.shipping td ul {
  list-style: none; padding: 0; margin: 0;
}
.fpv-cart-wrap .cart_totals tr.shipping td ul li {
  font-size: 13px; line-height: 1.5;
}
.fpv-cart-wrap .cart_totals .woocommerce-shipping-destination {
  font-size: 12px; color: #6b6b6b; margin-top: 2px; display: block;
}
.fpv-cart-wrap .cart_totals .shipping-calculator-button {
  font-size: 12px; color: #22c55e; display: block; margin-top: 4px;
}

/* Cart padding fix */
.woocommerce-cart .woocommerce {
  padding-left: 32px !important;
  padding-right: 32px !important;
}

/* Cart grid - parempoolne domineerib */
.fpv-cart-wrap {
  grid-template-columns: 1fr 420px !important;
}

/* Cart mobile fix */
@media (max-width: 768px) {
  .woocommerce-cart .woocommerce {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
  .fpv-cart-wrap {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  .fpv-cart-wrap .cart_totals {
    position: static !important;
  }
  /* Tabel scroll mobiilis */
  .fpv-cart-wrap form { overflow-x: auto; }
  body.woocommerce-cart table.cart {
    table-layout: auto !important;
    min-width: 400px;
  }
  body.woocommerce-cart table.cart th.product-name,
  body.woocommerce-cart table.cart td.product-name {
    min-width: 120px;
  }
}




@media (max-width: 768px) {
  .woocommerce-cart .woocommerce { padding: 0 16px !important; }
  .fpv-cart-wrap { grid-template-columns: 1fr !important; gap: 16px !important; }
  .fpv-cart-wrap .cart_totals { position: static !important; }

  /* Tabel -> kaardid */
  body.woocommerce-cart table.cart {
    display: block !important;
  }
  body.woocommerce-cart table.cart thead { display: none !important; }
  body.woocommerce-cart table.cart tbody { display: block !important; }
  body.woocommerce-cart table.cart tfoot { display: block !important; }

  /* Iga rida = kaart */
  body.woocommerce-cart table.cart tr {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 16px 0 !important;
    border-bottom: 1px solid #f0f0ee !important;
    border-top: none !important;
  }
  body.woocommerce-cart table.cart td {
    display: none !important;
    border: none !important;
    padding: 0 !important;
  }

  /* Pilt */
  body.woocommerce-cart table.cart td.product-thumbnail {
    display: block !important;
    flex-shrink: 0 !important;
    width: 72px !important;
  }
  body.woocommerce-cart table.cart td.product-thumbnail img {
    width: 72px !important; height: 72px !important;
    object-fit: cover !important; border-radius: 10px !important;
    border: 1px solid #e8e8e4 !important;
  }

  /* Nimi + hind */
  body.woocommerce-cart table.cart td.product-name {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    flex: 1 !important;
    min-width: 0 !important;
  }
  body.woocommerce-cart table.cart td.product-name a {
    font-size: 13px !important; font-weight: 600 !important;
    line-height: 1.3 !important; color: #0a0a0b !important;
    white-space: normal !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
  }
  body.woocommerce-cart table.cart td.product-name .woocommerce-Price-amount {
    color: #ff6a00 !important; font-weight: 700 !important; font-size: 14px !important;
  }

  /* Hind nime alla */
  body.woocommerce-cart table.cart td.product-price {
    display: none !important;
  }

  /* Qty kontrollerid */
  body.woocommerce-cart table.cart td.product-quantity {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-shrink: 0 !important;
  }
  body.woocommerce-cart table.cart td.product-quantity .qty {
    width: 40px !important; height: 36px !important;
    text-align: center !important; font-size: 15px !important;
    font-weight: 700 !important; border: 1.5px solid #e8e8e4 !important;
    border-radius: 8px !important; padding: 0 !important;
  }

  /* Peida subtotal ja remove */
  body.woocommerce-cart table.cart td.product-subtotal { display: none !important; }
  body.woocommerce-cart table.cart td.product-remove { display: none !important; }

  /* Actions rida */
  body.woocommerce-cart table.cart tr.actions {
    flex-wrap: wrap !important;
    gap: 8px !important;
  }
  body.woocommerce-cart table.cart tr.actions td {
    display: block !important;
    width: 100% !important;
  }
  .fpv-cart-wrap .coupon {
    display: flex !important; gap: 8px !important; width: 100% !important;
  }
  .fpv-cart-wrap .coupon input { flex: 1 !important; }
  .fpv-cart-wrap .actions .button[name=update_cart] {
    width: 100% !important; text-align: center !important;
  }
}

@media (max-width: 768px) {
  /* Naita hind nime all */
  body.woocommerce-cart table.cart td.product-price {
    display: block !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #ff6a00 !important;
    margin-top: 4px !important;
  }
  body.woocommerce-cart table.cart td.product-price .woocommerce-Price-amount {
    color: #ff6a00 !important;
  }
  /* Pane hind nime alla - muuda td.product-name flex column */
  body.woocommerce-cart table.cart td.product-name {
    order: 1 !important;
  }
  body.woocommerce-cart table.cart td.product-price {
    order: 2 !important;
    flex-shrink: 0 !important;
  }
  /* Wrapin nime ja hinna yhte kohta */
  body.woocommerce-cart table.cart td.product-thumbnail { order: 0 !important; }
  body.woocommerce-cart table.cart td.product-quantity { order: 3 !important; }
  body.woocommerce-cart table.cart tr {
    flex-wrap: wrap !important;
    align-items: flex-start !important;
  }
  /* Nimi votab kogu laiuse peale pildis */
  body.woocommerce-cart table.cart td.product-name {
    width: calc(100% - 72px - 60px - 36px) !important;
    flex: none !important;
  }
  body.woocommerce-cart table.cart td.product-price {
    margin-left: 84px !important;
    width: auto !important;
  }
  body.woocommerce-cart table.cart td.product-quantity {
    margin-left: auto !important;
  }
}

@media (max-width: 768px) {
  body.woocommerce-cart table.cart td.product-price {
    margin-top: 0 !important;
    margin-left: 0 !important;
    width: 100% !important;
    padding-left: 84px !important;
  }
  body.woocommerce-cart table.cart tr {
    row-gap: 2px !important;
  }
}

@media (max-width: 768px) {
  .fpv-price {
    color: #ff6a00 !important;
    font-weight: 700 !important;
    font-size: 13px !important;
    margin-top: 3px !important;
  }
  body.woocommerce-cart table.cart td.product-price { display: none !important; }
  body.woocommerce-cart table.cart tr { flex-wrap: nowrap !important; align-items: center !important; }
  body.woocommerce-cart table.cart td.product-name { flex: 1 !important; width: auto !important; }
  body.woocommerce-cart table.cart td.product-quantity { flex-shrink: 0 !important; margin-left: 0 !important; }
}

/* Trust badges - rohelisem */
.fpv-co-trust__item {
  background: #f0fdf4 !important;
  border: 1.5px solid #bbf7d0 !important;
  color: #15803d !important;
}
.fpv-co-trust__item span {
  color: #16a34a !important;
}

/* Rohkem ruumi step head ja body vahele */
.fpv-co-step__body {
  padding-top: 20px !important;
}
.fpv-co-step__head {
  padding-bottom: 20px !important;
}


/* Stripe iframe height fix */
#wc-stripe-upe-element { min-height: 200px !important; }
#wc-stripe-upe-element iframe { min-height: 200px !important; width: 100% !important; }
.fpv-co-step__body .payment_box { min-height: 50px !important; overflow: visible !important; }

/* Express checkout mobile fix */
@media (max-width: 768px) {
  .fpv-co-express__buttons { flex-direction: column; }
  /* Stripe express checkout wrapper */
  .fpv-co-express__buttons > * { width: 100% !important; }
  /* WC payment request button container */
  #wc-stripe-express-checkout-element,
  #wc-stripe-payment-request-wrapper,
  .wc-stripe-express-checkout-wrapper { width: 100% !important; }
  /* Peida 'Proceed to checkout' tekst express nupu seest */
  #wc-stripe-payment-request-wrapper::before,
  .wc-stripe-payment-request-button__separator { display: none !important; }
  /* Fix juhuks kui on flex row */
  .woocommerce-checkout-payment .wc-stripe-payment-request-button {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
  }
}

/* Peida WC checkout-button express sektsioonis */
.fpv-co-express__buttons a.checkout-button,
.fpv-co-express__buttons .wc-forward {
  display: none !important;
}
/* Express nupud veeru kaupa */
@media (max-width: 768px) {
  .fpv-co-express__buttons {
    flex-direction: column !important;
  }
  .fpv-co-express__buttons > div,
  .fpv-co-express__buttons #wc-stripe-express-checkout-element {
    width: 100% !important;
  }
}

/* Cart express checkout nupud - kompaktsed ja kõrvuti */
.woocommerce-cart .wc-stripe-express-checkout-wrapper,
.woocommerce-cart #wc-stripe-express-checkout-element {
  margin-top: 12px !important;
}
.woocommerce-cart .wc-stripe-express-checkout-wrapper > div {
  display: flex !important;
  flex-direction: row !important;
  gap: 8px !important;
  flex-wrap: wrap !important;
}
.woocommerce-cart .wc-stripe-express-checkout-wrapper iframe,
.woocommerce-cart #wc-stripe-express-checkout-element iframe {
  max-height: 44px !important;
  min-height: 44px !important;
}
/* Google Pay kaardipildid peida */
.woocommerce-cart .wc-stripe-express-checkout-wrapper .gpay-card-info-container img { display: none !important; }

/* Cart layout fix - woocommerce div on tegelik grid konteiner */
.woocommerce-cart .woocommerce {
  display: grid !important;
  grid-template-columns: 1fr 420px !important;
  gap: 24px !important;
  align-items: start !important;
  padding: 32px !important;
}
.woocommerce-cart .woocommerce form.woocommerce-cart-form {
  grid-column: 1 !important;
}
.woocommerce-cart .woocommerce .cart_totals {
  grid-column: 2 !important;
  grid-row: 1 !important;
  position: sticky !important;
  top: 100px !important;
}
/* Peida vana fpv-cart-wrap grid (duplikaat) */
.fpv-cart-wrap {
  display: contents !important;
}
@media (max-width: 900px) {
  .woocommerce-cart .woocommerce {
    grid-template-columns: 1fr !important;
    padding: 16px !important;
  }
  .woocommerce-cart .woocommerce .cart_totals {
    grid-column: 1 !important;
    grid-row: auto !important;
    position: static !important;
  }
}
