/**
 * SCHOOLSITE BUILDER - Editor Stylesheet
 * 
 * Stijlen voor de visuele pagina-editor.
 * Geïnspireerd op Mobirise en Nicepage.
 */

/* ============================================
   CSS VARIABELEN
   ============================================ */
:root {
    --editor-sidebar-width: 280px;
    --editor-panel-width: 300px;
    --editor-header-height: 56px;
    --primary: #667eea;
    --primary-dark: #5a6fd6;
    --secondary: #764ba2;
    --success: #27ae60;
    --warning: #f39c12;
    --danger: #e74c3c;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
}

/* ============================================
   RESET & BASE
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.editor-body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--gray-200);
    overflow: hidden;
    height: 100vh;
}

/* ============================================
   EDITOR LAYOUT
   ============================================ */
.editor-layout {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

/* Editor Header */
.editor-header {
    height: var(--editor-header-height);
    background: var(--gray-800);
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    flex-shrink: 0;
    z-index: 100;
}

.editor-header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.editor-back {
    color: var(--gray-400);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    transition: color 0.2s;
}

.editor-back:hover {
    color: white;
}

.editor-site-name {
    font-weight: 600;
    font-size: 16px;
}

.editor-page-select {
    background: var(--gray-700);
    border: 1px solid var(--gray-600);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
}

.editor-header-center {
    display: flex;
    align-items: center;
    gap: 10px;
}

.editor-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Responsive Preview Buttons */
.responsive-preview-buttons {
    display: flex;
    gap: 2px;
    background: var(--gray-700);
    border-radius: 8px;
    padding: 3px;
    margin-right: 12px;
}

.responsive-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 30px;
    background: transparent;
    border: none;
    border-radius: 6px;
    color: var(--gray-400);
    cursor: pointer;
    transition: all 0.2s;
}

.responsive-btn:hover {
    color: white;
    background: var(--gray-600);
}

.responsive-btn.active {
    background: var(--primary);
    color: white;
}

.responsive-btn svg {
    width: 18px;
    height: 18px;
}

/* Undo/Redo Buttons */
.undo-redo-buttons {
    display: flex;
    gap: 4px;
    margin-right: 12px;
}

.undo-redo-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--gray-700);
    border: 1px solid var(--gray-600);
    border-radius: 6px;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
}

.undo-redo-btn:hover:not(:disabled) {
    background: var(--gray-600);
    border-color: var(--gray-500);
}

.undo-redo-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.undo-redo-btn svg {
    width: 14px;
    height: 14px;
}

/* Undo/Redo Feedback Toast */
.undo-redo-feedback {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--gray-800);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 10000;
    pointer-events: none;
}

.undo-redo-feedback.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Save Button */
.save-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--gray-700);
    border: 1px solid var(--gray-600);
    border-radius: 6px;
    color: white;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.save-btn:hover {
    background: var(--gray-600);
    border-color: var(--gray-500);
}

.save-btn.saving {
    background: var(--warning);
    border-color: var(--warning);
    cursor: wait;
}

.save-btn.dirty {
    background: var(--primary);
    border-color: var(--primary);
    animation: pulse-save 1.5s infinite;
}

@keyframes pulse-save {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.save-btn.saved {
    background: var(--success);
    border-color: var(--success);
}

.save-status {
    font-size: 12px;
    color: var(--gray-400);
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.3s;
}

.save-status.saving {
    color: var(--warning);
    background: rgba(243, 156, 18, 0.1);
}

.save-status.saved {
    color: var(--success);
    background: rgba(39, 174, 96, 0.1);
}

.save-status.dirty {
    color: var(--warning);
    background: rgba(243, 156, 18, 0.1);
}

.editor-btn {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.editor-btn-secondary {
    background: var(--gray-700);
    color: white;
}

.editor-btn-secondary:hover {
    background: var(--gray-600);
}

.editor-btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

.editor-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.editor-btn-warning {
    background: var(--warning);
    color: white;
}

.editor-btn-warning:hover {
    background: #e67e22;
    transform: translateY(-1px);
}

.editor-btn-info {
    background: #3b82f6;
    color: white;
    padding: 8px 12px;
}

.editor-btn-info:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.editor-btn-success {
    background: #10b981;
    color: white;
}

.editor-btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
}

/* Editor Main Area */
.editor-main {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* ============================================
   BLOCKS SIDEBAR (Links)
   ============================================ */
.editor-sidebar {
    width: var(--editor-sidebar-width);
    background: white;
    border-right: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar-header {
    padding: 16px;
    border-bottom: 1px solid var(--gray-200);
    font-weight: 600;
    color: var(--gray-700);
}

.sidebar-search {
    padding: 12px 16px;
    border-bottom: 1px solid var(--gray-200);
}

.sidebar-search input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 14px;
}

.sidebar-search input:focus {
    outline: none;
    border-color: var(--primary);
}

.sidebar-categories {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}

.category-section {
    margin-bottom: 16px;
}

.category-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gray-500);
    padding: 8px 4px;
    font-weight: 600;
}

.block-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.block-item {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 12px 8px;
    text-align: center;
    cursor: grab;
    transition: all 0.2s;
    font-size: 12px;
    color: var(--gray-600);
}

.block-item:hover {
    border-color: var(--primary);
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.block-item.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.block-item-icon {
    font-size: 24px;
    margin-bottom: 6px;
    display: block;
}

.block-item .block-item-preview {
    width: 100%;
    height: 50px !important;
    max-height: 50px !important;
    margin-bottom: 6px;
    border-radius: 4px;
    overflow: hidden;
    background: var(--gray-100);
}

.block-item .block-item-preview img {
    width: 100%;
    height: 50px !important;
    max-height: 50px !important;
    object-fit: cover;
    object-position: top center;
}

.block-item.has-thumbnail {
    padding: 6px;
}

.block-item.has-thumbnail .block-item-name {
    font-size: 10px;
    margin-top: 4px;
    display: block;
}

/* ============================================
   CANVAS (Midden)
   ============================================ */
.editor-canvas {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
    background: var(--gray-200);
}

.canvas-wrapper {
    max-width: 100%;
    margin: 0 auto;
    background: white;
    min-height: 100%;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.1);
    transition: max-width 0.3s ease, box-shadow 0.3s ease;
}

/* Responsive Preview Modes */
.canvas-wrapper.tablet-view {
    max-width: 768px;
    box-shadow: 0 0 0 20px var(--gray-300), 0 0 60px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
}

.canvas-wrapper.mobile-view {
    max-width: 375px;
    box-shadow: 0 0 0 12px var(--gray-800), 0 0 60px rgba(0, 0, 0, 0.2);
    border-radius: 24px;
}

/* Mobile view: verberg menu items en toon hamburger */
.canvas-wrapper.mobile-view .slot-menu,
.canvas-wrapper.mobile-view .site-menu,
.canvas-wrapper.mobile-view .menu-btn-wrapper {
    display: none !important;
}

.canvas-wrapper.mobile-view .hamburger-btn {
    display: flex !important;
}

/* Hamburger knop container in header blokken */
.mobile-hamburger-container {
    display: none;
}

.canvas-wrapper.mobile-view .mobile-hamburger-container {
    display: flex !important;
}

/* Hamburger button in editor */
.hamburger-btn {
    display: none;
    width: 40px;
    height: 40px;
    background: var(--gray-100);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.hamburger-btn:hover {
    background: var(--gray-200);
}

/* Mobile Menu Overlay voor responsive preview - binnen canvas */
.canvas-wrapper {
    position: relative;
    overflow: hidden;
}

.canvas-mobile-menu-backdrop {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.canvas-mobile-menu-backdrop.active {
    display: block;
    opacity: 1;
    visibility: visible;
}

.canvas-mobile-menu-overlay {
    position: absolute;
    top: 0;
    right: -280px;
    width: 240px;
    height: 100%;
    background: #fff;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    z-index: 999;
    transition: right 0.3s ease;
    padding: 50px 0 20px;
    overflow-y: auto;
}

.canvas-mobile-menu-overlay.active {
    right: 0;
}

.mobile-menu-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 32px;
    height: 32px;
    border: none;
    background: var(--gray-100);
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-close:hover {
    background: var(--gray-200);
}

.mobile-menu-items {
    display: flex;
    flex-direction: column;
}

.mobile-menu-items a,
.mobile-menu-items .mobile-menu-item {
    display: block;
    padding: 14px 20px;
    border-bottom: 1px solid var(--gray-200);
    text-decoration: none;
    color: var(--gray-800);
    font-size: 15px;
    transition: background 0.2s;
}

.mobile-menu-items a:hover,
.mobile-menu-items .mobile-menu-item:hover {
    background: var(--gray-100);
}

/* Page blocks container */
.page-blocks {
    min-height: 400px;
}

/* Add block button between blocks */
.add-block-zone {
    padding: 30px 20px;
    text-align: center;
    border: 2px dashed transparent;
    transition: all 0.2s;
    min-height: 100px;
}

.add-block-zone:hover,
.add-block-zone.drag-over {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
    border-radius: 8px;
}

.add-block-zone.drag-over {
    border-width: 3px;
    box-shadow: inset 0 0 20px rgba(34, 197, 94, 0.2);
}

.add-block-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--gray-100);
    border: 2px dashed var(--gray-300);
    border-radius: 8px;
    color: var(--gray-500);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.add-block-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: white;
}

/* Block wrapper in canvas */
.block-wrapper {
    position: relative;
    transition: all 0.2s;
}

.block-wrapper:hover {
    outline: 2px solid var(--primary);
    outline-offset: -2px;
}

.block-wrapper.selected {
    outline: 3px solid var(--primary);
    outline-offset: -3px;
}

.block-wrapper.dragging {
    opacity: 0.5;
}

.block-wrapper.drag-over-top::before {
    content: '';
    position: absolute;
    top: -3px;
    left: 0;
    right: 0;
    height: 6px;
    background: #22c55e;
    z-index: 100;
    box-shadow: 0 0 12px 3px rgba(34, 197, 94, 0.6);
    border-radius: 3px;
}

.block-wrapper.drag-over-bottom::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    right: 0;
    height: 6px;
    background: #22c55e;
    z-index: 100;
    box-shadow: 0 0 12px 3px rgba(34, 197, 94, 0.6);
    border-radius: 3px;
}

/* Verberg blok selectielijnen wanneer een element wordt gesleept */
body.is-dragging-element .block-wrapper:hover {
    outline: none !important;
}

body.is-dragging-element:not(.is-dragging-plugin) .block-wrapper.drag-over-top::before,
body.is-dragging-element:not(.is-dragging-plugin) .block-wrapper.drag-over-bottom::after {
    display: none !important;
}

/* Kolom drop zones bij slepen van elementen/plugins */
body.is-dragging-element .block-column,
body.is-dragging-plugin .block-column {
    position: relative;
    outline: 2px dashed var(--primary);
    outline-offset: -2px;
    background: rgba(99, 102, 241, 0.05) !important;
    transition: all 0.15s ease;
}

body.is-dragging-element .block-column:hover,
body.is-dragging-plugin .block-column:hover,
.block-column.drag-over {
    outline-color: var(--success);
    outline-width: 3px;
    background: rgba(34, 197, 94, 0.1) !important;
}

/* Drop zone binnen kolom - vergroot bij slepen */
body.is-dragging-element .column-drop-zone,
body.is-dragging-plugin .column-drop-zone {
    min-height: 60px !important;
    border: 2px dashed var(--primary) !important;
    background: rgba(99, 102, 241, 0.1) !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

body.is-dragging-element .column-drop-zone::before,
body.is-dragging-plugin .column-drop-zone::before {
    content: '+ Drop element hier';
    color: var(--primary);
    font-size: 12px;
    font-weight: 600;
}

body.is-dragging-element .column-drop-zone:hover,
body.is-dragging-plugin .column-drop-zone:hover,
.column-drop-zone.drag-over {
    border-color: var(--success) !important;
    background: rgba(34, 197, 94, 0.15) !important;
}

body.is-dragging-element .column-drop-zone:hover::before,
body.is-dragging-plugin .column-drop-zone:hover::before,
.column-drop-zone.drag-over::before {
    color: var(--success);
}

/* Block toolbar */
.block-toolbar {
    position: absolute;
    top: 10px;
    right: 10px;
    display: none;
    gap: 4px;
    z-index: 20;
}

.block-wrapper:hover .block-toolbar,
.block-wrapper.selected .block-toolbar {
    display: flex;
}

.block-toolbar-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    background: var(--gray-800);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s;
}

.block-toolbar-btn:hover {
    background: var(--primary);
}

.block-toolbar-btn.danger:hover {
    background: var(--danger);
}

.block-toolbar-btn.primary {
    background: var(--primary);
}

.block-toolbar-btn.primary:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

/* Block resize handle */
.block-resize-handle {
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 16px;
    background: var(--gray-600);
    cursor: ns-resize;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 15;
    border-radius: 8px;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.block-resize-handle span {
    display: block;
    width: 30px;
    height: 3px;
    background: white;
    border-radius: 2px;
}

.block-wrapper:hover .block-resize-handle,
.block-wrapper.selected .block-resize-handle {
    display: flex;
}

.block-resize-handle:hover {
    background: var(--primary);
    transform: translateX(-50%) scale(1.1);
}

.block-wrapper.resizing {
    user-select: none;
}

.block-wrapper.resizing .block-resize-handle {
    display: flex;
    background: var(--primary);
}

/* Drag handle */
.block-drag-handle {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 40px;
    background: var(--gray-800);
    border-radius: 4px;
    cursor: grab;
    display: none;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
}

.block-wrapper:hover .block-drag-handle {
    display: flex;
}

/* ============================================
   RENDERED BLOCK STYLES
   ============================================ */
.rendered-block {
    width: 100%;
    overflow: hidden;
    position: relative;
}

/* Achtergrond layer voor blur effect */
.rendered-block .block-bg-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    /* Vergroot voor blur randen - scale ipv negatieve positie */
    transform: scale(1.1);
}

.rendered-block .block-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    pointer-events: none;
}

.rendered-block .block-container {
    position: relative;
    z-index: 2;
}

.rendered-block .block-container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
}

.rendered-block .block-columns {
    display: flex;
    gap: 30px;
    align-items: stretch;
    height: 100%;
}

.rendered-block .block-column {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
}

.rendered-block .slot-title {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 16px;
}

.rendered-block .slot-subtitle {
    font-size: 1.25rem;
    font-weight: 500;
    color: inherit;
    opacity: 0.8;
    margin-bottom: 12px;
}

.rendered-block .slot-text {
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 16px;
}

.rendered-block .slot-image {
    width: 100%;
    max-width: 100%;
    border-radius: 8px;
    display: block;
    object-fit: cover;
}

/* Afbeelding wrapper voor resize - neemt beschikbare ruimte */
.rendered-block .slot-image-wrapper {
    position: relative;
    width: 100%;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.rendered-block .slot-image-wrapper .slot-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Afbeelding in custom layout elementen - normale flow */
.column-element .slot-image-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.column-element .slot-image-wrapper .slot-image {
    position: static;
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 8px;
}

.rendered-block .slot-image-placeholder {
    width: 100%;
    aspect-ratio: 16/9;
    background: var(--gray-200);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
    font-size: 48px;
    cursor: pointer;
    transition: all 0.2s;
}

.rendered-block .slot-image-placeholder:hover {
    background: var(--gray-300);
}

.rendered-block .slot-button {
    display: inline-block;
    padding: 14px 28px;
    background: var(--button-color, var(--primary));
    color: white;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    margin-right: 10px;
    margin-bottom: 10px;
    transition: all 0.2s;
    width: auto;
    max-width: fit-content;
}

.rendered-block .slot-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Dropdown button in editor */
.editor-dropdown-wrapper {
    position: relative;
    display: inline-block;
}

/* Zorg dat blok met dropdown boven andere blokken valt */
.block-wrapper:has(.editor-dropdown-wrapper:hover) {
    z-index: 9999 !important;
    position: relative;
}

.rendered-block:has(.editor-dropdown-wrapper:hover) {
    overflow: visible !important;
}

.block-column:has(.editor-dropdown-wrapper:hover) {
    overflow: visible !important;
}

/* Fallback: header blokken altijd hoge z-index */
.block-wrapper:first-child {
    z-index: 100;
    position: relative;
}

.rendered-block.is-header-block {
    overflow: visible !important;
}

.rendered-block.is-header-block .block-container,
.rendered-block.is-header-block .block-columns,
.rendered-block.is-header-block .block-column {
    overflow: visible !important;
}

.rendered-block .slot-button.has-dropdown {
    margin-right: 0;
}

.dropdown-arrow {
    font-size: 0.7rem;
    margin-left: 4px;
    opacity: 0.7;
}

.editor-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 160px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s;
    z-index: 9999;
}

.editor-dropdown-wrapper:hover .editor-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.editor-dropdown-item {
    display: block;
    padding: 10px 16px;
    color: #374151;
    text-decoration: none;
    font-size: 0.85rem;
    transition: background 0.2s;
    white-space: nowrap;
}

.editor-dropdown-item:hover {
    background: #f3f4f6;
}

.rendered-block .slot-divider {
    border: none;
    border-top: 2px solid #e5e7eb;
    margin: 20px 0;
}

.rendered-block .slot-spacer {
    background: transparent;
}

.rendered-block .slot-video {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 8px;
    overflow: hidden;
}

.rendered-block .slot-video iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.rendered-block .slot-html {
    width: 100%;
    min-height: 60px;
    position: relative;
    border: 2px dashed transparent;
    border-radius: 8px;
    transition: border-color 0.2s;
}

.rendered-block .slot-html:hover {
    border-color: var(--primary);
}

.rendered-block .slot-html-content {
    width: 100%;
    pointer-events: none;
}

.rendered-block .slot-html-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s;
    border-radius: 6px;
    z-index: 5;
}

.rendered-block .slot-html:hover .slot-html-overlay {
    background: rgba(99, 102, 241, 0.15);
}

.rendered-block .slot-html-edit-btn {
    opacity: 0;
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.2s, transform 0.2s;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    transform: scale(0.9);
}

.rendered-block .slot-html:hover .slot-html-edit-btn {
    opacity: 1;
    transform: scale(1);
}

.rendered-block .slot-video-placeholder {
    width: 100%;
    aspect-ratio: 16/9;
    background: var(--gray-800);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
    cursor: pointer;
}

/* Padding classes */
.rendered-block.padding-S { padding: 40px 0; }
.rendered-block.padding-M { padding: 80px 0; }
.rendered-block.padding-L { padding: 120px 0; }

/* Text align */
.rendered-block.text-center { text-align: center; }
.rendered-block.text-center .block-columns { justify-content: center; }

/* ============================================
   PROPERTIES PANEL (Rechts)
   ============================================ */
.editor-panel {
    width: var(--editor-panel-width);
    background: white;
    border-left: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    overflow: hidden;
}

.panel-header {
    padding: 16px;
    border-bottom: 1px solid var(--gray-200);
    font-weight: 600;
    color: var(--gray-700);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-close {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--gray-400);
}

.panel-close:hover {
    color: var(--gray-600);
}

.panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.panel-section {
    margin-bottom: 24px;
}

.panel-section-title {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--gray-500);
    margin-bottom: 12px;
    font-weight: 600;
}

.panel-field {
    margin-bottom: 16px;
}

.panel-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.panel-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 14px;
}

.panel-input:focus {
    outline: none;
    border-color: var(--primary);
}

/* HTML Code Editor */
.html-code-editor {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace;
    font-size: 13px;
    line-height: 1.5;
    background: #1e1e2e;
    color: #cdd6f4;
    border: 1px solid #313244;
    border-radius: 8px;
    padding: 16px;
    tab-size: 2;
    white-space: pre-wrap;
    word-wrap: break-word;
    resize: vertical;
}

.html-code-editor:focus {
    border-color: #89b4fa;
    box-shadow: 0 0 0 3px rgba(137, 180, 250, 0.15);
}

.html-code-editor::placeholder {
    color: #6c7086;
}

.panel-color-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.panel-color-picker {
    width: 44px;
    height: 36px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    cursor: pointer;
    padding: 2px;
}

.panel-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--gray-400);
}

.panel-empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

/* ============================================
   INLINE EDITING
   ============================================ */
[contenteditable="true"] {
    outline: none;
    cursor: text;
}

[contenteditable="true"]:hover {
    background: rgba(102, 126, 234, 0.05);
}

[contenteditable="true"]:focus {
    background: rgba(102, 126, 234, 0.1);
    box-shadow: inset 0 0 0 2px var(--primary);
}

/* Links in editable content - behoud kleur, onderstrepen */
[contenteditable="true"] a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

[contenteditable="true"] a:hover {
    opacity: 0.8;
}

/* ============================================
   MODALS
   ============================================ */
.editor-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10200;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s;
}

.editor-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.editor-modal {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    transform: translateY(-20px);
    transition: transform 0.2s;
}

.editor-modal-overlay.active .editor-modal {
    transform: translateY(0);
}

.editor-modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.editor-modal-title {
    font-size: 18px;
    font-weight: 600;
}

.editor-modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: 60vh;
}

.editor-modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.editor-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--gray-400);
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.editor-modal-close:hover {
    color: var(--gray-600);
}

/* Share teachers list */
.share-teachers-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-teacher-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--gray-50);
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.share-teacher-option:hover {
    border-color: var(--primary);
    background: white;
}

.share-teacher-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
}

.share-teacher-option input[type="checkbox"]:checked + .share-teacher-name {
    color: var(--primary);
    font-weight: 600;
}

.share-teacher-name {
    font-size: 14px;
    color: var(--gray-700);
}

/* Editor input styling */
.editor-input {
    padding: 10px 12px;
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.editor-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.editor-input::placeholder {
    color: var(--gray-400);
}

/* Block picker modal */
.block-picker-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.block-picker-item {
    background: var(--gray-50);
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.block-picker-item:hover {
    border-color: var(--primary);
    background: white;
}

.block-picker-item-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.block-picker-item-name {
    font-size: 12px;
    font-weight: 500;
    color: var(--gray-700);
    margin-top: 8px;
}

/* Block Preview Thumbnails - Screenshot afbeeldingen */
.block-picker-preview {
    width: 100%;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
    background: var(--gray-100);
}

.block-picker-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

.block-picker-preview.no-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--gray-100), var(--gray-200));
}

.block-picker-preview .preview-icon {
    font-size: 32px;
    opacity: 0.5;
}

/* ============================================
   CUSTOM BUTTON STYLING (CSS Variables)
   ============================================ */

/* Button styles */
.rendered-block.btn-outline .slot-button {
    background-color: transparent;
    border: 2px solid var(--button-color, #667eea);
    color: var(--button-color, #667eea);
}

.rendered-block.btn-rounded .slot-button {
    border-radius: 8px;
}

.rendered-block.btn-pill .slot-button {
    border-radius: 50px;
}

/* Text alignment */
.rendered-block.text-right {
    text-align: right;
}

.rendered-block.text-right .block-column {
    text-align: right;
}

/* Panel button group */
.panel-btn-group {
    display: flex;
    gap: 4px;
}

.panel-btn {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid var(--gray-200);
    background: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s;
}

.panel-btn:hover {
    border-color: var(--primary);
    background: var(--gray-50);
}

.panel-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* Extra large padding */
.padding-XL {
    padding: 120px 40px;
}

/* Text Selection Toolbar - Color Picker */
.toolbar-divider {
    width: 1px;
    height: 20px;
    background: rgba(255,255,255,0.3);
    margin: 0 2px;
}

.toolbar-color-picker {
    position: relative;
    display: flex;
    align-items: center;
    width: 24px;
    height: 24px;
}

.toolbar-color-picker input[type="color"] {
    position: absolute;
    width: 24px;
    height: 24px;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
    border-radius: 50%;
}

.toolbar-btn.color-btn {
    width: 24px;
    height: 24px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.color-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.3);
}

/* ============================================
   MENU / HEADER BLOCK LAYOUT
   ============================================ */

/* Header blokken: buttons naast elkaar */
.rendered-block.is-header-block .block-column {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 8px !important;
}

.rendered-block.is-header-block .block-column:last-child {
    justify-content: flex-end !important;
}

.rendered-block.is-header-block .slot-button {
    margin: 0 !important;
}

.rendered-block.is-header-block .slot-title,
.rendered-block.is-header-block .slot-subtitle {
    margin: 0 !important;
    flex-shrink: 0;
}

/* Menu editor trigger button */
.menu-edit-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(79, 70, 229, 0.1);
    border: 1px dashed #4f46e5;
    border-radius: 6px;
    color: #4f46e5;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    margin-left: 8px;
}

.menu-edit-trigger:hover {
    background: #4f46e5;
    color: white;
    border-style: solid;
}

.menu-edit-trigger svg {
    width: 16px;
    height: 16px;
}

/* Add menu item button (+ icoon) */
.menu-add-item-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #e5e7eb;
    border: none;
    border-radius: 50%;
    color: #6b7280;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
    margin-left: 4px;
}

.menu-add-item-btn:hover {
    background: #4f46e5;
    color: white;
}

/* Menu item wrapper in editor */
.menu-item-inline {
    display: inline-flex;
    align-items: center;
    position: relative;
}

.menu-item-inline .menu-item-delete-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 20px;
    height: 20px;
    background: #ef4444;
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 12px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-item-inline:hover .menu-item-delete-btn {
    opacity: 1;
}

/* Dropdown indicator */
.menu-dropdown-badge {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 2px 6px;
    background: #dbeafe;
    color: #1d4ed8;
    font-size: 10px;
    border-radius: 4px;
    margin-left: 4px;
    cursor: pointer;
}

.menu-dropdown-badge:hover {
    background: #1d4ed8;
    color: white;
}

.menu-block-layout {
    display: flex;
    align-items: center;
}

.menu-logo-col {
    display: flex;
    align-items: center;
}

.menu-nav-col {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

/* ============================================
   MENU BUTTON HOVER CONTROLS
   ============================================ */
.menu-btn-wrapper {
    position: relative;
    display: inline-block;
}

/* Voorkom dat button links klikbaar zijn in editor */
.menu-btn-wrapper .slot-button {
    pointer-events: auto;
    cursor: pointer;
}

/* Alle links in de editor canvas niet klikbaar maken */
.editor-canvas a.slot-button {
    pointer-events: auto;
}

.menu-btn-controls {
    position: absolute;
    top: -8px;
    right: -8px;
    display: none;
    gap: 2px;
    z-index: 10;
}

.menu-btn-wrapper:hover .menu-btn-controls {
    display: flex;
}

.menu-btn-add,
.menu-btn-delete {
    width: 18px;
    height: 18px;
    border: none;
    border-radius: 50%;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    padding: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.menu-btn-add {
    background: var(--success);
    color: white;
}

.menu-btn-add:hover {
    background: #219a52;
}

.menu-btn-delete {
    background: var(--danger);
    color: white;
}

.menu-btn-delete:hover {
    background: #c0392b;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1200px) {
    .editor-sidebar {
        width: 240px;
    }
    
    .editor-panel {
        width: 260px;
    }
}

@media (max-width: 900px) {
    .editor-sidebar,
    .editor-panel {
        position: fixed;
        top: var(--editor-header-height);
        bottom: 0;
        z-index: 50;
        transform: translateX(-100%);
        transition: transform 0.3s;
    }
    
    .editor-sidebar.open {
        transform: translateX(0);
    }
    
    .editor-panel {
        right: 0;
        left: auto;
        transform: translateX(100%);
    }
    
    .editor-panel.open {
        transform: translateX(0);
    }
}

/* ============================================
   NIEUWE SIDEBAR STRUCTUUR
   Minimale sidebar + Uitschuifbaar blokken panel
   ============================================ */

/* Minimale Sidebar met icoon-knoppen */
.editor-sidebar-mini {
    width: 58px;
    background: white;
    border-right: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    z-index: 110;
    position: relative;
}

.sidebar-mini-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 46px;
    padding: 12px 4px;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--gray-600);
    position: relative;
}

.sidebar-mini-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: scale(1.05);
}

.sidebar-mini-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.sidebar-mini-btn svg:first-child {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.sidebar-mini-label {
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2px;
    white-space: nowrap;
    line-height: 1;
}

.sidebar-mini-arrow {
    display: none;
}

/* Welkomst Tooltip */
.welcome-tip {
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-80px);
    margin-left: 12px;
    z-index: 1000;
    animation: welcomePulse 2s ease-in-out infinite, welcomeSlideIn 0.4s ease-out;
}

@keyframes welcomePulse {
    0%, 100% { transform: translateY(-80px) scale(1); }
    50% { transform: translateY(-80px) scale(1.02); }
}

@keyframes welcomeSlideIn {
    from { opacity: 0; transform: translateY(-80px) translateX(-10px); }
    to { opacity: 1; transform: translateY(-80px) translateX(0); }
}

.welcome-tip-arrow {
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-right: 8px solid #6366f1;
}

.welcome-tip-content {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
    padding: 14px 18px;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
    min-width: 220px;
    max-width: 280px;
}

.welcome-tip-content strong {
    display: block;
    font-size: 15px;
    margin-bottom: 6px;
}

.welcome-tip-content p {
    font-size: 13px;
    line-height: 1.5;
    margin: 0 0 12px 0;
    opacity: 0.95;
}

.welcome-tip-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.welcome-tip-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.welcome-tip.hidden {
    display: none;
}

/* Pulserende ring rond de Blokken knop wanneer tip zichtbaar is */
.editor-sidebar-mini:has(.welcome-tip:not(.hidden)) #btnOpenBlocks::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 10px;
    border: 2px solid #6366f1;
    animation: ringPulse 1.5s ease-in-out infinite;
}

@keyframes ringPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.05); }
}

/* Blokken Panel Overlay (klikbaar om te sluiten, geen donkere achtergrond) */
.blocks-panel-overlay {
    position: fixed;
    top: var(--editor-header-height);
    left: 58px;
    right: 0;
    bottom: 0;
    background: transparent;
    z-index: 90;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.blocks-panel-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Overlay moet drag events doorlaten naar onderliggende elementen */
body.is-dragging-plugin .blocks-panel-overlay,
body.is-dragging-element .blocks-panel-overlay {
    pointer-events: none;
}

/* Blokken Panel (groot, uitschuifbaar) */
.blocks-panel {
    --blocks-panel-width: 480px;
    position: fixed;
    top: var(--editor-header-height);
    left: 58px;
    bottom: 0;
    width: var(--blocks-panel-width);
    background: white;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
    z-index: 500;
    display: flex;
    flex-direction: column;
    transform: translateX(-100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
    overflow: visible;
}

.blocks-panel.open {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.blocks-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-200);
}

.blocks-panel-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-800);
    margin: 0;
}

.blocks-panel-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    color: var(--gray-500);
    transition: all 0.2s;
}

.blocks-panel-close:hover {
    background: var(--gray-200);
    color: var(--gray-700);
}

.blocks-panel-search {
    padding: 12px 20px;
    border-bottom: 1px solid var(--gray-200);
}

.blocks-panel-search input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    background: var(--gray-50);
}

.blocks-panel-search input:focus {
    outline: none;
    border-color: var(--primary);
    background: white;
}

.blocks-panel-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: visible;
    padding: 16px 20px;
}

/* Blok Grid - 2 kolommen met grote previews */
.block-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 24px;
    overflow: visible;
}

/* Blok Card - grote preview */
.block-card {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    cursor: grab;
    transition: all 0.2s;
    position: relative;
}

.block-card:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
    transform: translateY(-2px);
}

.block-card.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

.block-card-preview {
    width: 100%;
    height: 80px;
    background: var(--gray-100);
    overflow: hidden;
    border-radius: 8px 8px 0 0;
}

.block-card-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.block-card-preview.no-thumb {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--gray-100), var(--gray-200));
    color: var(--gray-400);
}

.block-card-preview.no-thumb svg {
    width: 32px;
    height: 32px;
}

.block-card-name {
    display: block;
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 500;
    color: var(--gray-700);
    text-align: center;
    background: var(--gray-50);
    border-top: 1px solid var(--gray-100);
}

/* Category styling in blocks panel */
.blocks-panel-content .category-section {
    margin-bottom: 24px;
}

.blocks-panel-content .category-title {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--gray-500);
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Plugins Panel */
.plugins-panel {
    --blocks-panel-width: 400px;
}

.plugins-panel .blocks-panel-content {
    padding: 20px;
}

.plugins-intro {
    font-size: 13px;
    color: var(--gray-600);
    margin: 0 0 20px 0;
    line-height: 1.5;
}

.plugins-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray-500);
}

.plugins-empty-state svg {
    margin-bottom: 16px;
    opacity: 0.5;
}

.plugins-empty-state h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-700);
    margin: 0 0 8px 0;
}

.plugins-empty-state p {
    font-size: 13px;
    line-height: 1.5;
    margin: 0;
}

.plugins-panel .plugin-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.plugins-panel .plugin-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 10px;
    cursor: grab;
    transition: all 0.2s;
}

.plugins-panel .plugin-card:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.plugins-panel .plugin-card.plugin-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.plugins-panel .plugin-card.plugin-disabled:hover {
    border-color: var(--gray-200);
    box-shadow: none;
    transform: none;
}

.plugins-panel .plugin-card .block-card-preview {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
}

.plugins-panel .plugin-card .block-card-preview svg {
    width: 28px;
    height: 28px;
}

.plugins-panel .plugin-card .block-card-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--gray-800);
    display: block;
}

.plugins-panel .plugin-card .plugin-card-desc {
    font-size: 13px;
    color: var(--gray-500);
    display: block;
    margin-top: 2px;
}

/* Elementen Sidebar (compacte versie, verborgen standaard) */
.elements-sidebar {
    position: fixed;
    top: var(--editor-header-height);
    left: 58px;
    bottom: 0;
    width: var(--editor-sidebar-width);
    background: white;
    border-right: 1px solid var(--gray-200);
    z-index: 500;
    display: flex;
    flex-direction: column;
    transform: translateX(-100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.1);
}

.elements-sidebar.open {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.elements-sidebar .sidebar-categories {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}

.sidebar-header-compact {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid var(--gray-200);
}

.sidebar-header-compact h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--gray-800);
    margin: 0;
}

.sidebar-close-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    color: var(--gray-500);
    transition: all 0.2s;
}

.sidebar-close-btn:hover {
    background: var(--gray-200);
    color: var(--gray-700);
}

/* Canvas zoom effect wanneer blokken panel open is */
.editor-canvas {
    transition: padding 0.3s ease;
    position: relative;
}

/* Wanneer blokken panel open: centreer tussen blokken panel (480px) en eigenschappen panel (300px) */
.editor-canvas.zoomed-out {
    padding-left: 480px;
}

.editor-canvas.zoomed-out .canvas-wrapper {
    transform: scale(0.75);
    transform-origin: top center;
    transition: transform 0.3s ease;
}

/* Canvas shift wanneer elementen sidebar open is */
.editor-canvas.shifted {
    padding-left: 280px;
}

/* Blok Card Hover Preview Popup (JavaScript-gebaseerd, toegevoegd aan body) */
.block-hover-preview-popup {
    position: fixed;
    left: 58px;
    top: var(--editor-header-height);
    width: 480px;
    max-height: calc(100vh - var(--editor-header-height) - 20px);
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(0,0,0,0.1);
    z-index: 99999;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    overflow: hidden;
    transform: scale(0.95) translateY(10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.25s;
}

.block-hover-preview-popup.visible {
    opacity: 1;
    visibility: visible;
    transform: scale(1) translateY(0);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0s;
}

.block-hover-preview-popup img {
    width: 100%;
    height: auto;
    display: block;
}

.block-hover-preview-popup .preview-name {
    padding: 14px 18px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-800);
    background: var(--gray-50);
    border-top: 1px solid var(--gray-200);
}

/* Verberg inline hover previews (nu via JS) */
.block-hover-preview {
    display: none;
}

/* Verberg oude sidebar tabs (niet meer nodig) */
.sidebar-tabs {
    display: none;
}

.sidebar-tab-content {
    display: none;
}

/* ============================================
   PLUGINS SECTIE
   ============================================ */
.plugins-section {
    border-top: 2px solid var(--gray-200);
    margin-top: 16px;
    padding-top: 16px;
}

.plugins-section .category-title {
    display: flex;
    align-items: center;
    gap: 6px;
}

.plugin-badge-locked {
    font-size: 12px;
    margin-left: auto;
}

.plugin-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.plugin-card {
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}

.plugin-card.plugin-enabled:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.plugin-card.plugin-disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.plugin-card.plugin-disabled:hover {
    transform: none;
}

.plugin-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    border-radius: 8px;
    position: relative;
}

.plugin-preview svg {
    width: 32px;
    height: 32px;
}

.plugin-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

.plugin-lock-overlay svg {
    color: var(--gray-500);
    width: 24px;
    height: 24px;
}

.plugin-info-text {
    font-size: 12px;
    color: var(--gray-500);
    margin-top: 8px;
    text-align: center;
    padding: 8px;
    background: var(--gray-100);
    border-radius: 6px;
}

/* Plugin Block in Canvas */
.plugin-block {
    background: white;
    border: 2px dashed var(--gray-300);
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.plugin-block-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.plugin-block-icon svg {
    width: 28px;
    height: 28px;
}

.plugin-block-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--gray-800);
}

.plugin-block-desc {
    font-size: 14px;
    color: var(--gray-500);
    max-width: 400px;
}

.plugin-block-config-btn {
    margin-top: 8px;
    padding: 10px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.plugin-block-config-btn:hover {
    background: var(--primary-dark);
}

/* Plugin Config Modal */
.plugin-config-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.plugin-config-modal.active {
    opacity: 1;
    visibility: visible;
}

.plugin-config-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.plugin-config-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.plugin-config-header h3 {
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.plugin-config-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--gray-500);
    padding: 4px;
}

.plugin-config-close:hover {
    color: var(--gray-700);
}

.plugin-config-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.plugin-config-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.plugin-field-group {
    margin-bottom: 20px;
}

.plugin-field-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.plugin-field-group input,
.plugin-field-group select,
.plugin-field-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.plugin-field-group input:focus,
.plugin-field-group select:focus,
.plugin-field-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.plugin-field-group small {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: var(--gray-500);
}

.plugin-checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.plugin-checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: normal;
    cursor: pointer;
}

.plugin-checkbox-group input[type="checkbox"] {
    width: auto;
}

/* Plugin Modal Buttons */
.plugin-config-footer .btn {
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.plugin-config-footer .btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
}

.plugin-config-footer .btn-secondary:hover {
    background: var(--gray-200);
}

.plugin-config-footer .btn-primary {
    background: var(--primary);
    color: white;
}

.plugin-config-footer .btn-primary:hover {
    background: var(--primary-dark);
}

/* Contact Form Fields Manager */
.contact-fields-manager {
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 16px;
    margin-top: 8px;
}

.contact-field-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: var(--gray-50);
    border-radius: 6px;
    margin-bottom: 8px;
}

.contact-field-item:last-child {
    margin-bottom: 0;
}

.contact-field-item span {
    flex: 1;
    font-size: 14px;
}

.contact-field-item .field-type {
    font-size: 12px;
    color: var(--gray-500);
    background: var(--gray-200);
    padding: 2px 8px;
    border-radius: 4px;
}

.contact-field-item .field-required {
    font-size: 11px;
    color: var(--primary);
    font-weight: 500;
}

.contact-field-item button {
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    padding: 4px;
    font-size: 18px;
    line-height: 1;
}

.contact-field-item button:hover {
    color: var(--danger);
}

.add-field-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 10px;
    margin-top: 12px;
    background: var(--gray-100);
    border: 1px dashed var(--gray-300);
    border-radius: 6px;
    color: var(--gray-600);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.add-field-btn:hover {
    background: var(--gray-200);
    border-color: var(--gray-400);
}

/* Product Manager */
.product-manager {
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    overflow: hidden;
}

.product-manager-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-200);
}

.product-manager-header h4 {
    font-size: 14px;
    font-weight: 600;
    margin: 0;
}

.product-manager-header button {
    padding: 6px 12px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
}

.product-manager-header button:hover {
    background: var(--primary-dark);
}

.product-list {
    max-height: 300px;
    overflow-y: auto;
}

.product-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--gray-100);
}

.product-item:last-child {
    border-bottom: none;
}

.product-item-image {
    width: 50px;
    height: 50px;
    background: var(--gray-100);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.product-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-item-image span {
    font-size: 11px;
    color: var(--gray-400);
}

.product-item-info {
    flex: 1;
    min-width: 0;
}

.product-item-info strong {
    display: block;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-item-info span {
    font-size: 13px;
    color: var(--success);
    font-weight: 600;
}

.product-item-actions {
    display: flex;
    gap: 4px;
}

.product-item-actions button {
    padding: 6px 8px;
    background: var(--gray-100);
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.product-item-actions button:hover {
    background: var(--gray-200);
}

.product-item-actions button.delete:hover {
    background: var(--danger);
    color: white;
}

.product-empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--gray-500);
    font-size: 14px;
}

/* Product Form Modal */
.product-form-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10100;
}

.product-form-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.product-form-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.product-form-header h4 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}

.product-form-header button {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--gray-500);
}

.product-form-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.product-form-body .plugin-field-group {
    margin-bottom: 16px;
}

.product-form-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.product-form-footer .btn {
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
}

.product-form-footer .btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
}

.product-form-footer .btn-primary {
    background: var(--primary);
    color: white;
}

/* Product Image Picker */
.product-image-picker {
    border: 2px dashed var(--gray-300);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.product-image-picker:hover {
    border-color: var(--primary);
    background: var(--primary-light);
}

.product-image-picker.has-image {
    padding: 8px;
}

.product-image-picker img {
    max-width: 100%;
    max-height: 150px;
    border-radius: 6px;
}

.product-image-picker span {
    display: block;
    color: var(--gray-500);
    font-size: 14px;
}

/* Plugin Block Preview in Editor - Show form fields */
.plugin-block-preview {
    width: 100%;
    max-width: 400px;
    margin-top: 16px;
    text-align: left;
}

.plugin-block-preview .preview-field {
    margin-bottom: 16px;
}

.plugin-block-preview .preview-field label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.plugin-block-preview .preview-field input,
.plugin-block-preview .preview-field textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--gray-300);
    border-radius: 8px;
    font-size: 14px;
    background: white;
    pointer-events: none;
}

.plugin-block-preview .preview-field textarea {
    min-height: 80px;
    resize: none;
}

.plugin-block-preview .preview-submit {
    display: inline-block;
    padding: 12px 24px;
    background: var(--primary);
    color: white;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    margin-top: 12px;
}

/* Newsletter Preview */
.plugin-block-preview.newsletter-preview {
    display: flex;
    gap: 12px;
    align-items: center;
    max-width: 500px;
}

.plugin-block-preview.newsletter-preview input {
    flex: 1;
    padding: 14px 16px;
    font-size: 15px;
}

.plugin-block-preview.newsletter-preview .preview-submit {
    margin-top: 0;
    padding: 14px 24px;
}

/* Webshop Preview */
.plugin-block-preview.webshop-preview {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    max-width: 800px;
}

.plugin-block-preview .product-preview-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    overflow: hidden;
    text-align: left;
}

.plugin-block-preview .product-preview-card .img-placeholder {
    aspect-ratio: 1;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
    font-size: 12px;
}

.plugin-block-preview .product-preview-card .product-info {
    padding: 12px;
}

.plugin-block-preview .product-preview-card .name {
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.plugin-block-preview .product-preview-card .description {
    font-size: 11px;
    color: var(--gray-500);
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.plugin-block-preview .product-preview-card .price {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
}

.plugin-block-preview .product-preview-card .add-btn {
    width: 100%;
    padding: 8px;
    border: none;
    border-radius: 4px;
    font-weight: 500;
    font-size: 12px;
    cursor: default;
}

/* Webshop Preview - Loading & Empty states */
.webshop-preview .webshop-loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 20px;
    color: var(--gray-500);
    font-size: 13px;
}

.webshop-preview .webshop-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 20px;
    color: var(--gray-500);
}

.webshop-preview .webshop-empty p {
    margin: 4px 0;
}

.webshop-preview .product-preview-card .img-placeholder {
    overflow: hidden;
}

.webshop-preview .product-preview-card .img-placeholder .no-img {
    font-size: 10px;
    color: var(--gray-400);
}

.webshop-preview .product-preview-more {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: 1px dashed var(--gray-300);
    border-radius: 6px;
    padding: 12px;
    font-size: 13px;
    color: var(--gray-500);
    font-weight: 500;
}

/* ============================================
   COMPACTE PLUGIN PREVIEW
   ============================================ */

.plugin-block-compact {
    position: relative;
}

.plugin-block-compact .plugin-overlay {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    pointer-events: none;
}

.plugin-block-compact .plugin-overlay > * {
    pointer-events: auto;
}

.plugin-overlay-left {
    display: flex;
    align-items: center;
    gap: 6px;
}

.plugin-status-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
}

.plugin-status-icon.configured {
    background: #d1fae5;
    color: #059669;
}

.plugin-status-icon.needs-config {
    background: #fef3c7;
    color: #d97706;
}

.plugin-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.plugin-config-btn-mini {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    transition: all 0.15s ease;
}

.plugin-config-btn-mini:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.05);
}

/* Verberg oude plugin block elementen */
.plugin-block-compact .plugin-block-icon,
.plugin-block-compact .plugin-block-title,
.plugin-block-compact .plugin-block-status,
.plugin-block-compact .plugin-block-config-btn {
    display: none;
}

/* Plugin preview neemt nu volledige ruimte */
.plugin-block-compact .plugin-block-preview {
    margin: 0;
    padding-top: 40px; /* Ruimte voor overlay */
}

/* Hover edit overlay voor plugins */
.plugin-hover-edit {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--primary);
    color: white;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    z-index: 20;
}

.plugin-block-compact:hover .plugin-hover-edit {
    opacity: 1;
    visibility: visible;
}

.plugin-hover-edit:hover {
    background: var(--primary-dark);
    transform: translate(-50%, -50%) scale(1.05);
}

/* ============================================
   PLUGIN CONFIG TABS
   ============================================ */

.plugin-config-tabs {
    display: flex;
    border-bottom: 1px solid var(--gray-200);
    padding: 0 20px;
    gap: 4px;
}

.plugin-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    border: none;
    background: none;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-500);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: all 0.15s ease;
}

.plugin-tab:hover {
    color: var(--gray-700);
}

.plugin-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.plugin-tab svg {
    opacity: 0.7;
}

.plugin-tab.active svg {
    opacity: 1;
}

.plugin-tab-content {
    display: none;
}

.plugin-tab-content.active {
    display: block;
}

/* Color picker row */
.color-picker-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.color-picker-row input[type="color"] {
    width: 40px;
    height: 36px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    cursor: pointer;
    padding: 2px;
}

.color-picker-row .color-text-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 13px;
    font-family: monospace;
}

/* Slot Plugin Styling */
.slot-plugin {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 12px;
    position: relative;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.slot-plugin:hover {
    border-color: var(--primary);
}

.slot-plugin.selected {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.slot-plugin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.slot-plugin-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.slot-plugin-status {
    font-size: 14px;
}

.slot-plugin-status.configured {
    color: var(--success);
}

.slot-plugin-status.needs-config {
    color: var(--warning);
}

.slot-plugin-preview {
    margin-bottom: 10px;
}

/* Webshop element preview - behoud originele hoogte */
.slot-plugin-preview.webshop-element-preview {
    min-height: auto !important;
    height: auto !important;
    overflow: visible;
}

/* Plugin elementen in kolommen - voorkom compressie */
.rendered-block .block-column:has(.slot-plugin) {
    overflow: visible;
    min-height: auto;
}

.rendered-block .slot-plugin {
    flex-shrink: 0;
}

/* Contact form mini preview */
.contact-form-mini {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.contact-form-mini .mini-field {
    display: flex;
    align-items: center;
    gap: 8px;
}

.contact-form-mini .mini-label {
    font-size: 10px;
    color: var(--gray-500);
    width: 50px;
}

.contact-form-mini .mini-input {
    flex: 1;
    height: 20px;
    background: var(--gray-100);
    border-radius: 4px;
}

.contact-form-mini .mini-textarea {
    flex: 1;
    height: 32px;
    background: var(--gray-100);
    border-radius: 4px;
}

.contact-form-mini .mini-btn,
.newsletter-mini .mini-btn {
    display: inline-block;
    padding: 6px 12px;
    background: var(--primary);
    color: white;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-align: center;
    margin-top: 4px;
}

/* Newsletter mini preview */
.newsletter-mini {
    display: flex;
    gap: 8px;
    align-items: center;
}

.newsletter-mini .mini-input {
    height: 28px;
    background: var(--gray-100);
    border-radius: 4px;
}

/* Webshop mini preview */
.webshop-mini {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.webshop-mini .mini-product {
    aspect-ratio: 1;
    background: var(--gray-100);
    border-radius: 4px;
}

.slot-plugin-config-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 8px;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    color: var(--gray-700);
    cursor: pointer;
    transition: all 0.15s ease;
}

.slot-plugin-config-btn:hover {
    background: var(--gray-200);
}

/* Plugin element in sidebar */
.element-item.plugin-element {
    border: 1px dashed var(--gray-300);
}

.element-item.plugin-element:hover {
    border-color: var(--primary);
    background: var(--primary-light);
}
