/**
 * RM24 Themes UltraClean for WooCommerce - Karten-Design System
 */

/* -------------------------------------------------------------------------
 * 1. Hauptrahmen & Layout (1500px, 1px Rahmen, 20px Padding)
 * ------------------------------------------------------------------------- */
body {
    background-color: #f8fafc;
    color: #0f2733;
    font-size: 15px;
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.rm24-main-wrapper {
    max-width: 1500px;
    margin: 30px auto;
    background: #ffffff;
    border: 1px solid #dcdfe4;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 16px rgba(15, 39, 51, 0.04);
}

/* -------------------------------------------------------------------------
 * 2. Header & Horizontale Menueleiste
 * ------------------------------------------------------------------------- */
.rm24-site-header {
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 25px;
}

.rm24-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.rm24-site-title {
    font-size: 26px;
    font-weight: 700;
    margin: 0;
}

.rm24-site-title a {
    color: #0f2733;
    text-decoration: none;
}

.rm24-nav-bar {
    background: #2b2e34;
    border-radius: 6px;
    padding: 0 15px;
}

.rm24-nav-bar ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.rm24-nav-bar a {
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 16px;
    display: block;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.15s ease;
}

.rm24-nav-bar a:hover {
    background: #3a3e46;
}

/* -------------------------------------------------------------------------
 * 3. Kategorieseite & Subkategorien
 * ------------------------------------------------------------------------- */
.rm24-subcategories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.rm24-cat-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
    text-align: center;
    text-decoration: none;
    color: #0f2733;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    display: flex;
    flex-direction: column;
}

.rm24-cat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.rm24-cat-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    background: #f1f5f9;
}

.rm24-cat-card-title {
    font-size: 16px;
    font-weight: 700;
    padding: 15px 10px;
    margin: 0;
}

/* -------------------------------------------------------------------------
 * 4. Toolbar & Filterzeile
 * ------------------------------------------------------------------------- */
.rm24-toolbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 25px;
}

.rm24-toolbar-filters {
    display: flex;
    gap: 10px;
}

.rm24-select {
    padding: 8px 12px;
    font-size: 14px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    color: #0f2733;
    background: #fff;
}

.rm24-view-switcher {
    display: flex;
    gap: 6px;
}

.rm24-view-btn {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 6px 12px;
    cursor: pointer;
    font-size: 15px;
}

.rm24-view-btn.rm24-active {
    background: #2b2e34;
    color: #fff;
    border-color: #2b2e34;
}

/* -------------------------------------------------------------------------
 * 5. Produktraster & Produktkarten
 * ------------------------------------------------------------------------- */
ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 20px !important;
    list-style: none !important;
    padding: 0 !important;
    margin: 0 0 30px 0 !important;
}

ul.products.rm24-list-view {
    grid-template-columns: 1fr !important;
}

ul.products.rm24-list-view li.product .rm24-card-inner {
    flex-direction: row;
    align-items: center;
    gap: 25px;
}

ul.products.rm24-list-view li.product .rm24-card-img-link {
    width: 220px;
    flex-shrink: 0;
    margin-bottom: 0;
}

ul.products.rm24-list-view li.product .rm24-card-price-box {
    margin-top: 0;
    border-top: none;
}

li.product {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 0;
    margin: 0 !important;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.rm24-card-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 16px;
}

.rm24-card-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 2;
}

.rm24-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 3px;
    text-transform: uppercase;
}

.rm24-badge-sale { background: #e53e3e; color: #fff; }
.rm24-badge-stock { background: #2f855a; color: #fff; }
.rm24-badge-out { background: #718096; color: #fff; }

.rm24-card-img-link {
    display: block;
    margin-bottom: 12px;
}

.rm24-card-img-link img {
    width: 100%;
    height: 220px;
    object-fit: contain;
}

.rm24-card-title {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 6px 0;
    min-height: 44px;
}

.rm24-card-title a {
    color: #0f2733;
    text-decoration: none;
}

.rm24-card-sku {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 4px;
}

.rm24-card-fees {
    font-size: 12px;
    color: #475569;
    margin-bottom: 10px;
    line-height: 1.4;
}

.rm24-card-price-box {
    margin-top: auto;
    padding: 12px 0;
    border-top: 1px solid #f1f5f9;
}

/* Preis-Strukturierung */
.rm24-price-display {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.rm24-price-main {
    font-size: 19px;
    font-weight: 700;
    color: #0f2733;
}

.rm24-price-main small {
    font-size: 13px;
    font-weight: 500;
    color: #475569;
}

.rm24-price-sub {
    font-size: 13px;
    font-weight: 500;
    color: #64748b;
}

.rm24-price-sub small {
    font-size: 11px;
}

.rm24-price-free {
    color: #15803d;
    font-size: 20px;
    font-weight: 700;
}

.rm24-card-action {
    margin-top: 10px;
}

.rm24-card-action .button,
.single_add_to_cart_button {
    background: #2b2e34 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 4px !important;
    padding: 10px 18px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    text-align: center !important;
    display: inline-block !important;
    width: 100% !important;
    cursor: pointer !important;
    text-decoration: none !important;
    transition: background 0.15s ease !important;
}

.rm24-card-action .button:hover,
.single_add_to_cart_button:hover {
    background: #3a3e46 !important;
}

/* -------------------------------------------------------------------------
 * 6. Einzelprodukt-Seite
 * ------------------------------------------------------------------------- */
.rm24-single-title {
    font-size: 30px;
    font-weight: 700;
    margin: 0 0 20px 0;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 15px;
}

.rm24-single-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 35px;
}

.woocommerce-product-gallery__trigger {
    background: #2b2e34 !important;
    color: #fff !important;
    border-radius: 4px !important;
    width: 36px !important;
    height: 36px !important;
    text-indent: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    right: 15px !important;
    top: 15px !important;
    font-size: 16px !important;
}

.rm24-single-buybox {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.rm24-buybox-row.rm24-price-row {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 15px;
}

.rm24-single-fees {
    font-size: 13px;
    color: #475569;
    background: #f8fafc;
    padding: 10px 14px;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

/* Metadaten & Technische Daten */
.rm24-single-meta-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

.rm24-meta-btn {
    background: #2b2e34;
    color: #ffffff !important;
    border-radius: 4px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
}

.rm24-meta-btn strong {
    color: #cbd5e1;
    margin-right: 4px;
}

.rm24-tipp-box {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-left: 5px solid #2b2e34;
    border-radius: 6px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.02);
}

.rm24-tipp-badge {
    font-size: 16px;
    font-weight: 700;
    color: #0f2733;
    margin-bottom: 8px;
}

.rm24-tipp-content {
    font-size: 15px;
    line-height: 1.6;
    color: #334155;
}

.rm24-tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 15px;
}

.rm24-tech-badge {
    background: #2b2e34;
    color: #ffffff;
    border-radius: 4px;
    padding: 12px 16px;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
}

.rm24-tech-label {
    font-weight: 600;
    color: #cbd5e1;
}

.rm24-tech-val {
    font-weight: 700;
    color: #ffffff;
}

/* -------------------------------------------------------------------------
 * 7. Footer mit bis zu 5 Spalten im Karten-Design
 * ------------------------------------------------------------------------- */
.rm24-footer-widgets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 30px;
    border-top: 1px solid #e2e8f0;
    padding-top: 30px;
}

.rm24-footer-widget {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 20px;
}

.rm24-widget-title {
    font-size: 16px;
    font-weight: 700;
    color: #0f2733;
    margin: 0 0 12px 0;
    border-bottom: 2px solid #2b2e34;
    padding-bottom: 6px;
}

.rm24-footer-bottom {
    text-align: center;
    padding-top: 25px;
    font-size: 13px;
    color: #64748b;
}

/* Responsive */
@media (max-width: 992px) {
    .rm24-subcategories-grid, ul.products { grid-template-columns: repeat(2, 1fr) !important; }
    .rm24-single-grid { grid-template-columns: 1fr; }
}

@media (max-width: 576px) {
    ul.products { grid-template-columns: 1fr !important; }
    .rm24-toolbar-container { flex-direction: column; }
}