/* @file
 * This file is loaded into the frontend (As opposed to dpl_admin, that is
 * only added on admin pages).
 * NOTICE - these styles are added for **all** users - not just admins.
 */

/* Make sure that dialogs are placed above the DPL frontend. */
:root {
  --jui-dialog-z-index: 9999 !important;
}

/* Re-arranging the "preview" toolbar, that is shown when editors preview nodes. */
.node-preview-form-select .form-item-view-mode {
  display: flex !important;
  align-items: center !important;
  all: inherit !important;
}

/* Custom icons for the Gin admin toolbars. */
.toolbar-menu-administration .toolbar-icon-dpl-breadcrumb-breadcrumb-structure:before {
  mask-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 24 24"><path fill="currentColor" d="M5.023 11.278c-.051.463.064.86.387 1.183l3.776 3.776l-1.414 1.414l-3.627-3.627l-.03.082c-.558 1.52-.036 3.24 1.175 4.527c1.213 1.289 2.943 1.955 4.538 1.55c2.124-.538 4.425-2.026 6.429-3.946c1.92-2.004 3.407-4.305 3.946-6.429c.405-1.595-.261-3.325-1.55-4.538c-1.287-1.211-3.006-1.733-4.527-1.176l-.082.03l3.627 3.628l-1.414 1.414L12.48 5.39c-.323-.323-.72-.438-1.183-.387c-.489.054-1.03.297-1.49.677c-.463.383-.757.832-.853 1.209c-.085.328-.031.6.23.863l4.243 4.242l-1.414 1.414l-4.242-4.242c-.262-.262-.535-.316-.863-.231c-.377.096-.826.39-1.21.854c-.379.46-.622 1-.676 1.489m1.906-4.369a3.14 3.14 0 0 1 .088-.518c.229-.888.82-1.676 1.518-2.253c.702-.58 1.599-1.02 2.544-1.123c.31-.035.627-.032.941.014c.146-.167.312-.285.445-.368c.267-.167.604-.31.973-.445c2.413-.883 4.904.015 6.586 1.598c1.681 1.582 2.743 4.022 2.118 6.486c-.656 2.587-2.395 5.19-4.457 7.337l-.014.014l-.014.014c-2.147 2.062-4.75 3.8-7.337 4.457c-2.464.625-4.904-.437-6.486-2.118c-1.583-1.682-2.481-4.173-1.598-6.586c.136-.37.278-.706.445-.973c.083-.133.201-.299.368-.445a3.697 3.697 0 0 1-.014-.941c.104-.945.543-1.842 1.123-2.544c.577-.698 1.365-1.29 2.253-1.518a3.14 3.14 0 0 1 .518-.088"/></svg>') !important;
}

.toolbar-menu-administration .toolbar-icon-dpl-admin-redirect:before {
  mask-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 24 24"><path fill="currentColor" d="M5 13q-.425 0-.712-.288T4 12t.288-.712T5 11h6.6l5-5H15q-.425 0-.712-.288T14 5t.288-.712T15 4h4q.425 0 .713.288T20 5v4q0 .425-.288.713T19 10t-.712-.288T18 9V7.4l-5.025 5.025q-.275.275-.637.425t-.763.15zm10 7q-.425 0-.712-.288T14 19t.288-.712T15 18h1.6l-2.475-2.45q-.3-.3-.3-.712t.3-.713t.725-.3t.725.3L18 16.6V15q0-.425.288-.712T19 14t.713.288T20 15v4q0 .425-.288.713T19 20z"/></svg>') !important;
}

/*
  The DPL header gets confused when the admin toolbar exists, and keeps being
  placed in a wrong position.
  We'll just completely disable the dynamic movement, when the toolbar is
  visible.
*/
.toolbar-fixed {
  .header,
  .header[style] {
    top: 0 !important;
  }
}

/* Gin wants to hide the text of the secondary toolbar items way too early. */
@media (min-width: 61em) {
  .toolbar-horizontal .gin-secondary-toolbar .toolbar-secondary .toolbar-bar .toolbar-tab .toolbar-item {
    font-size: inherit;
    width: auto;
    height: auto;
  }
}

.swagger-ui code {
  background: transparent;
}
