/* ========== GLOBALS ========== */

/* Theme-Farben (werden dynamisch via Twig überschrieben falls nötig) */
:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --font-family-base: "Roboto", Arial, sans-serif;
}

/* Allgemeine Schriftart */
body {
    font-family: var(--font-family-base);
}

/* Buttons ein wenig smoother */
.btn {
    border-radius: 6px;
}

/* Tabellen im Admin kompakter */
.table-sm td, 
.table-sm th {
    padding: 4px 6px;
}

/* Hover für Tabellenreihen */
.table-hover tbody tr:hover {
    background-color: rgba(0,0,0,0.04);
}

/* ========== ADMIN AUTOSIZE HIGHLIGHT ========== */
.autosize-textarea.autosize-active {
    z-index: 10;
    position: relative;
    background: #fff;
    box-shadow: 0 0 12px rgba(0,0,0,.2);
}

/* Damit der aufpoppende Textbereich nicht springt */
.autosize-textarea {
    transition: box-shadow 0.2s ease;
}


/* ========== KLEINE NICE-TO-HAVES ========== */

/* Input-Felder schöner */
.form-control-sm {
    border-radius: 4px;
}

/* Checkbox zentriert */
.form-check-input {
    margin-top: 0.4rem;
}

/* Abstand zwischen Admin-Header & Inhalt */
.admin-header-space {
    margin-bottom: 1.2rem;
}

/* Badge Farben etwas modernisiert */
.badge.bg-warning {
    color: #664d03 !important;
}

/* JSON-Status im Admin */
.json-status {
    font-size: 11px;
    margin-top: 2px;
}

.json-status-ok {
    color: #198754; /* Bootstrap success */
}

.json-status-error {
    color: #dc3545; /* Bootstrap danger */
}

.json-border-ok {
    border-color: #198754 !important;
}

.json-border-error {
    border-color: #dc3545 !important;
}

/* Dropdown-Menü für Kategorien im Frontend */
.category-dropdown-menu a {
    text-decoration: none;
}

.category-dropdown-menu a:hover {
    text-decoration: underline;
}

.mega-dropdown-menu {
    max-height: 400px;
    overflow-y: auto;
}

.mega-dropdown-menu .dropdown-item.active {
    background-color: #0d6efd;
    color: #fff;
}


/* Produktbilder Frontend */
.product-main-image {
    max-width: 100%;
    max-height: 420px;
    object-fit: contain;
}

.product-thumb {
    width: 64px;
    height: 64px;
    object-fit: cover;
    cursor: pointer;
    border-radius: 4px;
}

/* Lightbox für Produktbilder */
.image-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1050;
}

.image-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.7);
}

.image-lightbox-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-lightbox-img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    background: #000;
}

.image-lightbox-close {
    position: absolute;
    top: -10px;
    right: -10px;
    border: none;
    background: #fff;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 20px;
    line-height: 28px;
    cursor: pointer;
}

.image-lightbox-prev,
.image-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: rgba(0,0,0,0.5);
    color: #fff;
    width: 36px;
    height: 60px;
    cursor: pointer;
    font-size: 22px;
}

.image-lightbox-prev {
    left: -45px;
}

.image-lightbox-next {
    right: -45px;
}
