/* Lamanify theme: brand layer on top of Twenty-One + Standard Cart */

:root {
    --lmf-brand: #e9204f;
    --lmf-brand-dark: #c4103b;
    --lmf-brand-soft: #fdecf1;
    --lmf-ink: #0a0a0a;
    --lmf-text: #0f172a;
    --lmf-muted: #64748b;
    --lmf-line: #e2e8f0;
    --lmf-surface: #ffffff;
    --lmf-bg: #f8fafc;
    --lmf-radius: 14px;
    --lmf-radius-sm: 10px;
    --lmf-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .06);
    --lmf-font: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* ---------- Base ---------- */

body.lmf {
    background: var(--lmf-bg);
    color: var(--lmf-text);
    font-family: var(--lmf-font);
    -webkit-font-smoothing: antialiased;
}
body.lmf h1, body.lmf h2, body.lmf h3, body.lmf h4, body.lmf h5, body.lmf h6,
body.lmf .h1, body.lmf .h2, body.lmf .h3, body.lmf .h4, body.lmf .h5 {
    font-family: var(--lmf-font);
    color: var(--lmf-ink);
    font-weight: 700;
    letter-spacing: -.01em;
}
body.lmf a { color: var(--lmf-brand); }
body.lmf a:hover { color: var(--lmf-brand-dark); }
body.lmf .lmf-muted, body.lmf .text-muted { color: var(--lmf-muted) !important; }
body.lmf .lmf-accent { color: var(--lmf-brand); }
body.lmf .lmf-link { font-weight: 600; text-decoration: none; }
body.lmf .lmf-link i { margin-left: 4px; transition: transform .15s; }
body.lmf .lmf-link:hover i { transform: translateX(3px); }
body.lmf .lmf-eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--lmf-brand);
    margin-bottom: 10px;
}

/* ---------- Buttons ---------- */

body.lmf .btn {
    font-family: var(--lmf-font);
    font-weight: 600;
    border-radius: 999px;
    padding: .55rem 1.25rem;
    transition: background-color .15s, border-color .15s, color .15s, box-shadow .15s;
}
body.lmf .btn-sm { padding: .3rem .85rem; }
body.lmf .btn-lg { padding: .8rem 1.75rem; font-size: 1rem; }
body.lmf .btn-primary,
body.lmf .btn-success,
body.lmf .btn-checkout {
    background: var(--lmf-brand);
    border-color: var(--lmf-brand);
    color: #fff;
}
body.lmf .btn-primary:hover, body.lmf .btn-primary:focus,
body.lmf .btn-success:hover, body.lmf .btn-success:focus,
body.lmf .btn-checkout:hover {
    background: var(--lmf-brand-dark);
    border-color: var(--lmf-brand-dark);
    color: #fff;
}
body.lmf .btn-primary:focus, body.lmf .btn-outline-primary:focus {
    box-shadow: 0 0 0 .2rem rgba(233, 32, 79, .25);
}
body.lmf .btn-outline-primary { color: var(--lmf-brand); border-color: var(--lmf-brand); }
body.lmf .btn-outline-primary:hover { background: var(--lmf-brand); border-color: var(--lmf-brand); color: #fff; }
body.lmf .btn-outline-dark { color: var(--lmf-ink); border-color: var(--lmf-line); background: #fff; }
body.lmf .btn-outline-dark:hover { border-color: var(--lmf-ink); background: var(--lmf-ink); color: #fff; }
body.lmf .btn-default, body.lmf .btn-light {
    background: #fff;
    border: 1px solid var(--lmf-line);
    color: var(--lmf-text);
}
body.lmf .btn-default:hover, body.lmf .btn-light:hover { border-color: var(--lmf-muted); background: #fff; }
body.lmf .btn-link { color: var(--lmf-brand); }

/* ---------- Header ---------- */

.lmf-topbar {
    background: var(--lmf-ink);
    color: #cbd5e1;
    font-size: 13px;
    padding: 6px 0;
}
.lmf-topbar .lmf-muted { color: #94a3b8 !important; }
.lmf-topbar-btn { color: #e2e8f0; padding: 2px 0; font-weight: 500; border-radius: 0; }
.lmf-topbar-btn:hover { color: #fff; }
.lmf-topbar-btn i { margin-right: 6px; }
.lmf-topbar .lmf-dot {
    display: inline-block;
    min-width: 18px;
    padding: 0 5px;
    margin-right: 4px;
    border-radius: 999px;
    background: var(--lmf-brand);
    color: #fff;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
}
body.lmf .lmf-topbar-link { color: #fff; font-weight: 500; }
body.lmf .lmf-topbar-link:hover { color: #fda4b8; text-decoration: none; }

.lmf-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    /* Solid, not a backdrop-filter blur: blurring on every scroll frame made pages lag. */
    background: #fff;
    border-bottom: 1px solid var(--lmf-line);
}
.lmf-navbar { padding: 14px 0; }
.lmf-navbar > .container { padding-left: 16px; padding-right: 16px; }
.lmf-brand img { height: 34px; width: auto; }
.lmf-navbar .navbar-nav > li > a {
    display: block;
    color: var(--lmf-text);
    font-weight: 500;
    font-size: 15px;
    padding: 8px 14px !important;
    border-radius: 999px;
    white-space: nowrap;
}
.lmf-navbar .navbar-nav > li > a:hover,
.lmf-navbar .navbar-nav > li.show > a {
    background: var(--lmf-bg);
    color: var(--lmf-ink);
    text-decoration: none;
}
.lmf-navbar .lmf-nav-secondary > li:last-child > a {
    background: var(--lmf-brand);
    color: #fff;
    margin-left: 6px;
}
.lmf-navbar .lmf-nav-secondary > li:last-child > a:hover { background: var(--lmf-brand-dark); color: #fff; }
.lmf-navbar .dropdown-menu {
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    box-shadow: var(--lmf-shadow);
    padding: 6px;
    margin-top: 8px;
}
.lmf-navbar .dropdown-menu li.dropdown-item { padding: 0; background: none; }
.lmf-navbar .dropdown-menu li > a {
    display: block;
    font-weight: 500;
    padding: 8px 12px !important;
    border-radius: 8px;
    color: var(--lmf-text);
    font-size: 14px;
}
.lmf-navbar .dropdown-menu li > a:hover { text-decoration: none; background: var(--lmf-brand-soft); color: var(--lmf-brand-dark); }

.lmf-icon-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid var(--lmf-line);
    background: #fff;
    color: var(--lmf-text) !important;
    font-size: 16px;
}
.lmf-icon-btn:hover { border-color: var(--lmf-ink); text-decoration: none; }
.lmf-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--lmf-brand);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    line-height: 18px;
    text-align: center;
}
.lmf-badge-empty { display: none; }

@media (max-width: 1199.98px) {
    .lmf-navbar .navbar-collapse {
        margin-top: 12px;
        padding-top: 12px;
        border-top: 1px solid var(--lmf-line);
    }
    .lmf-navbar .lmf-nav-secondary > li:last-child > a { margin: 6px 0 0; text-align: center; }
}

/* ---------- Breadcrumb ---------- */

body.lmf .master-breadcrumb { background: transparent; padding: 22px 0 6px; }
body.lmf .master-breadcrumb .breadcrumb { background: none; padding: 0; margin: 0; font-size: 13px; }
body.lmf .master-breadcrumb .breadcrumb-item a { color: var(--lmf-muted); }
body.lmf .master-breadcrumb .breadcrumb-item.active { color: var(--lmf-text); }

/* ---------- Homepage ---------- */

.lmf-hero {
    position: relative;
    overflow: hidden;
    padding: 88px 0 72px;
    background:
        radial-gradient(60% 80% at 100% 0%, rgba(233, 32, 79, .14), transparent 60%),
        radial-gradient(40% 60% at 85% 100%, rgba(233, 32, 79, .08), transparent 70%),
        #fff;
    border-bottom: 1px solid var(--lmf-line);
}
.lmf-hero-inner { max-width: 680px; }
.lmf-hero h1 {
    font-size: clamp(2.1rem, 5vw, 3.4rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -.03em;
    margin-bottom: 18px;
}
.lmf-lead { font-size: 1.1rem; color: var(--lmf-muted); margin-bottom: 28px; max-width: 560px; }
.lmf-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

body.lmf-home #main-body { padding-top: 24px; }
.lmf-section { padding: 48px 0 16px; }
.lmf-section-head { text-align: center; max-width: 640px; margin: 0 auto 32px; }
.lmf-section-head h2 { font-size: 2rem; margin-bottom: 8px; }
.lmf-section-head p { color: var(--lmf-muted); margin: 0; }

.lmf-plan {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    background: var(--lmf-surface);
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
    transition: box-shadow .15s;
}
.lmf-plan:hover { box-shadow: 0 12px 32px rgba(15, 23, 42, .1); }
.lmf-plan h3 { font-size: 1.35rem; margin-bottom: 6px; }
.lmf-plan-tagline { color: var(--lmf-muted); font-size: 14px; min-height: 42px; }
.lmf-plan-price {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--lmf-ink);
    letter-spacing: -.02em;
    margin: 8px 0 24px;
    flex-grow: 1;
}
.lmf-plan-price span { font-size: 15px; font-weight: 500; color: var(--lmf-muted); margin-left: 2px; }
.lmf-plan-featured { border: 2px solid var(--lmf-brand); position: relative; }
.lmf-plan-featured::before {
    content: "Recommended";
    position: absolute;
    top: -13px;
    left: 28px;
    padding: 2px 12px;
    border-radius: 999px;
    background: var(--lmf-brand);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
}

.lmf-domain {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 16px 32px;
    align-items: center;
    padding: 36px;
    background: var(--lmf-ink);
    border-radius: var(--lmf-radius);
    color: #cbd5e1;
}
body.lmf .lmf-domain h2 { color: #fff; font-size: 1.5rem; margin-bottom: 4px; }
.lmf-domain p { margin: 0; color: #94a3b8; }
.lmf-domain-form { display: flex; gap: 8px; }
.lmf-domain-form .form-control {
    flex: 1 1 auto;
    min-width: 0;
    height: 48px;
    border-radius: 999px;
    border: 0;
    padding: 0 20px;
}
.lmf-domain-form .btn { white-space: nowrap; }
.lmf-domain .lmf-link { color: #fda4b8; grid-column: 2; justify-self: end; }
@media (max-width: 991.98px) {
    .lmf-domain { grid-template-columns: 1fr; padding: 24px; }
    .lmf-domain-form { flex-wrap: wrap; }
    .lmf-domain-form .form-control { flex: 1 1 100%; }
    .lmf-domain-form .btn { flex: 1; }
    .lmf-domain .lmf-link { grid-column: 1; justify-self: start; }
}

.lmf-tiles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}
@media (min-width: 768px) { .lmf-tiles { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1200px) { .lmf-tiles { grid-template-columns: repeat(6, 1fr); } }
body.lmf .lmf-tile {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 22px;
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    color: var(--lmf-ink);
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: border-color .15s, box-shadow .15s;
}
body.lmf .lmf-tile i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--lmf-brand-soft);
    color: var(--lmf-brand);
    font-size: 18px;
}
body.lmf .lmf-tile:hover { border-color: var(--lmf-brand); box-shadow: var(--lmf-shadow); color: var(--lmf-ink); }

/* ---------- Client area surfaces ---------- */

body.lmf #main-body { padding-bottom: 48px; }
body.lmf .card,
body.lmf .sidebar .card,
body.lmf .tiles .tile,
body.lmf .client-home-cards .card {
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
}
body.lmf .card-header { background: #fff; border-bottom: 1px solid var(--lmf-line); }
body.lmf .card-header:first-child { border-radius: var(--lmf-radius) var(--lmf-radius) 0 0; }
body.lmf .card-title, body.lmf .card-header h3 { font-weight: 600; font-size: 1rem; }
/* Sidebar cards */
body.lmf .card-sidebar { overflow: hidden; }
body.lmf .card-sidebar .card-header { padding: 14px 18px; }
body.lmf .card-sidebar .card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--lmf-ink);
}
body.lmf .card-sidebar .card-title > i:first-child { color: var(--lmf-brand); width: 16px; text-align: center; }
body.lmf .card-sidebar .card-minimise { margin-left: auto; font-size: 11px; color: var(--lmf-muted); }
body.lmf .sidebar .list-group { padding: 6px; }
body.lmf .sidebar .list-group-item {
    width: auto;
    border: 0;
    border-radius: 8px !important;
    margin: 1px 0;
    padding: 9px 12px;
    font-size: 14px;
    color: var(--lmf-text);
    background: transparent;
}
body.lmf .sidebar .list-group-item i { width: 18px; margin-right: 6px; text-align: center; color: var(--lmf-muted); }
body.lmf .sidebar a.list-group-item:hover { background: var(--lmf-bg); }
body.lmf .sidebar .list-group-item.active,
body.lmf .sidebar .list-group-item.active:hover {
    background: var(--lmf-brand-soft);
    color: var(--lmf-brand-dark);
    font-weight: 600;
}
body.lmf .sidebar .list-group-item.active i { color: var(--lmf-brand); }
body.lmf .sidebar div.list-group-item { color: var(--lmf-muted); font-size: 13px; }
body.lmf .sidebar .list-group-item .badge { background: var(--lmf-bg); color: var(--lmf-text); font-weight: 600; }

body.lmf .tiles .tile { background: #fff; margin: 0; }
body.lmf .tiles .tile i { color: var(--lmf-brand); }
body.lmf .tiles .tile .stat { color: var(--lmf-ink); font-weight: 700; }
body.lmf .tiles .tile .highlight { background: var(--lmf-brand) !important; }

body.lmf .form-control, body.lmf .custom-select {
    border-color: var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    font-family: var(--lmf-font);
}
body.lmf .form-control:focus, body.lmf .custom-select:focus {
    border-color: var(--lmf-brand);
    box-shadow: 0 0 0 .2rem rgba(233, 32, 79, .15);
}
body.lmf .custom-control-input:checked ~ .custom-control-label::before {
    background-color: var(--lmf-brand);
    border-color: var(--lmf-brand);
}

body.lmf .table thead th {
    border-top: 0;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--lmf-muted);
    font-weight: 600;
}
body.lmf .page-item.active .page-link { background: var(--lmf-brand); border-color: var(--lmf-brand); }
body.lmf .page-link { color: var(--lmf-brand); }
body.lmf .nav-tabs .nav-link.active { color: var(--lmf-brand); border-bottom-color: var(--lmf-brand); }
body.lmf .badge-info, body.lmf .badge-primary { background: var(--lmf-brand); }
body.lmf .alert { border-radius: var(--lmf-radius-sm); }

/* Page title (header.tpl) */
.lmf-page-title { font-size: 1.75rem; font-weight: 800; letter-spacing: -.02em; margin: 6px 0 0; }

/* Search inputs: one pill with the button inside */
body.lmf .kb-search,
body.lmf .input-group-lg {
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: 999px;
    padding: 5px;
    box-shadow: var(--lmf-shadow);
    flex-wrap: nowrap;
}
body.lmf .kb-search .form-control,
body.lmf .input-group-lg .form-control {
    border: 0;
    box-shadow: none;
    height: 44px;
    padding: 0 16px;
    font-size: 15px;
    font-weight: 400 !important;
    background: transparent;
}
body.lmf .kb-search .btn,
body.lmf .input-group-lg .input-group-append .btn {
    border-radius: 999px !important;
    padding: 0 22px;
    font-size: 14px;
}
body.lmf .kb-search:focus-within,
body.lmf .input-group-lg:focus-within { border-color: var(--lmf-brand); }

/* Alerts */
body.lmf .alert { border: 1px solid transparent; font-size: 14px; }
body.lmf .alert-info { background: #f1f5f9; border-color: var(--lmf-line); color: var(--lmf-text); }
body.lmf .alert-success { background: #ecfdf3; border-color: #bbf7d0; color: #166534; }
body.lmf .alert-warning { background: #fffbeb; border-color: #fde68a; color: #92400e; }
body.lmf .alert-danger { background: var(--lmf-brand-soft); border-color: #fbc6d3; color: var(--lmf-brand-dark); }
/* Empty-state messages ("No Articles Found", "No Records Found", ...) */
body.lmf .primary-content > .alert-info.text-center {
    padding: 48px 24px;
    background: #fff;
    border: 1px dashed #cbd5e1;
    color: var(--lmf-muted);
}

/* WHMCS licence notice: keep it, but quiet */
body.lmf #main-body .primary-content > p[style="text-align:center;"] {
    margin-top: 40px;
    font-size: 12px;
    color: #94a3b8;
}
body.lmf #main-body .primary-content > p[style="text-align:center;"] a { color: #94a3b8; }

/* Login / register */
body.lmf .login-form, body.lmf .card.mw-540 {
    border-radius: var(--lmf-radius);
}

/* ---------- Standard Cart ---------- */

body.lmf #order-standard_cart .header-lined h1 { font-weight: 800; letter-spacing: -.02em; }
body.lmf #order-standard_cart .header-lined p { color: var(--lmf-muted); }
body.lmf #order-standard_cart .products .product {
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
    padding: 0;
    overflow: hidden;
}
body.lmf #order-standard_cart .products .product header {
    background: #fff;
    border-bottom: 1px solid var(--lmf-line);
    padding: 20px 24px;
}
body.lmf #order-standard_cart .products .product header span { font-size: 1.3rem; font-weight: 700; color: var(--lmf-ink); }
body.lmf #order-standard_cart .products .product div.product-desc { padding: 20px 24px; font-size: 14px; }
body.lmf #order-standard_cart .products .product footer { padding: 20px 24px; }
body.lmf #order-standard_cart .products .product div.product-pricing span.price {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--lmf-ink);
}
body.lmf #order-standard_cart .cart-sidebar .card-header,
body.lmf #order-standard_cart .cart-sidebar .panel-heading { background: #fff; }
body.lmf #order-standard_cart .cart-sidebar .list-group-item.active {
    background: var(--lmf-brand-soft);
    color: var(--lmf-brand-dark);
    border-color: transparent;
}
body.lmf #order-standard_cart .order-summary {
    background: var(--lmf-ink);
    border-radius: var(--lmf-radius);
    border: 0;
}
body.lmf #order-standard_cart .order-summary h2 { color: #fff; }
body.lmf #order-standard_cart .summary-container {
    background: #fff;
    border-radius: 0 0 var(--lmf-radius) var(--lmf-radius);
}
body.lmf #order-standard_cart .total-due-today .amt,
body.lmf #order-standard_cart .order-summary .total-due-today .amt { color: var(--lmf-brand); }
body.lmf #order-standard_cart .sub-heading span,
body.lmf #order-standard_cart .sub-heading-borderless span {
    background: var(--lmf-bg);
    color: var(--lmf-ink);
    font-weight: 600;
}
body.lmf #order-standard_cart .field-container,
body.lmf #order-standard_cart .view-cart-items-header {
    border-radius: var(--lmf-radius-sm);
}
body.lmf #order-standard_cart .view-cart-items-header { background: var(--lmf-ink); }

/* Lamanify cart product cards (orderforms/lamanify_cart/products.tpl) */
body.lmf .lmf-product {
    height: 100%;
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
    overflow: hidden;
}
body.lmf .lmf-product-top { padding: 24px; border-bottom: 1px solid var(--lmf-line); }
body.lmf .lmf-product-top h3 { font-size: 1.35rem; margin-bottom: 12px; }
body.lmf .lmf-product-qty { display: block; font-size: 13px; color: var(--lmf-muted); margin: -8px 0 12px; }
body.lmf .lmf-product-price { margin-bottom: 18px; color: var(--lmf-muted); font-size: 14px; }
body.lmf .lmf-product-price small { display: block; }
body.lmf .lmf-product-price .price {
    font-size: 2rem;
    font-weight: 800;
    color: var(--lmf-ink);
    letter-spacing: -.02em;
    margin-right: 4px;
}
body.lmf .lmf-product-desc {
    padding: 20px 24px 24px;
    font-size: 13.5px;
    line-height: 1.6;
    color: var(--lmf-text);
    overflow-wrap: anywhere;
}
body.lmf .lmf-product-desc > div > b:first-child { display: block; font-size: 15px; color: var(--lmf-ink); margin-bottom: 10px; }
body.lmf .lmf-product-desc p { margin-bottom: 12px; }
body.lmf .lmf-product-desc ul { padding-left: 18px; margin: 0; }
body.lmf .lmf-cart .cart-body { padding-left: 24px; }
@media (max-width: 991.98px) { body.lmf .lmf-cart .cart-body { padding-left: 15px; } }

/* ---------- Footer ---------- */

.lmf-footer {
    background: #fff;
    border-top: 1px solid var(--lmf-line);
    padding: 56px 0 24px;
    font-size: 14px;
}
.lmf-footer-brand img { height: 30px; margin-bottom: 14px; }
.lmf-footer h6 {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--lmf-muted);
    margin-bottom: 14px;
}
.lmf-footer li { margin-bottom: 8px; }
body.lmf .lmf-footer a { color: var(--lmf-text); }
body.lmf .lmf-footer a:hover { color: var(--lmf-brand); text-decoration: none; }
.lmf-footer-bottom {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: space-between;
    align-items: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--lmf-line);
    color: var(--lmf-muted);
    font-size: 13px;
}
body.lmf .lmf-locale { padding: 0; font-weight: 500; color: var(--lmf-muted); }

/* ---------- WHMCS loading overlay ---------- */
/* Twenty-One's "#fullpage-overlay {display: table}" outranks ".w-hidden", so the overlay
   could show on page load. Keep it hidden until WHMCS calls showOverlay() (inline style wins). */
#fullpage-overlay.w-hidden { display: none; }
#fullpage-overlay { z-index: 2000; background: rgba(15, 23, 42, .6); }

/* ---------- Twenty-One navbar auto-collapse ---------- */
/* Twenty-One's autoCollapse("#nav", 30) moves menu items into "More" while #nav is 30px+ tall.
   Our links are ~40px pills, so on desktop pin #nav's box at 28px (links overflow visibly, same look). */
@media (min-width: 1200px) {
    .lmf-navbar #nav { height: 28px; align-items: center; }
}

/* ---------- Homepage: client sign-in (homepage.tpl) ---------- */
body.lmf-home #main-body { padding: 56px 0 72px; }
.lmf-portal {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 56px;
    align-items: start;
}
.lmf-signin h1 { font-size: clamp(1.9rem, 3.4vw, 2.5rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.lmf-signin .lmf-lead { margin-bottom: 24px; }
body.lmf .lmf-signin-card {
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
    padding: 28px;
}
.lmf-signin-card label { font-size: 14px; font-weight: 500; color: var(--lmf-ink); }
.lmf-signin-card .form-control { height: 46px; }
.lmf-signin-card .custom-control-label { font-weight: 400; color: var(--lmf-muted); }
.lmf-signin-note { margin: 18px 0 0; font-size: 14px; color: var(--lmf-muted); }

.lmf-quick h2 { font-size: 1.05rem; font-weight: 700; margin: 6px 0 14px; }
.lmf-quick-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.lmf-help {
    margin-top: 18px;
    padding: 20px 22px;
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
}
.lmf-help h3 { font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--lmf-muted); margin-bottom: 10px; }
.lmf-help ul { list-style: none; padding: 0; margin: 0; }
.lmf-help li { padding: 8px 0; border-top: 1px solid var(--lmf-line); font-size: 14px; }
.lmf-help li:first-child { border-top: 0; padding-top: 0; }
body.lmf .lmf-help a { color: var(--lmf-text); font-weight: 500; }
body.lmf .lmf-help a:hover { color: var(--lmf-brand); text-decoration: none; }

@media (max-width: 991.98px) {
    .lmf-portal { grid-template-columns: minmax(0, 1fr); gap: 36px; }
    body.lmf-home #main-body { padding-top: 32px; }
}
@media (max-width: 575.98px) {
    body.lmf .lmf-signin-card { padding: 20px; }
}

/* ---------- Dashboard: invoice-first (clientareahome.tpl) ---------- */
.lmf-dash { max-width: 760px; margin: 32px auto 24px; }
.lmf-dash-hello { font-size: 1.75rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 20px; }

.lmf-due {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 28px 32px;
    background: var(--lmf-ink);
    border-radius: var(--lmf-radius);
    color: #fff;
}
.lmf-due p { margin: 0; }
.lmf-due-label { font-size: 13px; font-weight: 500; color: #94a3b8; }
.lmf-due-amount { font-size: 2.6rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.15; margin: 4px 0 6px !important; }
.lmf-due-meta { font-size: 14px; color: #cbd5e1; }
.lmf-due-overdue { color: #fda4b8; font-weight: 600; }
.lmf-due .btn-lg { padding: .85rem 2.25rem; white-space: nowrap; }
.lmf-due-clear { background: #fff; border: 1px solid var(--lmf-line); color: var(--lmf-text); }
.lmf-due-clear .lmf-due-label { color: var(--lmf-muted); }
.lmf-due-clear .lmf-due-amount { color: var(--lmf-ink); }
.lmf-due-clear .lmf-due-meta { color: var(--lmf-muted); }
.lmf-due-clear .lmf-due-meta i { color: #16a34a; margin-right: 4px; }

.lmf-list { margin-top: 32px; }
.lmf-list h2 { font-size: 15px; font-weight: 700; margin-bottom: 10px; }
body.lmf .lmf-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    margin-bottom: 8px;
    color: var(--lmf-text);
    text-decoration: none;
    transition: border-color .15s;
}
body.lmf .lmf-row:hover { border-color: var(--lmf-brand); color: var(--lmf-text); }
.lmf-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lmf-row-title { font-weight: 600; color: var(--lmf-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lmf-row-sub { font-size: 13px; color: var(--lmf-muted); margin-top: 2px; }
.lmf-row-amount { font-weight: 700; color: var(--lmf-ink); white-space: nowrap; }
.lmf-row-action {
    padding: 6px 16px;
    border-radius: 999px;
    background: var(--lmf-brand);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
}
.lmf-row-paid .lmf-row-action { background: transparent; color: var(--lmf-muted); padding: 6px 4px; }
.lmf-badge-overdue, .lmf-badge-soon {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}
.lmf-badge-overdue { background: var(--lmf-brand-soft); color: var(--lmf-brand-dark); }
.lmf-badge-soon { background: #fffbeb; color: #92400e; }

.lmf-shortcuts {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--lmf-line);
}
body.lmf .lmf-shortcuts a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 4px;
    border-radius: var(--lmf-radius-sm);
    color: var(--lmf-muted);
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
}
body.lmf .lmf-shortcuts a i { font-size: 18px; }
body.lmf .lmf-shortcuts a:hover { background: #fff; color: var(--lmf-ink); }
.lmf-addon { margin-top: 24px; }

@media (max-width: 575.98px) {
    .lmf-dash { margin-top: 16px; }
    .lmf-due { flex-direction: column; align-items: stretch; padding: 24px; }
    .lmf-due .btn-lg { width: 100%; }
    .lmf-due-amount { font-size: 2.2rem; }
    body.lmf .lmf-row { flex-wrap: wrap; padding: 14px 16px; }
    .lmf-row-main { flex-basis: 100%; }
    .lmf-row-amount { margin-right: auto; }
    .lmf-shortcuts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ---------- Invoice page (viewinvoice.tpl, standalone) and pay-all (masspay.tpl) ---------- */
body.lmf-invoice { background: var(--lmf-bg); }
.lmf-inv-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 680px;
    margin: 0 auto;
    padding: 20px 16px 8px;
}
body.lmf .lmf-inv-back { flex: 1; color: var(--lmf-muted); font-size: 14px; font-weight: 500; }
body.lmf .lmf-inv-back:hover { color: var(--lmf-ink); text-decoration: none; }
.lmf-inv-logo img { height: 28px; width: auto; }
.lmf-inv-top-spacer { flex: 1; }
.lmf-inv { max-width: 680px; margin: 0 auto; padding: 16px 16px 48px; }

.lmf-inv-card {
    background: #fff;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius);
    box-shadow: var(--lmf-shadow);
    padding: 28px 32px;
    margin-bottom: 16px;
}
.lmf-inv-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; }
.lmf-inv-number { font-size: 14px; font-weight: 600; color: var(--lmf-muted); }
.lmf-inv-status {
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    background: var(--lmf-bg);
    color: var(--lmf-muted);
}
.lmf-inv-status-unpaid, .lmf-inv-status-collections { background: var(--lmf-brand-soft); color: var(--lmf-brand-dark); }
.lmf-inv-status-paid, .lmf-inv-status-payment-pending { background: #ecfdf3; color: #166534; }
.lmf-inv-label { margin: 0 0 4px; font-size: 13px; font-weight: 500; color: var(--lmf-muted); }
.lmf-inv-amount { margin: 0; font-size: 2.6rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.15; color: var(--lmf-ink); }
.lmf-inv-meta { margin: 6px 0 0; font-size: 14px; color: var(--lmf-muted); }
.lmf-inv-hint { margin: 10px 0 0; font-size: 13px; color: var(--lmf-muted); line-height: 1.55; }
.lmf-inv-h { font-size: 15px; font-weight: 700; margin-bottom: 12px; }

.lmf-paywith { margin-top: 24px; }
.lmf-paywith-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 6px; }
body.lmf .lmf-paywith-option {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin: 0;
    padding: 14px 16px;
    background: #fff;
    border: 1.5px solid var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    text-align: left;
    font: inherit;
    color: var(--lmf-text);
    cursor: pointer;
}
body.lmf .lmf-paywith-option:hover { border-color: #cbd5e1; }
body.lmf .lmf-paywith-option.is-active { border-color: var(--lmf-brand); background: #fff7f9; }
.lmf-paywith-option input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.lmf-paywith-option i { font-size: 18px; color: var(--lmf-brand); width: 22px; text-align: center; }
.lmf-paywith-option span { display: flex; flex-direction: column; line-height: 1.35; }
.lmf-paywith-option strong { font-size: 14px; color: var(--lmf-ink); }
.lmf-paywith-option small { font-size: 12px; color: var(--lmf-muted); }

.lmf-payaction { margin-top: 18px; }
body.lmf .lmf-paynow { padding: 1rem 1.5rem; font-size: 1.05rem; margin-top: 16px; }
.lmf-payaction .lmf-paynow { margin-top: 0; }
.lmf-paynow i { margin-right: 6px; font-size: .9em; }
.lmf-paybox {
    padding: 16px 18px;
    background: var(--lmf-bg);
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    font-size: 14px;
    line-height: 1.6;
}
.lmf-paybox img { max-width: 100%; }

.lmf-items { list-style: none; padding: 0; margin: 0; }
.lmf-items li {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--lmf-line);
    font-size: 14px;
}
.lmf-items li strong { white-space: nowrap; color: var(--lmf-ink); }
.lmf-items-small li { font-size: 13px; }
.lmf-items small { color: var(--lmf-muted); }
.lmf-totals { margin: 12px 0 0; }
.lmf-totals > div { display: flex; justify-content: space-between; padding: 4px 0; font-size: 14px; color: var(--lmf-muted); }
.lmf-totals dt { font-weight: 400; }
.lmf-totals dd { margin: 0; }
.lmf-totals .lmf-totals-total { color: var(--lmf-ink); font-weight: 700; padding-top: 8px; }
.lmf-totals .lmf-totals-due { color: var(--lmf-brand-dark); font-weight: 700; }

.lmf-inv-details { padding-top: 8px; padding-bottom: 8px; }
.lmf-inv-details details { border-bottom: 1px solid var(--lmf-line); }
.lmf-inv-details details:last-child { border-bottom: 0; }
.lmf-inv-details summary {
    padding: 14px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--lmf-ink);
    cursor: pointer;
    list-style: none;
}
.lmf-inv-details summary::-webkit-details-marker { display: none; }
.lmf-inv-details summary::after { content: "+"; float: right; color: var(--lmf-muted); font-weight: 400; }
.lmf-inv-details details[open] summary::after { content: "\2212"; }
.lmf-details-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 24px; padding-bottom: 16px; font-size: 13px; }
.lmf-details-grid address, .lmf-details-grid p { margin: 0; }
.lmf-inv-actions { display: flex; justify-content: center; gap: 10px; }

.lmf-row-static { cursor: default; }
body.lmf .lmf-row-static:hover { border-color: var(--lmf-line); }

@media (max-width: 575.98px) {
    .lmf-inv-card { padding: 22px 20px; }
    .lmf-inv-amount { font-size: 2.2rem; }
    .lmf-details-grid { grid-template-columns: minmax(0, 1fr); }
    .lmf-inv-back span { display: none; }
}

@media print {
    body.lmf-invoice { background: #fff; }
    .lmf-inv-card { box-shadow: none; border-color: #ddd; }
    .lmf-inv-details details { display: block; }
    .lmf-inv-details details > *:not(summary) { display: block !important; }
}

/* viewinvoice.tpl loads Bootstrap but not Twenty-One's theme.min.css */
body.lmf-invoice a { text-decoration: none; }
body.lmf .lmf-paynow { display: block; width: 100%; text-align: center; }

/* Bank transfer details on the invoice page */
.lmf-bank {
    margin: 0;
    border: 1px solid var(--lmf-line);
    border-radius: var(--lmf-radius-sm);
    overflow: hidden;
}
.lmf-bank > div {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    border-bottom: 1px solid var(--lmf-line);
    font-size: 14px;
}
.lmf-bank > div:last-child { border-bottom: 0; }
.lmf-bank dt { font-weight: 400; color: var(--lmf-muted); }
.lmf-bank dd { display: flex; align-items: center; gap: 10px; margin: 0; font-weight: 600; color: var(--lmf-ink); text-align: right; }
body.lmf .lmf-copy {
    padding: 2px 10px;
    border: 1px solid var(--lmf-line);
    border-radius: 999px;
    background: #fff;
    font-size: 12px;
    font-weight: 600;
    color: var(--lmf-brand);
    cursor: pointer;
}
body.lmf .lmf-copy:hover { border-color: var(--lmf-brand); }
.lmf-steps { margin: 16px 0 0; padding-left: 20px; font-size: 14px; line-height: 1.6; color: var(--lmf-text); }
.lmf-steps li { margin-bottom: 4px; }
@media (max-width: 575.98px) {
    .lmf-bank > div { flex-direction: column; align-items: flex-start; gap: 2px; }
    .lmf-bank dd { text-align: left; }
}

/* Invoice page: what a maintenance package includes, under its line item. */
.lmf-included-label {
    display: block;
    margin: 8px 0 4px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.lmf-items .lmf-included {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 2px 16px;
}
.lmf-items .lmf-included li {
    display: block;
    padding: 0 0 0 18px;
    border: 0;
    position: relative;
    font-size: 13px;
    color: var(--lmf-muted);
}
.lmf-items .lmf-included li::before {
    content: "\2713";
    position: absolute;
    left: 0;
    color: var(--lmf-brand);
    font-weight: 700;
}
.lmf-items .lmf-included-long { grid-template-columns: 1fr; }
