/* ============================================================
   Microsoft Shop – frontend stijlen
   ============================================================ */

/* --- Login pagina --- */
#ms-login-wrap {
    max-width: 480px;
    margin: 0 auto;
}
#ms-login-tabs .nav-link {
    color: var(--themePrimary);
    font-weight: 600;
}
#ms-login-tabs .nav-link.active {
    color: var(--themePrimary);
    border-bottom-color: transparent;
}

.ms-login-welkom {
    max-width: 480px;
    margin: 0 auto;
}

/* --- Topbalk shop --- */
.ms-shop-topbar {
    background: #fff;
    border-radius: var(--themeBorderRadius, .5rem);
    padding: .75rem 1rem;
    box-shadow: 0 1px 20px rgb(0 0 0 / 4%);
}
.ms-cat-select {
    min-width: 180px;
    max-width: 220px;
}
.ms-cart-btn {
    white-space: nowrap;
    position: relative;
}
.ms-cart-badge {
    position: absolute !important;
    top: -6px;
    right: -8px;
    font-size: .65rem;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    aspect-ratio: 1;
}

.searchInput{
    width:auto !important;
}

/* --- Product kaart --- */
.ms-producten-grid {
    --columns: 3;
}
.ms-product-card {
    display: flex;
    flex-direction: column;
    background-color: #f9f7f3;
    border-radius: 15px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform .2s ease, box-shadow .2s ease;
    box-shadow: 0 1px 20px rgb(0 0 0 / 4%);
}
.ms-product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 28px rgba(0,0,0,.10);
    text-decoration: none;
    color: inherit;
}

/* Afbeelding */
.ms-product-card-img {
    width: 100%;
    aspect-ratio: 3/2;
    background-color: #e8e3de;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    flex: none;
}
.ms-product-card-no-img {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #bbb;
    font-size: 2.5rem;
}
.ms-detail-no-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #ccc;
    font-size: 5rem;
}

/* Content */
.ms-product-card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 0 1rem 1rem;
    width: 100%;
}

/* Pill-details: categorie + prijs */
.ms-product-card-details {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: .6rem 0 .5rem;
}
.ms-product-card-details span {
    display: inline-flex;
    align-items: center;
    background: #fff;
    color: var(--themePrimary, #144734);
    padding: 0 14px;
    height: 34px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
}
.ms-product-card-prijs {
    font-weight: 700 !important;
    color: var(--themePrimary2, #629931) !important;
}

/* Titel */
.ms-product-card-naam {
    font-size: 18px;
    font-weight: 300;
    color: var(--themePrimaryDark, #144734);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0 0 .25rem;
}

/* Omschrijving */
.ms-product-card-omschrijving p {
    font-size: 15px;
    color: #666;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: .25rem 0 .75rem;
}

/* Footer: aantal + knop */
.ms-product-card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: .5rem;
    justify-content: space-between;
}
.ms-product-card-footer .ms-product-aantal {
    width: 58px;
    height: 42px;
    border: 1px solid #ccc;
    border-radius: 8px;
    text-align: center;
    font-size: 15px;
    padding: 0 6px;
    background: #fff;
}

/* --- Winkelwagen tabel --- */
.ms-cart-table td,
.ms-cart-table th {
    vertical-align: middle;
}
.ms-cart-table .ms-cart-qty {
    min-width: 30px;
    display: inline-block;
    text-align: center;
}

/* --- Checkout samenvatting --- */
.ms-checkout-summary hr {
    margin: .5rem 0;
}

/* --- Bestelling bevestiging --- */
.ms-order-confirm-icon .fa {
    color: var(--themePrimary2, #629931);
}

/* --- Login notice --- */
.ms-login-notice {
    background: var(--themeBg, #F7F2EE);
    border-radius: var(--themeBorderRadius, .5rem);
    padding: 3rem 2rem;
}

/* --- Geen resultaten --- */
.ms-no-results {
    background: var(--themeBg, #F7F2EE);
    border-radius: var(--themeBorderRadius, .5rem);
    padding: 3rem;
}

/* --- Formulier feedback --- */
.ms-form-messages .alert {
    margin-top: .5rem;
    margin-bottom: 0;
}

/* --- Toast notificatie (aan winkelwagen toegevoegd) --- */
.ms-toast {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 9999;
    min-width: 260px;
    animation: msToastIn .25s ease;
}
@keyframes msToastIn {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* --- Categorie sidebar --- */
.ms-cat-sidebar {
    background: #fff;
    border-radius: var(--themeBorderRadius, .5rem);
    /* border: 1px solid rgba(0,0,0,.08); */
    padding: 1rem 0;
    position: sticky;
    top: 1rem;
    box-shadow: 0 1px 20px rgb(0 0 0 / 4%);
}
.ms-cat-sidebar-title {
    font-weight: 700;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #999;
    padding: 0 1rem .6rem;
    border-bottom: 1px solid rgba(0,0,0,.07);
    margin-bottom: .4rem;
}
.ms-cat-all {
    display: block;
    padding: .35rem 1rem;
    color: #444;
    font-size: .9rem;
    border-left: 3px solid transparent;
    cursor: pointer;
    user-select: none;
}
.ms-cat-all:hover,
.ms-cat-all.active {
    color: var(--themePrimary, #144734);
    border-left-color: var(--themePrimary, #144734);
    background: rgba(0,0,0,.03);
}

/* Category tree */
.ms-cat-tree,
.ms-cat-tree ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.ms-cat-tree-root {
    padding-top: .25rem;
}
.ms-cat-item {
    position: relative;
}
.ms-cat-item .ms-cat-toggle i.fa {
    color: #000;
}
.ms-cat-link {
    display: flex;
    align-items: center;
    gap: .4rem;
    padding: .35rem 1rem .35rem 1rem;
    color: #444;
    font-size: .9rem;
    border-left: 3px solid transparent;
    transition: background .1s, color .1s;
    line-height: 1.3;
    cursor: pointer;
    user-select: none;
}
.ms-cat-item.has-children > .ms-cat-link {
    padding-right: 2rem;
}
.ms-cat-link:hover {
    color: var(--themePrimary, #144734);
    background: rgba(0,0,0,.03);
}
.ms-cat-link.active {
    color: var(--themePrimary, #144734);
    font-weight: 700;
    border-left-color: var(--themePrimary, #144734);
    background: rgba(0,0,0,.04);
}

/* Vinkje */
.ms-cat-check {
    width: 16px;
    height: 16px;
    border: 1.5px solid #ccc;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: .6rem;
    color: transparent;
    background: #fff;
    transition: background .15s, border-color .15s, color .15s;
}
.ms-cat-link.active .ms-cat-check {
    background: var(--themePrimary, #144734);
    border-color: var(--themePrimary, #144734);
    color: #fff;
}

/* Toggle knop */
.ms-cat-toggle {
    position: absolute;
    right: .75rem;
    top: .35rem;
    width: 1.2rem;
    height: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #aaa;
    font-size: .65rem;
    transition: transform .2s;
    z-index: 1;
}
.ms-cat-item.open > .ms-cat-toggle {
    transform: rotate(90deg);
}

/* Geneste lijsten: standaard ingeklapt */
.ms-cat-item > ul {
    display: none;
    padding-left: .75rem;
}
.ms-cat-item.open > ul {
    display: block;
}

/* Diepere niveaus iets kleiner */
.ms-cat-tree .ms-cat-tree .ms-cat-link {
    font-size: .85rem;
    color: #666;
}
.ms-cat-tree .ms-cat-tree .ms-cat-tree .ms-cat-link {
    font-size: .82rem;
}

/* --- Responsive aanpassingen --- */
@media (max-width: 991.98px) {
    .ms-product-card-naam { font-size: 16px; }
}
@media (max-width: 767.98px) {
    .ms-cat-sidebar { position: static; }
}
@media (max-width: 575.98px) {
    .ms-shop-topbar {
        flex-direction: column;
        align-items: stretch !important;
    }
}

/* --- Account pagina --- */
#ms-account-tabs .nav-link {
    color: var(--themePrimary, #144734);
    font-weight: 500;
}
#ms-account-tabs .nav-link.active {
    color: var(--themePrimary, #144734);
    border-bottom-color: #fff;
    font-weight: 700;
}
#ms-account-tabs .nav-link:hover:not(.active) {
    background: rgba(20,71,52,.05);
}

/* Bestellingen tabel */
.ms-bestellingen-table thead tr {
    background: var(--themePrimary, #144734);
    color: #fff;
}
.ms-bestellingen-table thead th {
    font-weight: 600;
    font-size: .85rem;
    letter-spacing: .03em;
    padding: .75rem 1rem;
    border: none;
}
.ms-bestellingen-table tbody td {
    padding: .85rem 1rem;
    border-bottom: 1px solid #f0ebe6;
    font-size: .92rem;
    color: #333;
}
.ms-bestelling-row {
    cursor: pointer;
    transition: background .12s;
}
.ms-bestelling-row:hover {
    background: var(--themeBg, #F7F2EE);
}
.ms-bestelling-row:last-child td {
    border-bottom: none;
}
.ms-order-nr {
    font-weight: 700;
    color: var(--themePrimary, #144734);
}
.ms-row-arrow {
    text-align: right;
    color: #bbb;
    width: 32px;
}
.ms-bestelling-row:hover .ms-row-arrow {
    color: var(--themePrimary2, #629931);
}

/* Status badges */
.ms-status-badge {
    display: inline-block;
    padding: .2em .65em;
    border-radius: 99px;
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .02em;
}
.ms-status-done {
    background: #e6f4ec;
    color: #1a6b38;
}
.ms-status-open {
    background: #fef3e2;
    color: #a05c00;
}