/* NAMU admin */

html, body, div, p, ul, ol, li, h1, h2, h3, h4, pre, form, p, button, img, a img { border: 0 none; margin: 0; padding: 0; }
ul, li { list-style-type: none; }
* { box-sizing: border-box; }

/* remove outlines from focused elements */
input:focus, textarea:focus, select:focus, a:focus, .textarea_autogrow { outline: none; }

/* color variables */
:root 
	{
	--bg_dark: 				#262c31; /* dark background */
	--border: 					#404851; /* lines, separators, borders */
	--border_light: 		#748899; /* light borders of tables and forms */
	--bg_light: 				#313941; /* light background */
	--bg_lighter:			#47525d; /* light background of form elements [select] */
	--bg_light_hover: 	#353e47; /* light background hover */
	--font_light: 			#c9d2db; /* light font [standard] */
	--font_lighter: 			#e7e7e7; /* lighter font (some form items) */
	--font_red: 				#e59595; /* red highlight */
	--bg_form:				#1e2125; /* form background */
	--box: 						#b7bec5; /* darker font, checkobx mark, select color */
	--mark:						#ebecec; /* checkmark */
	--placeholder: 			#63717f; /* form placehodler text */
	--select_highlight: 	#1967d2; /* selector blue */ ;
	--select_highlight_hover: #1a57ab; /* selector hover blue */ ;
	--button1:					#bbc0c5; /* standard button */
	--bg_green:				#78bd8a; /* green backgound */
	--bg_red:					#e18181; /* green backgound */
	--code:						#20db20; /* code green */
	}

::selection { color: var(--font_light); background: var(--select_highlight); opacity: 0.9 }

body { font-family: Roboto, Arial, sans-serif; background: var(--bg_dark); line-height: 1.25em; }
input, textarea, button, .wysi-editor { font-family: Roboto, Arial, sans-serif; }

/* default font */

html { font-size: 15px; }
body, input, select, textarea { color: var(--font_light); }
a { color: var(--font_light); text-underline-offset: 4px; }

/* lines */
.menu_frame, .list_table tr { border-color: var(--border) !important; }
.menu_frame .menu .menu_separator { background: var(--border); }

/* sections and related backgrounds */
.section1 { background: var(--bg_light); margin-bottom: 2px; padding: 0.75rem; }
.section1 p { line-height: 1.5em; } 
.list_table { background: var(--bg_light); }
.green_bg { background: var(--bg_green) !important }
.red_bg { background: var(--bg_red) !important }
.red { color: var(--font_red); !important }

a { transition: 0.1s; text-decoration: none; }
b, strong { font-weight: 500; }
.hidden { display: none; }
.help { cursor: help; opacity: 0.5 }
.help:hover { opacity: 1 }
.invert { filter: invert(75%); }
.handle { cursor: move; }

/* fixes */

input:-webkit-autofill { -webkit-box-shadow: 0 0 0 30px var(--bg_form) inset; -webkit-text-fill-color: var(--font_light); outline: none; border: 0; } /* no extra highlights in forms */
::-webkit-calendar-picker-indicator { filter: invert(1); opacity: 0.5 } /* calendar dark mode */

.nowrap { white-space: nowrap; }
.single_form { flex-wrap: nowrap !important; }
.wrapper { width: 100%; margin-bottom: 0.75rem; }
.wrapper:last-child:not(:only-child) { margin-bottom: 0 }
.flex { display: flex; flex-wrap: wrap; align-items: center; }

.small { font-size: 0.8rem; }
.dark { opacity: 0.5; }
.dark75 { opacity: 0.75; }
.center { text-align: center; }
.copy { cursor: pointer; }
.justify { justify-content: space-between; }

h2 { font-size: 1.5em; font-weight: normal; display: inline-block; line-height: 1.25em; }

/* menu */

nav { position: fixed; left: 0; width: 100vw; z-index: 100;  display: flex; justify-content: center; flex-wrap: wrap; }
nav ul.menu_options { display: flex; width: 100%; justify-content: center; gap: 1.25rem; padding: 0.5rem 2rem; background: var(--bg_form); font-size: 0.85em; }
nav li { display: inline-block; }
nav a:hover { opacity: 0.8; }

.frame { width: 90%; position: absolute; left: 50%; transform: translateX(-50%); overflow: hidden; margin-top: 3.5rem; max-width: 980px; min-width: 350px; padding-bottom: 6em }

/* --- table --- */

table { border-collapse: collapse; width: 100%; }

.list_table { width: 100%; margin-bottom: 2px }
.list_table a { text-decoration: none; display: block; }
.list_table a b { color: var(--font_red); font-weight: normal; } /* search */ 
.list_table td { padding: 8px 6px; }
.list_table td:first-child { padding-left: 10px; }
.list_table td:last-child { padding-right: 8px; }
.list_table tr { border-top: 1px solid; transition: background 0.1s; }
.list_table tr:first-child { border-top: 0; }
.list_table tr:hover { background: var(--bg_light_hover); }
.list_table .item_preview img { width: 4rem; height: 3em; object-fit: cover; display: block; }

/* table ellipses */
.list_table .truncate { width: 100% }
.list_table .truncate a, .list_table .truncate span { overflow: hidden; text-overflow: ellipsis; width: 100%; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 1; }

/* invisible items */
.list_table .invisible .item_name a { opacity: 0.5; }

/* text acting like button in list tables */
.list_table .table_button { display: inline-block; opacity: 0.5; padding-left: 0.5em; font-size: 0.8rem; }
.list_table .table_button:hover { opacity: 1 }

/* table button in table header */
.inline_menu form { display: inline; }

/* table placeholder */

.table_drag_placeholder { height: 4.1rem; }

/* pagination */

.pages {  }
.pages a { display: inline-block; padding: 2px 0.5em 0px 0; width: 1.75em; text-align: center; opacity: 0.5; }
.pages b a { opacity: 1 }
.pages a:hover { opacity: 1 }

/* external link */

span.external { background-image: url('images/external.svg'); width: 1em; height: 0.8em; display: inline-block; background-size: 1em; background-repeat: no-repeat; }

/* --- forms --- */

.form_field input { width: 100%; background: var(--bg_form); font-size: 1rem; }
.form_field input:read-only { background: var(--bg_dark); opacity: 0.75; }
.form_field input[type="file"] { display:none; }
.file_form::after { content: attr(data-filename); }

/* standard form field */

.form1 input { border: 0; border-radius: 5px; padding: 6px 8px; }
.form1 input::placeholder { color: var(--placeholder); font-style: oblique; }

/* big form field */

.form2 input { border: 0; border-radius: 5px; padding: 6px 8px; font-size: 1.5em; }
.form2 input::placeholder { color: var(--placeholder); font-style: oblique; }

/* width */

.form_width10 { width: 10%; padding-right: 0.75rem; min-width: 6em; }
.form_width25 { width: 25%; padding-right: 0.3rem; min-width: 10em; }
.form_width50 { width: 50%; padding-right: 0.75rem }
.form_width75 { width: 75%; padding-right: 0.5rem; }
.form_width100 { width: 100%; }
.form_width10:last-child:not(:only-child),
.form_width25:last-child:not(:only-child),
.form_width50:last-child:not(:only-child) { padding-right: 0; }

/* labels */

label { font-size: 0.80rem; margin: 0 0 2px 2px; display: inline-block; opacity: 0.9 }
label span { opacity: 0.5; }
input[type=date] { height: 1.875rem; }
form .comment { margin-top: 0.5em; font-size: 0.8rem }

/* checkbox */

.form_field.checkbox { width: fit-content; height: auto; color: var(--box); background: var(--bg_form); padding: 2px 5px; border-radius: 15px; margin: 0.25em 0.5em 0.25em 0; cursor: pointer; }
.form_field.checkbox label { border: 0; position: relative; height: 2em; cursor: pointer; white-space: nowrap; display: inline; }
.form_field.checkbox label:hover .checkmark { opacity: 0.8 }
.form_field.checkbox label{ padding: 0 0.25em 0 1.9em }
.form_field.checkbox input  { position: absolute; opacity: 0; cursor: pointer; width: auto; }
.form_field label::selection { background: transparent; color: inherit; }
 /* custom checkmark */
.form_field .checkmark { position: absolute; top: 50%; left: 0; opacity: 1; transform: translateY(-50%); height: 16px; width: 16px; background-color: var(--bg_light); border-radius: 50%; }
.form_field input:checked ~ .checkmark { background-color: var(--mark); border: 3px solid var(--bg_light); }

/* buttons */

.button1, .button2, .button3 { font-size: 0.8rem;  }
.button1 { white-space: nowrap; border: 0; line-height: normal; background: var(--button1); color: var(--bg_light); padding: 4px 9px; border-radius: 5px; cursor: pointer; transition: opacity 0.2s; margin-right: 0.5rem; }
.button1:hover { opacity: 0.85; }
.button2 { white-space: nowrap; border: 0; line-height: normal; background: var(--bg_form); color: var(--box); padding: 4px 9px; border-radius: 5px; cursor: pointer; transition: opacity 0.2s; margin-right: 0.5rem; }
.button2:hover { opacity: 0.85; }
.button3 { white-space: nowrap; border: 0; line-height: normal; background: var(--bg_light); color: var(--box); padding: 4px 0; border-radius: 5px; cursor: pointer; transition: opacity 0.2s; margin: 0 0.5rem 0  0.25rem; }
.button3:hover { opacity: 0.85; }
label.button1 { margin: 0 1em 0 0 }

/* select */

select { color: var(--box); font-size: 1rem }
.select1 { background: var(--bg_light); border-radius: 3px; height: 1.55rem; padding: 0 5px; border: none; margin: -0.11em 1em 0 0; } 
.select2 { background: var(--bg_form); border-radius: 3px; height: 1.875rem; padding: 0 5px; border: none; margin: 0; display: flex; } 
.select3 { background: var(--bg_lighter); border-radius: 3px; height: 1.55rem; padding: 0 3px; border: none; margin: -0.11em 0 0 0.25rem; } 

.select_label { line-height: 2em; margin-right: 0.5rem; }

/* multiselect (SlimSelect) */

.ss-main { background-color: var(--bg_form); border: none; min-width: 15em; border-radius: 3px; }
.ss-content .ss-search input { background-color: var(--bg_light); }
.ss-main .ss-values .ss-value .ss-value-text { color: var(--box); }
.ss-content { background-color: var(--bg_form); border: 1px solid var(--bg_dark); }
.ss-content .ss-list .ss-option:not(.ss-disabled).ss-selected { background-color: var(--select_highlight); }
.ss-content .ss-list .ss-option:hover, .ss-content .ss-list .ss-option:not(.ss-disabled).ss-selected:hover { background-color: var(--select_highlight_hover); }
.ss-content .ss-list .ss-option { font-size: 0.8em; padding: 3px 8px; }
.ss-content .ss-list .ss-option, .ss-content .ss-list .ss-option.ss-highlighted, 
.ss-content .ss-list .ss-option:not(.ss-disabled).ss-selected, .ss-content .ss-list .ss-option:hover { color: var(--font_light); }
.ss-content .ss-search input { border: 1px solid var(--border_light); }
.ss-content .ss-search input:focus, .ss-main:focus { box-shadow: none; }
.ss-main .ss-values .ss-value { background: var(--bg_lighter); }
.ss-main .ss-values .ss-placeholder { color:var(--box); opacity: 0.5; font-size: 0.85em }
.ss-main .ss-values .ss-value .ss-value-text { padding-left: 0.55em }
.ss-main .ss-values .ss-value .ss-value-delete { padding: 0 0.55em 0 0.3em; border-left: none;  }
.ss-content .ss-list .ss-option, .ss-main { cursor: default; }
.ss-main .ss-values .ss-value .ss-value-delete svg { transform: scale(1.25); transition: opacity 0.2s }
.ss-main .ss-values .ss-value .ss-value-delete svg:hover { opacity: 0.75 }
.ss-main .ss-values .ss-value .ss-value-text { font-size: 0.8em; }
.ss-single { color: var(--font_light); text-overflow: ellipsis; height: auto; overflow: hidden; display: -webkit-box !important; -webkit-box-orient: vertical; -webkit-line-clamp: 1; } 
.ss-option { text-overflow: ellipsis; height: 2em; overflow: hidden; display: -webkit-box !important; -webkit-box-orient: vertical; -webkit-line-clamp: 1; } 
.sun-editor-editable ol li { list-style-type: decimal; }
.sun-editor-editable ul li { list-style-type: disc; }

/* generic textarea */

.form_textarea.large  { font-size: 1.5rem; }
.form_textarea textarea { font-size: 1rem; width: 100%; overflow: auto; border: 0; resize: vertical; background: var(--bg_form); border-radius: 3px; padding: 4px; line-height: 1.5em; box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2); }
.form_textarea.autoheight .textarea_autogrow { background: var(--bg_form); border-radius: 3px; padding: 6px 8px; line-height: 1.25em; box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2); }
.form_textarea.textarea5 textarea, .form_textarea.textarea6 .wysi-editor { height: 5rem; max-height: none; }
.form_textarea.textarea8 textarea, .form_textarea.textarea8 .wysi-editor { height: 8rem; max-height: none; }
.form_textarea.textarea12 textarea, .form_textarea.textarea12 .wysi-editor { height: 12rem; max-height: none; }
.form_textarea.textarea24 textarea, .form_textarea.textarea24 .wysi-editor { height: 24rem; max-height: none; }
.code textarea { color: var(--code); font-family: monospace; font-size: 0.9em; }

/* textarea scrolbars */

.ss-list::-webkit-scrollbar, .frame ::-webkit-scrollbar { width: 10px; }
.ss-list::-webkit-scrollbar-track, .frame ::-webkit-scrollbar-track { background: var(--bg_form); }
.ss-list::-webkit-scrollbar-thumb, .frame ::-webkit-scrollbar-thumb { background: var(--bg_lighter); border-radius: 5px; }
.ss-list::-webkit-scrollbar-thumb:hover, .frame ::-webkit-scrollbar-thumb:hover { cursor: default; }
.ss-list::-webkit-resizer, .frame ::-webkit-resizer { background-color: var(--bg_lighter); }

/* gallery */

.gallery { justify-content: center; }
.gallery_container { display: flex; width: 100%; justify-content: space-between; align-items:center; margin-bottom: 2px; padding: 0.5em 0.75rem; background: var(--bg_light); }
.gallery_tile { width: 8.5rem; height: 4.9rem; border-radius: 3px; margin: 0 10px 5px 0; overflow: hidden; }
.gallery_image { object-fit: cover; }
.gallery_placeholder { background: var(--placeholder); padding: 5px; overflow: hidden; font-size: 0.85rem; }
.gallery_placeholder.drag { background: var(--bg_dark); height: 6.3rem  }
.gallery .button { display: inline-block; margin: -8px 0 0 10px }

/* Sun Editor HTML area */

.sun-editor { background: none; width: auto !important; border: 0; }
.sun-editor .se-wrapper .se-wrapper-inner { min-height: 12em; border-radius: 0 0 4px 4px }
.sun-editor-editable { max-height: 70vh; }
.sun-editor-editable, .sun-editor .se-dialog { font-family: 'Roboto', Arial, sans-serif; font-size: 1.125rem; background: var(--bg_form); color: var(--font_light); border: 0; }
.sun-editor .se-resizing-bar.se-resizing-none { display: none; }
.sun-editor .se-toolbar { background: var(--bg_lighter); outline: none; border-radius: 4px 4px 0 0 }
.sun-editor button, 
.sun-editor .se-list-layer.se-list-format ul h1,
.sun-editor .se-list-layer.se-list-format ul h2 { color: var(--font_light); font-weight: normal !important; }
.sun-editor-editable a, .sun-editor-editable a:hover { color: var(--font_light); opacity: 0.6; text-decoration: none;  }
.sun-editor strong { font-weight: 600; }
.sun-editor .se-dialog .se-dialog-inner .se-dialog-content, 
.sun-editor .se-controller-link .link-content, .sun-editor .se-list-inner .se-list-basic li button.active { background: var(--bg_lighter); border: 0 }
.sun-editor .se-controller-link .link-content span { display: none; }
.sun-editor .se-controller .se-arrow { display: none }
.sun-editor .se-dialog { position: absolute !important; }
.sun-editor .se-dialog .se-dialog-back, .sun-editor .se-dialog .se-dialog-inner { width: 70%; left: 50%; transform: translateX(-50%); }
.sun-editor .se-dialog button, .sun-editor .se-dialog input, .sun-editor .se-dialog label { color: var(--font_light); }
.sun-editor .se-dialog .se-dialog-inner .se-dialog-content label,
.sun-editor .se-dialog .se-dialog-inner .se-dialog-header .se-modal-title { font-weight: normal; }
.sun-editor .se-dialog .se-dialog-inner .se-dialog-header,
.sun-editor .se-dialog .se-dialog-inner .se-dialog-footer { border-color: var(--border_light); }
.sun-editor input, .sun-editor select, .sun-editor textarea { border: 0 }
.sun-editor input:focus, .sun-editor select:focus, .sun-editor textarea:focus { box-shadow: none; border: 0 }
.sun-editor .se-dialog .se-dialog-inner .se-dialog-form .se-dialog-form-files .se-dialog-files-edge-button,
.sun-editor .se-dialog .se-dialog-inner .se-dialog-form-footer { display: none; }
.sun-editor .se-btn-primary, 
.sun-editor .se-btn-primary:focus, 
.sun-editor .se-btn-primary:active,
.sun-editor .se-btn-primary:hover { background-color: var(--bg_form); border: 0; color: var(--font_light); box-shadow: none; }
.sun-editor .se-btn-primary:hover { opacity: 0.8; }
.sun-editor .se-dialog .se-dialog-inner .se-anchor-preview-form .se-link-preview { display: none; }
.sun-editor .se-btn:enabled:focus, 
.sun-editor .se-btn:enabled:hover,
.sun-editor .se-btn:enabled.on,
.sun-editor .se-list-layer,
.sun-editor .se-btn:enabled:active { background: var(--bg_light) !important; border: 0 }
.sun-editor .se-btn:enabled:active { box-shadow: none; }
.sun-editor .se-btn-list:focus, .sun-editor .se-btn-list:hover { background-color: var(--bg_dark); }

/* dynemaix form - fixing replicated fields */

.dynamic_form .wrapper:not(:first-child) { margin-bottom: 0.75rem; }
.dynamic_form .wrapper:not(:first-child) label { display: none; }
.dynamic_form .wrapper:first-child .deleteButton { display: none; }

/* dropzones */

.image_upload_form.dropzone { width: 100%; border: 0; height: 15rem; margin-bottom: 1rem; box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.25); inset; background-color: var(--bg_dark); border-radius: 10px; background-image: url("images/dropfile.svg"); background-repeat: no-repeat; background-size: 5rem; background-position: center center; background-blend-mode: overlay; transition: background-size 0.2s; }
.image_upload_form.dropzone .dz-preview.dz-image-preview { background: none !important; }
.image_upload_form.dropzone .dz-preview .dz-details, .dz-size { font-size: 10px !important; }
.image_upload_form.dropzone:hover { background-size: 6rem; }

.file_upload_form.dropzone { width: 100%; border: 0; height: 2rem; box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.25); inset; background-color: var(--bg_dark); border-radius: 10px; background-image: url("images/dropfile.svg"); background-repeat: no-repeat; background-size: 4rem; background-position: center center; background-blend-mode: overlay; transition: background-size 0.2s; }
.file_upload_form.dropzone .dz-preview .dz-details, .dz-size { font-size: 10px !important; }
.file_upload_form.dropzone:hover { background-size: 4.5rem; }

.dropzone_image { width: 100%; height: 15rem; overflow: hidden; object-fit: contain; padding: 2rem 0 0 0; }
.dropzone_image { filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.25)); }
.dropzone .dz-preview { position: relative; left: 50% !important; transform: translateX(-50%); background: none !important; margin: 0 !important  }
.dz-image, .dz-success-mark, .dz-error-mark, .dz-details { display: none !important; }
.dz-button { display: none; }
.dropzone .dz-preview .dz-progress { top: 5% !important; background: var(--bg_dark) !important; }

/* login form */

#login_form { width: 50%; height: auto; max-width: 600px; margin: 10rem auto 0 auto }

/* sizing */

@media screen and (max-width: 1080px) 
	{
	.dropzone_image { padding: 2rem 1.5rem 0 1.5rem }
	.early_collapsable .collapsable { display: none; }
	}

@media screen and (max-width: 700px) 
	{

	.form_width50, .form_width75,	.ss-main { width: 100%; padding-right: 0; }	
	.single_form .form_width10, .single_form  .form_width50, .single_form .form_width75 { padding-right: 0.5rem; }	
	.form_width50:last-child, .form_width75:last-child { padding-top: 0.5em }
	.single_form .form_width50:last-child, .single_form .form_width75:last-child { padding-top: 0 }
	.single_form .select1 { margin-left: 1em; }
	.single_form .button1, .deleteButton { margin-left: 0.25rem; }
	.dropzone_image { padding: 0rem 1.5rem 0 1.5rem }
	.frame { min-width: 420px; }
	.menu_open { min-width: 380px; }

	.form_textarea.textarea8 textarea, .form_textarea.textarea8 .wysi-editor { height: 6rem; }
	.form_textarea.textarea8 textarea, .form_textarea.textarea8 .wysi-editor { height: 6rem; }
	.form_textarea.textarea12 textarea, .form_textarea.textarea12 .wysi-editor { height: 8rem; max-height: }
	.form_textarea.textarea24 textarea, .form_textarea.textarea24 .wysi-editor { height: 16rem; max-height: }
	
	.collapsable { display: none; }
	}

