.checkout-wrapper {
  display: grid;
  gap: 30px 0;

  /* Mobil först: en kolumn */
  grid-template-areas:
    "products"
    "form";
  grid-template-columns: 1fr;

  margin-top: 30px;
}

/* Grid area assignment */
.checkout-form {
  grid-area: form;
}

.checkout-products {
  grid-area: products;
}

.checkout-submit {
  grid-area: submit;
}

/* Desktop layout – två kolumner */
@media (min-width: 1200px) {
  .checkout-wrapper {
    gap: 30px 45px;
    grid-template-areas:
    "products"
    "form";
  grid-template-columns: 1fr;
    /* grid-template-areas:
      "form products";
    grid-template-columns: 1fr 1fr; */
  }
}

/* Styling för tydlighet (valfritt) */
.checkout-wrapper > div {
  padding: 10px 0;
}



.cart-table {
  display: flex;
  flex-direction: column;
  padding: 30px;
  box-shadow: 0 3px 10px rgb(0 0 0 / 0.2);
  border-radius: 5px;
}

.cart-table-article {
  display: flex;
  gap: 30px;
  width: 100%;
  padding-top: 15px;
  padding-bottom: 15px;
  border-bottom: 1px solid #DFE2E6;
}

.cart-table-article:not(:last-child) {
}

.cart-table-article-image img {
  /* width: 100%;
  max-width: 90px; */
  width: 90px;
  height:auto;
}
.cart-table-article-information {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.cart-table-article-title {
  /* font-family: flex-100; */
  font-size: 1rem;
  font-weight: 600;
  /* text-transform: uppercase; */
}

.cart-table-article-title a {
  color: #002A4D;
}

.cart-table-article-variation {
  font-size: 0.8rem;
}
.cart-table-article-extrainfo {
  font-size: 0.8rem;
}
.cart-table-article-quantity {
  max-width: 100px;
  font-size: 0.8rem;
}
.cart-table-article-delete .btn { padding: 0 !important }

.cart-summery {
  margin-top: 30px;
}


.discount-container {
  display: flex;
  flex-direction: column;
  margin-top: 30px;
  font-size: 1rem;
}

.cart-discount-container {
  margin-top: 15px;
  margin-bottom: 15px;
  display: flex;
  gap: 15px;
  flex-direction: column;
}

.cart-discount-inputs {
  display: flex;
  gap: 15px;
  flex-direction: column;
}

.cart-discount-inputs-input {
  flex: 1;
}

.cart-discount-button {
  display: flex;
  justify-content: flex-end;
}


.deliveryRadioButton {
  box-sizing: border-box;
  display: flex;
  align-items: stretch;
  flex-direction: row;
  flex-shrink: 0;
  border-style: solid;
  border-width: 0px;
  position: relative;
  z-index: 0;
  min-height: 0px;
  min-width: 0px;
  width: 20px;
  height: 20px;
  cursor: pointer;
}
.deliveryItems {
  margin-bottom: 30px;
}
.deliveryItem {
  box-sizing: border-box;
  display: flex;
  align-items: stretch;
  flex-direction: column;
  flex-shrink: 0;
  border-style: solid;
  border-width: 0px 0px 1px;
  position: relative;
  z-index: 0;
  min-height: 0px;
  min-width: 0px;
  border-color: rgb(227, 229, 233);
}
.deliveryOption input {
  margin-right: 5px;
}
.deliveryItem-wrapper {
  display: flex;
  flex-direction: row;
  gap: 15px;
  padding-top: 19px;
  padding-bottom: 20px;
}
.deliveryOptions {
  /* margin-top: 10px; */
}
.deliveryOption {
  margin-block: 5px;
}
.deliveryOption input {
  cursor: pointer;
}

.deliveryItem .form-check-label {
  cursor: pointer;
}

.delivery-option-info {
  margin-left: 5px; 
  cursor: pointer;
}

#countryPostalWrapper.disabled-overlay, #deliveryOptionsWrapper.disabled-overlay {
  pointer-events: none;
  user-select: none;
  opacity: 0.2;
}

#countryPostalWrapper.disabled-overlay .form-control, 
#countryPostalWrapper.disabled-overlay .custom-select, 
#countryPostalWrapper.disabled-overlay .form-control:focus {
  border-width: 1px;
  border-color: #CCC;
}

@media (min-width: 1200px) {
  #deliveryInformation .container {
    /* max-width: 1140px; */
    /* max-width: 1024px; */
  }
}



.dialog-backdrop {
  display: none;
  position: fixed;
  z-index: 100;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.4);
  text-align:center;
}

.dialog-backdrop.dialog-open {
  display: block;
}

body.dialog-open {
  overflow: hidden;
  padding-right: 15px;
}

.dialog {
  background-color: #fefefe;
  /* margin: auto auto; */
  /* border: 1px solid #888; */
  border-radius: 5px;
  width: 90%;
  max-width: 500px;
  z-index: 101;
  display:inline-block;
  vertical-align:middle;
}

.dialog-backdrop:before {
  content:"";
  display:inline-block;
  width:0;
  height:100%;
  vertical-align:middle;
}

.dialog-header {
  padding: 15px 15px;
  background-color: #cccccc;
  color: black;
  border-radius: 5px 5px 0 0;

  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dialog-header h4 {
  margin-bottom: 0;
  font-size: 0.8rem;
  font-weight: 600;
}

.dialog-content {
  padding: 15px 15px;
  font-size: 0.9rem;
  text-align: left;
  /* min-height: 100px; */
}

.dialog-footer {
  display: flex;
  justify-content: space-between;
  padding: 15px 15px;
  /* background-color: #f0f0f0; */
  border-top: solid 2px #f0f0f0;
  background-color: #fafafa;
}

.dialog-data-wrapper {
  margin-top: 10px;
  margin-bottom: 10px;
}

.dialog-data {
  margin-bottom: 10px;
  font-style: italic;
  background-color: #F0F0F0;
  border-radius: 3px;
  padding: 10px;
}

.dialog-error {
  margin-top: 10px;
  background-color: #ffe3e3;
  border-radius: 3px;
  padding: 10px;
  font-weight: 600;
  display: none;
}

.btn-dialog {
  padding: 3px 10px;
  min-width: 80px;
  border-radius: 3px;
  cursor: pointer;
  border: 0;
}

.dialog-content-header { font-weight: 600; }

.btn-dialog-cancel {
  background-color: #E0E0E0;
}
.btn-dialog-cancel:hover {
  background-color: #C0C0C0;
}
.btn-dialog-cancel:disabled {
  background-color: #C0C0C0;
}
.btn-dialog-ok {
  background-color: #0fc60f;
  background-color: #198754;
  color: white;
}
.btn-dialog-ok:hover {
  background-color: #209120;
  background-color: #157347;
}
.btn-dialog-ok:disabled {
  background-color: #209120;
  background-color: #157347;
  background-color: #cccccc;
}

.btn-dialog:disabled {
  cursor: not-allowed;
}

.dialog-close {
  color: #666;
  font-size: 12px;
  font-weight: bold;
}

.dialog-close:hover,
.dialog-close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}





#newCartTable .cart-product-image img {
  height: 70px;
  max-width: 70px;
  object-fit: contain;
}
#newCartTable .cart-product-image {
  background-color: #F9F9F9;
  width: 75px;
  height: 75px;
  text-align: center;
  line-height: 70px;
  display: block;
}
#newCartTable .cart-product-info {
  position: relative;
  margin-left: 10px;
  margin-bottom: 0px;
  margin-right: 20px;
}

#cart-head {
  position: relative;
  height: 15px;
  padding-bottom: 18px;
  color: #444;
  font-weight: bold;
  margin-bottom: 5px;
  font-size: 0.8rem;
}

#cart-head-product {
  position: absolute;
  left: 10px;
}

#cart-head-quantity {
  position: absolute;
  right: 372px;
}

#cart-head-price {
  position: absolute;
  right: 195px;
}

#cart-head-sum {
  position: absolute;
  right: 10px;
}


.cart-product-info-wrapper {
  justify-content: space-between;
}

.cart-product-info-container {
  flex-direction: row;
  flex: 1;
}

.cart-product-info-inner-container {
  flex-direction: column;
  flex: 1;
}

.cart-product-totals {
  padding: 0;
  font-weight: 600;
}

.cart-quantity-wrapper {
  align-self: center !important;
}

@media (max-width: 1200px) {
  .cart-product-info-container {
    flex-direction: column;
  }
  .cart-quantity-wrapper {
    align-self: flex-start !important;
  }
  /* .cart-product-totals {
    padding: 0 10px;
  } */
}

@media (min-width: 480px) {
  #newCartTable .cart-product-image {
      /* width: 138px;
      min-width: 138px; */
      width: 90px;
      min-width: 90px;
  }
}

.text-end {
  text-align: right !important;
}
.nowrap {
  white-space: nowrap;
}

#buyerInformation .form-control,
#buyerInformation .custom-select,
.checkout-wrapper .form-control,  
.checkout-wrapper .custom-select {
  font-size: 16px;
  height: 2rem;
}

.checkout-wrapper .quantity-button {
  height: 32px;
}







#newCartTable .cart-item {
  display: grid;
  grid-template-columns: 80px 1fr 200px 100px 100px;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1rem;
  /* border-bottom: 1px solid #ddd; */
  position: relative; background-color: #F9F9F9; margin-bottom: 12px;
}

#newCartTable .item-image img {
  height: 70px;
  max-width: 70px;
  object-fit: contain;
}

#newCartTable .item-total-price {
  text-align: right;
}

#newCartTable .item-quantity {
  max-width: 125px;
}

/* Mobilanpassning */
@media (max-width: 992px) {
  #newCartTable .cart-item {
    grid-template-columns: 50px 1fr 70px;
    grid-template-areas:
      "image name total"
      "image quantity total";
  }

  #newCartTable .item-image      { grid-area: image; }
  #newCartTable .item-name       { grid-area: name; }
  #newCartTable .item-quantity   { grid-area: quantity; }
  #newCartTable .item-unit-price { display: none; }
  #newCartTable .item-total-price{ grid-area: total; text-align: right; }

  #newCartTable .item-image img {
    height: 50px;
    max-width: 50px;
    object-fit: contain;
  }

  #newCartTable .cart-table-article-title { font-size: 0.9rem; }
  #newCartTable .item-total-price { font-size: 0.9rem; font-weight: 600; }
}

#deliveryOptionsWrapper .form-check-input {
  position: relative;
  margin-left: 0;
}
#deliveryOptionsWrapper .form-check {
  padding-left: 0;
}