/* ============================================================
   BASE — Variables, reset, typography, buttons, forms, alerts
   Used on every page
   ============================================================ */

:root {
  /* Brand đỏ Material Design — màu chủ đạo */
  --primary: #b71c1c;          /* Đỏ đậm — text, h1/h2/h3 */
  --red: #d32f2f;              /* Đỏ chính — buttons, links, accents */
  --red-dark: #b71c1c;         /* Hover state */
  --red-light: #ffebee;        /* Nền nhạt */
  --red-border: #ffcdd2;       /* Viền nhạt */

  /* Aliases để code cũ vẫn chạy (--blue, --blue-dark, --blue-light, --blue-border)
     Map sang đỏ — không phải thay tên biến trong file riêng. */
  --blue: var(--red);
  --blue-dark: var(--red-dark);
  --blue-light: var(--red-light);
  --blue-border: var(--red-border);

  /* Trung lập — giữ y nguyên */
  --text: #1e293b;
  --muted: #64748b;
  --border: #e2e8f0;
  --bg: #f8fafc;
  --white: #ffffff;

  /* Status semantic — KHÔNG đổi (giữ UX quen thuộc) */
  --success: #16a34a;          /* Xanh lá = thành công */
  --orange: #f97316;           /* Cam = cảnh báo */
  --error: #dc2626;            /* Đỏ tươi cho error (khác với brand red) */

  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
  --radius: 10px;
  --radius-lg: 16px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Be Vietnam Pro', 'Segoe UI', sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  font-size: 14px;
  line-height: 1.6;
  /* `overflow: clip` prevents horizontal scroll WITHOUT creating a scroll
     container — keeps `position: sticky` working in descendants.
     `overflow: hidden` would break sticky positioning. */
  overflow-x: clip;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ---- LAYOUT ---- */
.container { max-width: 1280px; margin: 0 auto; padding: 0 40px; }
.container-md { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---- TYPOGRAPHY ---- */
h1 { font-size: 32px; font-weight: 900; color: var(--primary); }
h2 { font-size: 24px; font-weight: 800; color: var(--primary); }
h3 { font-size: 18px; font-weight: 700; color: var(--primary); }
p { color: var(--muted); line-height: 1.7; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 22px; border-radius: var(--radius);
  font-size: 14px; font-weight: 600; border: none;
  cursor: pointer; transition: all 0.15s;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--blue-dark); color: #fff; }
.btn-primary:hover { background: var(--primary); }
.btn-outline { background: #fff; color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { border-color: var(--blue); color: var(--blue); }
.btn-outline.active { background: var(--blue-light); border-color: var(--blue); color: var(--blue); font-weight: 700; }
.btn-blue-outline { background: #fff; color: var(--blue); border: 1px solid var(--blue); }
.btn-blue-outline:hover { background: var(--blue-light); }
.btn-secondary { background: #fff; color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { border-color: var(--blue); color: var(--blue); }
.btn-lg { padding: 13px 32px; font-size: 15px; border-radius: 12px; }
.btn-xl { padding: 14px 36px; font-size: 16px; border-radius: 12px; }
.btn-sm { padding: 12px 14px; font-size: 12px; }
.btn-full { width: 100%; justify-content: center; }

/* ---- FORM ELEMENTS ---- */
.form-group { margin-bottom: 16px; }
.form-group.span-2 { grid-column: span 2; }
.form-label, .form-group label {
  display: block; font-size: 12px; font-weight: 600;
  color: var(--muted); margin-bottom: 5px;
}
.form-label .req, .form-group label em { color: var(--red); font-style: normal; }
.form-control {
  width: 100%; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: 13px; outline: none; background: #fff;
  transition: border-color 0.15s;
  color: var(--text);
}
.form-control::placeholder {
  color:#e5e6e8;
}
input[type='date'], input[type='time'] {
    -webkit-appearance: none !important;
    height: 38px;
}
.form-control:focus { border-color: var(--blue); }
.form-select {
  width: 100%; padding: 10px 32px 10px 12px;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: 13px; outline: none; background: #fff;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer; color: var(--text);
  transition: border-color 0.15s;
}
.form-select:focus { border-color: var(--blue); }

/* ---- CARDS ---- */
.card {
  background: #fff; border-radius: var(--radius-lg);
  border: 1px solid var(--border); overflow: hidden;
}
.card-body { padding: 24px; }

/* ---- BADGE ---- */
.badge {
  display: inline-block; padding: 3px 10px;
  border-radius: 99px; font-size: 11px; font-weight: 700;
}
.badge-blue { background: #ffebee; color: var(--blue); }
.badge-orange { background: #ffedd5; color: var(--orange); }
.badge-green { background: #dcfce7; color: var(--success); }

/* ---- GRID ---- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; }

/* ---- DIVIDER ---- */
.divider { border: none; border-top: 1px solid var(--border); margin: 20px 0; }

/* ---- ALERT ---- */
.alert {
  padding: 14px 18px; border-radius: var(--radius);
  display: flex; gap: 10px; align-items: flex-start;
}
.alert-blue { background: var(--blue-light); border: 1px solid var(--blue-border); color: var(--primary); }
.alert-yellow { background: #fffbeb; border: 1px solid #fcd34d; color: #92400e; }
.alert-green { background: #dcfce7; border: 1px solid #86efac; color: #15803d; }

/* ---- SEA PLACEHOLDER ---- */
.sea-ph {
  width: 100%; background: linear-gradient(135deg, #0ea5e9 0%, #0369a1 100%);
  border-radius: var(--radius); position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.sea-ph::before {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(45deg,transparent,transparent 12px,rgba(255,255,255,0.04) 12px,rgba(255,255,255,0.04) 24px);
}
.sea-ph-label { color: rgba(255,255,255,0.5); font-size: 11px; font-family: monospace; text-align: center; padding: 8px; position: relative; z-index: 1; }

/* ---- UTILITIES ---- */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-6 { gap: 6px; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }
.mb-24 { margin-bottom: 24px; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-blue { color: var(--blue); }
.text-muted { color: var(--muted); }
.text-primary { color: var(--primary); }
.text-success { color: var(--success); }
.fw-700 { font-weight: 700; }
.fw-800 { font-weight: 800; }
.fs-12 { font-size: 12px; }
.fs-13 { font-size: 13px; }
.fs-14 { font-size: 14px; }
.hidden { display: none !important; }

/* ---- TOAST (used by app.js) ---- */
#toast-container {
  position: fixed; top: 20px; right: 20px; z-index: 9999;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  background: var(--text); color: #fff;
  padding: 12px 18px; border-radius: 8px;
  font-size: 13px; box-shadow: var(--shadow-lg);
  opacity: 0; transform: translateX(20px); transition: all 0.25s;
  max-width: 320px;
}
.toast.toast-show { opacity: 1; transform: translateX(0); }
.toast-success { background: var(--success); }
.toast-error { background: var(--error); }
.toast-warning { background: var(--orange); }

/* ---- RESPONSIVE BASE ---- */
@media (max-width: 1024px) {
  .container { padding: 0 24px; }
  .grid-4 { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 768px) {
  /* .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } */
  .home-cat-block .grid-3 { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .container, .container-md { padding: 0 16px; }
  
  
}
.air-datepicker {
  border-radius: 10px !important;
}

.air-datepicker-nav--title {
  font-weight: bold !important;
}
.air-datepicker-body--day-name {
  font-weight: bold !important;
  color:var(--red) !important;
}
.air-datepicker-cell.-selected- {
  background:var(--red) !important;
}
figure,
table {
  width: 100% !important;
  max-width: 100% !important ;
}


/* FIXED CONTACT */
.contact-fixed{
    position:fixed;
    right:20px;
    bottom:30px;

    z-index:99999;

    display:flex;
    flex-direction:column;
    gap:20px;
}

/* BUTTON */
.contact-btn{
    position:relative;

    width:50px;
    height:50px;

    border-radius:50%;

    display:flex;
    align-items:center;
    justify-content:center;

    text-decoration:none;

    overflow:visible;

    transition:.3s ease;

    box-shadow:
    0 10px 30px rgba(0,0,0,.25);
}

/* HOVER */
.contact-btn:hover{
    transform:translateY(-4px) scale(1.08);
}

/* ICON */
.contact-btn .icon{
    position:relative;
    z-index:3;

    font-size:30px;
    color:#fff;
}

/* LABEL */
.contact-btn .label{
    position:absolute;
    right:85px;

    background:#111827;

    color:#fff;

    padding:11px 16px;

    border-radius:14px;

    font-size:14px;
    font-weight:600;

    white-space:nowrap;

    opacity:0;
    visibility:hidden;

    transform:translateX(10px);

    transition:.3s ease;

    box-shadow:
    0 8px 25px rgba(0,0,0,.2);
}

/* SHOW LABEL */
.contact-btn:hover .label{
    opacity:1;
    visibility:visible;
    transform:translateX(0);
}

/* HOTLINE */
.hotline{
    background:
    linear-gradient(135deg,#ff512f,#dd2476);
}

/* ZALO */
.zalo{
    background:
    linear-gradient(135deg,#0084ff,#00c6ff);
}

/* WAVE EFFECT */
.wave{
    position:absolute;
    inset:0;

    border-radius:50%;

    background:inherit;

    animation:waveOut 2s infinite;

    opacity:.55;

    z-index:0;
}

/* SECOND WAVE */
.contact-btn::after{
    content:"";

    position:absolute;
    inset:0;

    border-radius:50%;

    background:inherit;

    animation:waveOut 2s 1s infinite;

    opacity:.35;

    z-index:0;
}

/* ANIMATION */
@keyframes waveOut{

    0%{
        transform:scale(1);
        opacity:.55;
    }

    100%{
        transform:scale(2);
        opacity:0;
    }

}

/* MOBILE */
@media(max-width:768px){

    .contact-fixed{
        right:14px;
        bottom:20px;
    }

    .contact-btn{
        width:58px;
        height:58px;
    }

    .contact-btn .icon{
        font-size:24px;
    }

    .contact-btn .label{
        display:none;
    }

}
/*date picker*/

.flatpickr-months .flatpickr-month {
  background-color: #b71c1c !important;
  color:#FFF !important;
}
.dayContainer {
  gap:2px;
  padding: 5px !important;
  
}
.flatpickr-day {
  border-radius: 4px !important;
 
    background-color: var(--success) !important;
    color: #FFF !important;
    border:0px !important;
}
.flatpickr-day.flatpickr-disabled ,.flatpickr-day.nextMonthDay{
  background-color: #e7e3e3 !important;
  color:#a0a0a0 !important;
}
.flatpickr-day.selected , .flatpickr-day:not(.flatpickr-disabled):hover{
  background-color: #ffb500 !important;
  color:#FFF !important;

}
.flatpickr-day.date-sold-out {
  color: #ffffff !important;
  background: #4d4d4d !important;
}
.flatpickr-months .flatpickr-prev-month svg, .flatpickr-months .flatpickr-next-month svg {
  fill:#FFF !important;
}

/*khung cho datepicker*/
.flatpickr-calendar {
    width: auto !important;
    padding: 0 !important;
    font-size: 12px !important;
}

.flatpickr-months {
    padding: 0 !important;
}

.flatpickr-current-month {
    font-size: 14px !important;
}

.flatpickr-weekdays {
    width: 100% !important;
}

.flatpickr-weekdaycontainer {
    display: flex !important;
    justify-content: space-between !important;
    padding: 0 8px !important;
}

.flatpickr-weekday,
.flatpickr-day {
    width: 34px !important;
    max-width: 34px !important;
    min-width: 34px !important;
    flex-basis: 34px !important;
    margin: 0 !important;
    border-radius: 6px !important;
}

.flatpickr-weekday {
    height: 34px !important;
    line-height: 34px !important;
    font-size: 11px !important;
}

.flatpickr-day {
    height: 36px !important;
    line-height: 36px !important;
}

.dayContainer {
    width: 280px !important;
    min-width: 280px !important;
    max-width: 280px !important;
    padding: 0 8px 8px !important;
}

.flatpickr-days,
.flatpickr-rContainer,
.flatpickr-innerContainer {
    width: auto !important;
    min-width: auto !important;
    max-width: auto !important;
    padding: 0 !important;
}