/* ============================================================
   Sales Kit For Gladia Heights 2026 — giao diện công khai
   ============================================================ */
:root {
  --teal: #2f9296;
  --teal-dark: #277c80;
  --orange: #e88a57;
  --orange-deep: #df7b45;
  --cream: #fcf8dc;
  --cream-line: #efe6b8;
  --ink: #2a7a80;
  --link: #de7a3f;
  --white: #ffffff;
  --shadow: 0 18px 60px rgba(24, 70, 72, 0.18);
  --radius: 14px;
  --sheet-w: 900px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #234;
  background: #e9eef0;
  background-image: radial-gradient(1200px 600px at 50% -10%, #d8eceb 0%, #e9eef0 55%);
  -webkit-font-smoothing: antialiased;
}

/* ---- Khung "tờ" trung tâm ---- */
.sheet {
  max-width: var(--sheet-w);
  margin: 32px auto;
  background: var(--cream);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* ---- HERO ---- */
.hero { position: relative; }
.hero__img {
  height: clamp(180px, 30vw, 300px);
  background-size: cover;
  background-position: center 35%;
}
.hero__title {
  position: relative;
  margin-top: -8px;
  padding: 6px 6% 22px;
  text-align: center;
  background: linear-gradient(180deg, rgba(64,190,196,0.0) 0%, var(--cream) 62%);
}
.hero__prefix {
  display: block;
  font-family: "Playfair Display", serif;
  font-weight: 700;
  font-style: italic;
  color: var(--orange);
  font-size: clamp(34px, 7vw, 66px);
  line-height: 1;
  text-shadow: 0 2px 10px rgba(255,255,255,0.35);
  margin-top: -0.35em;
}
.hero__project {
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
  margin-top: 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.hero__name {
  font-family: "Playfair Display", serif;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--ink);
  font-size: clamp(22px, 4.4vw, 40px);
}
.hero__year {
  font-family: "Playfair Display", serif;
  font-weight: 500;
  color: #6a6f57;
  font-size: clamp(18px, 3.4vw, 30px);
}

/* ---- BẢNG ---- */
.table-wrap { padding: 0 clamp(14px, 3.2%, 30px) clamp(10px, 2%, 20px); }
.doc-table {
  width: 100%;
  border: 1px solid var(--cream-line);
  border-radius: 8px;
  overflow: hidden;
}
.row {
  display: grid;
  grid-template-columns: 15% 46% 39%;
  align-items: stretch;
}
.cell {
  padding: 13px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-width: 0;
  word-break: break-word;
}
.cell--content { justify-content: center; }

/* Hàng tiêu đề bảng */
.row--head .cell {
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.5px;
  font-size: clamp(12px, 1.5vw, 15px);
  text-transform: uppercase;
}

/* Hàng nhóm (category) */
.row--cat .cell {
  background: var(--teal);
  color: #fff;
  font-weight: 700;
  border-top: 2px solid var(--cream);
  font-size: clamp(12px, 1.6vw, 15.5px);
  text-transform: uppercase;
}
.row--cat .cell--stt { font-weight: 700; }
.row--cat .cell--content { justify-content: flex-start; text-align: left; }
.row--cat .cell--link { text-transform: none; }
.row--cat .cell--link a { color: #fff; text-decoration: underline; font-weight: 600; }
.row--cat .cell--link a:hover { color: #fff8e6; }

/* Hàng mục (item) */
.row--item .cell {
  background: transparent;
  color: var(--ink);
  border-top: 1px solid var(--cream-line);
  font-size: clamp(12px, 1.5vw, 15px);
}
.row--item:hover .cell { background: rgba(255,255,255,0.5); }
.row--item .cell--stt { color: #6a6f57; font-weight: 600; }
.row--item .cell--content { font-weight: 500; }
.row--item .cell--link a {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
}
.row--item .cell--link a:hover { color: var(--orange-deep); }
.cell--link .no-link { color: #b9b189; font-style: italic; }

/* ---- FOOTER ---- */
.footer { line-height: 0; }
.footer__img { width: 100%; height: auto; display: block; }

/* ---- Nút quản trị nổi ---- */
.admin-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--teal);
  color: #fff;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(39, 124, 128, 0.4);
  transition: transform .15s ease, background .15s ease;
  z-index: 50;
}
.admin-fab:hover { background: var(--teal-dark); transform: translateY(-2px); }

/* ---- Trạng thái tải ---- */
.sheet[aria-busy="true"] #tableBody { min-height: 200px; }
.loading {
  padding: 40px;
  text-align: center;
  color: #8a8a6a;
  font-style: italic;
}

/* ---- Responsive ---- */
@media (max-width: 560px) {
  .sheet { margin: 0; border-radius: 0; }
  .row { grid-template-columns: 13% 44% 43%; }
  .cell { padding: 11px 9px; }
  .admin-fab span { display: none; }
  .admin-fab { padding: 12px; }
}
