/*!
 * Bootstrap Docs (https://getbootstrap.com/)
 * Copyright 2011-2023 The Bootstrap Authors
 * Licensed under the Creative Commons Attribution 3.0 Unported License.
 * For details, see https://creativecommons.org/licenses/by/3.0/.
 */

html,
body {
    margin: 0;
    padding: 0;
	padding-top: 0px;    /* space for top navbar */
    padding-bottom: 0px; /* space for bottom nav */
    font-size: 14px;
    font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
}

:root,
[data-bs-theme="light"] {
    --bd-purple: #4c0bce;
    --bd-violet: #712cf9;
    --bd-accent: #ffe484;
    --bd-violet-rgb: 112.520718, 44.062154, 249.437846;
    --bd-accent-rgb: 255, 228, 132;
    --bd-pink-rgb: 214, 51, 132;
    --bd-teal-rgb: 32, 201, 151;
    --bd-violet-bg: var(--bd-violet);
    --bd-toc-color: var(--bd-violet);
    --bd-sidebar-link-bg: rgba(var(--bd-violet-rgb), .1);
    --bd-callout-link: 10, 88, 202;
    --bd-callout-code-color: #ab296a;
    --bd-pre-bg: var(--bs-tertiary-bg)
}

[data-bs-theme="dark"] {
    --bd-violet: #9461fb;
    --bd-violet-bg: #712cf9;
    --bd-toc-color: var(--bs-emphasis-color);
    --bd-sidebar-link-bg: rgba(84, 33, 187, .5);
    --bd-callout-link: 110, 168, 254;
    --bd-callout-code-color: #e685b5;
    --bd-pre-bg: #1b1f22
}

.bd-callout {
    --bs-link-color-rgb: var(--bd-callout-link);
    --bs-code-color: var(--bd-callout-code-color);
    padding: 1.25rem;
    margin-top: 1.25rem;
    margin-bottom: 1.25rem;
    color: var(--bd-callout-color, inherit);
    background-color: var(--bd-callout-bg, var(--bs-gray-100));
    border-left: 0.25rem solid var(--bd-callout-border, var(--bs-gray-300))
}

.bd-callout h4 {
    margin-bottom: .25rem
}

.bd-callout>:last-child {
    margin-bottom: 0
}

.bd-callout+.bd-callout {
    margin-top: -.25rem
}

.bd-callout .highlight {
    background-color: rgba(0, 0, 0, 0.05)
}

.bd-callout-info {
    --bd-callout-color: var(--bs-info-text-emphasis);
    --bd-callout-bg: var(--bs-info-bg-subtle);
    --bd-callout-border: var(--bs-info-border-subtle)
}

.bd-callout-warning {
    --bd-callout-color: var(--bs-warning-text-emphasis);
    --bd-callout-bg: var(--bs-warning-bg-subtle);
    --bd-callout-border: var(--bs-warning-border-subtle)
}

.bd-callout-danger {
    --bd-callout-color: var(--bs-danger-text-emphasis);
    --bd-callout-bg: var(--bs-danger-bg-subtle);
    --bd-callout-border: var(--bs-danger-border-subtle)
}

/**** Hide the print elements ****/
@media print {
    .hidden-in-print {
        display: none !important;
    }
}

/**** Tiêu đề tuần trên trang chủ: tiêu đề, khoảng ngày và nút "Chuyển lịch tuần sang To do" nằm chung một hàng ****/
/* Hàng tự xuống dòng khi màn hình hẹp. Chỉ áp dụng trên màn hình: khi in, ba dòng vẫn xếp như trước */
@media screen {
    #event-header .event-head {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: center;
        gap: 4px 16px;
    }
    #event-header .event-head h5,
    #event-header .event-head h6 {
        margin-bottom: 0;
    }
    /* Dòng "Năm học" đang để trống: không để nó chiếm một khoảng cách trong hàng */
    #event-header .event-head #EventSemester:empty {
        display: none !important;
    }
}

/**** Nhãn "New" nhấp nháy cạnh mục menu mới ****/
.menu-new {
    font-size: .62em;
    vertical-align: super;
    padding: .28em .5em;
    animation: menu-new-blink 1.1s ease-in-out infinite;
}
@keyframes menu-new-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: .2; }
}
/* Máy đã bật "giảm chuyển động" (Windows: tắt "Hiệu ứng hoạt ảnh"): vẫn nhấp nháy nhưng chậm và nhẹ hơn */
@media (prefers-reduced-motion: reduce) {
    .menu-new { animation-name: menu-new-pulse; animation-duration: 2.4s; }
}
@keyframes menu-new-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: .55; }
}

/**** Thanh menu trên màn hình vừa: thu gọn để các mục, kể cả mục "To do list" mới, vẫn nằm trên một dòng như trước ****/
/* 768–991 px (máy tính bảng dọc, cửa sổ hẹp): chữ menu 13 px thay cho 14 px, khoảng cách giữa các mục hẹp hơn */
@media (min-width: 768px) and (max-width: 991.98px) {
    .navbar.navbar-expand-md {
        --bs-navbar-nav-link-padding-x: .2rem;
        --bs-navbar-brand-font-size: .95rem;
        --bs-navbar-brand-margin-end: .3rem;
    }
    .navbar.navbar-expand-md .navbar-nav {
        --bs-nav-link-font-size: .93rem;
    }
}
/* 992–1199 px: chỉ menu của quản trị viên (nhiều mục hơn), giữ nguyên cỡ chữ */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .navbar.navbar-expand-md.navbar-admin {
        --bs-navbar-nav-link-padding-x: .25rem;
        --bs-navbar-brand-font-size: 1rem;
        --bs-navbar-brand-margin-end: .35rem;
    }
}

/*.text-primary {
   /*color:darkblue !important;*
   color:#0c0cb8 !important;
}*/

.text-success {
    color: darkgreen !important;
}

/**** Switch between devices ****/

.screen-desktop {
	display: revert;
}

.screen-mobile {
	display: none;
}

#tbl-calendar th.col-day {
	width: 5%;
}
#tbl-calendar th.col-time {
	width: 6%;
}
#tbl-calendar th.col-content {
	width: 20%;
}
#tbl-calendar th.col-participant {
	width: 40%;
}
#tbl-calendar th.col-location {
	width: 15%;
}
#tbl-calendar th.col-host {
	width: 15%;
}
#tbl-calendar .sticky-header {
	top: 0;
	z-index: 20;
	position: sticky;
	position: -webkit-sticky; /* Safari */
	/*background-color: #e9ecef !important;
	border-top: 1px solid #dc3545;*/
	box-shadow: inset 0 1px 0 #ccc/*, 0 2px 3px rgba(0,0,0,0.08)*/;
}
#tbl-calendar .sticky-header th.tr-mobi {
	background-color: #e9ecef !important;
}

/*
/* Màu nền cho các hàng xen kẽ *
.striped-row:nth-child(even) th:not(:first-child),
.striped-row:nth-child(even) td:not(:first-child) {
	background-color: #f2f2f2 !important;
	background-color: #dda23e !important;
	background-color: #ede560 !important;
}

.striped-row:nth-child(odd) th:not(:first-child) {
	background-color: #ffffff !important;
}

/* Đảm bảo hàng đầu tiên không bị ảnh hưởng *
thead tr {
	background-color: inherit !important;
}

/* Loại trừ cột đầu tiên *
tbody tr th:first-child,
tbody tr td:first-child {
	background-color: inherit !important;
}
*/

.striped-row:nth-child(even) td {
	background-color: #f2f2f2; /* Màu nền cho các ô trong hàng chẵn, trừ cột đầu tiên */
}
.striped-row:nth-child(odd) td {
	background-color: #ffffff; /* Màu nền cho các ô trong hàng lẻ, trừ cột đầu tiên */
}
thead tr {
	background-color: inherit; /* Giữ nguyên màu nền của hàng đầu tiên */
}
tbody tr th {
	background-color: inherit; /* Giữ nguyên màu nền cho cột đầu tiên */
}

/* Lịch được mở từ liên kết "về lịch gốc" của VKU To do list (index.php?event=<mã lịch>): nền vàng nhạt, vạch cam bên trái.
   Bootstrap 5.3 tô nền ô bảng bằng box-shadow nên phải đặt cả hai thuộc tính. Ô "Thứ/Ngày" (th) dùng chung cho cả ngày nên giữ nguyên. */
#tbl-calendar tr.event-focus > td {
	background-color: #fff3cd !important;
	box-shadow: inset 0 0 0 9999px #fff3cd !important;
}
#tbl-calendar tr.event-focus > td:first-of-type {
	box-shadow: inset 4px 0 0 #f7951d, inset 0 0 0 9999px #fff3cd !important;
}
/* Khi trang tự cuộn tới lịch này: chừa chỗ cho phần đầu trang đang dính ở trên và thanh điều hướng dính dưới đáy màn hình điện thoại */
#tbl-calendar tr.event-focus {
	scroll-margin-top: 150px;
	scroll-margin-bottom: 60px;
}


@media (max-width: 767px) {
	.screen-mobile {
		display: table-row !important;
	}
	.screen-desktop {
		display: none !important;
	}
	#tbl-calendar th.col-day {
		width: 10%;
	}
	#tbl-calendar th.col-content {
		width: 90%;
	}
}

.icon-bookmark {
	cursor: pointer;
}

/**** CSS for Dashboard ****/

.bd-placeholder-img {
    font-size: 1.125rem;
    text-anchor: middle;
    -webkit-user-select: none;
    -moz-user-select: none;
    user-select: none;
}

@media (min-width: 768px) {
    .bd-placeholder-img-lg {
        font-size: 3.5rem;
    }
}

.b-example-divider {
    width: 100%;
    height: 3rem;
    background-color: rgba(0, 0, 0, .1);
    border: solid rgba(0, 0, 0, .15);
    border-width: 1px 0;
    box-shadow: inset 0 .5em 1.5em rgba(0, 0, 0, .1), inset 0 .125em .5em rgba(0, 0, 0, .15);
}

.b-example-vr {
    flex-shrink: 0;
    width: 1.5rem;
    height: 100vh;
}

.bi {
    vertical-align: -.125em;
    fill: currentColor;
}

.nav-scroller {
    position: relative;
    z-index: 2;
    height: 2.75rem;
    overflow-y: hidden;
}

.nav-scroller .nav {
    display: flex;
    flex-wrap: nowrap;
    padding-bottom: 1rem;
    margin-top: -1px;
    overflow-x: auto;
    text-align: center;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
}

.btn-bd-primary {
    --bd-violet-bg: #712cf9;
    --bd-violet-rgb: 112.520718, 44.062154, 249.437846;

    --bs-btn-font-weight: 600;
    --bs-btn-color: var(--bs-white);
    --bs-btn-bg: var(--bd-violet-bg);
    --bs-btn-border-color: var(--bd-violet-bg);
    --bs-btn-hover-color: var(--bs-white);
    --bs-btn-hover-bg: #6528e0;
    --bs-btn-hover-border-color: #6528e0;
    --bs-btn-focus-shadow-rgb: var(--bd-violet-rgb);
    --bs-btn-active-color: var(--bs-btn-hover-color);
    --bs-btn-active-bg: #5a23c8;
    --bs-btn-active-border-color: #5a23c8;
}

.bd-mode-toggle {
    z-index: 1500;
}

.bd-mode-toggle .dropdown-menu .active .bi {
    display: block !important;
}

.password-toggle {
    top: 50%;
    right: 10px;
    cursor: pointer;
    position: absolute;
    transform: translateY(-50%);
}
