/* PBusiness (PRAJZ) custom styles */

/* Navbar company logo: show cleanly with rounded corners (not a sharp box) */
.navbar .navbar-brand img.logo,
.navbar-logo-container img.logo {
    border-radius: 8px;
    object-fit: contain;
}

/*
 * Navbar version badge ("v9.1.7") vertical alignment.
 *
 * Root cause (verified in live DOM, viewport 1440x900):
 *   Stock Espo renders the badge as <div id="nav-show-extensions">v9.1.7</div>
 *   inside <li data-item="espoVersion">. The inner div carries an INLINE
 *   `height:100%` while its <li> collapses to content height (~21px) instead
 *   of the 45px navbar row. Result: the div lands at y=0 (cy=11), i.e. ~12px
 *   ABOVE the vertically-centered search box / help / power icons (cy=23).
 *
 * Fix: force the <li> to stretch to the full 45px row and flex-center its
 * content, and neutralize the inner div's collapsing inline `height:100%`.
 * Measured after fix: badge cy=23 == icon row cy=23 (delta ~1px vs search).
 *
 * NOTE: the reason a previous copy of this rule "did not work" for the user
 * was NOT the CSS itself but browser caching — Espo busts custom cssList URLs
 * with `?r=<appTimestamp>`, and appTimestamp had gone stale, so returning
 * browsers kept the pre-fix cached file. `command.php rebuild` bumps
 * appTimestamp and forces a refetch. !important below hardens against theme
 * overrides.
 */
.navbar .navbar-nav > li[data-item="espoVersion"] {
    display: flex !important;
    align-items: center !important;
    align-self: stretch !important;
}

.navbar #nav-show-extensions {
    height: auto !important;
    align-self: center !important;
    position: static !important;
    top: auto !important;
}

/*
 * Validation tooltip (A4) — keep it visible above the fixed header.
 *
 * Root cause: Bootstrap `.popover` (used by Espo for the "Pole je povinné"
 * validation message) ships z-index:1600, but the fixed side-navbar is raised
 * to z-index:2150 !important. When a required field near the top fails
 * validation, its popover renders UNDER the header and looks clipped/hidden.
 *
 * Fix: lift the validation popover above the navbar (2150) while staying below
 * true overlays. Also give form fields a scroll-margin-top so any scroll (native
 * or JS, see records/base onInvalid override) lands the field BELOW the ~45px
 * fixed header instead of behind it.
 */
.popover {
    z-index: 2200 !important;
}

.record .cell,
.record .field,
.panel-body .cell,
.panel-body .field {
    scroll-margin-top: 70px;
}

/*
 * Prázdné middle panely tabů (tabBreak bez polí, např. Opportunity "Doklady a nabídky"
 * / "Realizace a provize") renderují prázdný rám. Reálné panely mají třídu .headered,
 * prázdné ne — skryjeme jen ty bez hlavičky a bez buněk. Zůstává tab bar + dolní panely.
 */
.middle > .panel.panel-default:not(.headered):not(:has(.cell)) {
    display: none !important;
}

/*
 * 36979 — Quote item grid: column widths come from layouts/QuoteItem/listItem.json;
 * the CSS below keeps every row on one line (unit next to quantity, "%" addon inline,
 * compact numeric inputs) and lets long money values wrap instead of overflowing.
 */
[data-scope="Quote"] .field[data-name="items"] th.field-header-cell {
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="listPrice"] input,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="unitPrice"] input {
    padding-left: 4px;
    padding-right: 4px;
}
/* Numeric inputs must not outgrow their column and cover the next one. */
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td input.form-control {
    min-width: 0;
    max-width: 100%;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td .input-group-currency,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td .input-group-currency .input-group-item {
    width: 100%;
    min-width: 0;
}
[data-scope="Quote"] .field[data-name="items"] .list:not(.edit-mode) td .cell-wrapper,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="sellingUnitPrice"] .cell-wrapper,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="amount"] .cell-wrapper,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="taxAmount"] .cell-wrapper,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="amountWithTax"] .cell-wrapper {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}
[data-scope="Quote"] .field[data-name="items"] td .cell-wrapper .numeric-text {
    white-space: nowrap;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] .cell-wrapper {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] .input-group-item {
    display: block;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] .input-group-item:first-child {
    flex: 1 1 auto;
    min-width: 3.5em;
}
/* The free-text unit input has a ~20ch intrinsic width; without a fixed basis it squeezed the quantity to zero. */
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] .input-group-item:last-child {
    flex: 0 0 3.2em;
    min-width: 0;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="lineOriginType"] select {
    padding-left: 4px;
    padding-right: 2px;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] input,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="quantity"] select {
    width: 100%;
    min-width: 0;
    padding-left: 4px;
    padding-right: 2px;
}
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="priceMarginPercentage"] input,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="taxRate"] input,
[data-scope="Quote"] .field[data-name="items"] .list.edit-mode td[data-name="discount"] input {
    padding-left: 4px;
    padding-right: 4px;
    text-align: right;
}
[data-scope="Quote"] .field[data-name="items"] .input-group-percentage {
    display: flex;
    flex-wrap: nowrap;
}
[data-scope="Quote"] .field[data-name="items"] .input-group-percentage .input-group-addon {
    width: auto;
    padding-left: 4px;
    padding-right: 4px;
}

/* Quote items grouped by their source supplier quote/file (#36976). */
.quote-item-group-row > td {
    padding: 8px 10px !important;
    background: var(--panel-bg, #f5f7f9);
    border-top: 2px solid var(--panel-border, #d7dce1) !important;
}

.quote-item-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.quote-item-group-name {
    font-weight: 600;
}

.quote-item-group-margin {
    margin-left: 4px;
}

.quote-item-group-included {
    margin: 0 0 0 auto;
    font-weight: 400;
    white-space: nowrap;
}

/* Row tools left of the quote item name (#41114): add montage, save to the catalogue. */
.quote-item-name-cell > .quote-item-tools {
    float: left;
    display: flex;
    flex-direction: column;
    margin-right: 2px;
}

.quote-item-name-cell > .quote-item-tools > .btn {
    padding: 0 3px;
    line-height: 1.3;
}

/*
 * Task create/edit modal (#38806): wider dialog, and the parent-type select in a
 * full-width "Nadřazený záznam" row shows the whole type name.
 */
.dialog-record:has(.record .cell[data-name="childrenTasks"]) .modal-dialog {
    width: min(1100px, calc(100vw - 32px));
    max-width: none;
}

.cell.col-md-12[data-name="parent"] .input-group-link-parent > .input-group-item:first-child {
    min-width: 12em;
}

/*
 * Side menu scrolls (#41110). AutocrmThemes autoerp.css sets `overflow-y: hidden` on the side
 * navbar tab list from 768px up, so on a laptop (1366x768) every item below ~670px - Kalendář,
 * Servis, Banka, Nastavení - was cut off with no way to reach it (training 20 Nov 2026:
 * "nevidím kalendár"). Let the list scroll with a thin scrollbar; `html` outranks the theme,
 * which loads after this file with the same selector.
 */
@media screen and (min-width: 768px) {
    html body[data-navbar="side"] #navbar .navbar ul.tabs {
        overflow-y: auto;
        scrollbar-width: thin;
    }
}

/* E-mail reading pane (SUP-3301): the subject reads as the headline, like in a mail client. */
.email-reading-pane .cell[data-name="subject"] .field {
    font-size: 1.4em;
    font-weight: 600;
    line-height: 1.3;
}

/* Quote item multi-select (SUP-3307): row checkbox left of the row tools, bulk bar under the list. */
.quote-item-name-cell > .quote-item-select,
td.cell[data-name="name"] > .quote-item-select {
    float: left;
    margin: 6px 4px 0 0;
}

tr.list-row.quote-item-selected > td {
    background: #fff6dc !important;
}

tr.list-row.quote-item-drag-companion {
    opacity: 0.45;
}

.quote-items-bulk {
    position: sticky;
    bottom: 0;
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: var(--panel-bg, #f5f7f9);
    border-top: 1px solid var(--panel-border, #d7dce1);
}

.quote-items-bulk-all {
    margin: 0;
    font-weight: 600;
}

/*
 * E-mail reading pane header (SUP-3308): collapsed to sender and date on one line, no labels;
 * "Podrobnosti" (custom:views/email/record/combined-detail) expands the rest. AutocrmThemes sets
 * `div.detail .row > .cell { display: block !important }` from 1400px, so `html body` and
 * `!important` are needed to outrank it.
 */
html body .email-reading-pane.email-header-collapsed .row > .cell:is([data-name="to"], [data-name="parent"],
    [data-name="cc"], [data-name="bcc"], [data-name="replied"], [data-name="replies"]) {
    display: none !important;
}

.email-reading-pane.email-header-collapsed .cell:is([data-name="from"], [data-name="dateSent"]) > .control-label {
    display: none;
}

.email-reading-pane.email-header-collapsed .cell[data-name="dateSent"] .field {
    text-align: right;
}

.email-reading-pane .email-header-toggle-row .cell {
    margin-bottom: var(--10px, 10px);
    font-size: 0.92em;
}

/* SUP-3382: live contract data in "Upravené znění smlouvy" (filled from the contract fields on save) */
.field[data-name="workTerms"] .wt-field {
    background: #f6efdc;
    border-bottom: 1px dashed #ab8f36;
    border-radius: 3px;
    padding: 0 2px;
    cursor: help;
}

/*
 * Home-page chart cards in the look of the client's chart template (SUP-3401): white card, a 4px
 * gold accent bar left of the title, semibold title in the theme's text colour (readable on Dark too).
 * A Report dashlet counts as a chart card once its Flotr canvas renders; the bars and colours themselves come from
 * custom:chart-gold-bars and the theme's chart colours (metadata themes/AutoERP.json).
 */
.dashlet-container[data-name="SalesPipeline"] .panel-title,
.dashlet-container[data-name="OpportunitiesByStage"] .panel-title,
.dashlet-container:has(canvas.flotr-canvas) .panel-title {
    border-left: 4px solid #ab8f36;
    padding-left: 10px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* The report's "Souhrn" figure above a chart takes the gold (it took the report's own chart colour before). */
.dashlet-container:has(canvas.flotr-canvas) .numeric-text.text-primary {
    color: #ab8f36;
}

/*
 * Whole AutoERP UI in the client's PRAJZ template (SUP-3401, round 2; client sample vzor-system.png):
 * charcoal side menu with gold icons and a gold pill for the active item, white top bar, warm off-white
 * page, white rounded cards with a soft shadow and the 4px gold title accent, gold primary buttons and
 * links. Scoped to the AutoERP theme (`html:has(#main-stylesheet[href*=autoerp])`), so a user on Dark
 * keeps it as it was; the id inside :has() also outranks the theme's own selectors. Text colours are
 * chosen for WCAG AA: white on #8c722b is 4.6:1, link #7a6324 on white 5.8:1, on the page 5.2:1.
 */
html:has(#main-stylesheet[href*="autoerp"]) {
    --prajz-gold: #ab8f36;
    --prajz-gold-icon: #cfae55;
    --prajz-gold-dark: #8c722b;
    --prajz-gold-darker: #7a6324;
    --prajz-gold-deep: #66501b;
    --prajz-beige: #f6efdc;
    --prajz-cream: #f5f2ec;
    --prajz-line: #e4ddcd;
    --prajz-text: #2b2b2b;
    --prajz-muted: #5f5f5f;

    --body-bg: var(--prajz-cream);
    --fc-page-bg-color: var(--prajz-cream);
    --text-color: var(--prajz-text);
    --text-gray-color: var(--prajz-muted);
    --text-muted-color: var(--prajz-muted);
    --panel-default-text: var(--prajz-text);
    --form-control-color: var(--prajz-text);
    --input-color: var(--prajz-text);
    --code-color: var(--prajz-text);
    --btn-text-color: var(--prajz-text);
    --dropdown-link-color: var(--prajz-text);
    --navbar-link-color: var(--prajz-text);
    --select-item-text-color: var(--prajz-text);
    --field-info-color: #8a8a8a;
    --field-info-hover-color: var(--prajz-gold-dark);

    --brand-primary: var(--prajz-gold-dark);
    --brand-primary-5: var(--prajz-gold-darker);
    --brand-primary-10: var(--prajz-gold-deep);
    --brand-primary-light: #efe6c8;
    --brand-primary-lighter: #faf6ea;
    --brand-primary-lighten-10: var(--prajz-gold);
    --brand-primary-lighten-30: #c6ad5b;
    --brand-primary-lighten-50: #dfcb8a;
    --state-primary-text: var(--prajz-gold-darker);
    --link-color: var(--prajz-gold-darker);
    --link-hover-color: var(--prajz-gold-deep);
    --site-footer-color: var(--prajz-gold-darker);

    --btn-primary-bg: var(--prajz-gold-dark);
    --btn-primary-border: var(--prajz-gold-dark);
    --btn-primary-hover-bg: var(--prajz-gold-darker);
    --btn-primary-hover-border: var(--prajz-gold-darker);
    --btn-primary-active-bg: var(--prajz-gold-deep);
    --btn-primary-active-border: var(--prajz-gold-deep);
    --btn-default-color: #3d3d3d;
    --btn-default-border: var(--prajz-line);
    --btn-default-hover-bg: #f8f4ea;
    --btn-default-hover-border: #d6cbb0;
    --btn-default-active-bg: #f3ecd9;
    --btn-default-active-border: #d6cbb0;

    --select-item-active-bg: var(--prajz-gold-dark);
    --input-bg: #fbfaf7;
    --form-control-bg: #fbfaf7;
    --input-bg-disabled: #efebe2;
    --input-border: var(--prajz-line);
    --input-border-focus: var(--prajz-gold);
    --input-border-focus-rgba: rgba(171, 143, 54, .5);
    --form-control-focus-border-color: rgba(171, 143, 54, .6);
    --form-control-focus-shadow: 0 0 4px 1px rgba(171, 143, 54, .3), 0 0 0 1px var(--prajz-gold);
    --default-border-color: #ddd5c3;
    --caret-color-hover: var(--prajz-gold-dark);

    --dropdown-link-hover-bg: #f3ecd9;
    --dropdown-link-hover-color: var(--prajz-text);
    --navbar-link-hover-bg: #f6f1e5;
    --navbar-link-active-bg: #f3ecd9;
    --table-bg-accent: #faf8f3;
    --table-active-bg: #f8f4ea;
    --table-th-bg-color: #3d3d3d;
    --table-th-hover-bg-color: #262626;
    --label-default-bg: #4d4d4d;
    --panel-default-heading-bg: #ffffff;
    --calendar-today-bg: #faf6ea;

    --panel-border-radius: 12px;
    --panel-box-shadow: 0 2px 12px rgba(40, 32, 10, .07);
    --panel-box-shadow-hover: 0 4px 20px rgba(40, 32, 10, .12);

    --navbar-inverse-bg: linear-gradient(180deg, #1d1d1d 0%, #121212 100%);
    --navbar-inverse-link-active-bg: #2a2a2a;
}

/* Side menu: charcoal, white labels, gold icons (over the per-tab inline colours), grey group labels. */
html:has(#main-stylesheet[href*="autoerp"]) body[data-navbar="side"] #navbar .navbar ul.tabs li.tab-group {
    background-color: transparent;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs > li > a {
    color: #f4f4f4;
    border-radius: 12px;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs .short-label {
    color: var(--prajz-gold-icon) !important;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs .group-caret {
    color: #bdbdbd;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs > li.tab-divider > div > .label-text {
    color: #9e9e9e;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs > li > a:hover,
html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs > li > a:focus {
    color: #ffffff;
    background: rgba(171, 143, 54, .16);
}

/* Active item: the gold pill of the sample (gradient, gold border); the inline tab colour border is replaced. */
html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs li.active > a {
    color: #ffffff;
    background: linear-gradient(90deg, #7d6526 0%, #4a3c17 100%);
    border: 1px solid var(--prajz-gold) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 2px 8px rgba(0, 0, 0, .35);
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar ul.tabs li.active > a .short-label {
    color: #f3d98a !important;
}

/* Top bar: white, dark icons, a light rounded search field with a visible border. */
html:has(#main-stylesheet[href*="autoerp"]) #navbar .navbar-right > li > a,
html:has(#main-stylesheet[href*="autoerp"]) #navbar .navbar-right .global-search-container a.global-search-button {
    color: #2b2b2b;
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar .navbar-right > li > a:hover {
    color: var(--prajz-gold-dark);
}

html:has(#main-stylesheet[href*="autoerp"]) #navbar .global-search-container input {
    background-color: #f7f5f0;
    border: 1px solid #ddd6c6;
}

/* Cards: every dashlet and record panel title carries the gold accent bar of the sample. */
html:has(#main-stylesheet[href*="autoerp"]) .dashlet-container .panel-title,
html:has(#main-stylesheet[href*="autoerp"]) .record .panel-default > .panel-heading > .panel-title {
    border-left: 4px solid var(--prajz-gold);
    padding-left: 10px;
    font-weight: 600;
}

html:has(#main-stylesheet[href*="autoerp"]) .panel {
    box-shadow: var(--panel-box-shadow);
}

/* Chart totals as in the sample: gold figure in a light beige pill with a coin icon. */
html:has(#main-stylesheet[href*="autoerp"]) .dashlet-container:has(canvas.flotr-canvas) .numeric-text.text-primary {
    color: var(--prajz-gold-darker);
    background: var(--prajz-beige);
    display: inline-block;
    border-radius: 10px;
    padding: 0 14px;
    font-weight: 600;
}

html:has(#main-stylesheet[href*="autoerp"]) .dashlet-container:has(canvas.flotr-canvas) .numeric-text.text-primary::before {
    content: "\f51e";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 8px;
    color: var(--prajz-gold);
}

/* Round "+" create button of list headers: gold instead of the theme's green (status colours stay green). */
html:has(#main-stylesheet[href*="autoerp"]) .page-header .header-buttons > .main-header-manu-action:is([data-action="create"], [data-action="quickCreate"]) {
    background-color: var(--prajz-gold-dark);
    border-color: var(--prajz-gold-dark);
}

html:has(#main-stylesheet[href*="autoerp"]) .page-header .header-buttons > .main-header-manu-action:is([data-action="create"], [data-action="quickCreate"]):hover {
    background-color: var(--prajz-gold-darker);
}

html:has(#main-stylesheet[href*="autoerp"]) .page-header .header-buttons:has(.main-header-manu-action[data-action="composeEmail"]) > .main-header-manu-action[data-action="composeEmail"] {
    background-color: var(--prajz-gold-dark);
    border-color: var(--prajz-gold-dark);
}

/* Recent-record tabs in the top bar as rounded pills with a round close button, as in the sample. */
html:has(#main-stylesheet[href*="autoerp"]) .history-tabs-container .history-tabs {
    gap: 8px;
}

html:has(#main-stylesheet[href*="autoerp"]) .history-tabs-container .history-tab {
    height: 34px;
    border: 1px solid transparent;
    border-radius: 17px;
    background-color: #f2efe8;
    color: #3d3d3d;
    opacity: 1;
}

html:has(#main-stylesheet[href*="autoerp"]) .history-tabs-container .history-tab:hover {
    background-color: #ebe5d6;
}

html:has(#main-stylesheet[href*="autoerp"]) .history-tabs-container .history-tab.active {
    background-color: #ffffff;
    border: 1px solid #d9cba3 !important;
    color: var(--prajz-text);
    font-weight: 600;
}

/* Menu button of the collapsed side menu in gold like the menu icons. */
html:has(#main-stylesheet[href*="autoerp"]) #navbar .navbar-header :is(a.side-menu-button, .navbar-toggle) {
    color: var(--prajz-gold-icon);
}

/*
 * E-mail folders column (SUP-3460): a fixed 180px instead of col-md-2, which was 330px on a 2258px
 * window (Růžalovský: "zabírá strašně moc místa") and 159px at 1024px, where a four-digit unread count
 * ran over "Doručené". 180px fits the longest folder name ("Rozepsané") and the count; the list and the
 * reading pane share the rest 3:7 as before. Below 992px the theme's col-sm layout is unchanged.
 */
@media screen and (min-width: 992px) {
    #main .email-combined > .left-container {
        width: 180px;
    }

    #main .email-combined > .left-container ~ .list-container {
        width: calc(100% - 180px);
    }

    #main .email-combined.is-combined > .left-container ~ .list-container {
        width: calc((100% - 180px) * 0.3);
    }

    #main .email-combined.is-combined > .left-container ~ .detail-container {
        width: calc((100% - 180px) * 0.7);
    }
}

/*
 * A task on the calendar time axis (SUP-3461, custom:views/calendar/calendar): the Autocrm renderer puts icon, time and
 * name on one nowrap line, which left "Koni…" in a week column. The block already stands at its time on the axis, so the
 * time text gives way and the name gets up to two lines.
 */
.fc-timegrid-event:has(.fa-tasks) .fc-event-main > div > span:not(:last-child) {
    display: none;
}

.fc-timegrid-event:has(.fa-tasks) .fc-event-main > div > span:last-child {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    white-space: normal !important;
    line-height: 1.25;
}

/*
 * Meeting place under the name on calendar events (SUP-3513, custom:helpers/calendar-place puts it after a line break):
 * one row each with its own ellipsis in the Autocrm renderer (month, week, day); the shared view's title keeps wrapping.
 */
.fc-event-main > div > span:last-child {
    white-space: pre !important;
    line-height: 1.25;
}

.fc-event-main .fc-event-title {
    white-space: pre-line;
}

/*
 * Multi-day and all-day events: the Autocrm renderer writes the title as bare text into its column div (no span),
 * so the line break needs the div itself (SUP-3535: "je to v jednom řádku" on a meeting spanning two days).
 */
.fc-event-main > div {
    white-space: pre-line;
}

/* Časová osa: the place on the item's second row (vis-timeline sets nowrap; the row grows to two lines). */
.timeline .vis-item .vis-item-content {
    white-space: pre;
    line-height: 1.25;
}

/* Month cells are narrow: icon and time on the first row, name and place each on a full-width row below. */
.fc-daygrid-event .fc-event-main > div {
    flex-wrap: wrap;
    row-gap: 0 !important;
}

.fc-daygrid-event .fc-event-main > div > span:last-child {
    flex: 0 0 100% !important;
}
