/* Login + booking popups — loaded by app.js */
.vw-modal-bg {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: transparent;
}
.vw-modal-bg.show { display: flex; }
/* Blur sits on a sibling layer so Chrome does not duplicate the form over the photo */
.vw-modal-dim {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: rgba(40, 32, 24, .42);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  pointer-events: auto;
}
.vw-modal {
  position: relative;
  z-index: 1;
  isolation: isolate;
  transform: translateZ(0);
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 24px 70px rgba(40, 28, 22, .22);
  max-height: 92vh;
  overflow: hidden;
}
.vw-modal-x {
  position: absolute;
  top: 14px;
  right: 16px;
  z-index: 3;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #8a7c72;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.vw-modal-x:hover { background: rgba(0,0,0,.06); }

/* —— Login modal — ảnh / form 50-50, ô nhập không tràn sang ảnh —— */
.vw-modal-login {
  width: min(900px, 96vw);
  height: min(680px, 92vh);
  display: flex;
  flex-direction: row;
  align-items: stretch;
  overflow: hidden;
  background: #fff;
}
.vw-login-photo {
  flex: 0 0 50%;
  width: 50%;
  min-width: 0;
  overflow: hidden;
  background: #d8cfc4;
}
.vw-login-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  max-width: none;
}
.vw-login-body {
  flex: 1 1 50%;
  min-width: 0;
  overflow: auto;
  padding: 28px 22px 22px;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  contain: paint;
}
.vw-login-body > * {
  width: 100%;
  max-width: 300px;
  flex-shrink: 0;
}
.vw-login-body form {
  display: block;
  margin: 0;
}
.vw-login-brand {
  display: flex;
  justify-content: center;
  margin: 2px 0 10px;
}
.vw-login-brand img {
  height: 56px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
  display: block;
}
.vw-login-body h2 {
  margin: 4px 0 8px;
  text-align: center;
  color: #5c3d2e;
  font-family: "Times New Roman", Times, serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.25;
}
.vw-login-lead {
  margin: 0 auto 12px;
  text-align: center;
  color: #6b5c52;
  font-size: 12.5px;
  line-height: 1.5;
}
.vw-tabs {
  display: flex;
  justify-content: center;
  gap: 28px;
  border-bottom: 1px solid rgba(92,61,46,.14);
  margin: 6px 0 14px;
}
.vw-tabs button {
  background: none;
  border: 0;
  padding: 8px 0 10px;
  cursor: pointer;
  color: #8a7c72;
  font-size: 15px;
  font-weight: 600;
  border-bottom: 2px solid transparent;
}
.vw-tabs button.on { color: #5c3d2e; border-color: #8a6a4a; }
.vw-field-wrap { position: relative; }
.vw-field-wrap .vw-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: #8a7c72;
  pointer-events: none;
}
.vw-field-wrap .vw-eye {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: none;
  cursor: pointer;
  color: #8a7c72;
  padding: 4px;
}
.vw-login-body label {
  display: block;
  margin: 10px 0 6px;
  color: #5c3d2e;
  font-size: 13px;
  font-weight: 600;
}
.vw-login-body .field {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px 10px 36px;
  border: 1px solid #e4dcd0;
  border-radius: 10px;
  background: #fff;
  font-size: 13px;
}
.vw-login-body .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.vw-login-body .field.no-ico { padding-left: 14px; }
.vw-forgot {
  display: block;
  text-align: right;
  margin: 6px 0 0;
  font-size: 12.5px;
  color: #6b5c52;
  text-decoration: underline;
  cursor: pointer;
}
.vw-btn-login {
  display: block;
  width: 100%;
  margin-top: 14px;
  height: 42px;
  border: 0;
  border-radius: 10px;
  background: #5c6646;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  cursor: pointer;
}
.vw-btn-outline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 10px;
  height: 42px;
  border: 1.5px solid #c9b8a6;
  border-radius: 10px;
  background: #fff;
  color: #5c3d2e;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .05em;
  cursor: pointer;
}
.vw-signup-hint {
  margin: 14px 0 0;
  text-align: center;
  font-size: 13px;
  color: #6b5c52;
}
.vw-signup-hint a { color: #5c3d2e; font-weight: 700; text-decoration: underline; cursor: pointer; }
.vw-modal-msg { min-height: 18px; margin-top: 8px; font-size: 13px; }
.vw-modal-msg.err { color: #9b2c2c; }
.vw-modal-msg.ok { color: #3d4f3a; }

/* —— Booking form — khớp mockup lịch —— */
.vw-modal-book {
  width: min(1120px, 100%);
  padding: 26px 26px 20px;
  background: #fdfbf7;
  border-radius: 22px;
  overflow: auto;
}
.vw-book-title {
  margin: 0 0 16px;
  color: #8b6e57;
  font-family: "Times New Roman", Times, serif;
  font-size: 26px;
  font-weight: 600;
}
.vw-book-grid {
  display: grid;
  grid-template-columns: 1.55fr .92fr;
  gap: 14px;
  align-items: start;
}
.vw-book-card {
  background: #fff;
  border-radius: 18px;
  padding: 16px 16px 14px;
  box-shadow: 0 6px 20px rgba(58,47,40,.06);
}
.vw-book-card h3 {
  margin: 0 0 12px;
  color: #8b6e57;
  font-family: "Times New Roman", Times, serif;
  font-size: 16px;
  font-weight: 600;
}
.vw-book-split {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 14px;
}
.vw-cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.vw-cal-nav select {
  border: 1px solid #e4dcd0;
  border-radius: 8px;
  padding: 6px 8px;
  background: #fff;
  font-size: 13px;
  color: #3a2f28;
}
.vw-cal-nav button {
  width: 32px;
  height: 32px;
  border: 1px solid #e4dcd0;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  color: #8b6e57;
}
.vw-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  text-align: center;
}
.vw-cal-grid .wd {
  font-size: 11px;
  color: #8a7c72;
  font-weight: 600;
  padding: 4px 0;
}
.vw-day {
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  font-size: 13px;
  color: #3a2f28;
}
.vw-day:disabled { color: #ccc; cursor: default; }
.vw-day.today { box-shadow: inset 0 0 0 1.5px #8b6e57; }
.vw-day.on { background: #8b6e57; color: #fff; box-shadow: none; }
.vw-times {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
}
.vw-time {
  height: 34px;
  border: 1px solid #c9b8a6;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  font-size: 12.5px;
  color: #3a2f28;
}
.vw-time.on,
.vw-time.on:disabled {
  background: #8b6e57;
  color: #fff;
  border-color: #8b6e57;
  cursor: default;
}
.vw-time:disabled:not(.on) { background: #eceae6; color: #aaa; border-color: #eceae6; cursor: not-allowed; }
.vw-book-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.vw-legend {
  display: flex;
  gap: 14px;
  font-size: 12px;
  color: #6b5c52;
  margin-right: auto;
}
.vw-legend i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
  border: 1px solid #c9b8a6;
  background: #fff;
}
.vw-legend .off { background: #d8d4cf; border-color: #d8d4cf; }
.vw-legend .pick { background: #8b6e57; border-color: #8b6e57; }
.vw-book-go {
  display: block;
  min-width: 150px;
  height: 42px;
  padding: 0 22px;
  border: 0;
  border-radius: 10px;
  background: #8b6e57;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}
.vw-book-side { display: flex; flex-direction: column; gap: 12px; }
.vw-loc {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 10px;
  margin: 0 -6px 4px;
  border-radius: 10px;
  cursor: pointer;
}
.vw-loc.on { background: #f3ebe0; }
.vw-loc input { margin-top: 4px; accent-color: #8b6e57; }
.vw-loc span { font-size: 13.5px; line-height: 1.4; color: #3a2f28; }
.vw-loc-info { display: flex; gap: 12px; align-items: flex-start; }
.vw-pin {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #f3ebe0;
  color: #8b6e57;
}
.vw-pin svg { width: 20px; height: 20px; }
.vw-loc-detail {
  font-size: 13.5px;
  color: #3a2f28;
  line-height: 1.45;
}
.vw-loc-detail strong { color: #8b6e57; }
.vw-loc-detail p { margin: 4px 0 0; color: #5a4e46; }
.vw-loc-phones { margin-top: 10px; padding-top: 10px; border-top: 1px solid #eee; font-size: 13px; color: #3a2f28; }
.vw-help-box {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 14px;
  border-radius: 16px;
  background: #f6f3ec;
  font-size: 13px;
  color: #5a4e46;
  line-height: 1.45;
  box-shadow: 0 6px 20px rgba(58,47,40,.05);
}
.vw-help-box p { margin: 0; }
.vw-leaf {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  color: #8b6e57;
}
.vw-leaf svg { width: 18px; height: 18px; }

@media (max-width: 860px) {
  .vw-modal-login {
    flex-direction: column;
    height: auto;
    width: min(440px, 96vw);
  }
  .vw-login-photo { display: none; }
  .vw-book-grid, .vw-book-split { grid-template-columns: 1fr; }
  .vw-times { grid-template-columns: repeat(4, 1fr); }
  .vw-book-go { width: 100%; }
}

/* Popup gửi SĐT nhận tư vấn — không cần đăng nhập */
.vw-consult {
  width: min(920px, 96vw);
  height: min(560px, 90vh);
  display: flex;
  flex-direction: row;
  overflow: hidden;
  background: #f6f1e9;
  border-radius: 22px;
}
.vw-consult-form {
  flex: 0 0 46%;
  width: 46%;
  min-width: 0;
  padding: 36px 28px 28px 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.vw-consult-form h2 {
  margin: 0 0 22px;
  color: #2a3d28;
  font-family: "Times New Roman", Times, serif;
  font-size: 26px;
  font-weight: 700;
  line-height: 1.28;
}
.vw-consult-form label {
  display: block;
  margin: 0 0 6px;
  color: #5c534c;
  font-size: 13px;
  font-weight: 600;
}
.vw-consult-form .field { margin-bottom: 14px; }
.vw-consult-flag { width: 18px; height: 12px; display: block; border-radius: 1px; }
.vw-consult-form input,
.vw-consult-form select {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid #e4ddd4;
  border-radius: 12px;
  background: #fff;
  color: #1c1916;
  font-size: 14px;
  outline: none;
  box-sizing: border-box;
}
.vw-consult-form select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 38px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%235c534c' d='M1.2 1.2L6 6l4.8-4.8'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  cursor: pointer;
}
.vw-consult-form input:focus,
.vw-consult-form select:focus {
  border-color: #8aa07a;
  box-shadow: 0 0 0 3px rgba(61, 79, 58, .12);
}
.vw-consult-phone {
  display: flex;
  align-items: stretch;
  border: 1px solid #e4ddd4;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}
.vw-consult-phone:focus-within {
  border-color: #8aa07a;
  box-shadow: 0 0 0 3px rgba(61, 79, 58, .12);
}
.vw-consult-cc {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  border-right: 1px solid #eee6dc;
  color: #3a322c;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  background: #faf7f2;
}
.vw-consult-cc img { width: 18px; height: 12px; display: block; border-radius: 2px; }
.vw-consult-phone input {
  border: 0;
  box-shadow: none;
  height: 46px;
  border-radius: 0;
}
.vw-consult-go {
  margin-top: 8px;
  width: 100%;
  height: 48px;
  border: 0;
  border-radius: 999px;
  background: #3d4f3a;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .06em;
  cursor: pointer;
}
.vw-consult-go:hover { background: #2f3e2d; }
.vw-consult-photo {
  position: relative;
  flex: 1 1 54%;
  min-width: 0;
  overflow: hidden;
  background: #e8dfd2;
}
.vw-consult-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% 18%;
  display: block;
}
.vw-consult-photo::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 46%;
  background: linear-gradient(90deg, #f6f1e9 0%, rgba(246,241,233,.82) 38%, rgba(246,241,233,0) 100%);
  pointer-events: none;
  z-index: 1;
}
.vw-consult .vw-modal-x {
  background: rgba(255,255,255,.88);
  color: #5c534c;
}
@media (max-width: 760px) {
  .vw-consult {
    flex-direction: column-reverse;
    height: auto;
    max-height: 92vh;
  }
  .vw-consult-form {
    flex: none;
    width: auto;
    padding: 22px 20px 24px;
  }
  .vw-consult-form h2 { font-size: 22px; margin-bottom: 16px; }
  .vw-consult-photo {
    flex: none;
    height: 168px;
  }
  .vw-consult-photo::before {
    width: 100%;
    height: 56%;
    inset: auto 0 0 0;
    background: linear-gradient(0deg, #f6f1e9 0%, rgba(246,241,233,.7) 45%, transparent 100%);
  }
}

body.vw-modal-open { overflow: hidden; }
