﻿.page-builder {
    height: calc(100vh - var(--mud-appbar-height) + 24px);
}

.page-builder-content {
    max-width: 1200px;
    margin: 0 auto 0 auto;
    padding: 10px 10px 50px 10px;
}

.page-builder-content-wrapper {
    overflow-y: scroll;
}

.page-builder-settings-drawer {
    height: calc(100vh - var(--mud-appbar-height));
    overflow-y: scroll;
    position: sticky;
    top: var(--mud-appbar-height);
    padding: 10px;
    box-shadow: -5px 0 10px rgba(0, 0, 0, 0.1);
}

.add-row-drop-zone {
    height: 6px;
    margin: 20px 0 20px 0;
    border: 1px dashed gray;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.draggable-component-wrapper {
    width: 100%;
    height: 100%;
    padding: 20px;
}

.editor-wrapper {
    height: 100% !important;
}

.tinymce-wrapper {
    height: 100%;
    width: 100%;
    display: flex; /* Enables flex context */
    flex-direction: column;
    overflow: hidden; /* Prevents double scrollbars */
}

    .tinymce-wrapper .tox-tinymce {
        height: 100% !important; /* Force override of TinyMCE's inline style */
        flex-grow: 1; /* Grow to fill available space */
        border: none !important; /* Optional: Looks cleaner in a dashboard */
    }

.static-page-container {
    display: grid;
    /* Matches your SfDashboardLayout Columns="6" */
    grid-template-columns: repeat(12, 1fr);
    /* Adjust this to match your desired Aspect Ratio or let content dictate height */
    /* Gap matches Syncfusion default cell spacing */
    gap: 10px;
    width: 100%;
    grid-auto-rows: 75px;
}

.viewer-component {
    width: 100%;
    height: 100%;
}

.static-page-item {
    /* Optional: Ensure content fills the 'widget' area */
    /*height: 100%;
    width: 100%;*/
    /* No borders, no shadows - just pure content */
    background: transparent;
    overflow-wrap: break-word;
}

.text-block-content p {
    margin-bottom: 1em !important; /* Adds the gap back */
    line-height: 1.6; /* improves readability */
    display: block; /* ensures it breaks to a new line */
}

/* Optional: Fix lists if you use them in TinyMCE later */
.text-block-content ul, .text-block-content ol {
    padding-left: 2rem;
    margin-bottom: 1em;
}

.text-block-content li {
    list-style-type: disc; /* Restores bullets */
}

@media (max-width: 600px) {
    .static-page-container {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }

    .static-page-item {
        /* Reset grid positioning for mobile stack */
        grid-column: auto !important;
        grid-row: auto !important;
    }
}

.page-picker-item {
    padding: 8px 12px;
    border-radius: 4px;
}

.page-picker-item-clickable:hover {
    background-color: var(--mud-palette-action-default-hover);
    cursor: pointer;
}

/* Carousel Styles */
.carousel-slide {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.carousel-slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-slide-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--mud-palette-background-grey);
    color: var(--mud-palette-text-secondary);
}

.carousel-slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 20px;
}

.carousel-slide-content {
    color: white;
}

.carousel-slide-title {
    margin: 0 0 5px 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.carousel-slide-description {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.9;
}

.carousel-slide-link {
    text-decoration: none;
    display: block;
    height: 100%;
}