/* ============================================================
   LAYOUT — Container, Grid, Sections, Responsive
   ============================================================ */

/* ---- Container ---- */
.container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--sp-md);
  padding-right: var(--sp-md);
}
.container-sm  { max-width: 768px; }
.container-md  { max-width: 960px; }
.container-lg  { max-width: 1200px; }
.container-xl  { max-width: 1440px; }
.container-fluid { max-width: none; }

/* ---- 12-column Grid ---- */
.row {
  display: flex;
  flex-wrap: wrap;
  margin-left:  calc(var(--sp-sm) * -0.5);
  margin-right: calc(var(--sp-sm) * -0.5);
}
.row > [class*='col-'] {
  padding-left:  calc(var(--sp-sm) * 0.5);
  padding-right: calc(var(--sp-sm) * 0.5);
  width: 100%;
}

/* Mobile-first column widths */
.col-1  { width: 8.333%; }
.col-2  { width: 16.666%; }
.col-3  { width: 25%; }
.col-4  { width: 33.333%; }
.col-5  { width: 41.666%; }
.col-6  { width: 50%; }
.col-7  { width: 58.333%; }
.col-8  { width: 66.666%; }
.col-9  { width: 75%; }
.col-10 { width: 83.333%; }
.col-11 { width: 91.666%; }
.col-12 { width: 100%; }

/* Tablet (641px+) */
@media (min-width: 641px) {
  .col-md-1  { width: 8.333%; }
  .col-md-2  { width: 16.666%; }
  .col-md-3  { width: 25%; }
  .col-md-4  { width: 33.333%; }
  .col-md-5  { width: 41.666%; }
  .col-md-6  { width: 50%; }
  .col-md-7  { width: 58.333%; }
  .col-md-8  { width: 66.666%; }
  .col-md-9  { width: 75%; }
  .col-md-10 { width: 83.333%; }
  .col-md-11 { width: 91.666%; }
  .col-md-12 { width: 100%; }
}

/* Desktop (1025px+) */
@media (min-width: 1025px) {
  .col-lg-1  { width: 8.333%; }
  .col-lg-2  { width: 16.666%; }
  .col-lg-3  { width: 25%; }
  .col-lg-4  { width: 33.333%; }
  .col-lg-5  { width: 41.666%; }
  .col-lg-6  { width: 50%; }
  .col-lg-7  { width: 58.333%; }
  .col-lg-8  { width: 66.666%; }
  .col-lg-9  { width: 75%; }
  .col-lg-10 { width: 83.333%; }
  .col-lg-11 { width: 91.666%; }
  .col-lg-12 { width: 100%; }
}

/* ---- CSS Grid helpers ---- */
.grid      { display: grid; }
.grid-2    { grid-template-columns: repeat(2, 1fr); gap: var(--sp-md); }
.grid-3    { grid-template-columns: repeat(3, 1fr); gap: var(--sp-md); }
.grid-4    { grid-template-columns: repeat(4, 1fr); gap: var(--sp-md); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--sp-md); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-4,
  .grid-3,
  .grid-2 { grid-template-columns: 1fr; }
}

/* ---- Sections ---- */
.section          { padding: var(--sp-2xl) 0; }
.section-sm       { padding: var(--sp-xl)  0; }
.section-lg       { padding: var(--sp-3xl) 0; }
.section-bg-light { background-color: var(--off-white); }
.section-bg-dark  { background-color: var(--dark); color: var(--white); }
.section-bg-emerald { background-color: var(--emerald-primary); color: var(--white); }
.section-bg-gold  { background-color: var(--gold-muted); }

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(4,120,87,.7) 0%, rgba(0,0,0,.5) 100%);
}
.hero-content {
  position: relative;
  z-index: 1;
  color: var(--white);
}
.hero-content h1 { color: var(--white); }
.hero-content .eyebrow { color: var(--gold-accent); }

/* ---- Footer ---- */
.footer {
  background-color: var(--dark);
  color: var(--white);
  padding: var(--sp-2xl) 0 var(--sp-md);
}
.footer a { color: var(--mid-gray); }
.footer a:hover { color: var(--gold-primary); }
.footer-heading {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: var(--sp-sm);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: var(--sp-md);
  margin-top: var(--sp-xl);
  text-align: center;
  font-size: .85rem;
  color: var(--mid-gray);
}


/* ---- Hotline floating widget ---- */
.hotline-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  left: unset;
  z-index: 250;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

@keyframes hotline-pulse {
  0%, 100% {
    box-shadow: 0 4px 18px rgba(212,175,55,.35),
                0 0 0 0 rgba(212,175,55,.22);
  }
  55% {
    box-shadow: 0 6px 26px rgba(212,175,55,.58),
                0 0 0 11px rgba(212,175,55,0);
  }
}

.hotline-btn {
  position: relative;
  width: 52px;
  height: 52px;
  background: var(--gold-primary);
  color: var(--dark);
  border: none;
  border-radius: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: hotline-pulse 2.6s ease-in-out infinite;
  transition: background .22s, color .22s;
  overflow: visible;
}
.hotline-btn::before,
.hotline-btn::after {
  content: '';
  position: absolute;
  width: 7px; height: 7px;
  pointer-events: none;
}
.hotline-btn::before { top: -3px; left: -3px; border-top: 1.5px solid rgba(0,0,0,.22); border-left: 1.5px solid rgba(0,0,0,.22); }
.hotline-btn::after  { bottom: -3px; right: -3px; border-bottom: 1.5px solid rgba(0,0,0,.22); border-right: 1.5px solid rgba(0,0,0,.22); }

.hotline-icon-close { display: none; }

.hotline-widget.open .hotline-btn {
  animation: none;
  background: #1a1f18;
  color: var(--white);
  box-shadow: 0 4px 18px rgba(0,0,0,.35);
}
.hotline-widget.open .hotline-icon-open  { display: none; }
.hotline-widget.open .hotline-icon-close { display: block; }
.hotline-widget.open .hotline-btn::before { border-color: rgba(212,175,55,.45); }
.hotline-widget.open .hotline-btn::after  { border-color: rgba(212,175,55,.45); }

.hotline-popup {
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
}
.hotline-widget.open .hotline-popup {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.hotline-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px 11px 12px;
  background: var(--dark);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 0;
  color: var(--white);
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  overflow: visible;
  transition: background .2s, border-color .2s;
}
.hotline-item::before,
.hotline-item::after {
  content: '';
  position: absolute;
  width: 6px; height: 6px;
  opacity: 0;
  transition: opacity .2s, width .2s, height .2s;
  pointer-events: none;
}
.hotline-item::before { top: -3px; left: -3px; border-top: 1px solid var(--gold-primary); border-left: 1px solid var(--gold-primary); }
.hotline-item::after  { bottom: -3px; right: -3px; border-bottom: 1px solid var(--gold-primary); border-right: 1px solid var(--gold-primary); }
.hotline-item:hover { background: #1e2a1c; border-color: rgba(212,175,55,.5); color: var(--white); }
.hotline-item:hover::before,
.hotline-item:hover::after { opacity: 1; width: 9px; height: 9px; }

.hotline-item-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.hotline-item--phone .hotline-item-icon {
  background: rgba(212,175,55,.12);
  color: var(--gold-primary);
}
.hotline-item--zalo .hotline-item-icon {
  background: #0068ff;
  color: #fff;
  font-weight: 900;
  font-size: 1.05rem;
  font-family: var(--font-base);
  letter-spacing: -.03em;
}

.hotline-item-label {
  display: block;
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold-primary);
  line-height: 1;
  margin-bottom: 4px;
}
.hotline-item-num {
  display: block;
  font-size: .875rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1;
  letter-spacing: .02em;
}

@media (max-width: 480px) {
  .hotline-widget { bottom: 16px; right: 16px; }
  .hotline-btn    { width: 48px; height: 48px; }
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-xl);
}

.footer-social {
  color: var(--mid-gray);
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color var(--transition-fast), color var(--transition-fast);
  text-decoration: none;
}
.footer-social:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
}

@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: var(--sp-lg); }
}

@media (max-width: 640px) {
  .footer-grid { grid-template-columns: 1fr; gap: var(--sp-lg); }
  .footer-bottom {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: center;
  }
  .footer-bottom .mx-2 { display: none; }
}

/* ---- Breadcrumb ---- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  font-size: .85rem;
  color: var(--mid-gray);
  padding: var(--sp-sm) 0;
}
.breadcrumb a { color: var(--mid-gray); }
.breadcrumb a:hover { color: var(--emerald-primary); }
.breadcrumb .separator { color: var(--border-color); }
.breadcrumb .current   { color: var(--charcoal); font-weight: 600; }

/* ---- Page header ---- */
.page-header {
  background: linear-gradient(135deg, var(--emerald-dark) 0%, var(--emerald-primary) 100%);
  padding: var(--sp-xl) 0;
  color: var(--white);
  margin-bottom: var(--sp-2xl);
}
.page-header h1   { color: var(--white); }
.page-header .breadcrumb a,
.page-header .breadcrumb .separator { color: rgba(255,255,255,.6); }
.page-header .breadcrumb .current   { color: var(--white); }

/* ---- Sidebar ---- */
.sidebar-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: var(--sp-2xl);
  align-items: start;
}
@media (max-width: 1024px) {
  .sidebar-layout { grid-template-columns: 1fr; }
}

.sidebar-widget {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--sp-md);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--sp-md);
}
.sidebar-widget-title {
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--charcoal);
  padding-bottom: var(--sp-sm);
  border-bottom: 2px solid var(--gold-primary);
  margin-bottom: var(--sp-md);
}

/* ---- Pagination ---- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: var(--sp-xl);
}
.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 10px;
  border-radius: var(--radius-md);
  font-size: .9rem;
  font-weight: 600;
  border: 1.5px solid var(--border-color);
  color: var(--charcoal);
  transition: all var(--transition-fast);
}
.pagination a:hover { border-color: var(--emerald-primary); color: var(--emerald-primary); }
.pagination .active { background: var(--emerald-primary); border-color: var(--emerald-primary); color: var(--white); }
.pagination .disabled { opacity: .4; pointer-events: none; }
