/* Styly pro admin rozhraní */
.image-card {
    position: relative;
    height: 100%;
}

.image-container {
    position: relative;
    width: 100%;
    height: 150px;
    overflow: hidden;
    background-color: #f8f9fa;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Styly pro modální okna */
.modal-dialog.modal-lg {
    max-width: 800px;
}

/* Styly pro formuláře */
.form-label {
    font-weight: 500;
}

/* Styly pro tabulky */
.table th {
    background-color: #f8f9fa;
}

/* Styly pro tlačítka */
.btn-group-sm .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Styly pro karty */
.card {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid rgba(0,0,0,0.125);
}

/* Styly pro náhledy obrázků */
.img-thumbnail {
    max-height: 150px;
    object-fit: contain;
}

/* Styly pro zprávy */
.alert {
    margin-bottom: 1rem;
}

/* Styly pro přepínače */
.form-check-input:checked {
    background-color: #198754;
    border-color: #198754;
}

/* Styly pro administrační rozhraní */

/* Základní styly pro taby */
.admin-container .nav-tabs {
    border-bottom: 1px solid #dee2e6;
    margin-bottom: 1.5rem;
}

.admin-container .nav-tabs .nav-link {
    color: #212529 !important;
    font-weight: 500;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 0.75rem 1.25rem;
    margin-bottom: 0;
    transition: all 0.2s ease-in-out;
}

.admin-container .nav-tabs .nav-link:hover {
    color: #0056b3 !important;
    border-bottom: 2px solid #0056b3;
    background-color: rgba(0, 86, 179, 0.05);
}

.admin-container .nav-tabs .nav-link.active {
    color: #0056b3 !important;
    background-color: transparent;
    border-bottom: 2px solid #0056b3;
    font-weight: 600;
}

/* Obsah tabů */
.admin-container .tab-content {
    padding: 1.5rem 0;
}

.admin-container .tab-pane {
    animation: fadeIn 0.3s ease-in-out;
}

/* Animace pro přechod mezi taby */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responzivní úpravy */
@media (max-width: 768px) {
    .admin-container .nav-tabs .nav-link {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

/* Obecné styly pro administrační rozhraní */
.admin-container {
    color: #212529;
}

.admin-container h1, 
.admin-container h2, 
.admin-container h3, 
.admin-container h4, 
.admin-container h5, 
.admin-container h6 {
    color: #212529;
}

.admin-container p, 
.admin-container li, 
.admin-container td, 
.admin-container th {
    color: #212529;
}

/* Styly pro formuláře */
.admin-container .form-label {
    color: #212529;
    font-weight: 500;
}

.admin-container .form-control {
    color: #212529;
}

.admin-container .form-control::placeholder {
    color: #6c757d;
}

/* Styly pro tlačítka */
.admin-container .btn-primary {
    color: #fff;
    background-color: #0056b3;
    border-color: #0056b3;
}

.admin-container .btn-secondary {
    color: #fff;
    background-color: #6c757d;
    border-color: #6c757d;
}

.admin-container .btn-outline-primary {
    color: #0056b3;
    border-color: #0056b3;
}

.admin-container .btn-outline-secondary {
    color: #6c757d;
    border-color: #6c757d;
}

.menu-icon-picker {
    width: 100%;
}

.menu-icon-picker__toggle {
    display: inline-flex;
    width: 100%;
    align-items: center;
    justify-content: flex-start;
    gap: 0.65rem;
    min-height: 2.375rem;
    text-align: left;
}

.menu-icon-picker__preview {
    display: inline-grid;
    flex: 0 0 1.5rem;
    place-items: center;
    width: 1.5rem;
    height: 1.5rem;
    color: #212529;
}

.menu-icon-picker__label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.menu-icon-picker__menu {
    width: min(22rem, calc(100vw - 2rem));
    max-height: 17rem;
    overflow-y: auto;
    padding: 0.6rem;
}

.menu-icon-picker__search {
    margin-bottom: 0.5rem;
}

.menu-icon-picker__options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(2.4rem, 1fr));
    gap: 0.3rem;
}

.menu-icon-picker__option {
    display: grid;
    place-items: center;
    width: 2.4rem;
    height: 2.4rem;
    margin: 0;
    border: 1px solid #dee2e6;
    border-radius: 0.35rem;
    background: #ffffff;
    color: #212529;
    line-height: 1;
    vertical-align: top;
}

.menu-icon-picker__option i {
    display: block;
    width: 1.25em;
    line-height: 1;
    text-align: center;
}

.menu-icon-picker__option:hover,
.menu-icon-picker__option:focus {
    border-color: #0d6efd;
    color: #0d6efd;
    box-shadow: 0 0 0 0.16rem rgba(13, 110, 253, 0.14);
}

.menu-icon-picker__option--selected {
    border-color: #0d6efd;
    background: #e7f1ff;
    color: #0d6efd;
}

.menu-icon-picker__empty-mark {
    font-weight: 700;
    line-height: 1;
}

.menu-icon-picker__empty-results {
    padding: 0.45rem 0.25rem 0;
    color: #6c757d;
    font-size: 0.875rem;
}

.carousel-menu-picker {
    width: 100%;
}

.carousel-menu-picker__toggle {
    display: flex;
    width: 100%;
    min-height: 2.375rem;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
}

.carousel-menu-picker__menu {
    width: min(30rem, calc(100vw - 2rem));
    max-height: 20rem;
    overflow-y: auto;
    padding: 0.4rem;
}

.carousel-menu-picker__option {
    display: grid;
    grid-template-columns: calc(var(--menu-depth, 0) * 1.25rem) 1.35rem minmax(0, 1fr) auto;
    width: 100%;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.55rem;
    border: 0;
    border-radius: 0.35rem;
    background: transparent;
    color: #212529;
    text-align: left;
}

.carousel-menu-picker__option:hover,
.carousel-menu-picker__option:focus {
    background: #e7f1ff;
    color: #0d6efd;
}

.carousel-menu-picker__option--selected {
    background: #e7f1ff;
    color: #0d6efd;
    font-weight: 600;
}

.carousel-menu-picker__option--disabled {
    color: #6c757d;
    font-weight: 600;
    opacity: 0.78;
}

.carousel-menu-picker__option--disabled:hover,
.carousel-menu-picker__option--disabled:focus {
    background: transparent;
    color: #6c757d;
}

.carousel-menu-picker__icon {
    display: inline-grid;
    place-items: center;
    width: 1.35rem;
    text-align: center;
}

.carousel-menu-picker__text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.carousel-menu-picker__type {
    color: #6c757d;
    font-size: 0.75rem;
}

.carousel-menu-picker__empty {
    padding: 0.55rem;
    color: #6c757d;
}

.page-block-editor__stack {
    display: grid;
    gap: 0.75rem;
}

.markdown-block-editor {
    margin-bottom: 1rem;
}

.markdown-block-editor__tabs {
    margin-bottom: 0;
    border-bottom: 1px solid #dee2e6;
}

.markdown-block-editor__tabs .nav-link {
    color: #212529 !important;
    padding: 0.75rem 1.25rem !important;
    border: 0;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: transparent;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.markdown-block-editor__tabs .nav-link:hover,
.markdown-block-editor__tabs .nav-link:focus {
    color: #0056b3 !important;
    border-bottom-color: #0056b3;
    background-color: rgba(0, 86, 179, 0.05);
}

.markdown-block-editor__tabs .nav-link.active {
    color: #0056b3 !important;
    border-bottom-color: #0056b3;
    background: transparent;
    font-weight: 600;
}

.markdown-block-editor__content {
    padding: 0.85rem;
    border: 1px solid #dee2e6;
    border-top: 0;
    border-radius: 0 0 0.45rem 0.45rem;
    background: #ffffff;
}

.markdown-block-editor__preview {
    min-height: 14rem;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    background: #ffffff;
    outline: 0;
}

.markdown-block-editor__preview:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.markdown-block-editor__preview > :last-child {
    margin-bottom: 0;
}

.markdown-block-editor [data-markdown-raw-pane] label.form-label {
    display: none;
}

.carousel-image-picker {
    width: 100%;
}

.carousel-image-picker__toggle {
    display: flex;
    width: 100%;
    min-height: 3.75rem;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    text-align: left;
}

.carousel-image-picker__preview {
    display: grid;
    flex: 0 0 4rem;
    place-items: center;
    width: 4rem;
    height: 2.6rem;
    overflow: hidden;
    border-radius: 0.35rem;
    background: #f8f9fa;
}

.carousel-image-picker__preview:empty::before {
    content: "";
    display: block;
    width: 1.75rem;
    height: 1.75rem;
    border: 1px dashed #adb5bd;
    border-radius: 0.35rem;
}

.carousel-image-picker__preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-image-picker__menu {
    width: min(34rem, calc(100vw - 2rem));
    max-height: 22rem;
    overflow-y: auto;
    padding: 0.6rem;
}

.carousel-image-picker__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr));
    gap: 0.55rem;
}

.carousel-image-picker__item {
    position: relative;
    display: block;
    width: 100%;
    padding: 0.35rem;
    border: 1px solid #dee2e6;
    border-radius: 0.4rem;
    background: #ffffff;
}

.carousel-image-picker__item:hover,
.carousel-image-picker__item:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.16rem rgba(13, 110, 253, 0.14);
}

.carousel-image-picker__item--selected {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.16rem rgba(13, 110, 253, 0.16);
}

.carousel-image-picker__thumb {
    display: block;
    overflow: hidden;
    border-radius: 0.3rem;
    background: #f8f9fa;
}

.carousel-image-picker__thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.carousel-image-picker__check {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    display: none;
    place-items: center;
    width: 1.7rem;
    height: 1.7rem;
    border-radius: 50%;
    background: #198754;
    color: #ffffff;
}

.carousel-image-picker__item--selected .carousel-image-picker__check {
    display: grid;
}

.carousel-image-picker__empty {
    padding: 0.55rem;
    color: #6c757d;
}

.carousel-language-sections {
    display: grid;
    gap: 1.25rem;
}

.carousel-language-section__title {
    margin-bottom: 0.5rem;
    color: #212529;
    font-weight: 600;
}

.game-mode-app-sections {
    display: grid;
    gap: 1.25rem;
}

.game-mode-app-section__title {
    margin-bottom: 0.5rem;
    color: #212529;
    font-weight: 600;
}

.admin-game-mode-table {
    margin-bottom: 0;
}

.admin-game-mode-table__drag-cell {
    width: 2.5rem;
    text-align: center;
    vertical-align: middle;
}

.admin-game-mode-table__drag-handle {
    color: #6c757d;
    cursor: grab;
}

.admin-game-mode-table tr[draggable="true"]:active .admin-game-mode-table__drag-handle {
    cursor: grabbing;
}

.admin-game-mode-table__row--dragging {
    opacity: 0.45;
}

.admin-game-mode-table__row--drop-before {
    border-top: 3px solid #0d6efd;
}

.admin-game-mode-table__row--drop-after {
    border-bottom: 3px solid #0d6efd;
}

.admin-carousel-table {
    margin-bottom: 0;
}

.admin-carousel-table__drag-cell {
    width: 2.5rem;
    text-align: center;
    vertical-align: middle;
}

.admin-carousel-table__drag-handle {
    color: #6c757d;
    cursor: grab;
}

.admin-carousel-table tr[draggable="true"]:active .admin-carousel-table__drag-handle {
    cursor: grabbing;
}

.admin-carousel-table__row--dragging {
    opacity: 0.45;
}

.admin-carousel-table__row--drop-before {
    border-top: 3px solid #0d6efd;
}

.admin-carousel-table__row--drop-after {
    border-bottom: 3px solid #0d6efd;
}

.admin-carousel-table__image {
    max-width: 100px;
}

/* Styly pro tabulky */
.admin-container .table {
    color: #212529;
}

.admin-container .table th {
    background-color: #f8f9fa;
    color: #212529;
}

.admin-container .table td {
    color: #212529;
}

.admin-container .table .btn.btn-sm {
    display: inline-flex;
    box-sizing: border-box;
    height: 1.9375rem;
    min-height: 1.9375rem;
    padding: 0.25rem 0.5rem;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    line-height: 1.2;
    vertical-align: middle;
}

.admin-container .table .btn.btn-sm:hover {
    transform: none;
}

.admin-games-table__actions-header,
.admin-games-table__actions {
    width: 1%;
    min-width: max-content;
    white-space: nowrap;
}

.admin-games-table__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.admin-games-table__drag-cell {
    width: 2.5rem;
    text-align: center;
    vertical-align: middle;
}

.admin-games-table__drag-handle {
    color: #6c757d;
    cursor: grab;
}

.admin-games-table tr[draggable="true"]:active .admin-games-table__drag-handle {
    cursor: grabbing;
}

.admin-games-table__row--dragging {
    opacity: 0.45;
}

.admin-games-table__row--drop-before {
    border-top: 3px solid #0d6efd;
}

.admin-games-table__row--drop-after {
    border-bottom: 3px solid #0d6efd;
}

.game-blocks-table {
    table-layout: auto;
}

.game-blocks-table__name {
    min-width: 16rem;
    width: 34%;
    white-space: normal;
    overflow-wrap: anywhere;
}

.game-blocks-editor__toolbar {
    display: grid;
    grid-template-columns: auto minmax(14rem, 24rem);
    align-items: center;
    gap: 0.75rem;
}

.game-blocks-editor__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
}

.game-blocks-preview-modal .modal-dialog {
    width: min(100vw - 2rem, 1440px);
    max-width: 1440px;
}

.game-blocks-preview-modal .modal-body {
    padding: 0;
    background: var(--background-color, #f5f5f5);
}

.game-blocks-preview-modal__frame {
    display: block;
    width: 100%;
    height: min(78vh, 900px);
    border: 0;
    background: var(--background-color, #f5f5f5);
}

.game-blocks-canvas {
    display: grid;
    gap: 1rem;
}

.game-blocks-subtabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.game-blocks-pane {
    min-height: 4rem;
}

.game-block-card {
    position: relative;
    border: 1px solid #dee2e6;
    border-radius: 0.35rem;
    background: #ffffff;
    box-shadow: 0 0.25rem 0.7rem rgba(0, 0, 0, 0.05);
    cursor: grab;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.game-block-card:active {
    cursor: grabbing;
}

.game-block-card--hidden {
    background: #f8f9fa;
    opacity: 0.78;
}

.game-block-card--dragging {
    opacity: 0.45;
}

.game-block-card--drop-before {
    border-top: 4px solid #0d6efd;
}

.game-block-card--drop-after {
    border-bottom: 4px solid #0d6efd;
}

.game-block-card--drop-combine {
    border-color: #fd7e14;
    box-shadow: 0 0 0 0.2rem rgba(253, 126, 20, 0.18);
    transform: scale(1.01);
}

.admin-menu-table__drag-cell {
    width: 2.5rem;
    text-align: center;
    vertical-align: middle;
}

.admin-menu-table__drag-handle {
    color: #6c757d;
    cursor: grab;
}

.admin-menu-table__label-cell {
    padding-left: calc(0.75rem + var(--menu-depth, 0rem)) !important;
}

.admin-menu-table__tree-mark,
.admin-menu-table__parent-mark {
    display: inline-block;
    color: #6c757d;
    margin-right: 0.35rem;
}

.admin-menu-table__parent-mark {
    color: #0d6efd;
}

.admin-menu-table tr[draggable="true"]:active .admin-menu-table__drag-handle {
    cursor: grabbing;
}

.admin-menu-table__row--dragging {
    opacity: 0.45;
}

.admin-menu-table__row--drop-before {
    border-top: 3px solid #0d6efd;
}

.admin-menu-table__row--drop-after {
    border-bottom: 3px solid #0d6efd;
}

.game-block-card__preview {
    padding: 0;
}

.game-block-card__preview .block-combination .block-text,
.game-block-card__preview .block-combination .block-text p,
.game-block-card__preview .block-combination .block-text li,
.game-block-card__preview .block-combination .block-text h2,
.game-block-card__preview .block-combination .block-text h3,
.game-block-card__preview .block-combination .block-text h4,
.game-block-card__preview .block-combination .block-text h5,
.game-block-card__preview .block-combination .block-text h6 {
    color: var(--block-combination-foreground, #212529);
}

.game-block-card__preview .block-combination .game-text-accent {
    color: var(--block-combination-accent, var(--secondary-color));
}

.game-block-card__overlay-actions {
    position: absolute;
    right: 0.65rem;
    bottom: 0.65rem;
    z-index: 3;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.4rem;
}

.game-block-card__overlay-button {
    display: inline-grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    border-radius: 999px;
    color: #fff;
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.22);
}

.game-block-card__visibility-toggle {
    background: #0d6efd;
}

.game-block-card__split {
    background: #6f42c1;
}

.game-block-card__delete {
    background: #dc3545;
}

.game-block-card__overlay-button--disabled {
    background: #adb5bd;
    color: #f8f9fa;
    cursor: not-allowed;
    opacity: 0.75;
}

.game-block-card__unused-warning {
    background: #ffc107;
    color: #212529;
    cursor: help;
}

.game-block-card__overlay-button:hover,
.game-block-card__overlay-button:focus {
    color: #fff;
    outline: none;
}

.game-block-card__visibility-toggle:hover,
.game-block-card__visibility-toggle:focus {
    background: #0b5ed7;
}

.game-block-card__split:hover,
.game-block-card__split:focus {
    background: #5a32a3;
}

.game-block-card__delete:hover,
.game-block-card__delete:focus {
    background: #bb2d3b;
}

.game-block-card__overlay-button--disabled:hover,
.game-block-card__overlay-button--disabled:focus {
    background: #adb5bd;
    color: #f8f9fa;
}

.game-block-card__unused-warning:hover,
.game-block-card__unused-warning:focus {
    color: #212529;
    background: #ffca2c;
}

.game-block-card__overlay-button:focus-visible {
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.35);
}

@media (max-width: 768px) {
    .game-blocks-editor__toolbar {
        grid-template-columns: minmax(0, 1fr);
        width: 100%;
    }
}

/* Styly pro karty */
.admin-container .card {
    color: #212529;
}

.admin-container .card-header {
    background-color: #f8f9fa;
    color: #212529;
}

.admin-container .card-body {
    color: #212529;
}

/* Styly pro modální okna */
.admin-container .modal-title {
    color: #212529;
}

.admin-container .modal-body {
    color: #212529;
}

/* Styly pro zprávy */
.admin-container .alert-success {
    color: #155724;
    background-color: #d4edda;
    border-color: #c3e6cb;
}

.admin-container .alert-danger {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

.admin-container .alert-warning {
    color: #856404;
    background-color: #fff3cd;
    border-color: #ffeeba;
}

.admin-container .alert-info {
    color: #0c5460;
    background-color: #d1ecf1;
    border-color: #bee5eb;
}

.block-editor-tools {
    align-items: center;
}

.block-editor-tools .btn {
    min-width: 2.15rem;
}

.block-editor-help {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.block-editor-help__trigger {
    min-width: 2.15rem;
}

.block-editor-help__panel {
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0;
    z-index: 1080;
    display: none;
    width: min(36rem, calc(100vw - 3rem));
    max-height: min(70vh, 32rem);
    overflow: auto;
    box-shadow: 0 0.75rem 2rem rgba(0, 0, 0, 0.18);
}

.block-editor-help:hover .block-editor-help__panel,
.block-editor-help:focus-within .block-editor-help__panel {
    display: block;
}

.block-editor-guide {
    padding: 0.85rem 1rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    background: #f8f9fa;
    font-size: 0.92rem;
}

.block-editor-guide ul {
    padding-left: 1.2rem;
}

.block-editor-guide code {
    color: #212529;
}

.block-editor-guide__code {
    max-height: 14rem;
    padding: 0.85rem;
    overflow: auto;
    border-radius: 0.4rem;
    background: #212529;
}

.block-editor-guide__code code {
    color: #f8f9fa;
    white-space: pre;
}

#addGameBlockModal .modal-dialog,
#editGameBlockModal .modal-dialog,
#editGameModal .modal-dialog,
.dynamic-block-editor-modal .modal-dialog {
    max-width: min(96vw, 72rem);
}

.game-details-editor .tab-content {
    background: #ffffff;
}

.combination-builder {
    display: grid;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    background: #f8f9fa;
}

.combination-builder__controls {
    display: grid;
    gap: 0.75rem;
}

.combination-builder__controls-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    gap: 0.75rem;
    align-items: end;
}

.combination-builder__controls-row--primary {
    grid-template-columns: repeat(3, minmax(8.5rem, 1fr));
}

@media (max-width: 640px) {
    .combination-builder__controls-row--primary {
        grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    }
}

.combination-builder__cell-controls {
    display: grid;
    gap: 0.75rem;
}

.combination-builder__cell-controls-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    gap: 0.75rem;
    align-items: end;
}

.combination-builder__cell-controls-row--layout {
    grid-template-columns: repeat(3, minmax(8.5rem, 1fr));
}

.combination-builder__cell-controls-row--actions {
    grid-template-columns: repeat(4, minmax(7rem, 1fr));
}

@media (max-width: 640px) {
    .combination-builder__cell-controls-row--layout,
    .combination-builder__cell-controls-row--actions {
        grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    }
}

.combination-builder__controls .form-control-color {
    width: 100%;
}

.combination-builder__grid {
    display: grid;
    align-items: stretch;
}

.combination-builder__slot {
    min-height: 7rem;
    padding: 0.85rem;
    border: 1px dashed #adb5bd;
    border-radius: 0.45rem;
    background: #ffffff;
    color: var(--block-combination-foreground, #212529);
    text-align: left;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.combination-builder__slot .block-text,
.combination-builder__slot .block-text p,
.combination-builder__slot .block-text li,
.combination-builder__slot .block-text h2,
.combination-builder__slot .block-text h3,
.combination-builder__slot .block-text h4,
.combination-builder__slot .block-text h5,
.combination-builder__slot .block-text h6 {
    color: var(--block-combination-foreground, #212529);
}

.combination-builder__slot.block-combination__cell--boxed,
.combination-builder__slot.block-combination__cell--feature-grid {
    background: var(--block-combination-background, #ffffff);
}

.combination-builder__grid .game-text-accent {
    color: var(--block-combination-accent, var(--secondary-color));
}

.combination-builder__grid.block-combination--boxed {
    padding: 1rem;
}

.combination-builder__grid.block-combination--feature-grid .combination-builder__slot {
    border-style: dashed;
}

.combination-builder__slot > span {
    color: #6c757d;
    font-size: 0.85rem;
}

.combination-builder__slot-preview {
    pointer-events: none;
}

.combination-builder__slot--selected {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.16);
}

.combination-builder__slot[draggable="true"] {
    cursor: grab;
    border-style: dashed;
}

.combination-builder__cell-panel {
    display: grid;
    gap: 0.75rem;
    padding: 0.85rem;
    border: 1px solid #dee2e6;
    border-radius: 0.45rem;
    background: #ffffff;
}

.combination-builder__helper-picker {
    display: grid;
    gap: 0.5rem;
}

.combination-builder__helper-picker .btn {
    justify-self: start;
}

.combination-block-picker {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.85rem;
}

.combination-block-picker__filters {
    margin-bottom: 0.85rem;
    padding: 0.75rem 0.85rem;
    border: 1px solid #dee2e6;
    border-radius: 0.45rem;
    background: #f8f9fa;
}

.combination-block-picker__item {
    display: grid;
    gap: 0.75rem;
    min-height: 0;
    padding: 0.85rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    background: #ffffff;
    color: #212529;
    text-align: left;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.combination-block-picker__item:hover,
.combination-block-picker__item:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.12);
}

.combination-block-picker__item--selected {
    border-color: #0d6efd;
    background: #f4f8ff;
}

.combination-block-picker__preview {
    display: block;
    max-height: 18rem;
    overflow: hidden;
    pointer-events: none;
}

.gallery-picker {
    display: grid;
    gap: 1rem;
    margin-bottom: 1rem;
}

.gallery-picker__selected {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-height: 2rem;
}

.gallery-picker__empty {
    color: #6c757d;
    font-size: 0.9rem;
}

.gallery-picker__selected-item {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    max-width: 100%;
    padding: 0.35rem 0.45rem 0.35rem 0.65rem;
    border: 1px solid #cfe2ff;
    border-radius: 999px;
    background: #e7f1ff;
    color: #052c65;
    font-size: 0.88rem;
}

.gallery-picker__selected-item span {
    overflow-wrap: anywhere;
}

.gallery-picker__scale {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin: 0;
    font-size: 0.82rem;
}

.gallery-picker__scale input {
    width: 4.25rem;
    padding: 0.15rem 0.3rem;
    border: 1px solid #9ec5fe;
    border-radius: 0.3rem;
    background: #ffffff;
    color: #052c65;
}

.gallery-picker__remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.45rem;
    height: 1.45rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: inherit;
}

.gallery-picker__remove:hover,
.gallery-picker__remove:focus {
    background: rgba(5, 44, 101, 0.12);
}

.gallery-picker__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
    gap: 0.75rem;
    max-height: min(48vh, 34rem);
    overflow: auto;
    padding: 0.15rem;
}

.gallery-picker__item {
    position: relative;
    display: grid;
    gap: 0.45rem;
    padding: 0.45rem;
    border: 1px solid #dee2e6;
    border-radius: 0.45rem;
    background: #ffffff;
    color: #212529;
    text-align: left;
}

.gallery-picker__item:hover,
.gallery-picker__item:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.14);
}

.gallery-picker__item--selected {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.16);
}

.gallery-picker__item--selected::after {
    content: attr(data-gallery-order);
    position: absolute;
    top: 0.45rem;
    left: 0.45rem;
    display: grid;
    place-items: center;
    min-width: 1.7rem;
    height: 1.7rem;
    padding: 0 0.35rem;
    border-radius: 999px;
    background: #0d6efd;
    color: #ffffff;
    font-size: 0.82rem;
    font-weight: 700;
}

.gallery-picker__thumb {
    display: block;
    overflow: hidden;
    border-radius: 0.3rem;
    background: #f8f9fa;
}

.gallery-picker__thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.gallery-picker__name {
    overflow-wrap: anywhere;
    font-size: 0.82rem;
}

.gallery-picker__check {
    position: absolute;
    top: 0.45rem;
    right: 0.45rem;
    display: none;
    place-items: center;
    width: 1.7rem;
    height: 1.7rem;
    border-radius: 50%;
    background: #198754;
    color: #ffffff;
}

.gallery-picker__item--selected .gallery-picker__check {
    display: grid;
}

.file-block-editor {
    margin-bottom: 1rem;
}

.file-block-editor__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.85rem;
    padding: 0.85rem;
    border: 1px solid #dee2e6;
    border-radius: 0.45rem;
    background: #ffffff;
}

.file-block-editor__wide {
    grid-column: 1 / -1;
}

.markdown-image-picker__item {
    display: grid;
    width: 100%;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 0.45rem;
    background: #ffffff;
    color: #212529;
    text-align: left;
}

.markdown-image-picker__item:hover,
.markdown-image-picker__item:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.14);
}

.markdown-image-picker__item img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 0.3rem;
}

.markdown-image-picker__item span {
    overflow-wrap: anywhere;
    font-size: 0.85rem;
}

.admin-images-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.admin-images-toolbar .pagination {
    margin-bottom: 0;
}
