html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    /* Prevent any rogue child from triggering horizontal scroll on narrow viewports.
       `clip` is preferred over `hidden` because it doesn't create a new scroll
       container — sticky-top headers and similar behaviors keep working. */
    overflow-x: clip;
}

/* Cap Bootstrap containers at xl size (1140px) on xxl screens so the layout
   stays consistent on 1920px-and-wider displays instead of jumping to 1320px. */
@media (min-width: 1400px) {
    .container,
    .container-sm,
    .container-md,
    .container-lg,
    .container-xl,
    .container-xxl {
        max-width: 1140px;
    }
}

/* Cap inline media so an oversized image / iframe / svg can never exceed its
   container and push the page wider than the viewport. */
img, svg, video, iframe {
    max-width: 100%;
}

/* Long unbroken strings (URLs, product codes, etc.) wrap at narrow widths so
   they don't force a containing column past the viewport edge. */
body {
    overflow-wrap: anywhere;
    word-break: normal;
}

a, .btn-link {
    color: #006bb7;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJ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yMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================================
   E-commerce Styles
   ============================================ */

/* Header contact prompt */
.header-contact {
    line-height: 1.55;
}

:root {
    --header-control-height: 2.75rem;
    --header-control-radius: 0.45rem;
}

.business-pricing-cta {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    max-width: 330px;
    margin-top: 0.25rem;
    padding: 0.18rem 0.55rem;
    border: 1px solid rgba(0, 172, 181, 0.24);
    border-radius: 999px;
    color: #05676e;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.12), rgba(45, 212, 191, 0.08));
    font-weight: 600;
    line-height: 1.25;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.business-pricing-mobile:hover {
    color: #044e54;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.17), rgba(45, 212, 191, 0.12));
    border-color: rgba(0, 172, 181, 0.36);
}

.business-pricing-mobile {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.45rem;
    padding: 0.28rem 0.55rem;
    border: 1px solid rgba(0, 172, 181, 0.22);
    border-radius: 0.35rem;
    color: #05676e;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.12), rgba(45, 212, 191, 0.08));
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
}

.electric-service-banner {
    border-color: rgba(0, 172, 181, 0.24) !important;
    background:
        linear-gradient(135deg, rgba(20, 184, 166, 0.12), rgba(45, 212, 191, 0.08)),
        rgba(255, 255, 255, 0.78);
}

.electric-service-icon {
    color: #057981;
}

.electric-service-button {
    color: #055e66;
    border: 1px solid rgba(0, 172, 181, 0.28);
    background: rgba(255, 255, 255, 0.72);
}

.electric-service-button:hover,
.electric-service-button:focus {
    color: #044e54;
    border-color: rgba(0, 172, 181, 0.45);
    background: rgba(224, 255, 250, 0.82);
}

.site-search-strip {
    background:
        linear-gradient(90deg, rgba(27, 110, 194, 0.10), rgba(255, 255, 255, 0.94) 42%, rgba(27, 110, 194, 0.08));
}

.header-search-wrap {
    min-width: 0;
}

.header-search-group {
    box-shadow: 0 0.35rem 1rem rgba(27, 110, 194, 0.14);
}

.header-search-group .form-control,
.header-search-group .input-group-text,
.header-search-group .btn {
    min-height: var(--header-control-height);
    border-color: rgba(27, 110, 194, 0.35);
}

.header-search-group .form-control {
    font-size: 1rem;
    font-weight: 500;
}

.header-search-group .form-control::placeholder {
    color: #5f7285;
}

.header-search-group:focus-within {
    box-shadow: 0 0.35rem 1rem rgba(27, 110, 194, 0.18), 0 0 0 0.18rem rgba(37, 140, 251, 0.22);
}

.header-search-group:focus-within .form-control,
.header-search-group:focus-within .input-group-text,
.header-search-group:focus-within .btn {
    border-color: #1b6ec2;
}

.header-actions {
    flex: 0 0 auto;
}

.header-actions .btn,
.header-actions .btn-group > .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: var(--header-control-height);
    padding-top: 0.45rem;
    padding-bottom: 0.45rem;
    border-radius: var(--header-control-radius);
}

.header-actions .btn-group > .btn {
    min-width: 2.85rem;
    border-radius: 0;
}

.header-actions .btn-group > .btn:first-child {
    border-top-left-radius: var(--header-control-radius);
    border-bottom-left-radius: var(--header-control-radius);
}

.header-actions .btn-group > .btn:last-child {
    border-top-right-radius: var(--header-control-radius);
    border-bottom-right-radius: var(--header-control-radius);
}

.header-actions .dropdown-toggle {
    max-width: 18rem;
}

.header-language-button {
    gap: 0.35rem;
    min-width: auto;
    min-height: 2.15rem;
    padding: 0.25rem 0.55rem;
    border-color: transparent;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.42);
    color: #526170;
    font-size: 0.86rem;
    font-weight: 600;
    box-shadow: none;
}

.header-language-button:hover,
.header-language-button:focus {
    border-color: rgba(6, 110, 118, 0.16);
    background: rgba(255, 255, 255, 0.76);
    color: #055e66;
    box-shadow: none;
}

.header-language-button::after {
    margin-left: 0.15rem;
    opacity: 0.55;
}

.language-switcher-menu {
    min-width: 5.2rem;
    padding-block: 0.25rem;
    border-radius: 0.55rem;
}

.language-switcher-menu .dropdown-item {
    font-size: 0.88rem;
    font-weight: 600;
}

.header-cart-button {
    gap: 0.4rem;
    min-width: 7.4rem;
    font-weight: 600;
    box-shadow: 0 0.25rem 0.75rem rgba(27, 110, 194, 0.22);
}

.header-cart-button:hover,
.header-cart-button:focus {
    box-shadow: 0 0.35rem 0.95rem rgba(27, 110, 194, 0.28);
}

.header-cart-label {
    font-size: 0.94rem;
    line-height: 1;
    white-space: nowrap;
}

.mobile-header-actions {
    align-items: center;
}

.mobile-header-actions .header-language-button,
.mobile-header-actions .header-cart-button {
    min-width: 2.6rem;
}

.mobile-header-actions .header-language-button {
    min-width: auto;
    min-height: 2rem;
    padding-inline: 0.5rem;
}

.mobile-header-actions .header-cart-label {
    display: none;
}

@media (max-width: 991.98px) {
    .header-actions .header-cart-button {
        min-width: 2.85rem;
        padding-inline: 0.85rem;
    }

    .header-actions .header-cart-label {
        display: none;
    }
}

@media (max-width: 767.98px) {
    .site-search-strip {
        background: linear-gradient(180deg, rgba(27, 110, 194, 0.12), rgba(255, 255, 255, 0.96));
    }

    .header-search-group .form-control,
    .header-search-group .input-group-text,
    .header-search-group .btn {
        min-height: 2.85rem;
    }
}

/* Product cards */
.product-card {
    border: 1px solid #e0e0e0;
    border-radius: 0.5rem;
    overflow: hidden;
    transition: box-shadow 0.2s ease, transform 0.15s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.product-card img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    padding: 1rem;
    background: #fafafa;
}

.product-card .card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-card .card-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card .card-text {
    font-size: 0.85rem;
    color: #666;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Price display */
.price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #d32f2f;
}

.price-original {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9rem;
    margin-left: 0.5rem;
}

.price-discount {
    background: #d32f2f;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.15rem 0.4rem;
    border-radius: 0.25rem;
    margin-left: 0.5rem;
}

.price-note {
    font-size: 0.75rem;
    color: #888;
}

.parent-category-intro {
    padding-bottom: 1.75rem;
    border-bottom: 1px solid rgba(16, 32, 43, 0.16);
}

.parent-category-product-grid {
    padding-top: 1.25rem;
}

.product-list-top-content .promoted-product-shelves {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.catalog-jobs-card {
    width: 100%;
}

.catalog-jobs-scroll {
    max-height: min(70vh, 760px);
    scrollbar-gutter: stable;
}

.catalog-jobs-table {
    table-layout: fixed;
    width: 1260px;
    min-width: 1260px;
    margin-bottom: 0;
}

.catalog-jobs-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    line-height: 1.2;
    white-space: normal;
}

.catalog-job-file-cell {
    min-width: 0;
}

.catalog-job-file-name,
.catalog-job-path {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.catalog-job-options {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.3rem;
}

.catalog-job-notes {
    display: -webkit-box;
    overflow: hidden;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.catalog-job-actions {
    display: grid;
    grid-template-columns: repeat(2, max-content);
    gap: 0.35rem;
    justify-content: flex-end;
    align-items: start;
}

.catalog-job-actions .btn {
    white-space: nowrap;
}

.catalog-job-action-wide {
    grid-column: 1 / -1;
    justify-self: end;
}

@media (min-width: 768px) {
    .product-filter-panel {
        position: sticky;
        top: 1rem;
        z-index: 1;
    }
}

/* Category cards */
.category-card {
    border: 1px solid #e0e0e0;
    border-radius: 0.5rem;
    text-align: center;
    padding: 1.5rem 1rem;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
    height: 100%;
}

.category-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #006bb7;
}

.category-card i {
    font-size: 2rem;
    color: #006bb7;
}

.category-card h5 {
    font-size: 0.95rem;
    margin-top: 0.75rem;
    margin-bottom: 0;
    font-weight: 600;
}

/* Cart table */
.cart-table th {
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: #555;
    border-bottom: 2px solid #dee2e6;
}

.cart-table td {
    vertical-align: middle;
}

.cart-item-img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border: 1px solid #eee;
    border-radius: 0.25rem;
}

/* Quantity selector */
.qty-selector {
    display: inline-flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 0.375rem;
    overflow: hidden;
}

.qty-selector button {
    background: #f8f9fa;
    border: none;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: 600;
    color: #333;
    transition: background 0.15s;
}

.qty-selector button:hover {
    background: #e9ecef;
}

.qty-selector button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.qty-selector .qty-value {
    min-width: 2.5rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    border-left: 1px solid #ccc;
    border-right: 1px solid #ccc;
    padding: 0.25rem 0;
}

/* Checkout steps */
.checkout-steps {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-bottom: 2rem;
    counter-reset: step;
}

.checkout-step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    color: #999;
    position: relative;
}

.checkout-step.active {
    color: #006bb7;
    font-weight: 600;
}

.checkout-step.completed {
    color: #26b050;
}

.checkout-step::before {
    counter-increment: step;
    content: counter(step);
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    background: #e9ecef;
    color: #666;
    flex-shrink: 0;
}

.checkout-step.active::before {
    background: #006bb7;
    color: #fff;
}

.checkout-step.completed::before {
    background: #26b050;
    color: #fff;
    content: "\2713";
}

/* Order status badges */
.badge-pending    { background-color: #ffc107; color: #333; }
.badge-started    { background-color: #17a2b8; color: #fff; }
.badge-prepared   { background-color: #6f42c1; color: #fff; }
.badge-shipped    { background-color: #007bff; color: #fff; }
.badge-delivered  { background-color: #28a745; color: #fff; }
.badge-cancelled  { background-color: #dc3545; color: #fff; }

/* Product detail page */
.product-detail-img {
    max-height: 400px;
    object-fit: contain;
    width: 100%;
}

.product-detail-carousel .carousel-item img {
    max-height: 400px;
    object-fit: contain;
    width: 100%;
    padding: 1rem;
    background: #fafafa;
}

.product-detail-specs dt {
    font-weight: 600;
    color: #555;
    font-size: 0.85rem;
}

.product-detail-specs dd {
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
}

/* Search bar */
.search-bar {
    position: relative;
}

.search-bar .form-control {
    padding-right: 2.5rem;
    border-radius: 0.375rem;
}

.search-bar .btn {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* Loading spinner */
.loading-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3rem;
}

/* Footer */
.site-footer {
    background: #2c3e50;
    color: #ccc;
    padding: 2rem 0 1rem;
    font-size: 0.9rem;
}

.site-footer a {
    color: #fff;
    text-decoration: none;
}

.site-footer a:hover {
    color: #ffc107;
    text-decoration: underline;
}

.site-footer h6 {
    color: #fff;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .product-card img {
        height: 150px;
    }

    .checkout-steps {
        flex-direction: column;
        align-items: flex-start;
    }

    .price {
        font-size: 1.1rem;
    }
}

/* Add-to-cart button */
.btn-add-to-cart {
    background-color: #f0c14b;
    border-color: #a88734;
    color: #111;
    font-weight: 600;
    transition: background-color 0.15s;
}

.btn-add-to-cart:hover {
    background-color: #ddb347;
    border-color: #a88734;
    color: #111;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #888;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

/* Breadcrumb customization */
.breadcrumb-item + .breadcrumb-item::before {
    content: "\203A";
}

/* Category marketing callout */
.category-marketing {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.1rem;
    border: 1px solid rgba(var(--bs-primary-rgb), 0.28);
    border-left: 4px solid var(--bs-primary);
    border-radius: 0.5rem;
    background: rgba(var(--bs-primary-rgb), 0.06);
    color: var(--bs-dark);
    font-weight: 500;
    line-height: 1.45;
    white-space: pre-line;
}

.category-marketing .bi {
    margin-top: 0.1rem;
    color: var(--bs-primary);
    font-size: 1.15rem;
    flex: 0 0 auto;
}

/* Order summary sidebar */
.order-summary {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 0.5rem;
    padding: 1.5rem;
}

.order-summary .summary-row {
    display: flex;
    justify-content: space-between;
    padding: 0.35rem 0;
    font-size: 0.9rem;
}

.order-summary .summary-total {
    border-top: 2px solid #333;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    font-weight: 700;
    font-size: 1.1rem;
}

/* Cookie preferences */
.cookie-consent-banner {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    left: 1rem;
    z-index: 1090;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    max-width: 1120px;
    margin: 0 auto;
    padding: 1rem 1.15rem;
    color: #20242a;
    background: #fff;
    border: 1px solid #cfd5dc;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1.5rem rgba(24, 31, 40, 0.2);
}

.cookie-consent-copy h2 {
    margin: 0 0 0.35rem;
    font-size: 1.05rem;
}

.cookie-consent-copy p {
    max-width: 760px;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.45;
}

.cookie-consent-actions {
    display: flex;
    flex: 0 0 auto;
    gap: 0.5rem;
}

.consented-embed {
    overflow: hidden;
    width: 100%;
    background: #f3f5f7;
    border: 1px solid #d8dde3;
}

.consented-embed-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    width: 100%;
    height: 100%;
    padding: 1rem;
    color: #545b64;
    text-align: center;
}

.consented-embed-placeholder .bi {
    font-size: 1.5rem;
}

.consented-embed-placeholder p {
    max-width: 32rem;
    margin: 0;
    font-size: 0.875rem;
}

.privacy-policy {
    max-width: 920px;
    margin: 0 auto;
}

.privacy-policy header,
.privacy-policy section {
    margin-bottom: 2rem;
}

.privacy-policy h1 {
    font-size: 2rem;
}

.privacy-policy h2 {
    margin-bottom: 0.75rem;
    font-size: 1.3rem;
}

@media (max-width: 767.98px) {
    .cookie-consent-banner {
        align-items: stretch;
        flex-direction: column;
        gap: 0.9rem;
    }

    .cookie-consent-actions {
        display: grid;
        grid-template-columns: 1fr;
    }
}
