/* Streamline — a focused checkout flow for FOSSBilling (huraga base)
   Uses Bootstrap CSS variables so it follows your huraga color settings. */

.sl-flow {
    max-width: 1080px;
    margin: 0 auto;
}

.sl-muted { color: var(--bs-secondary-color, #6c757d); font-size: .9rem; }
.sl-link { font-size: .9rem; text-decoration: none; }
.sl-link:hover { text-decoration: underline; }
.sl-title { font-size: 1.5rem; font-weight: 700; margin-bottom: .25rem; }

/* ---------- Cards ---------- */
.sl-card {
    background: var(--bs-body-bg, #fff);
    border: 1px solid var(--bs-border-color, #e5e7eb);
    border-radius: .75rem;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
}
.sl-card-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: .75rem;
}

/* ---------- Stepper ---------- */
.sl-steps {
    display: flex;
    justify-content: center;
    gap: .5rem;
    list-style: none;
    padding: 0;
    margin: 0 0 1.75rem;
}
.sl-step { display: flex; align-items: center; }
.sl-step > a,
.sl-step > span {
    display: flex;
    align-items: center;
    gap: .5rem;
    text-decoration: none;
    color: var(--bs-secondary-color, #6c757d);
}
.sl-step-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    border: 2px solid var(--bs-border-color, #d1d5db);
    font-size: .85rem;
    font-weight: 700;
    flex-shrink: 0;
}
.sl-step-label { font-size: .9rem; font-weight: 600; white-space: nowrap; }
.sl-step.is-active .sl-step-dot {
    border-color: var(--bs-primary);
    background: var(--bs-primary);
    color: #fff;
}
.sl-step.is-active .sl-step-label { color: var(--bs-body-color); }
.sl-step.is-done .sl-step-dot {
    border-color: var(--bs-success, #198754);
    color: var(--bs-success, #198754);
}
.sl-step.is-done .sl-step-dot .icon { width: .9rem; height: .9rem; }
/* Connector lines between steps */
.sl-step + .sl-step::before {
    content: "";
    display: block;
    width: 3rem;
    height: 2px;
    margin: 0 .75rem;
    background: var(--bs-border-color, #d1d5db);
}
@media (max-width: 575.98px) {
    .sl-step + .sl-step::before { width: 1.25rem; margin: 0 .35rem; }
    .sl-step-label { display: none; }
    .sl-step.is-active .sl-step-label { display: inline; }
}

/* ---------- Two-column layout ---------- */
.sl-columns {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 1.25rem;
    align-items: start;
}
@media (max-width: 991.98px) {
    .sl-columns { grid-template-columns: 1fr; }
}
.sl-sticky {
    position: sticky;
    top: 1rem;
}
@media (max-width: 991.98px) {
    .sl-sticky { position: static; }
}

/* ---------- Catalog ---------- */
.sl-catalog-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: 1rem;
}
.sl-category { margin-bottom: 2rem; }
.sl-category-head {
    display: flex;
    gap: .75rem;
    align-items: flex-start;
    margin-bottom: .9rem;
}
.sl-category-icon { width: 40px; height: 40px; object-fit: contain; }
.sl-category-title { font-size: 1.15rem; font-weight: 700; margin: 0; }
.sl-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
}
.sl-product-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: var(--bs-body-bg, #fff);
    border: 1px solid var(--bs-border-color, #e5e7eb);
    border-radius: .75rem;
    padding: 1.1rem 1.25rem;
    text-decoration: none;
    color: inherit;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.sl-product-card:hover,
.sl-product-card:focus-visible {
    border-color: var(--bs-primary);
    box-shadow: 0 4px 14px rgba(0, 0, 0, .07);
    transform: translateY(-2px);
    color: inherit;
}
@media (prefers-reduced-motion: reduce) {
    .sl-product-card { transition: none; }
    .sl-product-card:hover { transform: none; }
}
.sl-product-title { font-size: 1rem; font-weight: 700; margin-bottom: .35rem; }
.sl-product-desc {
    font-size: .875rem;
    color: var(--bs-secondary-color, #6c757d);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.sl-product-desc p { margin-bottom: .25rem; }
.sl-product-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    gap: .5rem;
}
.sl-product-price { font-weight: 700; }
.sl-product-cta .icon { width: .85rem; height: .85rem; margin-left: .15rem; }

/* ---------- Configuration ---------- */
.sl-config-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--bs-border-color, #e5e7eb);
}

/* ---------- Summary / cart ---------- */
.sl-summary-line {
    display: flex;
    flex-direction: column;
    gap: .15rem;
}
.sl-summary-product { font-weight: 600; }
.sl-mini-cart {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: .9rem;
}
.sl-mini-cart li {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    padding: .25rem 0;
}
.sl-cart-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.sl-cart-item {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: .75rem 0;
    border-bottom: 1px solid var(--bs-border-color, #e5e7eb);
}
.sl-cart-item:last-child { border-bottom: 0; }
.sl-cart-item-info {
    display: flex;
    flex-direction: column;
    gap: .1rem;
    flex: 1 1 auto;
    min-width: 0;
}
.sl-cart-item-title { font-weight: 600; }
.sl-cart-item-price { white-space: nowrap; font-weight: 600; }
.sl-remove {
    color: var(--bs-secondary-color, #6c757d);
    cursor: pointer;
    padding: .15rem;
    line-height: 1;
    border-radius: .35rem;
}
.sl-remove:hover { color: var(--bs-danger, #dc3545); background: var(--bs-tertiary-bg, #f3f4f6); }
.sl-remove .icon { width: 1rem; height: 1rem; }

.sl-promo { margin: .5rem 0 1rem; }
.sl-promo form { margin-top: .5rem; max-width: 320px; }

/* ---------- Totals ---------- */
.sl-totals { margin: 0 0 1rem; }
.sl-totals-row {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    padding: .2rem 0;
}
.sl-totals-row dt { font-weight: 400; }
.sl-totals-row dd { margin: 0; font-weight: 600; }
.sl-totals-grand {
    margin-top: .35rem;
    padding-top: .6rem;
    border-top: 1px solid var(--bs-border-color, #e5e7eb);
    font-size: 1.15rem;
}
.sl-totals-grand dt,
.sl-totals-grand dd { font-weight: 700; }

/* ---------- Gateways ---------- */
.sl-gateways {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: .5rem;
}
.sl-gateway-label {
    border: 1px solid var(--bs-border-color, #e5e7eb);
    border-radius: .5rem;
}
.btn-check:checked + .sl-gateway-label {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--bs-primary) 30%, transparent);
}

/* ---------- Account step ---------- */
.sl-signedin {
    display: flex;
    align-items: center;
    padding: .85rem 1.5rem;
}
.sl-tabs .nav-link { font-weight: 600; }

/* ---------- Misc ---------- */
.sl-empty { text-align: center; padding: 3rem 1.5rem; }
.sl-empty h2 { margin-bottom: .35rem; }

/* ---------- Single centered checkout column ---------- */
.sl-single {
    max-width: 520px;
    margin: 0 auto;
}

/* ---------- Focused order pages: hide chrome, center content ----------
   Scoped to body.streamline-checkout (set by mod_order_index), so the
   rest of the client area keeps its normal navigation. */

/* Hide the language selector and everything right of it (theme toggle,
   top menu links, profile dropdown) plus the mobile hamburger */
body.streamline-checkout header .navbar-collapse,
body.streamline-checkout header .navbar-toggler {
    display: none !important;
}
/* Center the remaining logo in the header */
body.streamline-checkout header .navbar .container-fluid {
    justify-content: center;
}

/* Hide the sidebar menu column and let the content column fill and center */
body.streamline-checkout .row > div:has(> #sidebarMenu) {
    display: none !important;
}
body.streamline-checkout .row > .col-md-9 {
    width: 100%;
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}

/* Center the breadcrumb over the centered content */
body.streamline-checkout .breadcrumb {
    justify-content: center;
}

/* ---------- Embedded /orderbutton page (inside the WordPress iframe) ---------- */
body.streamline-embed {
    padding: .25rem 1rem 1.25rem;
    background: transparent;
    height: auto !important;
    min-height: 0 !important;
}
body.streamline-embed .sl-flow {
    max-width: 960px;
}

/* ---------- Payment gateway output: fill the card, no inner scrollbars ---------- */
#payment-html-inner iframe {
    display: block;
    width: 100%;
    min-height: 560px;
    border: 0;
}
#payment-html-inner form {
    max-width: 100%;
}
body.streamline-checkout,
body.streamline-embed {
    overflow-x: hidden;
}

/* ---------- Notifications: center of the page instead of bottom-right ---------- */
.toast-container.position-fixed {
    top: 50% !important;
    left: 50% !important;
    bottom: auto !important;
    right: auto !important;
    transform: translate(-50%, -50%);
}

/* ---------- Brand: ProForge orange (duplicated from the global partial so
   order/checkout pages are orange even if the layout include is missing) ---------- */
:root,
[data-bs-theme=light],
[data-bs-theme=dark] {
    --bs-primary: #F7791E;
    --bs-primary-rgb: 247, 121, 30;
    --bs-link-color: #F7791E;
    --bs-link-color-rgb: 247, 121, 30;
    --bs-link-hover-color: #D9670F;
    --bs-link-hover-color-rgb: 217, 103, 15;
}
.btn-primary {
    --bs-btn-bg: #F7791E;
    --bs-btn-border-color: #F7791E;
    --bs-btn-hover-bg: #E06A12;
    --bs-btn-hover-border-color: #E06A12;
    --bs-btn-active-bg: #CE5F0E;
    --bs-btn-active-border-color: #CE5F0E;
    --bs-btn-disabled-bg: #F7791E;
    --bs-btn-disabled-border-color: #F7791E;
    --bs-btn-focus-shadow-rgb: 247, 121, 30;
}
.btn-outline-primary {
    --bs-btn-color: #F7791E;
    --bs-btn-border-color: #F7791E;
    --bs-btn-hover-bg: #F7791E;
    --bs-btn-hover-border-color: #F7791E;
    --bs-btn-active-bg: #F7791E;
    --bs-btn-active-border-color: #F7791E;
    --bs-btn-focus-shadow-rgb: 247, 121, 30;
}
.nav-pills {
    --bs-nav-pills-link-active-bg: #F7791E;
}
.form-check-input:checked {
    background-color: #F7791E;
    border-color: #F7791E;
}
.form-control:focus,
.form-select:focus {
    border-color: #F7791E;
    box-shadow: 0 0 0 .25rem rgba(247, 121, 30, .25);
}
.badge.text-bg-primary,
.bg-primary {
    background-color: #F7791E !important;
}
.text-primary {
    color: #F7791E !important;
}
