/*****************************************************************************************************
* Commerce Module: Common CSS
******************************************************************************************************/

/*
Defaults
---------------------------------------------------------------------------------------------------- */

/*
Layout
---------------------------------------------------------------------------------------------------- */

@media screen and (max-width: 1000px/*wooMobileMaxWidth*/) {

  .woocommerce-cart .site-inner > .wrap,
  .woocommerce-checkout .site-inner > .wrap, 
  .woocommerce-account .site-inner > .wrap {
    padding-left: 3%;
    padding-right: 3%;
  }
}


/*
Elements
---------------------------------------------------------------------------------------------------- */

/* Text Inputs
--------------------------------------------- */

#bubwoo .form-row label {
  line-height: 1.3;
  margin-bottom: 0.35em;
}

#bubwoo input::placeholder,
#bubwoo textarea::placeholder {
  transition: none;
}


/* Buttons
--------------------------------------------- */

/* Default Button */

#bubwoo .button,
.bubwoo-notice .button {
  background: var(--basicButton-background-def);
  border: var(--basicButton-border-def);
  border-radius: var(--basicButton-borderRadius-def);
  color: var(--basicButton-color-def);
  font-size: var(--basicButton-fontSize-def);
  font-weight: var(--basicButton-fontWeight-def);
  line-height: 1;
  padding: var(--basicButton-padding-def);
  text-decoration: none;
  white-space: nowrap;
}

#bubwoo .button:hover,
.bubwoo-notice .button:hover {
  filter: var(--basicButton-filter-acc);
}


/*
States
---------------------------------------------------------------------------------------------------- */

/* Errors */

#bubwoo .woocommerce-invalid label a,
#bubwoo .woocommerce-invalid .required {
  color: inherit;
}

#bubwoo .woocommerce-invalid label a:hover {
  filter: brightness(130%);
}


/*
Woo Notices
---------------------------------------------------------------------------------------------------- */

/* Notices: Common
--------------------------------------------- */

.bubwoo-notice {
  background: #fff;
  box-shadow: var(--contentBox-boxShadow-def);
  border-top-width: 5px;
  color: var(--cl-base-def);
  display: flex;
  flex-flow: row wrap;
  gap: 0.7em;
  margin: 0 0 20px !important;
  justify-content: space-between;
  padding: 1em 1.5em 1em 3.5em;
}

.bubwoo-notice::before {
  top: auto;
}

.woocommerce-message::before,
.woocommerce-error::before {
  font-size: 1.13em;
  left: 1.25em;
  top: 0.85em;
}

.bubwoo-notice::after {
  display: none;
}

.bubwoo-notice .button {
  order: 2;
  /* Overwrite 'transition: all': Causes unstyled content flashing. */
  transition: filter 200ms;
}

@media screen and (max-width: 500px) {

  .bubwoo-notice {
    margin: 0 0 20px !important;
    padding: 1em 1em 1em 2.3em;
  }

  .bubwoo-notice::before {
    left: 0.7em; 
  }
}

/* Toggle Notices: Login, Coupon etc. */

#bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
  + form[class*="woocommerce-form"] {
  background: #fff;
  border: none;
  border-radius: 0;
  box-shadow: var(--contentBox-boxShadow-def);
  margin: 0 0 20px;
  padding: 25px;
}

#bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
  + form[class*="woocommerce-form"] .form-row {
  padding: 0;
}

#bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
  + form[class*="woocommerce-form"] .input-text,
#bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
  + form[class*="woocommerce-form"] .button {
  border: var(--tableBox-border-def);
  height: 50px;
}

#bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
  + form[class*="woocommerce-form"] ::placeholder {
  font-size: 0.95rem !important;
}

@media screen and (max-width: 500px) {

  #bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
    + form[class*="woocommerce-form"] {
    padding: 20px 15px;
  }

  #bubwoo [class^="woocommerce-form-"][class$="-toggle"] 
    + form[class*="woocommerce-form"] .form-row-first {
  }  
}


/*
Shop Tables
---------------------------------------------------------------------------------------------------- */

#bubwoo .shop_table,
#bubwoo .shop_table th,
#bubwoo .shop_table td, 
#bubwoo .cart_totals td, 
#bubwoo .cart_totals th  {
  border-color: var(--tableBox-borderColor-def);
}

#bubwoo .shop_table {
  background: #fff;
  border: 1px solid var(--tableBox-borderColor-def);
  border-radius: 0;
}

#bubwoo .shop_table th,
#bubwoo .shop_table td {
  font-size: 1rem;
  padding: 0.9em 1em;
  word-break: keep-all;
  overflow-wrap: normal;
}

#bubwoo .shop_table td {
  line-height: 1.4em;
}

#bubwoo .shop_table .actions {
  padding: 0.7em 1em;
}

@media screen and (max-width: 1000px/*wooMobileMaxWidth*/) {

  #bubwoo .shop_table th,
  #bubwoo .shop_table td {
    padding: 0.7em 1em;
  }

  #bubwoo .shop_table td {
  }

  #bubwoo .shop_table td::before {
    padding-right: 0.5em;
  }

  /* Create pseudo margins between table items. */

  #bubwoo :where(.woocommerce-cart-form__contents, .woocommerce-orders-table, 
    .woocommerce-table--order-downloads) tr:nth-child(n+2)::before {
    background: var(--bg-base-def); 
    border-top: 1px solid var(--tableBox-borderColor-def);
    content: '';
    display: block;
    height: 15px;
    margin-left: -1px;
    width: calc(100% + 2px);
  }

  #bubwoo .shop_table tr:nth-child(2n) td {
    background-color: inherit;
  }
}

@media screen and (max-width: 500px) {

  #bubwoo .shop_table :is(th, td) {
    font-size: 0.9rem;
  }

  #bubwoo .shop_table :is(th, td) {
    padding: 0.7em 0.6em 0.7em 0.5em;
  }
}


/*
Shop Forms
---------------------------------------------------------------------------------------------------- */

/* Address Fields (Checkout, Edit Address) 
--------------------------------------------- */

#bubwoo .woocommerce-checkout .col-1,
#bubwoo .woocommerce-checkout .col-2,
#bubwoo .woocommerce-address-fields {
  background: #fff;
  box-shadow: var(--contentBox-boxShadow-def);
  margin-bottom: 20px;
  padding: 25px;
}

#bubwoo .form-row {
  margin: 0 0 1em;
  padding: 0;
}

#bubwoo .form-row-first,
#bubwoo .form-row-last {
  width: calc(50% - 5px);
}

#bubwoo .form-row:last-child {
  margin-bottom: 0;
}

#bubwoo .form-row[id*="_country_field"] {
  margin: 1em 0 1.5em;
}

#bubwoo .form-row[id*="_address_1_field"] {
  margin: 0 0 0.5em;
}

#bubwoo .form-row .input-text {
  border: var(--tableBox-border-def);
  height: 50px;
}

#bubwoo .form-row .select2-container--default .select2-selection--single {
  border: var(--tableBox-border-def);
  border-radius: 0;
  height: 50px;
}

#bubwoo .form-row .select2-selection__rendered {
  line-height: 2.0em;  
  height: 50px;
}

#bubwoo .form-row .select2-selection__arrow {  
  height: 48px;
  padding-right: 1.3em;
}

.woocommerce-page .select2-dropdown {
  border: var(--tableBox-border-def);
}

#bubwoo .form-row ::placeholder {
  font-size: 0.95rem;
}

@media screen and (max-width: 1000px/*wooMobileMaxWidth*/) {
}

@media screen and (max-width: 500px) {

  #bubwoo .woocommerce-checkout .col-1,
  #bubwoo .woocommerce-checkout .col-2,
  #bubwoo .woocommerce-address-fields {
    padding: 20px 15px;
  }

  #bubwoo .form-row-first,
  #bubwoo .form-row-last {
    width: 100%;
  }
}


/*
Mixed
---------------------------------------------------------------------------------------------------- */
