/* ==========================================================================
   HUTECH IT Got Talent - Giao diện công khai nền tảng (Public Base)
   Tokens --gt-*, Header, Navbar, Mobile Drawer, About banner, Footer & Modals
   ========================================================================== */

/* Biến thiết kế (Design Tokens) chuẩn tương phản WCAG AA cho giao diện công khai */
:root {
  --gt-accent: #d91438;
  --gt-accent-hover: #b80f2e;
  --gt-accent-bright: #f82249;
  --gt-navy: #0e1b4d;
  --gt-text: #2f3138;
  --gt-muted: #5c6274;
  --gt-bg-soft: #f6f7fd;
}

body {
  background: #fff;
  color: var(--gt-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

a {
  color: var(--gt-accent);
  text-decoration: none;
  transition: color 0.25s ease;
}

a:hover,
a:active {
  color: var(--gt-accent-hover);
  text-decoration: none;
}

:focus-visible {
  outline: 2px solid var(--gt-accent);
  outline-offset: 2px;
}

p {
  padding: 0;
  margin: 0 0 30px 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  margin: 0 0 20px 0;
  padding: 0;
  color: var(--gt-navy);
}

.subpage-main {
  padding-top: 70px;
  min-height: calc(100vh - 130px);
}

@media (prefers-reduced-motion: no-preference) {
  :root {
    scroll-behavior: auto;
  }
}

.skip-link-top {
  z-index: 2000;
}

/* Ẩn triệt để mũi tên gốc trình duyệt trên Bootstrap .form-select để tránh trùng chevron kép */
select.form-select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* Nút lên đầu trang: vùng chạm tối thiểu 44x44px và bật/tắt bằng class .is-visible */
.back-to-top {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gt-accent);
  color: #fff;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  right: 16px;
  bottom: 16px;
  z-index: 990;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, background-color 0.2s ease;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.back-to-top i {
  font-size: 24px;
  line-height: 1;
}

.back-to-top:hover,
.back-to-top:focus-visible {
  background: var(--gt-accent-hover);
  color: #fff;
}

/* Tiêu đề từng phân mục dùng chung giữa Trang chủ và các trang con */
section[id] {
  scroll-margin-top: 76px;
}

.section-header {
  margin-bottom: 42px;
  position: relative;
  padding-bottom: 18px;
}

.section-header::before {
  content: '';
  position: absolute;
  display: block;
  width: 60px;
  height: 5px;
  background: var(--gt-accent);
  bottom: 0;
  left: calc(50% - 30px);
}

.section-header h2 {
  font-size: 36px;
  text-transform: uppercase;
  text-align: center;
  font-weight: 700;
  margin-bottom: 10px;
}

.section-header p {
  text-align: center;
  padding: 0;
  margin: 0;
  font-size: 18px;
  font-weight: 500;
  color: var(--gt-muted);
}

.section-with-bg {
  background-color: var(--gt-bg-soft);
}

@media (max-width: 767.98px) {
  .section-header {
    margin-bottom: 26px;
    padding-bottom: 14px;
  }

  .section-header h2 {
    font-size: 26px;
    margin-bottom: 6px;
  }

  .section-header p {
    font-size: 15px;
  }
}

/*--------------------------------------------------------------
# Header & Thanh điều hướng
--------------------------------------------------------------*/
#header {
  height: 70px;
  padding: 0;
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  transition: all 0.25s ease;
  /* Đặt cao hơn nội dung & khung [data-aos], nhưng thấp hơn Bootstrap modal (1050+) */
  z-index: 1030;
  background: rgba(6, 12, 34, 0.98);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
  display: flex;
  align-items: center;
}

#header .container {
  max-width: 100%;
}

#header.header-scrolled,
#header.header-fixed {
  background: rgba(6, 12, 34, 0.98);
  height: 70px;
  padding: 0;
}

/* Giữ kiểu logo navbar khi chuyển từ H1 sang .navbar-brand-title */
#header #logo .navbar-brand-title {
  font-size: 28px;
  margin: 0;
  padding: 0;
  line-height: 1;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

#header #logo .navbar-brand-title span {
  color: var(--gt-accent-bright);
}

#header #logo .navbar-brand-title a,
#header #logo .navbar-brand-title a:hover {
  color: #fff;
}

@media (max-width: 991.98px) {
  #header #logo .navbar-brand-title {
    font-size: 22px;
  }
}

/* Menu điều hướng Desktop */
.nav-menu,
.nav-menu * {
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-menu li {
  position: relative;
  white-space: nowrap;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: nowrap;
}

.nav-menu>li {
  display: inline-flex;
  align-items: center;
  margin-left: 4px;
}

#nav-menu-container {
  margin: 0;
}

@media (max-width: 1199.98px) {
  #nav-menu-container {
    display: none;
  }
}

.nav-menu a {
  padding: 8px 9px;
  text-decoration: none;
  display: inline-block;
  color: rgba(202, 206, 221, 0.85);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 600;
  font-size: 13.5px;
  outline: none;
}

.nav-menu .menu-active a,
.nav-menu a:hover {
  color: #fff;
}

.nav-menu>li>a:before {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: #f82249;
  visibility: hidden;
  transition: all 0.3s ease-in-out 0s;
}

.nav-menu a:hover:before,
.nav-menu li:hover>a:before,
.nav-menu .menu-active>a:before {
  visibility: visible;
  width: 100%;
}

.nav-menu li.buy-tickets a {
  color: #fff;
  background: #f82249;
  padding: 7px 16px;
  border-radius: 50px;
  border: 2px solid #f82249;
  transition: all ease-in-out 0.3s;
  font-weight: 600;
  margin-left: 8px;
  margin-top: 0;
  line-height: 1;
  font-size: 13px;
}

.nav-menu li.buy-tickets a:hover {
  background: none;
}

.nav-menu li.buy-tickets:hover a:before,
.nav-menu li.buy-tickets.menu-active a:before {
  visibility: hidden;
}

/* Nút mở menu di động đạt vùng chạm tối thiểu 44x44px */
#mobile-nav-toggle {
  position: fixed;
  right: 12px;
  top: 13px;
  z-index: 1033;
  margin: 0;
  width: 44px;
  height: 44px;
  border: 0;
  background: none;
  font-size: 22px;
  display: none;
  align-items: center;
  justify-content: center;
  transition: all 0.25s;
  cursor: pointer;
}

#mobile-nav-toggle i {
  color: #fff;
}

@media (max-width: 1199.98px) {
  #mobile-nav-toggle {
    display: inline-flex;
  }
}

/* Ngăn kéo điều hướng di động (bật/tắt lớp nền bằng .d-none từ main.js) */
#mobile-nav {
  position: fixed;
  top: 0;
  padding-top: 18px;
  bottom: 0;
  z-index: 1032;
  background: rgba(6, 12, 34, 0.9);
  left: -260px;
  width: 260px;
  overflow-y: auto;
  transition: 0.4s;
}

#mobile-nav ul {
  padding: 0;
  margin: 0;
  list-style: none;
}

#mobile-nav ul li {
  position: relative;
}

#mobile-nav ul li a {
  color: #fff;
  font-size: 17px;
  overflow: hidden;
  padding: 10px 22px 10px 15px;
  position: relative;
  text-decoration: none;
  width: 100%;
  display: block;
  outline: none;
}

#mobile-nav ul li a:hover {
  color: #f82249;
}

#mobile-body-overly {
  width: 100%;
  height: 100%;
  z-index: 1031;
  top: 0;
  left: 0;
  position: fixed;
  background: rgba(6, 12, 34, 0.8);
}

body.mobile-nav-active {
  overflow: hidden;
}

body.mobile-nav-active #mobile-nav {
  left: 0;
}

body.mobile-nav-active #mobile-nav-toggle {
  color: #fff;
}

/*--------------------------------------------------------------
# Khung nền phần Giới thiệu (#about) dùng chung cho Trang chủ & Đăng ký
--------------------------------------------------------------*/
#about {
  /* Cập nhật đường dẫn tương đối do tệp nằm sâu hơn trong css/public/ */
  background: url("../../img/about-bg.jpg");
  background-size: cover;
  overflow: hidden;
  position: relative;
  color: #fff;
  padding: 60px 0 40px 0;
}

/* Đã gỡ background-attachment: fixed để cuộn trang mượt trên GPU và mobile Safari */

#about:before {
  content: "";
  background: rgba(13, 20, 41, 0.8);
  position: absolute;
  bottom: 0;
  top: 0;
  left: 0;
  right: 0;
}

#about h2 {
  font-size: 36px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #fff;
}

#about h3 {
  font-size: 18px;
  font-weight: bold;
  text-transform: uppercase;
  margin-bottom: 10px;
  color: #fff;
}

#about p {
  font-size: 14px;
  margin-bottom: 20px;
  color: #fff;
}

#about > .container {
  position: relative;
  z-index: 1;
}

/*--------------------------------------------------------------
# Chân trang (Footer) & Phân tầng Modal công khai
--------------------------------------------------------------*/
#footer {
  background: #101522;
  padding: 0 0 25px 0;
  color: #eee;
  font-size: 14px;
}

#footer .copyright {
  text-align: center;
  padding-top: 25px;
}

/* Phân tầng z-index rõ ràng cho modal công khai (backdrop < modal < #appUiModal) */
.modal-backdrop {
  z-index: 1050;
}

.modal {
  z-index: 1060;
}

#appUiModal {
  z-index: 1085;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
