/*
 * @link https://www.humhub.org/
 * @copyright Copyright (c) 2017 HumHub GmbH & Co. KG
 * @license https://www.humhub.com/licences
 */

.markdown-render h1,
.markdown-render h2,
.markdown-render h3,
.markdown-render h4,
.markdown-render h5,
.markdown-render h6 {
    font-weight: bold !important;
}

.markdown-render h1 {
    font-size: 28px !important;
}

.markdown-render h2 {
    font-size: 24px !important;
}

.markdown-render h3 {
    font-size: 18px !important;
}

.markdown-render h4 {
    font-size: 16px !important;
}

.markdown-render h5 {
    font-size: 14px !important;
}

.markdown-render h6 {
    color: #999;
    font-size: 14px !important;
}

.markdown-render pre {
    border: none;
    border-radius: 3px;
    padding: 0;
}

.markdown-render pre code {
    border-radius: 3px;
    font-size: 12px !important;
    padding: 10px;
}

.markdown-render a,
.markdown-render a:visited {
    background-color: inherit;
    color: #6fdbe8 !important;
    text-decoration: none;
}

.markdown-render img {
    max-width: 100%;
}

.markdown-render table {
    width: 100%;
}

.markdown-render table th {
    color: #555;
    font-size: 13px;
    font-weight: 700;
}

.markdown-render table thead tr {
    border-bottom: 1px solid #d7d7d7;
}

.markdown-render table tbody tr td,
.markdown-render table thead tr th {
    border: 1px solid #d7d7d7 !important;
    padding: 4px;
}

.md-editor.active {
    border: 1px solid #6fdbe8 !important;
}

.md-editor textarea {
    padding: 10px !important;
}

[data-ui-markdown] h1,
[data-ui-markdown] h2,
[data-ui-markdown] h3,
[data-ui-markdown] h4,
[data-ui-markdown] h5,
[data-ui-markdown] h6 {
    margin: 0 0 0.5em;
    text-align: start;
}

[data-ui-markdown] h1 {
    font-size: 1.7em !important;
    font-weight: 600;
}

[data-ui-markdown] h2 {
    font-size: 1.5em !important;
    font-weight: 500;
}

[data-ui-markdown] h3 {
    font-size: 1.2em !important;
}

[data-ui-markdown] h4 {
    font-size: 1.1em !important;
}

[data-ui-markdown] h5 {
    font-size: 1em !important;
}

[data-ui-markdown] h6 {
    font-size: .85em !important;
}

[data-ui-markdown] p,
[data-ui-markdown] pre,
[data-ui-markdown] blockquote {
    margin: 0 0 1.1em;
}

[data-ui-markdown] p:last-child {
    margin: 0;
}

[data-ui-markdown] blockquote {
    background-color: rgba(128, 128, 128, 0.05);
    border-left: 5px solid #888888;
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
    font-size: 1em;
    padding: 15px 20px;
}

[data-ui-markdown] table {
    background-color: transparent;
    border-collapse: collapse;
    border-spacing: 0;
    margin-bottom: 20px;
    max-width: 100%;
}

[data-ui-markdown] table caption + thead tr:first-child th,
[data-ui-markdown] table caption + thead tr:first-child td,
[data-ui-markdown] table colgroup + thead tr:first-child th,
[data-ui-markdown] table colgroup + thead tr:first-child td,
[data-ui-markdown] table thead:first-child tr:first-child th,
[data-ui-markdown] table thead:first-child tr:first-child td {
    border-top: 0;
}

[data-ui-markdown] table thead th {
    vertical-align: bottom;
}

[data-ui-markdown] table th {
    font-weight: bold;
    text-align: left;
}

[data-ui-markdown] table th,
[data-ui-markdown] table td {
    border-top: 1px solid #ddd;
    line-height: 20px;
    padding: 8px;
    vertical-align: top;
}

[data-ui-markdown] dt,
[data-ui-markdown] dd {
    line-height: 1.45;
    margin-top: 5px;
    margin-bottom: 5px;
}

[data-ui-markdown] dt {
    font-weight: bold;
}

[data-ui-markdown] dd {
    margin-left: 40px;
}

[data-ui-markdown] pre {
    border: 0;
    border-radius: 5px;
    padding: 10px 20px;
    text-align: start;
}

[data-ui-markdown] pre code {
    white-space: pre !important;
}

[data-ui-markdown] blockquote ul:last-child,
[data-ui-markdown] blockquote ol:last-child {
    margin-bottom: 0;
}

[data-ui-markdown] ul,
[data-ui-markdown] ol {
    margin-top: 0;
    margin-bottom: 10.5px;
}

[data-ui-markdown] ul li p,
[data-ui-markdown] ol li p {
    overflow: visible !important;
}

[data-ui-markdown] .footnote {
    font-size: .8em;
    position: relative;
    top: -0.5em;
    vertical-align: top;
}

blockquote {
    background: #d0f0ff;
    border-left: 2px dotted #888;
    padding-left: 5px;
}

.wmd-panel {
    min-width: 500px;
}

.wmd-button-bar {
    background-color: Silver;
    width: 100%;
}

.wmd-input {
    background-color: Gainsboro;
    border: 1px solid DarkGray;
    height: 300px;
    width: 100%;
}

.wmd-button-row {
    height: 20px;
    margin: 10px 5px 5px;
    padding: 0;
    position: relative;
}

.wmd-spacer {
    background-color: Silver;
    display: inline-block;
    height: 20px;
    width: 1px;
    list-style: none;
    margin-left: 14px;
    position: absolute;
}

.wmd-button {
    display: inline-block;
    cursor: pointer;
    list-style: none;
    height: 20px;
    width: 20px;
    padding-left: 2px;
    padding-right: 3px;
    position: absolute;
}

.wmd-button > span {
    background-image: url('../img/wmd-buttons.png');
    background-repeat: no-repeat;
    background-position: 0 0;
    display: inline-block;
    height: 20px;
    width: 20px;
}

.wmd-spacer1 {
    left: 50px;
}

.wmd-spacer2 {
    left: 175px;
}

.wmd-spacer3 {
    left: 300px;
}

.wmd-prompt-background {
    background-color: Black;
}

.wmd-prompt-dialog {
    background-color: #F5F5F5;
    border: 1px solid #999999;
}

.wmd-prompt-dialog > div {
    font-size: 0.8em;
    font-family: arial, helvetica, sans-serif;
}

.wmd-prompt-dialog > form > input[type="text"] {
    border: 1px solid #999999;
    color: black;
}

.wmd-prompt-dialog > form > input[type="button"] {
    border: 1px solid #888888;
    font-family: trebuchet MS, helvetica, sans-serif;
    font-size: 0.8em;
    font-weight: bold;
}

/* ProseMirror editor Source Mode */
.ProseMirror-editor-source {
    box-sizing: border-box;
    border: 1px solid #D9D9D9;
    border-radius: 0 4px 4px 4px;
    display: block;
    min-height: 36px;
    resize: none;
    overflow: auto;
    outline: none;
    padding: 10px;
    width: 100%;
}

.ProseMirror-editor-source:focus {
    border: 1px solid #21A1B3;
}

.ProseMirror {
    -webkit-font-variant-ligatures: none;
    font-variant-ligatures: none;
    outline: none;
    position: relative;
    word-wrap: break-word;
    white-space: pre-wrap;
}

.ProseMirror iframe {
    display: block;
    pointer-events: none;
}

.ProseMirror blockquote {
    border-left: 3px solid #eee;
    margin-left: 0;
    margin-right: 0;
    padding-left: 1em;
}

.ProseMirror pre {
    white-space: pre-wrap;
}

.ProseMirror ul,
.ProseMirror ol {
    cursor: default;
    padding-left: 30px;
}

.ProseMirror li {
    position: relative;
}

.ProseMirror-hideselection *::selection {
    background: transparent;
}

.ProseMirror-hideselection *::-moz-selection {
    background: transparent;
}

.ProseMirror-selectednode {
    outline: 2px solid #8cf;
}

/* Make sure li selections wrap around markers */
li.ProseMirror-selectednode {
    outline: none;
}

li.ProseMirror-selectednode:after {
    border: 2px solid #8cf;
    content: "";
    left: -32px;
    right: -2px;
    top: -2px;
    bottom: -2px;
    pointer-events: none;
    position: absolute;
}

.ProseMirror-textblock-dropdown {
    min-width: 3em;
}

.ProseMirror-gapcursor {
    display: none;
    pointer-events: none;
    position: absolute;
}

.ProseMirror-gapcursor:after {
    animation: ProseMirror-cursor-blink 1.1s steps(2, start) infinite;
    border-top: 1px solid black;
    display: block;
    content: "";
    position: absolute;
    top: -2px;
    width: 20px;
}

@keyframes ProseMirror-cursor-blink {
    to {
        visibility: hidden;
    }
}

.ProseMirror-focused .ProseMirror-gapcursor {
    display: block;
}

/* Add space around the hr to make clicking it easier */
.ProseMirror-example-setup-style hr {
    border: none;
    margin: 1em 0;
    padding: 2px 10px;
}

.ProseMirror-example-setup-style hr:after {
    background-color: silver;
    content: "";
    display: block;
    height: 1px;
    line-height: 2px;
}

.ProseMirror-example-setup-style img {
    cursor: default;
}

.ProseMirror-prompt {
    background: white;
    border: 1px solid silver;
    border-radius: 3px;
    box-shadow: -0.5px 2px 5px rgba(0, 0, 0, 0.2);
    color: #000;
    min-width: 300px;
    padding: 5px 10px 5px 15px;
    position: fixed;
    z-index: 11;
}

.ProseMirror-prompt h5 {
    font-size: 100%;
    font-weight: bold;
    margin: 0 0 10px;
}

.ProseMirror-prompt input {
    margin-bottom: 2px;
}

.ProseMirror-prompt-close {
    border: none;
    background: transparent;
    color: #666;
    padding: 0;
    position: absolute;
    left: 2px;
    top: 1px;
}

.ProseMirror-prompt-close:after {
    content: "✕";
    font-size: 12px;
}

.ProseMirror-invalid {
    background: #ffc;
    border: 1px solid #cc7;
    border-radius: 4px;
    min-width: 10em;
    padding: 5px 10px;
    position: absolute;
}

.ProseMirror-prompt-buttons {
    margin-top: 5px;
}

.ProseMirror p {
    margin-top: 1em;
    margin-bottom: 1em;
}

.ProseMirror p:first-child {
    margin: 0;
}

.ProseMirror p:first-child + * {
    margin-top: 1em;
}

.ProseMirror h1:first-child,
.ProseMirror h2:first-child,
.ProseMirror h3:first-child,
.ProseMirror h4:first-child,
.ProseMirror h5:first-child,
.ProseMirror h6:first-child {
    margin-top: 10px;
}

.ProseMirror [data-oembed] {
    font-size: 0;
}

ProsemirrorEditor img {
    max-width: 100%;
}

.ProseMirror-menu {
    line-height: 1;
    margin: 0 -4px;
    position: absolute;
}

.ProseMirror-tooltip .ProseMirror-menu {
    width: -webkit-fit-content;
    width: fit-content;
    white-space: pre;
}

.ProseMirror-menuitem {
    display: flex;
    margin-right: 0;
}

.ProseMirror-menuitem .ProseMirror-menu-group {
    border-right: 1px solid #d7d7d7;
}

.ProseMirror-menu-group {
    display: flex;
    flex-wrap: wrap;
    min-height: 24px;
}

.ProseMirror-menu-group.last {
    border-right: none;
}

.ProseMirror-menuitem .ProseMirror-icon {
    background: transparent;
}

.ProseMirror-menuseparator {
    border-right: 1px solid #ddd;
    margin-right: 3px;
}

.ProseMirror-menu-dropdown,
.ProseMirror-menu-dropdown-menu {
    white-space: nowrap;
}

.ProseMirror-menu-dropdown {
    cursor: pointer;
    padding-right: 14px !important;
    position: relative;
}

.ProseMirror-menu-dropdown-wrap {
    display: inline-block;
    padding: 0;
    position: relative;
}

.ProseMirror-doprdown-right {
    right: 0;
}

.ProseMirror-menu-dropdown:after {
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid currentColor;
    content: "";
    opacity: .6;
    position: absolute;
    right: 4px;
    top: calc(48%);
}

.ProseMirror-menu-submenu {
    border-top-right-radius: 4px;
}

.ProseMirror-menu-dropdown-menu,
.ProseMirror-menu-submenu {
    background: white;
    border: 1px solid #aaa;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
    color: #666;
    position: absolute;
}

.ProseMirror-menu-dropdown-menu {
    margin-top: 2px;
    min-width: 6em;
    z-index: 15;
}

.ProseMirror-menu-dropdown-item {
    cursor: pointer;
}

.ProseMirror-menu-dropdown-item:hover {
    background: #f2f2f2;
}

.ProseMirror-menu-dropdown-item div[title],
.ProseMirror-menu-dropdown-item a.ProseMirror-menu-trigger,
.ProseMirror-menu-submenu-wrap {
    display: block;
    padding: 4px;
}

.ProseMirror-menu-submenu-wrap {
    position: relative;
}

.ProseMirror-menu-submenu-label:after {
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 4px solid currentColor;
    content: "";
    opacity: .6;
    position: absolute;
    right: 4px;
    top: calc(46%);
}

.ProseMirror-menu-submenu {
    display: none;
    min-width: 4em;
    left: 100%;
    top: 0;
}

.ProseMirror-menu-active {
    background: #eee;
    border: 1px solid #D9D9D9 !important;
    border-radius: 4px;
}

.ProseMirror-menu-disabled {
    opacity: .3;
}

.ProseMirror-menu-submenu-wrap:hover .ProseMirror-menu-submenu,
.ProseMirror-menu-submenu-wrap-active .ProseMirror-menu-submenu {
    display: block;
}

.ProseMirror-menubar {
    -moz-box-sizing: border-box;
    box-sizing: border-box;
    background-color: #f4f4f4;
    border: 1px solid #D9D9D9;
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
    color: #666;
    display: table;
    margin-top: -25px;
    margin-left: 0;
    min-height: 1em;
    padding: 0 5px;
    overflow: visible;
    top: -13px;
    left: 15px;
    right: 0;
    z-index: 10;
}

.ProseMirror .placeholder {
    height: 0;
    padding: 0 !important;
    pointer-events: none;
}

.ProseMirror-icon {
    border: 1px solid transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;/* Compensate for padding */
}

.ProseMirror-menu-disabled.ProseMirror-icon {
    cursor: default;
}

.ProseMirror-icon svg {
    fill: currentColor;
    height: 20px;
}

.ProseMirror-icon span {
    vertical-align: text-top;
}

.ProseMirror .tableWrapper {
    margin: 1em 0;
    overflow-x: auto;
}

.ProseMirror table {
    border-collapse: collapse;
    margin: 0;
    overflow: visible;
    table-layout: fixed;
    width: 100%;
}

.ProseMirror th,
.ProseMirror td {
    border: 1px solid #dddddd;
    box-sizing: border-box;
    min-width: 1em;
    padding: 3px 5px;
    position: relative;
    vertical-align: top;
}

.ProseMirror th {
    font-weight: bold;
    text-align: left;
}

.ProseMirror .column-resize-handle {
    background-color: #adf;
    pointer-events: none;
    position: absolute;
    right: -2px;
    top: 0;
    bottom: 0;
    width: 4px;
    z-index: 20;
}

.ProseMirror.resize-cursor {
    cursor: ew-resize;
    cursor: col-resize;
}

/* Give selected cells a blue overlay */
.ProseMirror .selectedCell:after {
    background: rgba(200, 200, 255, 0.4);
    content: "";
    pointer-events: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    z-index: 2;
}

.ProseMirror-menubar-wrapper {
    outline: none;
}

.atwho-view .cur {
    background-color: #f7f7f7 !important;
    border-left: 3px solid #59d6e4;
}

.atwho-user,
.atwho-space,
.atwho-input a {
    color: #59d6e4;
}

.atwho-input a:hover {
    color: #59d6e4;
}

.atwho-view strong {
    background-color: #f9f0d2;
}

.atwho-view .cur strong {
    background-color: #f9f0d2;
}

[data-ui-markdown] {
    border: 1px solid silver;
}

.atwho-placeholder {
    color: #bebebe !important;
}

.atwho-view {
    background: white;
    border: 1px solid #d7d7d7;
    border-radius: 4px;
    -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
    color: #555555;
    display: none;
    font-size: 14px;
    font-weight: 400;
    margin-top: 18px;
    min-width: 120px;
    max-width: 265px;
    padding: 5px 0;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 11110 !important;
}

.atwho-view strong, .atwho-view b {
    font-weight: normal;
}

.atwho-view ul li.hint {
    background: #fff !important;
    border-left: 3px solid transparent !important;
    color: #999;
    font-size: 12px;
}

.atwho-view .cur small {
    color: red;
}

.atwho-view strong {
    background-color: #f9f0d2;
}

.atwho-view .cur strong {
    background-color: #f9f0d2;
}

.atwho-view ul {
    /* width: 100px; */
    list-style: none;
    margin: auto;
    padding: 0;
}

.atwho-view ul li {
    /* border-top: 1px solid #C8C8C8; */
    border-left: 3px solid transparent;
    cursor: pointer;
    display: block;
    padding: 4px 15px 4px 8px;
}

.atwho-view small {
    color: #777;
    font-size: smaller;
    font-weight: normal;
}

.atwho-input.form-control {
    height: auto;
    min-height: 36px;
    padding-right: 95px;
    word-wrap: break-word;
}

.atwho-input p {
    margin: 0;
    padding: 0;
}

.atwho-placeholder {
    color: #bebebe !important;
}

.atwho-emoji-entry {
    border: none !important;
    float: left;
    margin: 0 !important;
    padding: 4px !important;
}

.atwho-emoji-entry:hover, .atwho-emoji-entry:active, .atwho-emoji-entry:focus {
    background-color: #f7f7f7 !important;
    border: none !important;
    border-radius: 3px;
    margin: 0 !important;
    padding: 4px !important;
}


.atwho-view .cur {
    background-color: #f7f7f7 !important;
    border-left: 3px solid #f7f7f7;
}

.atwho-view strong {
    background-color: #f9f0d2;
}

.atwho-view .cur strong {
    background-color: #f9f0d2;
}

.atwho-view span {
    padding: 5px;
}

/* Emojis window style */
.emoji-nav {
    display: flex;
    padding-top: 10px;
}

.emoji-nav-item {
    border-top: 2px solid #00d6b2;
    display: flex;
    flex-grow: 1;
    align-items: center;
    justify-content: center;
}

.emoji-nav-item.cur {
    border-left: 0;
    border-top: 2px solid #21A1B3;
}

/* NOT REQUIRED FOR EDITOR !!!!*/
.column {
    float: left;
    width: 33.33%;
}

/* Clear floats after the columns */
.row:after {
    content: "";
    clear: both;
    display: table;
}
