/*
 * ChamaeleonStyle V5 – Cart & checkout
 * =====================================
 * Visual model: one continuous checkout flow. Cart -> address -> payment.
 * Existing PHP/order logic remains unchanged.
 */
.cs-checkout-wrapper {
    width: 100%;
    max-width: 1480px;
    margin: 0 auto;
    padding: 0;
    color: var(--cs-text);
}

.cs-checkout-progress {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin: 0 0 32px;
    border-top: 1px solid var(--cs-border-dark);
    border-bottom: 1px solid var(--cs-border-dark);
}

.cs-checkout-progress span {
    padding: 11px 12px;
    color: var(--cs-muted);
    border-right: 1px solid var(--cs-border);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cs-checkout-progress span:last-child {
    border-right: 0;
}

.cs-checkout-progress .is-active {
    color: var(--cs-red);
}

.cs-checkout-order-summary {
    margin: 24px 0 34px;
    padding: 0;
    border-top: 3px solid var(--cs-black);
}

.cs-checkout-order-summary > h2,
.cs-checkout-order-summary > .cs-card-title {
    margin: 0;
    padding: 18px 0 12px;
}

/* Old cart table output from show_cartnormal(). */
.cs-checkout-order-summary table,
.cs-cart-table-wrapper table {
    width: 100% !important;
    background: #fff;
    border-top: 1px solid var(--cs-border);
}

.cs-checkout-order-summary td,
.cs-checkout-order-summary th,
.cs-cart-table-wrapper td,
.cs-cart-table-wrapper th {
    padding: 12px 10px !important;
    border-bottom: 1px solid var(--cs-border) !important;
    vertical-align: middle;
}

.cs-checkout-order-summary img,
.cs-cart-table-wrapper img {
    max-width: 90px;
    max-height: 100px;
    object-fit: contain;
}

.cs-checkout-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(340px, 0.8fr);
    gap: clamp(34px, 5vw, 80px);
    align-items: start;
}

.cs-checkout-main,
.cs-checkout-side {
    min-width: 0;
}

.cs-checkout-side {
    position: sticky;
    top: 18px;
}

.cs-checkout-section {
    margin: 0 0 32px;
    padding: 0 0 30px;
    border-bottom: 1px solid var(--cs-border);
}

.cs-checkout-section__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 16px;
}

.cs-checkout-section__head h2 {
    margin: 0;
    font-size: 22px;
}

.cs-checkout-section__head span {
    color: var(--cs-muted);
    font-size: 12px;
}

.cs-option-list {
    display: grid;
    gap: 1px;
    background: var(--cs-border);
    border: 1px solid var(--cs-border);
}

.cs-option-link {
    display: flex;
    min-height: 54px;
    padding: 12px 14px;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #fff;
    color: var(--cs-text);
    border: 0;
    border-left: 4px solid transparent;
    border-radius: 0;
    box-shadow: none;
    font-size: 14px;
}

.cs-option-link:hover {
    color: var(--cs-black);
    background: var(--cs-surface-soft);
    border-left-color: var(--cs-border-dark);
}

.cs-option-link.cs-option-active {
    background: #fff;
    border-left-color: var(--cs-red);
    font-weight: 800;
}

.cs-option-price {
    white-space: nowrap;
    font-weight: 800;
}

.cs-payment-info,
.cs-address-block,
.cs-legal,
.cs-details-content {
    font-size: 14px;
    line-height: 1.65;
}

.cs-checkout-side .cs-card,
.cs-checkout-main .cs-card {
    margin-bottom: 1px;
    border-radius: 0;
    box-shadow: none;
}

.cs-buy-button {
    display: flex;
    width: 100%;
    min-height: 56px;
    margin-top: 16px;
    font-size: 15px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.cs-address-change-link a {
    display: inline-block;
    margin-top: 10px;
    color: var(--cs-red);
    border-bottom: 1px solid var(--cs-red);
    font-size: 13px;
    font-weight: 700;
}

.cs-login-toggle {
    margin: 0 0 16px;
}

.cs-login-box {
    margin: 0 0 28px;
    padding: 22px;
    background: var(--cs-surface-soft);
    border-top: 3px solid var(--cs-black);
}

#loginForm:not(.cs-open) {
    display: none;
}

.cs-form-row {
    margin-bottom: 14px;
}

.cs-warranty-notice {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 18px;
    margin: 22px 0;
    padding: 18px;
    align-items: center;
    background: var(--cs-surface-soft);
    border: 1px solid var(--cs-border);
    border-left: 3px solid var(--cs-red);
}

.cs-warranty-image {
    display: block;
    max-width: 150px;
    max-height: 130px;
    margin: auto;
}

.cs-warranty-copy {
    color: #4f5459;
    font-size: 12px;
    line-height: 1.55;
}

.cs-warranty-copy strong {
    display: block;
    margin-bottom: 5px;
    color: var(--cs-black);
    font-size: 15px;
}

.cs-warranty-copy a {
    color: var(--cs-red);
    font-weight: 700;
}

details.cs-details {
    border-top: 1px solid var(--cs-border);
}

details.cs-details summary {
    padding: 14px 0;
    cursor: pointer;
    color: var(--cs-black);
    font-size: 13px;
    font-weight: 800;
}

/* Address form helpers used by includes/login.php. */
.cs-field {
    position: relative;
    padding: 18px;
    background: #fff;
}

.cs-field input,
.cs-field select,
.cs-field textarea {
    margin-top: 18px;
}

.cs-field label {
    position: absolute;
    top: 12px;
    left: 18px;
    color: var(--cs-muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.cs-btn-full {
    width: 100%;
}

.cs-small-note {
    margin-top: 12px;
    color: var(--cs-muted);
    font-size: 11px;
    line-height: 1.6;
}

.cs-login-error {
    margin-top: 8px;
    color: var(--cs-red);
    font-size: 12px;
    font-weight: 700;
}

/* Legacy cart table (.wk) modernized without touching price/order logic. */
table.wk {
    width: 100% !important;
    border-top: 1px solid var(--cs-border);
    background: #fff;
}

table.wk tr.carttop {
    background: var(--cs-surface-soft);
}

table.wk td,
table.wk th {
    padding: 12px 10px !important;
    border-bottom: 1px solid var(--cs-border) !important;
    color: var(--cs-text);
    vertical-align: middle !important;
}

table.wk td:first-child {
    width: 110px;
}

table.wk img {
    max-width: 88px;
    max-height: 105px;
    object-fit: contain;
}

table.wk input[type="text"] {
    width: 64px;
    min-height: 38px;
    text-align: center;
}

table.wk .text-preis {
    color: var(--cs-black);
}

/* Compact filter / pagination controls in category lists. */
.txt-middle-blk {
    display: inline-flex;
    max-width: 100%;
    margin: 10px 0 18px;
    float: none !important;
    align-items: center;
    gap: 6px;
}

.css-radiobox {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.css-label {
    display: inline-flex;
    min-width: 34px;
    min-height: 34px;
    padding: 5px 9px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--cs-border-dark);
    background: #fff;
    font-size: 12px;
    cursor: pointer;
}

.css-radiobox:checked + .css-label,
.css-label:hover {
    background: var(--cs-black);
    border-color: var(--cs-black);
    color: #fff;
}
