/* Global styles for Globaltruck theme */

/* Set default text color */
body {
    color: #F2F3F4;
}

/* Link styling with fade-in effect */
a {
    text-decoration: none;
}

a:hover {
    color: red;
    text-decoration: none;
}

.am-custom-tabs-wrapper .prose p:last-child, .am-custom-tabs-wrapper.prose p:last-child {
    margin-bottom: 0 !important;
}
.am-custom-tabs-wrapper .prose h2:first-child, .am-custom-tabs-wrapper.prose h2:first-child  {
    margin-top: 0;
}
.am-custom-tab {
    padding:10px;
}

/* Input styling */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="url"],
input[type="search"],
input[type="number"],
input[type="date"],
textarea,
select,
select.form-select,
.form-select {
    border: 1px solid #5b5a55 !important;
    border-radius: 0.375rem;
    color: #F2F3F4 !important;
    padding: 0.5rem 0.75rem;
    background-color: transparent;
}

/* Select chevron only (not text inputs) - color #5b5a55 */
select,
select.form-select,
.form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%235b5a55' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E") !important;
    background-position: right 0.5rem center !important;
    background-repeat: no-repeat !important;
    background-size: 1.5em 1.5em !important;
    padding-right: 2.5rem;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="tel"]:focus,
input[type="url"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
textarea:focus,
select:focus,
select.form-select:focus,
.form-select:focus {
    outline: none;
    border-color: #42413d !important;
    box-shadow: 0 0 0 1px #42413d;
}

input::placeholder,
textarea::placeholder {
    color: #9ca3af;
}

#coupon_code::placeholder {
    color: #5b5a55 !important;
}

/* Wishlist comment box - placeholder and background */
.wishlist .comment-box .product-item-comment,
.wishlist .comment-box .form-textarea {
    background: transparent !important;
}
.wishlist .comment-box .product-item-comment::placeholder,
.wishlist .comment-box .form-textarea::placeholder {
    color: #5b5a55 !important;
}

/* Wishlist share form - textarea background */
.form.wishlist.share textarea.form-input {
    background-color: #111 !important;
}

input[type="checkbox"] {
    border: 1px solid #5b5a55 !important;
    background: transparent !important;
    position: relative;
}

input[type="checkbox"]:checked {
    background: transparent !important;
    border-color: #5b5a55 !important;
}

input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    display: block;
}

input[type="radio"] {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 9999px;
    border: 1px solid #5b5a55 !important;
    background: transparent !important;
    box-shadow: none !important;
    outline: none;
    position: relative;
    padding: 0;
    margin: 0;
    display: inline-grid;
    place-items: center;
    vertical-align: middle;
}

input[type="radio"]:checked {
    background: transparent !important;
    border-color: #5b5a55 !important;
    box-shadow: none !important;
}

input[type="radio"]:checked::after {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #f2f3f4;
    display: block;
}

input[type="radio"]:focus-visible {
    outline: none;
    box-shadow: 0 0 0 1px #42413d !important;
}

/* Border styling */
hr {
    border-color: #5b5a55 !important;
    border-top-color: #5b5a55 !important;
}

/* General border color for common elements */
div,
section,
article,
aside,
header,
footer,
nav,
main,
fieldset,
legend,
table,
td,
th {
    border-color: #5b5a55;
}

.footer p, .footer div, .footer a {
    color: #F2F3F4 !important;
}
.footer a:hover {
    color: red !important;
}

/* Hide generic stock status container on product detail page */
.catalog-product-view .right-side-details .amstockstatus-status-container {
    display: none !important;
}

/* Style Call For Price button on product detail page to match listing page */
.catalog-product-view .callforprice-action button.action.tocart.primary {
    display: inline-flex;
    min-width: 10rem;
    align-items: center;
    justify-content: center;
    border-radius: 0.375rem;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: white;
    transition: background-color 0.2s;
    border: none;
}

.catalog-product-view .callforprice-action button.action.tocart.primary:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.catalog-product-view .callforprice-action button.action.tocart.primary:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

.catalog-product-view .callforprice-action .mpcfp-icon {
    margin-right: 0.5rem;
    max-width: 20px;
    max-height: 20px;
}
.final-price-excl-tax, .price-excluding-tax {
    color: #ff0000 !important;
}
.final-price-excl-tax .price, .price-excluding-tax .price {
    color: #f00 !important;
}

/* Hide Ex GST only on list (old) price and "as low as" (minimal/tier) price; keep it on final price */
.product-item .old-price .price-excluding-tax,
.product-item .old-price .price-wrapper.price-excluding-tax,
.product-item .minimal-price-link .price-excluding-tax,
.product-item .minimal-price-link .price-wrapper.price-excluding-tax,
.product-item .prices-tier .price-excluding-tax,
.product-item .prices-tier .price-wrapper.price-excluding-tax,
.product-info-main .old-price .price-excluding-tax,
.product-info-main .old-price .price-wrapper.price-excluding-tax,
.product-info-main .minimal-price-link .price-excluding-tax,
.product-info-main .minimal-price-link .price-wrapper.price-excluding-tax,
.product-info-main .prices-tier .price-excluding-tax,
.product-info-main .prices-tier .price-wrapper.price-excluding-tax {
    display: none !important;
}

/* "As low as" – color and size */
.minimal-price-link,
.minimal-price-link .price-label,
.minimal-price-link .price {
    color: #71fa4c !important;
    font-size: .875rem !important;
}

/* "Price Ex Tax" and "List Price" – font size */
.price-excluding-tax,
.price-wrapper.price-excluding-tax,
.old-price,
.old-price .price {
    font-size: .875rem !important;
}

.catalog-product-view .callforprice-action .mpcfp-icon {
    display: none !important;
}
.callforprice-action {
    width: initial !important;
}

@media (max-width: 768px) {
    .sidebar-main .sidebar-image {
        display: none !important;
    }
}

/* Grid: bleed to card edges. List: max-width set inline in item.phtml, left bleed via product-list.css */
.products-grid .product-item .product-item-photo,
.mode-grid .product-item .product-item-photo {
    max-width: calc(100% + 1rem);
}

.products-list .product-item .product-item-photo,
.mode-list .product-item .product-item-photo,
.block-new-products.list .product-item .product-item-photo {
    margin-left: -0.5rem;
}

.product-item .product-item-photo img,
.product-item .product-item-photo picture,
.product-item .product-item-photo > * {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    display: block;
}

/* Thinner stroke for wishlist and cart icons in header */
#header a[href*="wishlist"] svg,
#header #menu-cart-icon svg {
    stroke-width: 1.5 !important;
}

.amfinder-common-wrapper {
    border-top: solid 20px #f00;
    border-bottom: solid 5px #f00;
}
.amfinder-dropdown {
    text-align: center !important;
}

.level1:hover, .level2:hover, .level3:hover, .level4:hover, .level5:hover {
    background-color: rgb(35, 35, 35) !important;
}

.sidebar .account-nav {
    background: transparent !important;
}

#account-nav .nav.item.current,#account-nav .nav.item.current strong {
    text-decoration: none;
    color: #f2f3f4;
}
#account-nav .nav.item a:hover {
    color: red !important;
}

.cms-index-index .page-main {
    padding-top: 0.25rem !important;
}


.form-email:focus, .form-input:focus, .form-multiselect:focus, .form-select:focus, .form-textarea:focus {
    --tw-ring-color: rgb(60 60 60/var(--tw-ring-opacity,1));
}

.am-custom-tab.prose {
    color: #f2f3f4;
}

/* btn-secondary border color */
.btn-secondary {
    border-color: #5b5a55 !important;
    --btn-stroke: #5b5a55;
    --btn-hover-stroke: #3c3c3c;
    --btn-hover-color: red;
}

#cart-totals .remove {
    display: none;
}

.legend {
    border-bottom: none !important
}

/* .actions-toolbar a.back - no underline, back arrow before text, red on hover */
.actions-toolbar a.back {
    text-decoration: none !important;
}

.actions-toolbar a.back::before {
    content: "\2190\00a0"; /* leftwards arrow + space */
    margin-right: 0.25em;
}

.actions-toolbar a.back:hover {
    color: red !important;
}

/* Mobile menu: back-to-main-menu button – no focus border */
button.back-to-main-menu:focus {
    outline: none;
    box-shadow: none;
}

#account-nav .nav.item.current strong {
    color: red !important;
}



.message.info, .message.notice {
    border: 1px solid #5b5a55 !important;
    background-color: #111 !important;
    color: #F2F3F4 !important;
}

.product-item .price-container .price-excluding-tax .price {
    font-size: initial !important;
    line-height: initial !important;
    font-weight: initial !important;
}

.account .column.main {
    padding-bottom: 30px;
}

/* Pagination: active page */
.pager nav.pages a[aria-current="page"],
nav.pages a[aria-current="page"] {
    background-color: #3c3c3c !important;
    border: 1px solid #5b5a55 !important;
}

/* Remove blue focus outline/border for common interactive elements */
button:focus,
button:focus-visible,
a:focus,
a:focus-visible,
input:focus,
input:focus-visible,
select:focus,
select:focus-visible,
textarea:focus,
textarea:focus-visible,
div:focus,
div:focus-visible,
[tabindex]:focus,
[tabindex]:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}

/* Checkout success / order confirmation page */
.checkout-onepage-success .amtypage-main-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.checkout-onepage-success .amtypage-main-container br {
    display: none;
}

.checkout-onepage-success .amtyblock {
    width: 100% !important;
}

.amtypage-main-container .content h1 {
    font-size: 1.875rem;
    line-height: 2.25rem;
    font-weight: 500;
    margin-bottom: 1rem;
    color: #f2f3f4;
}

.checkout-onepage-success .checkout-success-header .page-title,
.checkout-onepage-success .checkout-success-create-account .page-title,
.checkout-onepage-success .page-title-wrapper h2 {
    color: #f2f3f4;
}

.checkout-onepage-success .checkout-success-header .subtitle {
    color: #ababab;
}

.checkout-onepage-success .checkout-success-create-account .subtitle,
.checkout-onepage-success .checkout-success-create-account .text,
.checkout-onepage-success .checkout-success-create-account .content,
.checkout-onepage-success .checkout-success-create-account .container-success,
.checkout-onepage-success .success-messages p {
    color: #f2f3f4;
}

.checkout-onepage-success .thankyoupage-customer-create-form .label {
    color: #f2f3f4;
}

.checkout-onepage-success .thankyoupage-customer-create-form .create-account-password {
    max-width: 500px;
}

.checkout-onepage-success .password-strength-meter {
    color: #ababab;
}

.checkout-onepage-success .checkout-success .order-number {
    color: #f2f3f4;
    text-decoration: none;
}

.checkout-onepage-success tfoot .price {
    color: #fefefe;
}

.checkout-onepage-success .cart-price .price {
    color: #ababab;
}

.product-item .product-item-description p {
    margin-bottom: 10px;
}
