
:root {
  --apm-ink: #102636;
  --apm-deep: #07364a;
  --apm-blue: #0b7897;
  --apm-aqua: #4dc8c4;
  --apm-coral: #ef846f;
  --apm-sand: #f4eee5;
  --apm-cream: #fbf7f1;
  --apm-white: #fff;
  --apm-line: rgba(16,38,54,.11);
  --apm-muted: rgba(16,38,54,.67);
  --apm-shadow: 0 26px 75px rgba(10,43,61,.14);
}

body.apm-properties-page header.wp-block-template-part,
body.apm-properties-page footer.wp-block-template-part,
body.apm-properties-page .wp-block-post-title,
body.apm-properties-page .entry-title {
  display: none !important;
}

body.apm-properties-page,
body.apm-properties-page .wp-site-blocks,
body.apm-properties-page main,
body.apm-properties-page .entry-content,
body.apm-properties-page .wp-block-post-content {
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
  max-width: none !important;
}

body.apm-properties-page .apm-app {
  position: relative !important;
  left: 50% !important;
  width: 100vw !important;
  max-width: 100vw !important;
  margin-left: -50vw !important;
}

.apm-app {
  min-height: 100vh;
  color: var(--apm-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 12% 0%, rgba(77,200,196,.12), transparent 30%),
    radial-gradient(circle at 100% 12%, rgba(239,132,111,.11), transparent 26%),
    linear-gradient(180deg,#fff 0%,#f6f8f8 100%);
}

.apm-app-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  padding: 0 max(28px, calc((100vw - 1440px) / 2));
  background: rgba(255,255,255,.92);
  border-bottom: 1px solid var(--apm-line);
  backdrop-filter: blur(18px);
}

.admin-bar .apm-app-header { top: 32px; }

.apm-brand {
  display: flex;
  gap: 12px;
  align-items: center;
  color: var(--apm-ink) !important;
  text-decoration: none !important;
}

.apm-brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  background: linear-gradient(145deg,var(--apm-deep),var(--apm-aqua));
  border-radius: 13px;
  font-weight: 900;
}

.apm-brand strong,.apm-brand small { display:block; }
.apm-brand small { margin-top:3px;color:var(--apm-muted);font-size:10px;letter-spacing:.06em;text-transform:uppercase; }

.apm-app-nav { display:flex;gap:8px; }
.apm-app-nav a { padding:10px 14px;color:var(--apm-muted)!important;border-radius:999px;text-decoration:none!important;font-size:13px;font-weight:800; }
.apm-app-nav a:hover,.apm-app-nav a.is-active { color:var(--apm-deep)!important;background:rgba(77,200,196,.14); }

.apm-shell {
  width: min(1440px, calc(100vw - 64px));
  margin: 0 auto;
  padding: 84px 0 110px;
}

.apm-page-header {
  max-width: 900px;
  margin-bottom: 48px;
}

.apm-eyebrow {
  color: var(--apm-blue);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .18em;
}

.apm-page-header h1 {
  margin: 14px 0 18px;
  font-size: clamp(54px,6vw,90px);
  line-height:.95;
  letter-spacing:-.06em;
}

.apm-page-header p {
  max-width: 760px;
  margin:0;
  color:var(--apm-muted);
  font-size:18px;
  line-height:1.7;
}

.apm-property-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:34px;
}

.apm-property-card {
  overflow:hidden;
  background:#fff;
  border:1px solid rgba(16,38,54,.08);
  border-radius:28px;
  box-shadow:var(--apm-shadow);
}

.apm-image-wrap {
  position:relative;
  display:block;
  width:100%;
  aspect-ratio:16/9;
  padding:0;
  overflow:hidden;
  border:0;
  background:#ddd;
  cursor:pointer;
}

.apm-image-wrap::after {
  content:"";
  position:absolute;
  inset:auto 0 0;
  height:48%;
  background:linear-gradient(180deg,transparent,rgba(4,30,44,.46));
}

.apm-image-wrap img {
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
  transition:transform .45s ease;
}

.apm-image-wrap:hover img { transform:scale(1.035); }

.apm-location,.apm-gallery-count {
  position:absolute;
  z-index:2;
  bottom:20px;
  padding:9px 13px;
  color:#fff;
  background:rgba(7,34,48,.78);
  border:1px solid rgba(255,255,255,.22);
  border-radius:999px;
  backdrop-filter:blur(10px);
  font-size:12px;
  font-weight:800;
}

.apm-location { left:22px; }
.apm-gallery-count { right:22px; }

.apm-card-body {
  display:flex;
  flex-direction:column;
  min-height:430px;
  padding:32px;
}

.apm-title-row {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:30px;
}

.apm-title-row h2 {
  margin:0;
  max-width:470px;
  font-size:clamp(32px,3vw,46px);
  line-height:1.02;
  letter-spacing:-.05em;
}

.apm-rate {
  flex:0 0 auto;
  text-align:right;
}

.apm-rate strong {
  display:block;
  font-size:30px;
  line-height:1;
}

.apm-rate span { color:var(--apm-muted);font-size:12px; }

.apm-facts {
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:22px;
}

.apm-facts span {
  padding:8px 12px;
  background:var(--apm-sand);
  border-radius:999px;
  font-size:12px;
  font-weight:800;
}

.apm-description {
  margin-top:24px;
  color:var(--apm-muted);
  font-size:16px;
  line-height:1.7;
}

.apm-description p { margin:0; }

.apm-card-footer {
  margin-top:auto;
  padding-top:28px;
}

.apm-price-meta {
  display:flex;
  justify-content:space-between;
  gap:20px;
  padding:17px 0;
  margin-bottom:18px;
  border-top:1px solid var(--apm-line);
  border-bottom:1px solid var(--apm-line);
  color:var(--apm-muted);
  font-size:13px;
}

.apm-price-meta strong { color:var(--apm-ink); }

.apm-button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  width:100%;
  min-height:56px;
  padding:14px 20px;
  color:#fff!important;
  background:linear-gradient(135deg,var(--apm-deep),var(--apm-aqua));
  border:0;
  border-radius:14px;
  box-shadow:0 14px 32px rgba(10,120,151,.24);
  font-size:15px;
  font-weight:900;
  cursor:pointer;
}

.apm-modal {
  position:fixed;
  inset:0;
  z-index:99999;
  display:none;
  align-items:center;
  justify-content:center;
  padding:24px;
}

.apm-modal[aria-hidden="false"] { display:flex; }

.apm-modal-backdrop {
  position:absolute;
  inset:0;
  background:rgba(3,23,33,.72);
  backdrop-filter:blur(8px);
}

.apm-modal-dialog {
  position:relative;
  z-index:2;
  width:min(1180px,100%);
  max-height:calc(100vh - 48px);
  overflow:auto;
  background:#fff;
  border-radius:28px;
  box-shadow:0 40px 120px rgba(0,0,0,.34);
}

.apm-modal-close {
  position:absolute;
  top:18px;
  right:18px;
  z-index:4;
  width:42px;
  height:42px;
  border:0;
  border-radius:50%;
  background:#f3f5f5;
  color:var(--apm-ink);
  font-size:25px;
  cursor:pointer;
}

.apm-modal-heading {
  padding:42px 48px 28px;
  border-bottom:1px solid var(--apm-line);
}

.apm-modal-heading h2 {
  margin:10px 0 6px;
  font-size:42px;
  line-height:1;
  letter-spacing:-.04em;
}

.apm-modal-heading p { margin:0;color:var(--apm-muted); }

.apm-booking-workspace {
  display:grid;
  grid-template-columns:minmax(0,1.2fr) minmax(340px,.8fr);
}

.apm-calendar-panel {
  padding:38px 48px 48px;
  border-right:1px solid var(--apm-line);
}

.apm-calendar-toolbar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:24px;
}

.apm-calendar-toolbar button {
  width:42px;
  height:42px;
  border:1px solid var(--apm-line);
  border-radius:12px;
  background:#fff;
  cursor:pointer;
}

.apm-calendar-toolbar strong { font-size:20px; }

.apm-calendar-weekdays,.apm-calendar-grid {
  display:grid;
  grid-template-columns:repeat(7,1fr);
  gap:8px;
}

.apm-calendar-weekdays {
  margin-bottom:8px;
  color:var(--apm-muted);
  font-size:11px;
  font-weight:800;
  text-align:center;
  text-transform:uppercase;
}

.apm-calendar-grid button,.apm-calendar-empty {
  aspect-ratio:1;
}

.apm-calendar-grid button {
  border:1px solid var(--apm-line);
  border-radius:12px;
  background:#fff;
  color:var(--apm-ink);
  font-weight:800;
  cursor:pointer;
}

.apm-calendar-grid button:hover:not(:disabled) { border-color:var(--apm-aqua);background:rgba(77,200,196,.10); }
.apm-calendar-grid button.is-unavailable { color:#a8b0b4;background:#f1f3f3;text-decoration:line-through;cursor:not-allowed; }
.apm-calendar-grid button.is-selected { color:#fff;background:var(--apm-deep);border-color:var(--apm-deep); }
.apm-calendar-grid button.is-in-range { background:rgba(77,200,196,.23);border-color:rgba(77,200,196,.25); }

.apm-calendar-legend {
  display:flex;
  flex-wrap:wrap;
  gap:18px;
  margin-top:22px;
  color:var(--apm-muted);
  font-size:12px;
}

.apm-calendar-legend span { display:flex;align-items:center;gap:7px; }
.apm-calendar-legend i { width:12px;height:12px;border-radius:4px;border:1px solid var(--apm-line); }
.apm-calendar-legend .is-available { background:#fff; }
.apm-calendar-legend .is-selected { background:var(--apm-deep); }
.apm-calendar-legend .is-unavailable { background:#e4e8e9; }

.apm-reservation-panel {
  padding:38px 42px 48px;
  background:linear-gradient(180deg,rgba(77,200,196,.08),transparent 36%),#fff;
}

.apm-reservation-panel h3 {
  margin:0 0 22px;
  font-size:28px;
  letter-spacing:-.03em;
}

.apm-reservation-dates {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px;
}

.apm-reservation-dates div {
  padding:15px;
  background:var(--apm-cream);
  border-radius:14px;
}

.apm-reservation-dates span,.apm-reservation-dates strong { display:block; }
.apm-reservation-dates span { color:var(--apm-muted);font-size:11px;text-transform:uppercase; }
.apm-reservation-dates strong { margin-top:5px;font-size:14px; }

.apm-reservation-pricing {
  padding:18px 0;
  margin:20px 0;
  border-top:1px solid var(--apm-line);
  border-bottom:1px solid var(--apm-line);
}

.apm-reservation-pricing div {
  display:flex;
  justify-content:space-between;
  gap:18px;
  padding:8px 0;
  font-size:14px;
}

.apm-reservation-pricing .apm-total-row {
  margin-top:8px;
  padding-top:14px;
  border-top:1px solid var(--apm-line);
  font-size:18px;
}

#apm-booking-form label {
  display:grid;
  gap:7px;
  margin-top:14px;
  font-size:12px;
  font-weight:800;
}

#apm-booking-form input,#apm-booking-form textarea {
  width:100%;
  box-sizing:border-box;
  padding:12px 13px;
  border:1px solid rgba(16,38,54,.15);
  border-radius:10px;
  font:inherit;
}

.apm-form-row { display:grid;grid-template-columns:1fr 1fr;gap:12px; }
#apm-booking-form .apm-button { margin-top:18px; }
.apm-payment-note { color:var(--apm-muted);font-size:11px;line-height:1.5;text-align:center; }

.apm-booking-message {
  margin-top:14px;
  padding:0;
  border-radius:12px;
  font-size:13px;
  line-height:1.5;
}

.apm-booking-message.is-error { padding:13px;background:#fff0ed;color:#8d2c1d; }
.apm-booking-message.is-success { padding:13px;background:#e9f8ef;color:#175c38; }

.apm-gallery-dialog { width:min(1100px,100%);background:#0a1820; }
.apm-gallery-stage {
  display:grid;
  grid-template-columns:60px 1fr 60px;
  align-items:center;
  min-height:600px;
  padding:40px 20px 10px;
}
.apm-gallery-stage img { width:100%;max-height:72vh;object-fit:contain; }
.apm-gallery-stage button {
  width:46px;height:46px;margin:auto;border:0;border-radius:50%;background:rgba(255,255,255,.12);color:#fff;font-size:20px;cursor:pointer;
}
.apm-gallery-caption { display:flex;justify-content:space-between;padding:18px 80px 28px;color:#fff; }

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

@media(max-width:980px){
  .apm-property-grid,.apm-booking-workspace { grid-template-columns:1fr; }
  .apm-calendar-panel { border-right:0;border-bottom:1px solid var(--apm-line); }
}

@media(max-width:700px){
  .apm-shell { width:calc(100vw - 24px);padding:52px 0 72px; }
  .apm-app-header { padding:14px 16px; }
  .apm-brand small { display:none; }
  .apm-title-row,.apm-price-meta { display:block; }
  .apm-rate { margin-top:18px;text-align:left; }
  .apm-price-meta span { display:block;margin:5px 0; }
  .apm-card-body { min-height:0;padding:24px; }
  .apm-modal { padding:8px; }
  .apm-modal-heading,.apm-calendar-panel,.apm-reservation-panel { padding:28px 22px; }
  .apm-calendar-weekdays,.apm-calendar-grid { gap:4px; }
  .apm-modal-heading h2 { font-size:34px; }
  .apm-form-row,.apm-reservation-dates { grid-template-columns:1fr; }
  .apm-gallery-stage { grid-template-columns:44px 1fr 44px;min-height:420px;padding:52px 4px 10px; }
  .apm-gallery-caption { padding:14px 20px 22px; }
  .admin-bar .apm-app-header { top:46px; }
}


/* Checkout step */
.apm-checkout-screen {
  grid-column: 1 / -1;
  padding: 46px;
  background:
    radial-gradient(circle at 100% 0%, rgba(77,200,196,.12), transparent 35%),
    #fff;
}

.apm-checkout-screen[hidden],
.apm-calendar-panel[hidden],
.apm-reservation-panel[hidden] {
  display: none !important;
}

.apm-checkout-screen h3 {
  margin: 10px 0 8px;
  font-size: 40px;
  line-height: 1;
  letter-spacing: -.045em;
}

.apm-checkout-property {
  margin: 0 0 28px;
  color: var(--apm-muted);
  font-size: 16px;
}

.apm-checkout-back {
  display: block;
  margin: 0 0 30px;
  padding: 0;
  color: var(--apm-deep);
  background: transparent;
  border: 0;
  font-weight: 800;
  cursor: pointer;
}

.apm-checkout-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.apm-checkout-summary div {
  padding: 18px;
  background: var(--apm-cream);
  border: 1px solid var(--apm-line);
  border-radius: 15px;
}

.apm-checkout-summary span,
.apm-checkout-summary strong {
  display: block;
}

.apm-checkout-summary span {
  color: var(--apm-muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.apm-checkout-summary strong {
  margin-top: 7px;
  font-size: 15px;
}

.apm-checkout-price {
  max-width: 620px;
  padding: 22px 0;
  margin: 0 auto 24px;
  border-top: 1px solid var(--apm-line);
  border-bottom: 1px solid var(--apm-line);
}

.apm-checkout-price div {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 8px 0;
}

.apm-checkout-price .apm-total-row {
  margin-top: 10px;
  padding-top: 17px;
  border-top: 1px solid var(--apm-line);
  font-size: 21px;
}

.apm-secure-box {
  max-width: 620px;
  padding: 20px;
  margin: 0 auto 20px;
  background: #eef8f7;
  border: 1px solid rgba(77,200,196,.28);
  border-radius: 16px;
}

.apm-secure-box p {
  margin: 7px 0 0;
  color: var(--apm-muted);
  line-height: 1.55;
}

.apm-checkout-screen > .apm-button,
.apm-checkout-screen > .apm-payment-note,
.apm-checkout-screen > .apm-booking-message {
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}

.apm-webhook-box {
  padding: 18px;
  margin-bottom: 18px;
  background: #f5f8f9;
  border: 1px solid #dfe6e9;
  border-radius: 12px;
}

.apm-webhook-box code {
  display: block;
  padding: 10px;
  margin: 10px 0;
  overflow-wrap: anywhere;
  background: #fff;
}

@media(max-width:760px) {
  .apm-checkout-screen {
    padding: 28px 22px;
  }

  .apm-checkout-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
