/* Custom CSS fixes for user frontend (PMOD theme) */

/* 1. Đổi màu các nút và thành phần cho đồng bộ với theme color */
.ant-btn-primary,
.ant-btn-primary:focus,
.ant-btn-primary:active,
.btn-primary,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--theme-color) !important;
  border-color: var(--theme-color) !important;
}

.ant-btn-primary:hover,
.btn-primary:hover {
  background-color: var(--theme-color) !important;
  border-color: var(--theme-color) !important;
  opacity: 0.85 !important;
}

.text-primary,
a.text-primary,
a.text-primary:hover,
a.text-primary:focus,
a.text-primary:active {
  color: var(--theme-color) !important;
}

.ant-tabs-tab.ant-tabs-tab-active .ant-tabs-tab-btn {
  color: var(--theme-color) !important;
}

.ant-tabs-ink-bar {
  background: var(--theme-color) !important;
}

/* 2. Fix layout hiển thị trên Mobile (khoảng trắng card và nút đè chữ) */
@media (max-width: 768px) {
  /* Giảm bớt khoảng trắng bên ngoài để mở rộng Card */
  .ant-layout-content,
  .ant-pro-page-container {
    padding: 8px 4px !important;
  }

  .ant-pro-page-container-children-content {
    margin: 0 !important;
  }

  .ant-card {
    margin-bottom: 12px !important;
    border-radius: 8px !important;
  }

  .ant-card-body {
    padding: 12px !important;
  }

}

/* 3. Tối ưu Bottom Sheet "Tính năng mở rộng" fit-content & spacing */
.bottom-nav-drawer.ant-drawer-bottom .ant-drawer-content-wrapper {
  height: fit-content !important;
  height: -moz-fit-content !important;
  height: -webkit-fit-content !important;
  max-height: 85vh !important;
  max-height: 85dvh !important;
  bottom: 0 !important;
}

.bottom-nav-drawer.ant-drawer-bottom .ant-drawer-content {
  height: auto !important;
  max-height: 85vh !important;
  max-height: 85dvh !important;
  border-top-left-radius: 18px !important;
  border-top-right-radius: 18px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch !important;
}

.bottom-nav-drawer.ant-drawer-bottom .ant-drawer-wrapper-body {
  height: auto !important;
}

.bottom-nav-drawer.ant-drawer-bottom .ant-drawer-body {
  flex: none !important;
  height: auto !important;
  padding: 0 !important;
}

.bottom-nav-drawer .ant-drawer-header {
  border-bottom: 1px solid #f0f0f0 !important;
  text-align: center !important;
  padding: 12px 16px !important;
  border-top-left-radius: 18px !important;
  border-top-right-radius: 18px !important;
}

.bottom-nav-drawer .ant-drawer-title {
  font-weight: 700 !important;
  font-size: 15px !important;
  line-height: 1.3 !important;
  margin: 0 !important;
}

.bottom-nav-drawer-body {
  padding: 12px 16px 4px !important;
}

.bottom-nav-drawer-grid {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 10px !important;
}

.bottom-nav-drawer-card {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  padding: 12px 14px !important;
  background: #f8f9fa !important;
  border-radius: 12px !important;
  border: 1px solid #f0f0f0 !important;
  height: 100% !important;
  transition: background-color 0.2s ease, transform 0.15s ease !important;
  -webkit-tap-highlight-color: transparent !important;
}

.bottom-nav-drawer-card:active {
  transform: scale(0.98) !important;
  background-color: #edf2f7 !important;
}

.bottom-nav-drawer-section-title {
  grid-column: span 2 !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  color: #94a3b8 !important;
  margin: 8px 0 2px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
}

.bottom-nav-drawer-footer {
  width: 100% !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  padding-top: 10px !important;
  padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px)) !important;
  padding-left: 16px !important;
  padding-right: 16px !important;
  color: #bfbfbf !important;
  font-size: 12px !important;
  text-align: center !important;
  line-height: 1.4 !important;
}

/* 4. Login / Register / Forget Password readability & styling */
.v2board-background {
  position: relative !important;
  background-color: #0f172a !important;
  background-repeat: no-repeat !important;
  background-position: 50% 50% !important;
  background-size: cover !important;
  background-attachment: fixed !important;
  min-height: 100vh !important;
}

/* ==========================================================================
   LIGHT THEME AUTH PAGES (LOGIN / REGISTER / FORGET) - VNCLOUD INITIATIVE
   ========================================================================== */

/* Nền sáng tổng thể */
body,
.auth-light-theme,
.auth-light-theme #main-container,
.auth-light-theme #page-container,
.v2board-background {
  background-color: #f8fafc !important;
  background-image: none !important;
  color: #1e293b !important;
  min-height: 100vh !important;
}

.v2board-background::before {
  display: none !important;
}

/* Cardless: Form hoàn toàn không có khối viền trắng/bóng đổ bao ngoài */
.v2board-auth-card {
  background: transparent !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
}

/* Cột trái Hero Brand (Desktop) */
.auth-brand-side {
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%) !important;
  border-right: 1px solid #e2e8f0 !important;
}

.auth-logo-badge {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 44px !important;
  height: 44px !important;
  background-color: rgba(37, 99, 235, 0.08) !important;
  border-radius: 12px !important;
}

.auth-hero-headline {
  font-size: 32px !important;
  font-weight: 800 !important;
  line-height: 1.3 !important;
  letter-spacing: -0.5px !important;
  color: #0f172a !important;
}

.auth-hero-sub {
  font-size: 15px !important;
  color: #64748b !important;
  line-height: 1.6 !important;
}

.auth-feature-list {
  display: flex !important;
  flex-direction: column !important;
}

.auth-feature-item {
  display: flex !important;
  align-items: flex-start !important;
}

.auth-feature-icon {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  border-radius: 10px !important;
  background-color: rgba(37, 99, 235, 0.08) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 16px !important;
  color: #2563eb !important;
}

/* Cột phải Form Side */
.auth-form-side {
  background-color: #ffffff !important;
}

@media (max-width: 991.98px) {
  .auth-form-side {
    background-color: #ffffff !important;
    min-height: 100vh !important;
  }
}

.auth-form-wrapper {
  max-width: 420px !important;
  width: 100% !important;
}

/* Tiêu đề & nhãn nhập liệu (Labels) */
.auth-field-label {
  display: block !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  margin-bottom: 6px !important;
  text-align: left !important;
}

.auth-forgot-link {
  font-size: 13px !important;
  font-weight: 500 !important;
  color: #2563eb !important;
  text-decoration: none !important;
  transition: color 0.15s ease !important;
}

.auth-forgot-link:hover {
  color: #1d4ed8 !important;
  text-decoration: underline !important;
}

/* Ô nhập liệu sáng, viền gọn gàng */
.auth-input,
.auth-form-side .form-control,
.auth-form-side .form-control-alt,
.v2board-auth-card .form-control-alt {
  background-color: #ffffff !important;
  border: 1.5px solid #cbd5e1 !important;
  border-radius: 10px !important;
  color: #0f172a !important;
  font-size: 14.5px !important;
  font-weight: 500 !important;
  padding: 10px 14px !important;
  height: 48px !important;
  box-sizing: border-box !important;
  transition: all 0.2s ease !important;
  box-shadow: none !important;
}

.auth-input:focus,
.auth-form-side .form-control:focus,
.auth-form-side .form-control-alt:focus,
.v2board-auth-card .form-control-alt:focus {
  background-color: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
  color: #0f172a !important;
  outline: none !important;
}

.auth-input::placeholder,
.auth-form-side .form-control::placeholder,
.auth-form-side .form-control-alt::placeholder,
.v2board-auth-card .form-control-alt::placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
  font-size: 14px !important;
  font-weight: 400 !important;
}

/* Nút Submit Chính (Xanh dương hiện đại) */
.auth-btn-primary,
.auth-form-side .btn-hero-primary,
.auth-form-side .btn-hero-success,
.auth-form-side .btn-hero-warning,
.auth-form-side .btn-primary {
  background-color: #2563eb !important;
  border-color: #2563eb !important;
  color: #ffffff !important;
  border-radius: 10px !important;
  height: 48px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25) !important;
  transition: all 0.2s ease !important;
  cursor: pointer !important;
}

.auth-btn-primary:hover,
.auth-form-side .btn-hero-primary:hover,
.auth-form-side .btn-hero-success:hover,
.auth-form-side .btn-hero-warning:hover,
.auth-form-side .btn-primary:hover {
  background-color: #1d4ed8 !important;
  border-color: #1d4ed8 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35) !important;
  transform: translateY(-1px) !important;
}

.auth-btn-primary:disabled,
.auth-form-side .btn-hero-primary:disabled,
.auth-form-side .btn-hero-success:disabled,
.auth-form-side .btn-hero-warning:disabled {
  opacity: 0.5 !important;
  cursor: not-allowed !important;
  transform: none !important;
  box-shadow: none !important;
}

/* Checkbox điều khoản */
.auth-form-side .custom-control-label {
  color: #475569 !important;
  font-size: 13.5px !important;
}

.auth-form-side .custom-control-label a {
  color: #2563eb !important;
  font-weight: 600 !important;
}

/* Dropdown ngôn ngữ nền sáng */
.auth-lang-pill {
  background-color: #f1f5f9 !important;
  border: 1px solid #e2e8f0 !important;
  color: #334155 !important;
  border-radius: 20px !important;
  padding: 5px 12px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
}

.auth-lang-pill:hover {
  background-color: #e2e8f0 !important;
  color: #0f172a !important;
}

/* Thông báo kiểm tra hợp lệ mật khẩu */
.auth-validation-msg {
  display: flex !important;
  align-items: center !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  line-height: 1.3 !important;
}
.auth-validation-msg.error {
  color: #dc2626 !important;
}
.auth-validation-msg.success {
  color: #16a34a !important;
}

.anticon {
  vertical-align: 0.1em !important;
}


