/**
 * Staging
 * Loaded conditionally via my-account-customizer.php MU-Plugin
 * - Aims for Full-width Nav Bar background area.
 * - Centers Nav Links within main content width (1680px).
 * - Centers Content Block at 50% width below nav.
 * - Restores V1.4 navigation link appearance (background, borders, active state).
 * - Explicitly overrides theme floats on Nav element and Content element.
 * - Removes styling from `.mac-my-account-content-area` wrapper.
 */


/*--------------------------------------------------------------
# Base Layout & Containers
--------------------------------------------------------------*/
.mac-my-account-wrapper {
    max-width: 100%; /* Allow full width for nav background */
    margin-left: auto;
    margin-right: auto;
    padding-left: 0; /* No padding on outer wrapper */
    padding-right: 0;
  }
  
  /* Optional Header - Contained */
  .mac-my-account-wrapper .mac-my-account-header {
    padding-left: 15px; /* Standard content padding */
    padding-right: 15px;/* Standard content padding */
    max-width: 100%; /* Contained width */
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 2em; /* Space below header */
    display: none !important;
  }
  .woocommerce-MyAccount-content {
    font-size: clamp(0.805rem,0.8115rem + 0.2033vw,0.8375rem);
}
  /* Navigation Container - Full width */
  .mac-my-account-wrapper .mac-my-account-nav-container {
    position: relative;
    /* Add background color here if you want the entire bar colored */
    /* background-color: #f1f1f1; */
  }
  
  /* Content Area Wrapper - Provides vertical spacing only */
  .mac-my-account-wrapper .mac-my-account-content-area {
      padding-top: 2em; /* Space between nav bar bottom and content block top */
  }
  
  /* The actual content block - Centered 50% Width */
  .mac-my-account-wrapper .mac-my-account-main-content.woocommerce-MyAccount-content {
      /* --- Specific Theme Float Override --- */
      float: none !important; /* Override potential theme float */
      /* --- End Override --- */
  
      width: 70%; /* Per request */
      max-width: 1300px; /* Optional: Prevent extreme width on large screens */
      margin-left: auto;  /* Center the block */
      margin-right: auto; /* Center the block */
  
      /* Styling for the content block */
      background-color: #ffffff;
      padding: 0px; /* Add padding back */
      border: none; /* Add border back for visual separation */
      border-radius: 0; /* Add radius back */
      overflow: hidden; /* Keep if needed */
  }

  .mac-my-account-wrapper .mac-my-account-main-content.endpoint-dashboard {
      /* --- Specific Theme Float Override --- */
      float: none !important; /* Override potential theme float */
      /* --- End Override --- */
  
      width: 50%; /* Per request */
      max-width: 1300px; /* Optional: Prevent extreme width on large screens */
      margin-left: auto;  /* Center the block */
      margin-right: auto; /* Center the block */
      padding-top: 4em;
      margin-bottom: 40vh;
      /* Styling for the content block */
      background-color: #ffffff;
      padding: 0px; /* Add padding back */
      border: none; /* Add border back for visual separation */
      border-radius: 0; /* Add radius back */
      overflow: hidden; /* Keep if needed */
      text-align: center;
  }
  .mac-my-account-wrapper .mac-my-account-main-content.endpoint-test3 {
          /* --- Specific Theme Float Override --- */
          float: none !important; /* Override potential theme float */
          /* --- End Override --- */
          width: 100%; /* Per request */
          max-width: 100%; /* Optional: Prevent extreme width on large screens */
          margin-left: auto;  /* Center the block */
          margin-right: auto; /* Center the block */
          padding: 0px; /* Add padding back */
          border: none; /* Add border back for visual separation */
          border-radius: 0; /* Add radius back */
          overflow: hidden; /* Keep if needed */
  }

  /* Clearfix for content */
  .mac-my-account-wrapper .mac-my-account-main-content::after {
    content: "";
    display: table;
    clear: both;
  }
  
  /*--------------------------------------------------------------
  # Navigation - Core Override & Desktop (Horizontal)
  --------------------------------------------------------------*/
  
  /* Specific Shoptimizer Override for Nav element (<nav>) */
  body.woocommerce-account .mac-my-account-wrapper .woocommerce-MyAccount-navigation {
      float: none; /* Override Shoptimizer's float: left */
      width: 100%; /* Ensure it takes full width */
      margin-right: 0; /* Override Shoptimizer's margin */
      /* Add background color here ONLY if nav container doesn't have one */
      /* background-color: #f1f1f1; */
      border-bottom: 1px solid #000; /* Separator line below nav */
      padding-bottom: 0;
      margin-bottom: 0; /* Nav directly followed by content area */
      margin-top: -1px;
  }
  
  /* Style the UL as a flex container, contained & centered */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation ul {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    /* Center the UL within the Nav bar, constrained width */
    max-width: 100%; /* Match desired main content width */
    margin: 0 auto;   /* Center the UL block */
    padding: 0px; /* Padding inside the UL */
    border: none;
    justify-content: center; /* Center tabs within the UL */
    align-items: stretch;
  }
  
  /* Style individual list items (<li>) */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation li {
    list-style: none;
    margin: 0 -1px -1px 0;
    padding: 0;
    border: none;
    flex-shrink: 0;
}
  
  /* Remove the ::before pseudo-element */
  body.woocommerce-account .mac-my-account-wrapper .woocommerce-MyAccount-navigation ul li a::before {
      display: none !important;
      content: none !important;
  }
  
  fieldset legend {
    width: calc(100% + 60px);
    margin-left: -30px;
    padding: 10px 30px;
    color: #111;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

  /* Style the links (Tabs) - Restoring V1.4 appearance */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation li a {
    display: block;
    padding: 0.8em 2em;
    text-decoration: none;
    color: #000000;
    background-color: #fff;
    border: 1px solid #000;
    border-top: none;
    border-radius: 0px;
    transition: all 0.2s ease-in-out;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 11px;
    margin-bottom: 0;
    letter-spacing: 0.4px;
}
  
  /* Tab Hover State */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation li:not(.is-active) a:hover {
    background-color: #eee;
    color: #333;
  }
  
  /* Active Tab State - Restoring V1.4 style */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation li.is-active a {
    background-color: #fff; /* Match content area background */
    color: #000; /* Ensure active color is distinct */
    position: relative;
    z-index: 2; /* Bring active tab above potential content border */
    border-color: #000; /* Match other borders */
    /* Create the illusion of connection */
    border-bottom: 1px solid #000; /* Make bottom border white to blend */
  }
  
  
  /*--------------------------------------------------------------
  # Navigation - Mobile (Vertical)
  --------------------------------------------------------------*/
  @media (max-width: 768px) { /* Adjust breakpoint as needed */
  
  .mac-my-account-wrapper .mac-my-account-main-content.woocommerce-MyAccount-content.endpoint-cgkit-wishlist {
    padding: 1.1em !important;
}
.endpoint-cgkit-wishlist ul.commercekit-wishlist-list li.product .commercekit-wishlist.mini {
    position: absolute;
    right: 3px;
    top: 3px;
}
    /* Reset nav element styles for mobile */
    body.woocommerce-account .mac-my-account-wrapper .woocommerce-MyAccount-navigation {
         border-bottom: none;
         width: auto;
         background-color: transparent; /* Reset background */
    }

    /* Adjust UL for mobile */
     .mac-my-account-wrapper .woocommerce-MyAccount-navigation ul {
         flex-direction: column; /* Stack vertically */
         justify-content: flex-start; /* Align top */
         align-items: stretch; /* Full width */
         max-width: 100%; /* Allow full width */
         padding: 0 15px; /* Keep padding consistent */
         margin: 0; /* Reset centering margin */
     }
  
    /* List item margin */
    .mac-my-account-wrapper .woocommerce-MyAccount-navigation li {
      margin-right: 0;
      margin-bottom: 5px;
      margin-left: 0;
      margin-top: 0; /* Reset top part of margin shorthand */
    }
  
    /* Link styles for mobile - button appearance */
    .mac-my-account-wrapper .woocommerce-MyAccount-navigation li a {
      border-radius: 4px; /* Add radius back for mobile buttons */
      border: 1px solid #e0e0e0; /* Add border back */
      border-bottom: 1px solid #e0e0e0; /* Ensure bottom border */
      text-align: center;
      margin-bottom: 0; /* Reset margin */
      background-color: #f7f7f7; /* Restore background for button look */
       font-weight: 500; /* Reset font weight */
    }
  
    /* Adjust active state for vertical */
    .mac-my-account-wrapper .woocommerce-MyAccount-navigation li.is-active a {
      background-color: #eee;
      color: #000;
      border-color: #ccc;
      border-bottom-color: #ccc; /* Ensure bottom border is consistent */
      font-weight: 600; /* Keep active bolder */
      z-index: 1; /* Reset z-index */
    }
  
    /* Content block full width on mobile */
    .mac-my-account-wrapper .mac-my-account-main-content.woocommerce-MyAccount-content {
        width: auto; /* Allow full width */
        margin-left: 0; /* Reset margin */
        margin-right: 0; /* Reset margin */
        max-width: 100%; /* Ensure no max width constraint */
        padding: 15px; /* Adjust padding for mobile */
        border-radius: 4px; /* Add radius for mobile */
        float: none !important; /* Ensure float override persists */
    }
  
    /* Adjust top spacing for content area */
    .mac-my-account-wrapper .mac-my-account-content-area {
        padding-top: 1.5em; /* Adjust space */
    }
  }
  
  @media (min-width: 768px) {
  ul.commercekit-wishlist-list.products.columns-4 {
    display: flex;
    flex-wrap: wrap;
    width: 100% !important;
    margin-left: 0px !important;
    margin-bottom: 0;
    clear: both;
}
.mac-my-account-wrapper .mac-my-account-main-content.endpoint-edit-account {
  width: 80% !important;
  max-width: 800px !important;

}
.mac-my-account-wrapper .mac-my-account-main-content.woocommerce-MyAccount-content {
    float: none !important;
    width: 80%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    background-color: #ffffff;
    padding: 0px;
    border: none;
    border-radius: 0;
    overflow: hidden;
}
}
  /*--------------------------------------------------------------
  # Basic Content Area Styling (Scoped)
  --------------------------------------------------------------*/
  /* These rules target elements within the .mac-my-account-main-content block */
  
  .mac-my-account-wrapper .mac-my-account-main-content h2,
  .mac-my-account-wrapper .mac-my-account-main-content h3 {
  font-size: 13px;
  text-transform: uppercase;
  }

  .mac-my-account-wrapper .woocommerce table.shop_table {
    border: 1px solid #e0e0e0;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 4px;
    margin-bottom: 1.5em;
    width: 100%;
  }
  
  .mac-my-account-wrapper .woocommerce table.shop_table th,
  .mac-my-account-wrapper .woocommerce table.shop_table td {
    border-top: 1px solid #e0e0e0;
    padding: 0.8em 1em;
    text-align: left;
    vertical-align: middle;
  }
  .mac-my-account-wrapper .woocommerce table.shop_table tbody tr:first-child th,
  .mac-my-account-wrapper .woocommerce table.shop_table tbody tr:first-child td {
      border-top: none;
  }
  
  .mac-my-account-wrapper .woocommerce table.shop_table thead th {
    background-color: #f7f7f7;
    font-weight: 600;
    border-top: none;
    border-bottom: 1px solid #e0e0e0;
  }
  
  /* Remove default cell borders */
  .mac-my-account-wrapper .woocommerce table.shop_table td,
  .mac-my-account-wrapper .woocommerce table.shop_table th {
      border-left: none;
      border-right: none;
      border-bottom: none;
  }
  
  .mac-my-account-wrapper .woocommerce form .form-row {
    margin-bottom: 1em;
    padding: 0;
  }
  
  .mac-my-account-wrapper .woocommerce form label {
    display: block;
    margin-bottom: 0.5em;
    font-weight: 500;
  }
  
  .mac-my-account-wrapper .woocommerce form input.input-text,
  .mac-my-account-wrapper .woocommerce form select,
  .mac-my-account-wrapper .woocommerce form textarea {
      border: 1px solid #ccc;
      padding: 10px;
      width: 100%;
      box-sizing: border-box;
      border-radius: 3px;
      background-color: #fff;
      color: #333;
  }
  
  .mac-my-account-wrapper .woocommerce form select {
       height: auto;
       line-height: normal;
  }
  
  /* Style buttons - Adapt to your theme's button style */
  .mac-my-account-wrapper .woocommerce-MyAccount-content .button,
  .mac-my-account-wrapper .woocommerce form button.button {
    /* Example Shoptimizer-like style - Adjust colors/padding */
    background-color: #fff; /* Example dark */
    color: #000;
    border: 1px solid #000 !important;
    padding: 0.8em 1.5em;
    border-radius: 0px;
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: inline-block;
    text-transform: uppercase;
  }
  
  .addresses header.title a {
    padding: 10px 19px;
    margin-left: 0px;
    text-decoration: none;
    font-size: 12px;

}

  .mac-my-account-wrapper .woocommerce-MyAccount-content .button:hover,
  .mac-my-account-wrapper .woocommerce form button.button:hover {
     background-color: #d6d6d6; /* Example slightly lighter hover */
     color: #272727;
  }
  
  /* Notices */
  .mac-my-account-wrapper .woocommerce-error,
  .mac-my-account-wrapper .woocommerce-info,
  .mac-my-account-wrapper .woocommerce-message {
      border-top-width: 3px;
      border-radius: 4px;
      padding: 1em 1.5em;
      margin: 0 0 1.5em 0;
      list-style: none outside;
  }
  .mac-my-account-wrapper .woocommerce-error { border-top-color: #e2401c; }
  .mac-my-account-wrapper .woocommerce-info { border-top-color: #1e85be; }
  .mac-my-account-wrapper .woocommerce-message { border-top-color: #0f834d; }
  
  /*--------------------------------------------------------------
  # Header Styling
  --------------------------------------------------------------*/
  .mac-my-account-wrapper .mac-my-account-header {
    background-color: #e9e9e9; /* Placeholder grey background */
    padding-top: 2em; /* Space above content */
    padding-bottom: 2em; /* Space below content */
    width: 100%; /* Ensure full width */
    margin-bottom: 0; /* Remove bottom margin, spacing handled by content area */
  }
  
  .mac-my-account-wrapper .mac-header-content {
    max-width: 1680px; /* Adjust to match your theme's main content max-width */
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px; /* Standard content padding */
    padding-right: 15px;/* Standard content padding */
    color: #333; /* Example text color */
  }
  
  .mac-my-account-wrapper .mac-header-title {
    margin-top: 0;
    margin-bottom: 0.5em;
    font-size: 1.8rem; /* Example size */
    font-weight: 600;
    /* Add other title styles */
  }
  
  .mac-my-account-wrapper .mac-header-greeting {
    margin-bottom: 0.25em;
    font-size: 1.1rem;
  }
  .mac-my-account-wrapper .mac-header-greeting strong {
      font-weight: 600; /* Or bold */
  }
  
  
  .mac-my-account-wrapper .mac-header-description {
    margin-bottom: 0;
    font-size: 1rem;
    color: #555; /* Slightly lighter description text */
  }
  
  /*--------------------------------------------------------------
  # Dashboard Specific Styling
  --------------------------------------------------------------*/
  .mac-my-account-wrapper .mac-dashboard-logout {
      margin-top: 2em; /* Add space above the logout button */
      text-align: center; /* Or center/right */
      display: none !important;
  }

  /* Adjust nav container spacing now that header has padding */
  .mac-my-account-wrapper .mac-my-account-nav-container {
      margin-bottom: 0; /* Remove space below nav container */
  }
  /* Adjust content area spacing now that header has padding */
  .mac-my-account-wrapper .mac-my-account-content-area {
    padding-top: 4em;
    margin-bottom: 10vh;
}
  
  /* Adjust active tab connection for header background */
  .mac-my-account-wrapper .woocommerce-MyAccount-navigation li.is-active a {
    background-color: #ffffff;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}
 /*--------------------------------------------------------------
  # WISHLIST
  --------------------------------------------------------------*/
ul.commercekit-wishlist-list.products .wsl-no-products .wsl-no-title {
    font-size: 14px;
    color: #000;
    font-weight: 600;
    margin-top: 0px;
    margin-bottom: 0.5rem;
}
ul.commercekit-wishlist-list.products .wsl-no-products .wsl-no-desc {
  font-size: 12px;
  color: #000;
  margin-bottom: 1.5rem;
}
.wsl-no-icon svg {
  width: 200px;
  display: none;
}
.mac-my-account-wrapper .woocommerce-MyAccount-content .button {
  background-color: #f7f7f7 !important;
  border: 1px solid #000;
  padding: 1em 1.1em;
  border-radius: 0px;
  font-size: 11px !important;
  font-weight: 500 !important;
  letter-spacing: 0.3px !important;
}
ul.commercekit-wishlist-list.products .wsl-no-products {
  margin-top: 15vh;
}

/* ORDERS */

tr.woocommerce-orders-table__row--status-completed td.woocommerce-orders-table__cell-order-status {
  color: #000;
  font-weight: 600;
}

@media screen and (max-width: 992px) {
  .woocommerce-MyAccount-content table tr {
      display: block;
      margin-bottom: 0.625em;
      border-bottom: 1px solid #9f9f9f;
  }
    ul.commercekit-wishlist-list.products.columns-4 {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
}
  .mac-my-account-wrapper .woocommerce-MyAccount-content .button {
    padding: 0.7em 3.2em;
}
body.woocommerce-account .mac-my-account-wrapper .woocommerce-MyAccount-navigation {
  border-bottom: none;
  width: auto;
  background-color: transparent; /* Reset background */
}

/* --- Apply Grid Layout to UL --- */
.mac-my-account-wrapper .woocommerce-MyAccount-navigation ul {
  /* Add grid properties */
  display: grid; /* Use grid layout */
  grid-template-columns: repeat(2, 1fr); /* Create 2 equal-width columns */
  gap: 8px; /* Spacing between grid items (rows and columns) - Adjust as needed */

  /* Keep necessary base styles */
  max-width: 100%; /* Allow full width */
  padding: 0 15px; /* Keep padding consistent */
  margin: 0; /* Reset centering margin */
  list-style: none; /* Ensure no bullets */
}

/* --- Adjust List Item Margins --- */
.mac-my-account-wrapper .woocommerce-MyAccount-navigation li {
/* Remove individual margins, rely on grid gap */
margin: 0;
/* Keep other necessary styles */
list-style: none;
border: none;
/* flex-shrink: 0; /* Not needed for grid */
}

/* --- Link Styles for Mobile Grid Items --- */
.mac-my-account-wrapper .woocommerce-MyAccount-navigation li a {
border-radius: 4px; /* Keep radius for mobile buttons */
border: 1px solid #afafaf; /* Keep border */
border-radius: 0px;
text-align: center;
margin-bottom: 0; /* Ensure no bottom margin */
background-color: #f7f7f7; /* Keep background for button look */
font-weight: 500; /* Reset font weight */
display: block; /* Ensure link fills the grid cell */
padding: 0.8em 1em; /* Adjust padding if needed */
height: 100%; /* Optional: Make buttons in same row equal height */
box-sizing: border-box; /* Include padding/border in height */
}

/* Adjust active state for vertical */
.mac-my-account-wrapper .woocommerce-MyAccount-navigation li.is-active a {
background-color: #eee;
color: #000;
border-color: #000;
font-weight: 600; /* Keep active bolder */
z-index: 1; /* Reset z-index */
}

/* --- Content block full width on mobile --- */
.mac-my-account-wrapper .mac-my-account-main-content.woocommerce-MyAccount-content {
 width: auto; /* Allow full width */
 margin-left: 0; /* Reset margin */
 margin-right: 0; /* Reset margin */
 max-width: 100%; /* Ensure no max width constraint */
 padding: 23px; /* Adjust padding for mobile */
 border-radius: 0px; /* Add radius for mobile */
 float: none !important; /* Ensure float override persists */
 margin-top: 0.3em; /* Adjust spacing if needed */
 margin-bottom: 1.5em; /* Adjust spacing if needed */
}

/* Adjust top spacing for content area */
.mac-my-account-wrapper .mac-my-account-content-area {
 padding-top: 1.5em; /* Adjust space */
}
}