@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,600;0,900;1,600;1,900&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css');

/* Responsive utility */
@media (max-width: 768px) { .hide-mobile { display: none !important; } }
@media (min-width: 769px) { .hide-desktop { display: none !important; } }

:root{  --bg:#f6f6f4;
  --text:#1f2933;
  --muted:#6b7280;
  --line:#e5e5e5;
  --card:#ffffff;
  --active:#2f2f31;
  --accent:#d7264d;
  --tab:#ececec;
  --avatar:#d8d8d8;
  --shadow-1:0 1px 1px rgba(0,0,0,0.02);
  --shadow-2:0 4px 12px rgba(0,0,0,0.03);

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  /* Single source of truth for all shell widths */
  --shell-max-width: 1200px;
  --shell-pad-x: 24px;

*{
  box-sizing:border-box;
}

html{
  -webkit-text-size-adjust:100%;
}

body{
  margin:0;
  background:var(--bg);
  font-family:var(--font-body);
  color:var(--text);
}

img{
  display:block;
  max-width:100%;
}

button,
input,
select,
textarea{
  font:inherit;
}

a{
  color:inherit;
  text-decoration:none;
}

details summary{
  cursor:pointer;
  list-style:none;
}

details summary::-webkit-details-marker{
  display:none;
}

/* ---------- APP SHELL ---------- */

#app-shell{
  width:100%;
  max-width:var(--shell-max-width);
  margin:0 auto;
  min-height:100vh;
  /* Clear fixed footer + safe area on all devices */
  padding-bottom:calc(64px + env(safe-area-inset-bottom, 0px));
  position:relative;
}

/* Zone spacing — .zone-collapsed class removes margin when all children hidden */
#shell-top-content-1,
#shell-top-content-2{ margin-bottom:20px; }
#shell-top-content-1:empty, #shell-top-content-2:empty,
#shell-below-content-1:empty, #shell-below-content-2:empty { margin:0 !important; }
.zone-collapsed { margin:0 !important; padding:0 !important; }
#shell-below-content-1{ margin-top:32px; }
#shell-below-content-2{ margin-top:20px; margin-bottom:20px; }
#shell-below-menu-footer{ padding-top:8px; padding-bottom:8px; }

.is-hidden{
  display:none !important;
}

/* ---------- TYPE ---------- */

h1,h2,h3{
  font-family: var(--font-display);
}

h1{
  font-size:44px;
  line-height:1.06;
  letter-spacing:-0.02em;
  font-weight:600;
  margin:24px 0 18px 0;
}

h2{
  font-size:28px;
  line-height:1.1;
  font-weight:600;
  letter-spacing:-0.02em;
  margin:0 0 16px 0;
}

h3{
  font-size:20px;
  line-height:1.2;
  font-weight:600;
  letter-spacing:-0.01em;
  margin:0 0 10px 0;
}

/* Brand wordmark — always lowercase, 900 black, 3px tracking */
.brand-word{
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 22px;
  letter-spacing: 2px;
  text-transform: lowercase;
  font-style: normal;
  white-space: nowrap;
  margin-top: -10px; /* align single 'a' with tab buttons on mobile */
}

/* Mobile: hide 'irflow' suffix so only 'a' shows */
.brand-word-suffix{
  display: none;
}

@media (min-width: 560px){
  .brand-word-suffix{
    display: inline;
  }
  .brand-word{
    font-size: 40px;
    margin-top: 0;
  }
}

/* Page load status text — info now lives in the access panel → Page data section */
#status { display: none; }

p{
  margin:0 0 12px 0;
  color:var(--muted);
  line-height:1.45;
}

.eyebrow{
  display:inline-block;
  margin-bottom:10px;
  font-size:12px;
  line-height:1;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:var(--muted);
  font-weight:700;
}

.lead{
  font-size:18px;
  line-height:1.5;
  max-width:760px;
}

.muted-strong{
  color:#111827;
  font-weight:600;
}

.timestamp{
  font-size:14px;
  color:var(--muted);
}

.text-link{
  color:#111827;
  font-weight:600;
  font-size:14px;
}

/* ---------- PAGE CONTENT ---------- */

.page-content{
  padding:28px var(--shell-pad-x);
}

.page-section{
  margin-bottom:40px;
}

.card-stack{
  display:flex;
  flex-direction:column;
  gap:22px;
}

.two-col-grid,
.three-col-grid,
.stats-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:18px;
}

.card{
  background:var(--card);
  border-radius:22px;
  padding:22px;
  border:1px solid #e6e6e6;
  box-shadow:var(--shadow-1), var(--shadow-2);
}

.card-head-row{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:16px;
}

.action-row{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
}

.action-row.right{
  justify-content:flex-end;
}

.sidebar-actions{
  padding-top:18px;
  border-top:1px solid #eceff3;
  margin-top:8px;
}

/* ── Property switcher strip ───────────────────────────────────────────────── */
.property-switcher{
  display:flex;
  align-items:center;
  gap:6px;
  flex-wrap:wrap;
  padding:10px 0 14px;
  border-bottom:1px solid var(--line);
  margin-bottom:4px;
}
.property-switcher-label{
  font-size:11px;
  font-weight:700;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.06em;
  white-space:nowrap;
  margin-right:2px;
}
.prop-pill{
  appearance:none;
  display:inline-flex;
  align-items:center;
  gap:6px;
  border:1.5px solid var(--line);
  background:#fff;
  border-radius:999px;
  padding:5px 13px;
  font-size:13px;
  font-weight:600;
  cursor:pointer;
  color:#374151;
  transition:background .12s,border-color .12s,color .12s;
  white-space:nowrap;
}
.prop-pill:hover{ border-color:#2f2f31; color:#2f2f31; }
.prop-pill.active{ background:#2f2f31; color:#fff; border-color:#2f2f31; }
.prop-pill-init{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:20px;
  height:20px;
  border-radius:50%;
  background:rgba(255,255,255,.18);
  font-size:10px;
  font-weight:800;
  flex-shrink:0;
}
.prop-pill:not(.active) .prop-pill-init{ background:#f3f4f6; color:#6b7280; }

/* ── Access panel — controls + property selector + details toggle ─────────── */
.access-controls-bar{
  display:flex;
  align-items:center;
  gap:6px;
  padding:10px 12px 10px;
  border-bottom:1px solid var(--line);
  flex-wrap:wrap;
}
.access-controls-bar .pill-button{
  padding:5px 10px;
  font-size:11px;
  flex-shrink:0;
}
@media (max-width: 768px) {
  .access-controls-bar { gap:5px; padding:8px 10px; }
  .access-controls-bar .pill-button { padding:5px 8px; font-size:11px; }
}
.access-prop-selector{
  border-bottom:1px solid var(--line);
}
.access-prop-current{
  display:flex;
  align-items:center;
  gap:10px;
  width:100%;
  background:none;
  border:none;
  padding:12px 16px;
  cursor:pointer;
  text-align:left;
  transition:background .12s;
}
.access-prop-current:hover{ background:#f9fafb; }
.access-prop-avatar{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:38px;
  height:38px;
  border-radius:50%;
  background:#2f2f31;
  color:#fff;
  font-size:13px;
  font-weight:800;
  flex-shrink:0;
  letter-spacing:-.02em;
}
.access-prop-info{
  display:flex;
  flex-direction:column;
  gap:1px;
  flex:1;
  min-width:0;
  overflow:hidden;
}
.access-prop-info strong{
  font-size:14px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.access-prop-info span{
  font-size:12px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.access-prop-chevron{
  font-size:18px;
  color:var(--muted);
  flex-shrink:0;
  transition:transform .18s;
  line-height:1;
  display:inline-block;
}
.access-prop-chevron.open{ transform:rotate(90deg); }
.access-prop-list{
  border-top:1px solid var(--line);
  padding:4px 0;
  background:#fafafa;
}
.access-prop-item{
  display:flex;
  align-items:center;
  gap:10px;
  width:100%;
  background:none;
  border:none;
  padding:9px 16px;
  cursor:pointer;
  text-align:left;
  font-size:13px;
  font-weight:500;
  color:#374151;
  transition:background .12s;
}
.access-prop-item:hover{ background:#f3f4f6; }
.access-prop-item--active{ background:#f0fdf4; }
.access-prop-item-avatar{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:28px;
  height:28px;
  border-radius:50%;
  background:#e5e7eb;
  color:#6b7280;
  font-size:10px;
  font-weight:800;
  flex-shrink:0;
}
/* ── Unified select / filter style ──────────────────────── */
.airflow-select{
  width:100%;
  appearance:none;
  -webkit-appearance:none;
  border:1.5px solid #d1d5db;
  border-radius:12px;
  padding:10px 36px 10px 14px;
  font-size:13px;
  font-weight:600;
  color:#111827;
  background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%239ca3af' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center/10px no-repeat;
  font-family:inherit;
  cursor:pointer;
  transition:border-color .15s, box-shadow .15s;
  box-shadow:0 1px 2px rgba(0,0,0,0.04);
}
.airflow-select:hover{ border-color:#9ca3af; box-shadow:0 1px 4px rgba(0,0,0,0.08); }
.airflow-select:focus{ outline:none; border-color:#2f2f31; box-shadow:0 0 0 3px rgba(47,55,65,0.08); }

/* ── Admin sidebar — dark left panel, matches FOH site ── */
.admin-sidebar{
  position:fixed;
  left:0;
  top:0;
  bottom:0;
  width:220px;
  background:#1f2937;
  color:#fff;
  z-index:100;
  transform:translateX(-100%);
  transition:transform .25s ease;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  box-shadow:4px 0 20px rgba(0,0,0,0.2);
}
.admin-sidebar.open{
  transform:translateX(0);
}
.admin-sidebar[data-compact=true]{
  width:48px;
}
.admin-sidebar[data-compact=true] .g-text,
.admin-sidebar[data-compact=true] .admin-label,
.admin-sidebar[data-compact=true] .admin-search-wrap{
  display:none;
}
.admin-sidebar[data-compact=true] .admin-link{
  justify-content:center;
  padding:8px 4px;
  border-left:none;
}
.admin-sidebar[data-compact=true] .admin-header-title{
  display:none;
}
.admin-sidebar[data-compact=true] .admin-header{
  justify-content:center;
  padding:10px 4px;
}
.admin-sidebar[data-compact=true] .admin-link:after{
  content:attr(title);
  position:absolute;left:100%;top:50%;transform:translateY(-50%);
  background:#1f2937;color:#fff;font-size:11px;font-weight:600;
  padding:4px 10px;border-radius:6px;white-space:nowrap;
  opacity:0;pointer-events:none;transition:opacity .15s;
  margin-left:8px;z-index:200;box-shadow:0 2px 8px rgba(0,0,0,0.3);
}
.admin-sidebar[data-compact=true] .admin-link:hover:after{
  opacity:1;
}

.admin-header{
  display:flex;justify-content:space-between;align-items:center;
  padding:14px 14px 10px;border-bottom:1px solid rgba(255,255,255,0.1);
}
.admin-header-title{
  font-size:15px;font-weight:700;
}
.admin-header-close{
  background:none;border:none;color:rgba(255,255,255,0.5);
  font-size:20px;cursor:pointer;padding:2px 6px;line-height:1;
}
.admin-header-close:hover{ color:#fff; }

.admin-nav{ padding:6px 0;flex:1; }

.admin-label{
  font-size:9px;font-weight:700;text-transform:uppercase;
  letter-spacing:0.08em;color:rgba(255,255,255,0.3);
  padding:10px 14px 3px;margin:0;
}
.admin-link{
  display:flex;align-items:center;gap:8px;
  padding:6px 14px;color:rgba(255,255,255,0.65);
  text-decoration:none;font-size:12px;font-weight:500;
  transition:all .12s;border-left:3px solid transparent;
  position:relative;cursor:pointer;
  background:none;border-right:none;border-top:none;border-bottom:none;
  width:100%;text-align:left;font-family:inherit;
}
.admin-link:hover{
  background:rgba(255,255,255,0.06);color:#fff;
  border-left-color:#d7264d;
}
.admin-link--active{
  background:rgba(255,255,255,0.08);color:#fff;
  border-left-color:#d7264d;
}
.admin-link .admin-icon{
  width:16px;height:16px;display:inline-flex;align-items:center;
  justify-content:center;opacity:0.5;flex-shrink:0;
}
.admin-link:hover .admin-icon{ opacity:1; }

.admin-search-wrap{
  padding:8px 14px;
}
.admin-search-input{
  width:100%;padding:6px 10px;border:1px solid rgba(255,255,255,0.15);
  border-radius:6px;background:rgba(255,255,255,0.08);color:#fff;
  font-size:12px;font-family:inherit;outline:none;
}
.admin-search-input::placeholder{ color:rgba(255,255,255,0.35); }
.admin-search-input:focus{ border-color:rgba(255,255,255,0.3); }

.admin-footer{
  padding:8px 10px;border-top:1px solid rgba(255,255,255,0.1);
}
.admin-compact-btn{
  display:flex;align-items:center;gap:6px;width:100%;
  padding:6px 8px;background:rgba(255,255,255,0.06);
  border:none;border-radius:6px;color:rgba(255,255,255,0.5);
  font-size:11px;font-family:inherit;cursor:pointer;transition:all .15s;
}
.admin-compact-btn:hover{
  background:rgba(255,255,255,0.12);color:#fff;
}

.admin-overlay{
  position:fixed;inset:0;background:rgba(0,0,0,0.3);
  z-index:99;display:none;
}
.admin-overlay.open{ display:block; }

/* ── Detail page layout (property-detail, org-settings) ── */
.detail-hero{
  position:relative;
  border-radius:16px;
  overflow:hidden;
  background:#1f2937;
}
.detail-hero__image{
  width:100%;
  height:200px;
  background:#2f3742;
}
.detail-hero__placeholder{
  width:100%;height:100%;display:flex;align-items:center;justify-content:center;
  font-size:48px;color:rgba(255,255,255,0.15);
}
.detail-hero__overlay{
  position:absolute;bottom:0;left:0;right:0;
  padding:20px 24px;
  background:linear-gradient(transparent, rgba(0,0,0,0.7));
  color:#fff;
}
.detail-hero__badges{
  display:flex;gap:6px;margin-bottom:8px;
}
.detail-hero__overlay h1{
  margin:0;font-size:24px;font-weight:800;letter-spacing:-0.02em;
  text-shadow:0 1px 3px rgba(0,0,0,0.3);
}
.detail-hero__meta{
  display:flex;gap:12px;margin-top:4px;font-size:13px;
}
@media (min-width:700px) {
  .detail-hero__image{ height:260px; }
  .detail-hero__overlay h1{ font-size:32px; }
}
.detail-stats{
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:8px;
}
@media (min-width:600px) {
  .detail-stats{ grid-template-columns:repeat(4,1fr); }
}
.detail-stat{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:12px;
  padding:14px 16px;
  text-align:center;
}
.detail-stat__value{
  font-size:20px;font-weight:800;color:#111827;letter-spacing:-0.02em;
}
.detail-stat__label{
  font-size:11px;color:var(--muted);margin-top:2px;font-weight:600;
  text-transform:uppercase;letter-spacing:0.04em;
}
.detail-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:0;
}
@media (min-width:800px) {
  .detail-grid{
    grid-template-columns:1fr 1fr;
    gap:0 24px;
  }
}

/* ── Collapsible detail cards ─────────────────────────── */
.detail-card-toggle{
  display:flex;
  align-items:center;
  justify-content:space-between;
  width:100%;
  background:none;
  border:none;
  padding:0;
  cursor:pointer;
  text-align:left;
  font-family:inherit;
}
.detail-card-toggle .card-chevron{
  font-size:16px;
  color:var(--muted);
  transition:transform 0.2s;
  flex-shrink:0;
  margin-left:8px;
}
.detail-card-toggle.open .card-chevron{
  transform:rotate(90deg);
}
.detail-card-body{
  display:none;
  padding-top:12px;
}
.detail-card-body.open{
  display:block;
}

.access-details-toggle{
  display:flex;
  align-items:center;
  justify-content:space-between;
  width:100%;
  background:none;
  border:none;
  border-top:1px solid var(--line);
  padding:10px 16px;
  cursor:pointer;
  font-size:11px;
  font-weight:700;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.06em;
  transition:background .12s;
}
.access-details-toggle:hover{ background:#f9fafb; }
.access-details-chevron{
  font-size:16px;
  transition:transform .18s;
  line-height:1;
  display:inline-block;
}
.access-details-chevron.open{ transform:rotate(90deg); }
.access-more-section .side-menu-item{ border-top:none; }
.access-more-section .side-menu-item:first-child{ border-top:1px solid var(--line); }

.pill-button{
  appearance:none;
  border:none;
  background:#ececec;
  color:#111827;
  border-radius:999px;
  padding:12px 18px;
  font-weight:600;
  cursor:pointer;
}

.pill-button.dark{
  background:#2f2f31;
  color:#fff;
}

.pill-button.ghost{
  background:#fff;
  border:1px solid var(--line);
}

.meta-chip-row{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

.meta-chip{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border-radius:999px;
  background:#f1f3f5;
  color:#374151;
  font-size:13px;
  font-weight:600;
}

.status-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  padding:8px 12px;
  font-size:12px;
  font-weight:700;
  line-height:1;
  white-space:nowrap;
}

.status-pill.success{ background:#dcfce7; color:#166534; }
.status-pill.warning{ background:#fef3c7; color:#92400e; }
.status-pill.danger{ background:#fee2e2; color:#991b1b; }
.status-pill.info{ background:#dbeafe; color:#1d4ed8; }
.status-pill.neutral{ background:#f3f4f6; color:#374151; }

.counter-badge{
  display:inline-flex;
  min-width:28px;
  height:28px;
  padding:0 10px;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#111827;
  color:#fff;
  font-size:12px;
  font-weight:700;
}

/* ---------- SHELL REGIONS ---------- */

#shell-above-menu,
#shell-top-menu,
#shell-top-content-1,
#shell-top-content-2,
#shell-main-content,
#shell-below-content-1,
#shell-below-content-2,
#shell-footer-menu,
#shell-below-menu-footer{
  width:100%;
}

/* ---------- TOP MENU ---------- */

.top-menu{
  padding:0;
  border-bottom:1px solid var(--line);
  background:var(--card);
  position:relative;
  z-index:30;
  /* stretch white background full viewport width */
  width:100vw;
  margin-left:calc(-50vw + 50%);
}

/* Fixed top bar wrapper — contains notice + header */
#shell-top-menu{
  position:fixed;
  top:0;
  left:0;
  right:0;
  z-index:30;
  background:var(--card);
  transition:transform 0.3s ease;
}
#shell-top-menu.nav-hidden{
  transform:translateY(-100%);
}
/* Spacer pushes content below the fixed top bar */
#shell-top-spacer{
  width:100%;
}

/* ── Global notice bar ───────────────────────────────── */
#global-notices{
  background:#1f2937;
  width:100%;
}
.global-notice{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 16px;
  max-width:var(--shell-max-width);
  margin:0 auto;
  text-decoration:none;
  color:#fff;
  font-size:12px;
  transition:background 0.15s;
}
.global-notice:hover{ background:rgba(255,255,255,0.06); }
.global-notice--setup{
  border-bottom:1px solid rgba(255,255,255,0.08);
}
.global-notice__icon{
  font-size:14px;
  flex-shrink:0;
  opacity:0.8;
}
.global-notice__text{
  flex:1;
  min-width:0;
  color:rgba(255,255,255,0.85);
}
.global-notice__text strong{
  font-weight:700;
  color:#fff;
}
.global-notice__action{
  font-size:11px;
  font-weight:700;
  color:#fff;
  background:rgba(255,255,255,0.12);
  padding:4px 10px;
  border-radius:6px;
  white-space:nowrap;
  flex-shrink:0;
  transition:background 0.15s;
}
.global-notice:hover .global-notice__action{
  background:rgba(255,255,255,0.2);
}

@media (max-width:899px) {
  .top-menu{
    width:100%;
    margin-left:0;
  }
}

.top-menu-inner{
  max-width:var(--shell-max-width);
  margin:0 auto;
  padding:14px var(--shell-pad-x) 10px;
  display:grid;
  grid-template-columns:auto 1fr auto;
  align-items:center;
  gap:18px;
}

.logo-link{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  min-width:0;
}

.logo{
  height:56px;
  width:auto;
  object-fit:contain;
}

.top-tabs{
  display:flex;
  justify-content:center;
  gap:8px;
  min-width:0;
  flex-wrap:nowrap;
}
.dash-tabs{
  display:flex;
  gap:8px;
}

/* ── Context bar (org/property selectors in top menu) ──────────────────── */
.ctx-bar{
  display:flex;
  align-items:center;
  gap:6px;
  justify-content:center;
  min-width:0;
}
.ctx-bar__sep{
  color:var(--muted, #9ca3af);
  font-size:14px;
  user-select:none;
}
.ctx-bar__select{
  position:relative;
}
.ctx-bar__btn{
  display:flex;
  align-items:center;
  gap:6px;
  background:var(--bg, #f3f4f6);
  border:1px solid var(--line, #e5e7eb);
  border-radius:8px;
  padding:5px 10px;
  cursor:pointer;
  max-width:200px;
  transition:background 0.12s, border-color 0.12s;
}
.ctx-bar__btn:hover{
  background:#e5e7eb;
  border-color:#d1d5db;
}
.ctx-bar__avatar{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:22px;
  height:22px;
  border-radius:50%;
  background:#2f2f31;
  color:#fff;
  font-size:8px;
  font-weight:800;
  flex-shrink:0;
  letter-spacing:-0.02em;
}
.ctx-bar__label{
  font-size:12px;
  font-weight:600;
  color:var(--text, #111827);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:130px;
}
.ctx-bar__chevron{
  font-size:12px;
  color:var(--muted, #6b7280);
  flex-shrink:0;
  transition:transform 0.18s;
  display:inline-block;
  transform:rotate(-90deg);
}
.ctx-bar__chevron.open{
  transform:rotate(0deg);
}
.ctx-bar__dropdown{
  position:absolute;
  top:calc(100% + 4px);
  left:0;
  min-width:220px;
  max-width:300px;
  background:var(--card, #fff);
  border:1px solid var(--line, #e5e7eb);
  border-radius:10px;
  box-shadow:0 8px 24px rgba(0,0,0,0.12);
  z-index:100;
  max-height:300px;
  overflow-y:auto;
  padding:4px 0;
}
.ctx-bar__item{
  display:flex;
  align-items:center;
  gap:8px;
  width:100%;
  background:none;
  border:none;
  padding:7px 12px;
  cursor:pointer;
  text-align:left;
  font-size:12px;
  font-weight:500;
  color:#374151;
  transition:background 0.12s;
}
.ctx-bar__item:hover{ background:#f3f4f6; }
.ctx-bar__item.is-active{ background:#ecfdf5; font-weight:600; }
.ctx-bar__item-avatar{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:24px;
  height:24px;
  border-radius:50%;
  background:#e5e7eb;
  color:#6b7280;
  font-size:9px;
  font-weight:700;
  flex-shrink:0;
}
.ctx-bar__item.is-active .ctx-bar__item-avatar{
  background:#d1fae5;
  color:#065f46;
}
.ctx-bar__item-info{
  display:flex;
  flex-direction:column;
  gap:0;
  min-width:0;
  overflow:hidden;
}
.ctx-bar__item-name{
  font-size:12px;
  font-weight:600;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.ctx-bar__item-meta{
  font-size:10px;
  color:var(--muted, #6b7280);
  white-space:nowrap;
}
@media (max-width:600px){
  .ctx-bar__label{ max-width:80px; }
  .ctx-bar__btn{ padding:4px 8px; }
}

.tab{
  appearance:none;
  border:none;
  background:var(--tab);
  border-radius:28px;
  padding:10px 22px;
  font-size:16px;
  line-height:1;
  font-weight:500;
  color:#111;
  cursor:pointer;
  white-space:nowrap;
}

.tab.active,
.tab.is-active{
  background:var(--active);
  color:#fff;
}

.tab:disabled{
  opacity:0.38;
  cursor:not-allowed;
}

.avatar-button{
  appearance:none;
  border:none;
  background:transparent;
  padding:0;
  margin:0;
  cursor:pointer;
  position:relative;
  width:48px;
  height:48px;
  border-radius:999px;
  overflow:hidden;
  flex-shrink:0;
}

.avatar-photo{
  position:absolute;
  inset:0;
  border-radius:999px;
  background:
    radial-gradient(circle at 50% 35%, #f2f2f2 0 18%, transparent 19%),
    radial-gradient(circle at 50% 78%, #d6d6d6 0 34%, transparent 35%),
    linear-gradient(135deg, #e8e8e8, #cfcfcf);
}

.avatar-fallback{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:700;
  font-size:15px;
  color:#2f2f31;
  background:rgba(255,255,255,0.28);
  border-radius:999px;
}

/* ---------- WORKSPACE ---------- */

.workspace{
  display:block;
  width:100%;
}

.main-column{
  min-width:0;
}

.content-column{
  width:100%;
  max-width:none;
  margin:0 auto;
}

.side-panel{
  display:none;
}

.side-panel-stack{
  display:flex;
  flex-direction:column;
  gap:20px;
}

/* ---------- COMPONENT ZONE PLACEHOLDERS ---------- */

.component-zone{
  width:100%;
}

.zone-placeholder{
  margin:0 var(--shell-pad-x) 16px;
  border:2px dashed #d1d5db;
  border-radius:18px;
  padding:20px 22px;
  background:#fafafa;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.zone-placeholder-label{
  font-size:12px;
  font-weight:700;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:#9ca3af;
}

.zone-placeholder-hint{
  font-size:12px;
  color:#d1d5db;
}

/* ---------- HERO / SUMMARY ---------- */

.hero-card-top{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:16px;
  margin-bottom:20px;
}

.hero-title{
  font-size:32px;
  line-height:1.05;
  letter-spacing:-0.03em;
  margin:0 0 10px 0;
}

.hero-stat-badge{
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:64px;
  height:64px;
  padding:0 16px;
  border-radius:999px;
  background:#111827;
  color:#fff;
  font-size:22px;
  font-weight:700;
}

.stat-card{
  border:1px solid var(--line);
  border-radius:18px;
  padding:18px;
  background:#fff;
}

.stat-card.soft-red{
  background:#fff1f3;
}

.stat-label{
  color:var(--muted);
  font-size:13px;
  font-weight:600;
  margin-bottom:8px;
}

.stat-value{
  font-size:28px;
  line-height:1;
  font-weight:700;
  color:#111827;
  margin-bottom:8px;
}

.stat-sub{
  color:var(--muted);
  font-size:13px;
}

.notice-card.warm{
  background:#efe4c9;
  border-color:#e4c98b;
}

.notice-row{
  display:grid;
  grid-template-columns:auto 1fr auto;
  gap:14px;
  align-items:start;
  margin-bottom:16px;
}

.notice-icon{
  font-size:26px;
  line-height:1;
  padding-top:2px;
}

.notice-copy h3{
  margin-bottom:8px;
}

.notice-count{
  font-size:22px;
  font-weight:700;
  color:#111827;
}

.banner-card{
  display:flex;
  flex-direction:column;
  gap:16px;
}

.banner-left{
  display:flex;
  gap:14px;
  align-items:flex-start;
}

.banner-icon{
  width:36px;
  height:36px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#fff7ed;
  color:#c2410c;
  font-weight:700;
  flex-shrink:0;
}

/* ---------- BOOKINGS ---------- */

.booking-card-large{
  padding:24px;
}

.booking-card-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:18px;
}

.guest-stack{
  display:flex;
  align-items:center;
  gap:16px;
  min-width:0;
}

.guest-avatar{
  width:72px;
  height:72px;
  border-radius:50%;
  background:#d8d8d8;
  flex-shrink:0;
}

.photo-a{ background:linear-gradient(135deg,#d7b28c,#8f4b2d); }
.photo-b{ background:linear-gradient(135deg,#8fb0d8,#324f85); }
.photo-c{ background:linear-gradient(135deg,#d8c78f,#7b6b34); }

.booking-date{
  font-size:22px;
  line-height:1.05;
  font-weight:700;
  letter-spacing:-0.02em;
  color:#111827;
}

.booking-date-sub{
  margin-top:6px;
  font-size:14px;
  color:var(--muted);
}

.guest-count-circle{
  width:92px;
  height:92px;
  border-radius:999px;
  background:#efefef;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:24px;
  font-weight:700;
  flex-shrink:0;
}

.booking-main-name{
  font-size:36px;
  line-height:1.04;
  letter-spacing:-0.04em;
  font-weight:700;
  margin-bottom:18px;
}

.booking-divider{
  height:1px;
  background:#eceff3;
  margin:18px 0;
}

.booking-footer-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.booking-detail-card .detail-grid{
  margin-bottom:18px;
}

.mini-booking-card{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.mini-booking-top{
  display:flex;
  gap:14px;
  align-items:center;
}

.mini-avatar{
  width:56px;
  height:56px;
  border-radius:50%;
  flex-shrink:0;
}

.mini-booking-foot{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.mini-value{
  font-weight:700;
  color:#111827;
}

/* ---------- DETAIL GRID ---------- */

.detail-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:14px;
}

.detail-grid.single-column{
  grid-template-columns:1fr;
}

.detail-item{
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:14px 16px;
  border-radius:16px;
  background:#f8f9fa;
  border:1px solid #edf0f2;
}

.detail-label{
  font-size:12px;
  letter-spacing:0.06em;
  text-transform:uppercase;
  color:var(--muted);
  font-weight:700;
}

.detail-value{
  font-size:16px;
  color:#111827;
  font-weight:600;
}

/* ---------- MESSAGES ---------- */

.message-card,
.thread-card,
.email-log-card{
  overflow:hidden;
}

.thread-stack{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin-bottom:18px;
}

.chat-bubble{
  max-width:86%;
  border-radius:18px;
  padding:14px 16px;
  border:1px solid var(--line);
}

.chat-bubble.wide{
  max-width:100%;
}

.chat-bubble.incoming{
  background:#fff;
}

.chat-bubble.outgoing{
  background:#f3f4f6;
  margin-left:auto;
}

.chat-meta{
  font-size:12px;
  color:var(--muted);
  font-weight:700;
  margin-bottom:6px;
}

.chat-text{
  color:#111827;
  line-height:1.45;
}

.list-table,
.list-stack{
  display:flex;
  flex-direction:column;
}

.list-stack.compact{
  gap:14px;
}

.list-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:14px 0;
  border-top:1px solid #edf0f2;
}

.list-row:first-child{
  border-top:none;
  padding-top:0;
}

.list-main{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}

.list-main strong{
  color:#111827;
}

.list-main span{
  color:var(--muted);
  font-size:14px;
}

.list-item-icon{
  display:grid;
  grid-template-columns:32px 1fr;
  gap:12px;
  align-items:start;
}

.item-icon{
  width:32px;
  height:32px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#f3f4f6;
  font-size:16px;
}

/* ---------- TASKS / TIMELINE ---------- */

.task-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.task-item{
  display:flex;
  gap:10px;
  align-items:flex-start;
  color:#111827;
  font-weight:500;
}

.activity-timeline{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.timeline-item{
  display:grid;
  grid-template-columns:14px 1fr;
  gap:12px;
  align-items:start;
}

.timeline-dot{
  width:10px;
  height:10px;
  margin-top:6px;
  border-radius:999px;
  background:#111827;
}

/* ---------- PROFILE / LISTING ---------- */

.profile-head{
  display:flex;
  gap:14px;
  align-items:center;
  margin-bottom:16px;
}

.profile-avatar{
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#ececec;
  color:#111827;
  font-weight:700;
}

.profile-avatar.large{
  width:64px;
  height:64px;
  font-size:22px;
}

.listing-card{
  overflow:hidden;
  padding:0;
}

.listing-image{
  height:220px;
  background:linear-gradient(135deg,#8fc5d8,#3c6e84);
}

.listing-copy{
  padding:22px;
}

/* ---------- AI / FAQ / HELP ---------- */

.ai-input-row{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.ai-input{
  min-height:56px;
  border:1px solid var(--line);
  background:#fff;
  border-radius:18px;
  padding:16px;
  color:var(--muted);
}

.faq-list{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.faq-list details{
  border:1px solid #eceff3;
  border-radius:16px;
  padding:16px;
  background:#fafafa;
}

.faq-list summary{
  font-weight:700;
  color:#111827;
}

.faq-list details p{
  margin-top:12px;
  margin-bottom:0;
}

/* ---------- FORM / BILLING ---------- */

.form-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:16px;
  margin-bottom:20px;
}

.form-field{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.form-field span{
  font-size:13px;
  color:#374151;
  font-weight:600;
}

.form-field input,
.form-field select{
  width:100%;
  min-height:48px;
  border:1px solid var(--line);
  border-radius:14px;
  padding:0 14px;
  background:#fff;
  color:#111827;
}

.billing-card,
.usage-card{
  display:flex;
  flex-direction:column;
  gap:14px;
}

.billing-card.featured{
  border-color:#111827;
}

.price-line{
  font-size:34px;
  line-height:1;
  font-weight:700;
  letter-spacing:-0.03em;
  color:#111827;
}

.price-line span{
  font-size:16px;
  color:var(--muted);
  font-weight:500;
  margin-left:4px;
}

.progress-block{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.progress-meta{
  display:flex;
  justify-content:space-between;
  gap:10px;
  font-size:14px;
  color:#374151;
  font-weight:600;
}

.progress-bar{
  height:12px;
  border-radius:999px;
  background:#eceff3;
  overflow:hidden;
}

.progress-fill{
  width:78%;
  height:100%;
  background:#111827;
  border-radius:999px;
}

/* ---------- REPORTS / TABLE ---------- */

.report-bars{
  display:flex;
  flex-direction:column;
  gap:16px;
}

.report-bar-row{
  display:grid;
  grid-template-columns:70px minmax(0,1fr) auto;
  gap:12px;
  align-items:center;
}

.report-bar-track{
  height:12px;
  border-radius:999px;
  background:#eceff3;
  overflow:hidden;
}

.report-bar-fill{
  height:100%;
  border-radius:999px;
  background:#111827;
}

.report-bar-fill.w-80{ width:80%; }
.report-bar-fill.w-45{ width:45%; }
.report-bar-fill.w-20{ width:20%; }

/* ── Currency / FX breakdown ──────────────────────────── */
.fx-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:10px 0;
  border-top:1px solid #edf0f2;
  gap:12px;
  flex-wrap:wrap;
}
.fx-row:first-child{ border-top:none; }
.fx-row-left{ display:flex; align-items:baseline; gap:10px; flex-wrap:wrap; }
.fx-code{
  font-weight:700;
  font-size:12px;
  letter-spacing:0.06em;
  background:#f3f4f6;
  padding:2px 8px;
  border-radius:4px;
  color:#111827;
  font-variant-numeric:tabular-nums;
}
.fx-meta{ font-size:12px; color:var(--muted); }
.fx-row-right{ display:flex; align-items:center; gap:8px; flex-shrink:0; }
.fx-orig{ font-size:14px; color:#374151; }
.fx-arrow{ color:var(--muted); font-size:12px; }
.fx-converted{ font-size:14px; font-weight:600; color:#111827; }
.fx-native{
  font-size:11px;
  color:var(--muted);
  background:#e5e7eb;
  padding:1px 6px;
  border-radius:3px;
}
.fx-total-row{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:12px 0 2px;
  border-top:2px solid #e5e7eb;
  margin-top:8px;
  font-size:15px;
}

.table-wrap,
.table-wrap-demo{
  overflow:auto;
}

.data-table,
.demo-table{
  width:100%;
  min-width:520px;
  border-collapse:collapse;
}

.data-table th,
.data-table td,
.demo-table th,
.demo-table td{
  text-align:left;
  padding:14px 12px;
  border-bottom:1px solid #edf0f2;
  font-size:14px;
}

.data-table th,
.demo-table th{
  color:#374151;
  font-size:12px;
  letter-spacing:0.06em;
  text-transform:uppercase;
}

/* Row status colours (bookings + activity log) */
tr.row-confirmed { background:#f0fdf4; }
tr.row-pending   { background:#fefce8; }
tr.row-cancelled { background:#fef2f2; }
tr.row-confirmed:hover { background:#dcfce7; }
tr.row-pending:hover   { background:#fef9c3; }
tr.row-cancelled:hover { background:#fee2e2; }
tr[data-href] { cursor:pointer; }

/* Activity log row colours by processed_status */
tr.row-parsed            { background:#f0fdf4; }
tr.row-processed         { background:#f0fdf4; }
tr.row-completed         { background:#f0fdf4; }
tr.row-owner_replied     { background:#eff6ff; }
tr.row-not_a_booking     { background:#fefce8; }
tr.row-skipped           { background:#fefce8; }
tr.row-rejected          { background:#fefce8; }
tr.row-queued            { background:#f5f3ff; }
tr.row-failed            { background:#fef2f2; }
tr.row-error             { background:#fef2f2; }
tr.row-parsed:hover            { background:#dcfce7; }
tr.row-processed:hover         { background:#dcfce7; }
tr.row-completed:hover         { background:#dcfce7; }
tr.row-owner_replied:hover     { background:#dbeafe; }
tr.row-not_a_booking:hover     { background:#fef9c3; }
tr.row-skipped:hover           { background:#fef9c3; }
tr.row-rejected:hover          { background:#fef9c3; }
tr.row-queued:hover            { background:#ede9fe; }
tr.row-failed:hover            { background:#fee2e2; }
tr.row-error:hover             { background:#fee2e2; }

/* Activity detail page */
.ad-back-link {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--muted); font-size: 13px; font-weight: 600;
  text-decoration: none; margin-bottom: 18px;
}
.ad-back-link:hover { color: var(--text); }
.ad-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 768px) { .ad-two-col { grid-template-columns: 1fr; } }
.ad-error-box {
  background: #fef2f2; border: 1px solid #fecaca; border-radius: 12px;
  padding: 14px 16px; font-size: 13px; color: #991b1b; line-height: 1.5;
  white-space: pre-wrap; word-break: break-word;
}
.ad-json-box {
  background: #f9fafb; border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; font-size: 12px; font-family: monospace;
  color: #374151; line-height: 1.5; white-space: pre-wrap;
  word-break: break-word; max-height: 300px; overflow-y: auto;
}
.ad-credit-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0; border-bottom: 1px solid #f0f0f0;
}
.ad-credit-row:last-child { border-bottom: none; }

/* =========================================
   SIDEBAR / ACCESS PANELS
   =========================================
   .side-menu-item MUST be display:grid.
   Declared on both element and a[...] to
   override browser default inline for <a>.
   ========================================= */

.side-menu{
  background:#fff;
  border:1px solid var(--line);
  border-radius:32px;
  padding:24px 28px;
  box-shadow:var(--shadow-1), var(--shadow-2);
}

.side-menu h2{
  margin:0 0 14px 0;
  font-size:26px;
  line-height:1.05;
  letter-spacing:-0.02em;
}

/* Force grid on ALL side-menu-item elements including <a> tags */
.side-menu-item,
a.side-menu-item{
  display:grid !important;
  grid-template-columns:22px 1fr 16px;
  gap:10px;
  align-items:center;
  padding:11px 0;
  border-top:1px solid #eceff3;
  text-decoration:none;
  color:inherit;
  min-width:0;
}

.side-menu-item:first-of-type,
a.side-menu-item:first-of-type{
  border-top:none;
  padding-top:4px;
}

/* Static items (no arrow column) */
.side-menu-item.static,
a.side-menu-item.static{
  grid-template-columns:22px 1fr;
}

.side-menu-icon{
  font-size:15px;
  line-height:1;
  color:#111827;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  width:22px;
}

.side-menu-copy{
  display:flex;
  flex-direction:column;
  min-width:0;
  overflow:hidden;
}

.side-menu-copy strong{
  font-size:15px;
  line-height:1.2;
  letter-spacing:-0.01em;
  color:#0f172a;
  font-weight:700;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.side-menu-copy span{
  margin-top:1px;
  font-size:12px;
  line-height:1.3;
  color:#6b7280;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
/* Spans inside strong (e.g. data-vlabel) inherit strong's style */
.side-menu-copy strong span{
  font-size:inherit;
  color:inherit;
  font-weight:inherit;
  margin-top:0;
}

/* Access panel inline label rows */
.side-menu-copy .access-row{
  display:flex;
  align-items:baseline;
  gap:8px;
  font-size:13px;
  margin-top:3px;
}

.side-menu-copy .access-row b{
  min-width:58px;
  color:#374151;
  font-size:12px;
  flex-shrink:0;
}

.side-menu-arrow{
  font-size:16px;
  line-height:1;
  color:#9ca3af;
  text-align:right;
  flex-shrink:0;
}

/* Settings submenu */
.settings-submenu{
  display:none;
  margin-left:16px;
  padding-left:16px;
  border-left:2px solid var(--line);
}

.settings-submenu.open{
  display:block;
}

.settings-sub-item{
  padding-top:9px !important;
  padding-bottom:9px !important;
}

.settings-sub-item:first-child{
  border-top:none !important;
}

/* Settings row: nav link spans icon+copy columns, button is chevron only */
.settings-nav-link{
  grid-column:span 2;
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
  text-decoration:none;
  color:inherit;
}

.settings-chevron-btn{
  appearance:none;
  background:none;
  border:none;
  border-left:1px solid #eceff3;
  padding:8px 0 8px 12px;
  margin:0;
  cursor:pointer;
  color:#9ca3af;
  font-size:16px;
  line-height:1;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}

/* Chevron rotates when submenu is open */
.settings-group.submenu-open .settings-chevron{
  transform:rotate(90deg);
}

.settings-chevron{
  display:inline-block;
  transition:transform 0.18s ease;
}

/* Live status dot in access panel */
.access-status-dot-wrap{
  display:flex;
  align-items:center;
  justify-content:center;
}

.access-status-dot{
  width:10px;
  height:10px;
  border-radius:50%;
  background:#22c55e;
  box-shadow:0 0 0 3px rgba(34,197,94,0.2);
  flex-shrink:0;
}

.panel-head-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}

.panel-head-row h2,
.panel-head-row h3{
  margin:0;
  flex:1;
}

.panel-head-row .pill-button{
  margin-left:auto;
  line-height:1;
  padding:6px 12px;
  min-width:32px;
  text-align:center;
}

/* ---------- FOOTER NAV ---------- */

.footer-menu{
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:40;
  background:#fff;
  border-top:1px solid var(--line);
  display:flex;
  justify-content:center;
  will-change:transform;
  transition:transform 0.2s ease;
}
.footer-menu.nav-hidden{
  transform:translateY(100%);
}

.footer-menu-inner{
  width:100%;
  max-width:var(--shell-max-width);
  display:grid;
  grid-template-columns:repeat(4,1fr);
  align-items:center;
  min-height:54px;
  padding:8px var(--shell-pad-x) calc(10px + env(safe-area-inset-bottom, 0px));
}

.footer-item{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  text-align:center;
  font-size:13px;
  color:#555;
  cursor:pointer;
  min-height:54px;
  text-decoration:none;
  background:none;
  border:none;
  padding:0;
  font:inherit;
}

.footer-item span{
  display:block;
}

.footer-item .icon{
  font-size:22px;
  line-height:1;
  margin-bottom:2px;
}

.footer-item.active,
.footer-item.is-active{
  color:var(--accent);
  font-weight:600;
}

/* ---------- MOBILE MENU DRAWER ---------- */

.mobile-menu-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.28);
  opacity:0;
  pointer-events:none;
  transition:opacity 0.22s ease;
  z-index:49;
}

.mobile-menu-overlay.open{
  opacity:1;
  pointer-events:auto;
}

.mobile-menu{
  position:fixed;
  top:0;
  right:-100%;
  width:min(420px, 96vw);
  height:100vh;
  background:transparent;
  transition:right 0.25s ease;
  z-index:50;
  overflow-y:auto;
  padding:16px 12px 100px;
  display:flex;
  flex-direction:column;
  gap:12px;
}

.mobile-menu.open{
  right:0;
}

.mobile-panel-stack{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.mobile-panel-card{
  border:none;
  border-radius:24px;
  padding:20px 22px;
  background:#fff;
  box-shadow:0 4px 24px rgba(0,0,0,0.12);
}

/* ---------- BELOW FOOTER ---------- */

#shell-below-menu-footer{
  padding:0 var(--shell-pad-x) 18px;
  text-align:center;
  color:var(--muted);
  font-size:12px;
}

/* =========================================
   DESKTOP — min-width: 900px
   ========================================= */

@media (min-width:900px){

  #app-shell{
    padding-bottom:calc(84px + env(safe-area-inset-bottom, 0px));
  }

  .top-menu-inner{
    padding:16px var(--shell-pad-x) 12px;
  }

  .logo{
    height:52px;
  }

  .avatar-button{
    width:52px;
    height:52px;
  }

  .avatar-fallback{
    font-size:17px;
  }

  .tab{
    padding:12px 26px;
    font-size:17px;
    border-radius:30px;
  }

  .workspace{
    width:100%;
    max-width:var(--shell-max-width);
    margin:0 auto;
    transition:grid-template-columns 0.22s ease, gap 0.22s ease;
  }

  .workspace.menu-closed,
  .workspace.menu-open{
    display:grid;
    grid-template-columns:minmax(0,1fr) 320px;
    gap:24px;
    align-items:start;
    padding:0 var(--shell-pad-x);
  }

  /* Main column always in col 1 */
  .main-column{
    grid-column:1;
  }

  /* Side panel and right panel share col 2 — only one visible at a time */
  .side-panel{
    grid-column:2;
    grid-row:1;
  }
  .right-panel{
    grid-column:2;
    grid-row:1;
  }

  .workspace.menu-open .side-panel{
    display:block;
    min-width:0;
  }

  .workspace.menu-open .page-content,
  .workspace.menu-closed .page-content{
    padding-left:0;
    padding-right:0;
  }

  /* Right panel — always visible on desktop when menu closed */
  .right-panel{
    display:block;
    width:100%;
    min-width:0;
  }
  .right-panel-stack{
    position:sticky;
    top:calc(84px + 16px);
    padding-top:20px;
    display:flex;
    flex-direction:column;
    gap:20px;
  }
  /* Hide right panel when side menu is open (side panel takes over the column) */
  .workspace.menu-open .right-panel{
    display:none;
  }
  /* Hide side panel when menu is closed (right panel takes over) */
  .workspace.menu-closed .side-panel{
    display:none;
  }

  .main-column{
    display:flex;
    justify-content:flex-start;
    min-width:0;
  }

  .content-column{
    width:100%;
  }

  .page-content{
    padding:32px var(--shell-pad-x);
  }

  .side-panel{
    width:100%;
  }

  .side-panel-stack{
    position:sticky;
    top:calc(84px + 16px);
    padding-top:20px;
  }

  .footer-menu{
    height:72px;
  }

  .footer-menu-inner{
    padding:10px var(--shell-pad-x) 10px;
    max-width:var(--shell-max-width);
  }

  .footer-item{
    font-size:14px;
    gap:5px;
  }

  .footer-item .icon{
    font-size:22px;
  }

  /* Mobile drawer hidden on desktop */
  .mobile-menu,
  .mobile-menu-overlay{
    display:none;
  }

  /* Grid helpers */
  .stats-grid{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }

  .two-col-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .three-col-grid{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }

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

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

  .listing-card{
    display:grid;
    grid-template-columns:340px 1fr;
  }

  .listing-image{
    height:100%;
    min-height:240px;
  }

  .ai-input-row{
    flex-direction:row;
    align-items:center;
  }

  .ai-input{
    flex:1;
  }

  .zone-placeholder{
    margin-left:0;
    margin-right:0;
  }
}


/* ---------- ZONE SPACING ----------
   All shell zone regions get consistent
   vertical breathing room automatically.
   Individual zone components should NOT
   set their own top/bottom margin.
-----------------------------------*/

#shell-above-menu {
  /* Unused zone — notices now render inside #shell-top-menu */
  display:none;
}

#shell-top-content-1,
#shell-top-content-2 {
  padding-top: 20px;
}

#shell-below-content-1 {
  padding-top: 32px;
}

#shell-below-content-2 {
  padding-top: 20px;
  padding-bottom: 20px;
}

#shell-below-menu-footer {
  padding-top: 8px;
  padding-bottom: 8px;
}

/* Ensure app shell bottom padding clears the mobile footer */
#app-shell {
  padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
}


/* ---------- SMALL MOBILE (≤420px) ---------- */

@media (max-width:420px){

  :root{
    --shell-pad-x: 16px;
  }

  .logo{
    height:44px;
  }

  .top-tabs{
    gap:8px;
  }

  .tab{
    padding:10px 16px;
    font-size:15px;
  }

  .avatar-button{
    width:42px;
    height:42px;
  }

  h1{
    font-size:34px;
    margin:18px 0 16px 0;
    font-family:var(--font-display);
    font-weight:600;
  }

  .hero-title{
    font-size:26px;
  }

  .booking-main-name{
    font-size:28px;
  }

  .hero-card-top,
  .booking-card-header,
  .booking-footer-row,
  .card-head-row{
    flex-direction:column;
    align-items:flex-start;
  }

  .guest-count-circle,
  .hero-stat-badge{
    width:auto;
    height:auto;
    min-width:0;
    padding:10px 16px;
  }

  .report-bar-row{
    grid-template-columns:1fr;
    gap:8px;
  }
}

/* ==========================================================================
   PAGE-SPECIFIC STYLES
   Centralised here so HTML pages remain lightweight.
   ========================================================================== */

/* ---------- SHARED FORM / FIELD UTILITIES ---------- */

.save-msg  { font-size: 13px; color: #166534; display: none; }
.error-msg { font-size: 13px; color: #991b1b; display: none; }

/* ---------- BOOKINGS PAGE ---------- */

.filter-bar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.filter-btn {
  appearance: none; border: 1px solid var(--line); background: #fff;
  border-radius: 999px; padding: 8px 16px; font-size: 13px;
  font-weight: 600; cursor: pointer; color: #374151;
}
.filter-btn.active { background: #2f2f31; color: #fff; border-color: #2f2f31; }

/* ---------- UPCOMING PAGE ---------- */

.bookings-table-wrap { display: none; }
@media (min-width: 900px) {
  .bookings-cards     { display: none; }
  .bookings-table-wrap { display: block; }
}

/* ---------- SETTINGS PAGE ---------- */

.settings-section { margin-bottom: 32px; }
.field-row {
  display: flex; flex-direction: column; gap: 6px;
  padding: 14px 0; border-bottom: 1px solid #f0f0f0;
}
.field-row:last-child { border-bottom: none; }
.field-label {
  font-size: 12px; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--muted);
}
.field-value { font-size: 15px; font-weight: 600; color: #111827; }
.field-value.muted-val { color: var(--muted); font-weight: 400; }
.edit-input {
  width: 100%; min-height: 44px; border: 1px solid var(--line);
  border-radius: 12px; padding: 0 14px; font-size: 15px;
  color: #111827; background: #fff; font-family: inherit;
}
.edit-input:focus { outline: 2px solid #2f2f31; outline-offset: 2px; }
select.edit-input {
  appearance:none; -webkit-appearance:none;
  padding-right:36px;
  background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%239ca3af' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center/10px no-repeat;
  cursor:pointer;
}
.section-actions { display: flex; gap: 8px; margin-top: 16px; align-items: center; }

/* ---------- BOOKING DETAIL PAGE ---------- */

.bd-back-link {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--muted); font-size: 13px; font-weight: 600;
  text-decoration: none; margin-bottom: 18px;
}
.bd-back-link:hover { color: var(--text); }

.bd-hero { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 6px; }
.bd-hero h1 { margin: 0; font-size: 32px; font-weight: 800; letter-spacing: -0.03em; }
.bd-hero-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }

.bd-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 768px) { .bd-two-col { grid-template-columns: 1fr; } }

.bd-copy-btn {
  background: none; border: none; cursor: pointer;
  color: var(--muted); font-size: 12px; padding: 2px 6px; border-radius: 4px;
}
.bd-copy-btn:hover { background: #f3f4f6; color: #111827; }

.bd-toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: #111827; color: #fff; padding: 10px 20px;
  border-radius: 12px; font-size: 13px; font-weight: 600;
  z-index: 9999; opacity: 0; transition: opacity 0.2s;
  pointer-events: none;
}
.bd-toast.show { opacity: 1; }

.bd-save-bar {
  display: none; align-items: center; gap: 10px;
  padding: 14px 0; border-top: 1px solid #f0f0f0; margin-top: 8px;
}
.bd-save-bar.visible { display: flex; }
.bd-save-bar .save-status { font-size: 13px; color: var(--muted); margin-left: auto; }

.bd-log-placeholder {
  text-align: center; padding: 32px 20px;
  color: var(--muted); font-size: 13px;
}
.bd-log-placeholder i { font-size: 28px; display: block; margin-bottom: 10px; opacity: 0.35; }

/* ---------- CART ---------- */

.cart-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: #ef4444; color: #fff; font-size: 11px; font-weight: 700;
  line-height: 1; margin-right: 4px;
}
.top-cart-btn {
  position: relative; display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--active); color: #fff; font-size: 16px;
  text-decoration: none; transition: opacity 0.15s;
}
.top-cart-btn:hover { opacity: 0.85; }
.cart-badge-header {
  position: absolute; top: -2px; right: -4px;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: #ef4444; color: #fff; font-size: 10px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; line-height: 1;
}
.cart-line-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; border-bottom: 1px solid var(--line); gap: 12px;
}
.cart-line-item:last-child { border-bottom: none; }
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-info strong { font-size: 14px; color: #111827; display: block; }
.cart-item-info span { font-size: 12px; color: var(--muted); }
.cart-item-price { font-size: 15px; font-weight: 700; color: #111827; white-space: nowrap; }
.cart-added-flash {
  color: #16a34a; font-weight: 600; font-size: 13px;
}
.cart-banner {
  background: var(--card); border: 2px solid var(--active);
  border-radius: 18px; padding: 16px 20px; margin-bottom: 16px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.cart-banner-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
}
.cart-banner-info {
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.cart-banner-info strong { font-size: 14px; color: #111827; }
.cart-banner-info span { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cart-banner-actions {
  display: flex; align-items: center; gap: 12px; flex-shrink: 0;
}
.cart-banner-total { font-size: 15px; font-weight: 700; color: #111827; white-space: nowrap; }

/* ---------- ONBOARDING PAGE ---------- */

.onboarding-shell {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 24px; background: var(--bg);
}
.onboarding-wrap { width: 100%; max-width: 520px; }
.onboarding-brand {
  font-family: var(--font-display, 'Playfair Display', Georgia, serif);
  font-weight: 900; font-size: 32px; letter-spacing: 3px;
  text-transform: lowercase; color: var(--text); display: block;
}
.onboarding-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 22px;
  padding: 28px 24px; box-shadow: var(--shadow-1), var(--shadow-2);
}
.onboarding-steps {
  display: flex; gap: 4px; margin-bottom: 24px;
}
.ob-step {
  flex: 1; text-align: center; padding: 10px 8px; border-radius: 10px;
  font-size: 13px; font-weight: 600; color: var(--muted);
  background: #f3f4f6; transition: background 0.2s, color 0.2s;
}
.ob-step span {
  display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px; border-radius: 999px; background: #e5e7eb;
  color: var(--muted); font-size: 11px; font-weight: 700; margin-right: 4px;
}
.ob-step.active { background: var(--active); color: #fff; }
.ob-step.active span { background: rgba(255,255,255,0.25); color: #fff; }
.ob-step.done { background: #dcfce7; color: #16a34a; }
.ob-step.done span { background: #16a34a; color: #fff; }
.email-display {
  display: inline-block; background: #f3f4f6; border-radius: 999px;
  padding: 8px 16px; font-size: 14px; font-weight: 600; color: #374151;
}

/* ---------- PROPERTY DETAIL PAGE ---------- */

.back-link { display:inline-flex; align-items:center; gap:6px; color:var(--muted); font-size:13px; font-weight:600; text-decoration:none; margin-bottom:18px; }
.back-link:hover { color:var(--text); }
.prop-hero { display:flex; align-items:flex-start; gap:18px; margin-bottom:24px; }
.prop-avatar { width:60px; height:60px; min-width:60px; border-radius:18px; background:var(--active); color:#fff; display:flex; align-items:center; justify-content:center; font-size:22px; font-weight:800; letter-spacing:-1px; }
.prop-hero-copy h1 { margin:0 0 4px; font-size:28px; font-weight:800; letter-spacing:-0.03em; }
.prop-hero-copy .eyebrow { margin-bottom:4px; }
.email-alias-row { display:flex; align-items:center; gap:8px; justify-content:flex-end; flex-wrap:wrap; }
.copy-btn { background:none; border:1px solid var(--line); border-radius:6px; padding:3px 9px; font-size:12px; cursor:pointer; color:var(--muted); font-family:inherit; }
.copy-btn:hover { background:#f3f4f6; color:#111827; }
.sender-row { display:flex; align-items:center; justify-content:space-between; padding:8px 0; border-bottom:1px solid var(--line); }
.sender-row:last-child { border-bottom:none; }
.sender-email { font-size:14px; font-weight:500; color:#111827; }
.sender-meta { font-size:12px; color:var(--muted); margin-top:1px; }
.credits-bar-wrap { margin-top:10px; }
.credits-bar-track { height:8px; background:#e5e7eb; border-radius:999px; overflow:hidden; margin-top:4px; }
.credits-bar-fill { height:100%; background:var(--active); border-radius:999px; transition:width 0.4s; }
.credits-bar-fill.warn { background:#f59e0b; }
.credits-bar-fill.danger { background:#ef4444; }
.prop-images-placeholder { text-align:center; padding:48px 24px; color:var(--muted); }
.prop-images-placeholder i { font-size:36px; display:block; margin-bottom:14px; opacity:0.3; }
.security-item { display:flex; align-items:flex-start; gap:10px; padding:10px 0; border-bottom:1px solid var(--line); }
.security-item:last-child { border-bottom:none; }
.security-item-icon { width:28px; text-align:center; color:var(--muted); font-size:13px; padding-top:1px; }
.security-item-copy strong { font-size:13px; display:block; margin-bottom:2px; }
.security-item-copy span { font-size:12px; color:var(--muted); }

/* ---------- PROPERTIES PAGE ---------- */

.prop-card {
  cursor: pointer; transition: border-color 0.15s, box-shadow 0.15s;
  border: 2px solid transparent;
}
.prop-card:hover { border-color: #d1d5db; }
.prop-card.selected {
  border-color: #2f2f31;
  box-shadow: 0 0 0 1px #2f2f31, var(--shadow-2);
}
.prop-card-image {
  width: 100%; height: 160px; object-fit: cover;
  border-radius: 14px; margin-bottom: 14px; background: #f3f4f6;
}
.prop-card-image-placeholder {
  width: 100%; height: 160px; border-radius: 14px;
  background: linear-gradient(135deg, #e5e7eb 0%, #f3f4f6 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 36px; color: var(--muted); opacity: 0.4; margin-bottom: 14px;
}
.prop-card-actions {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px;
  padding-top: 14px; border-top: 1px solid #f0f0f0;
  align-items: center;
}
.prop-card-actions .switch-note {
  width: 100%; font-size: 12px; color: var(--muted); margin: 0 0 4px;
}

/* ---------- CONNECT PAGE ---------- */

.conn-card {
  display: flex; align-items: flex-start; gap: 16px;
  padding: 18px 0; border-bottom: 1px solid #f0f0f0;
}
.conn-card:last-child  { border-bottom: none; padding-bottom: 0; }
.conn-card:first-child { padding-top: 0; }
.conn-logo {
  width: 48px; height: 48px; border-radius: 12px;
  background: #f3f4f6; display: flex; align-items: center;
  justify-content: center; font-size: 22px; flex-shrink: 0;
  border: 1px solid #e5e7eb;
}
.conn-body    { flex: 1; min-width: 0; }
.conn-name    { font-size: 16px; font-weight: 700; color: #111827; margin-bottom: 2px; }
.conn-desc    { font-size: 13px; color: var(--muted); margin-bottom: 10px; line-height: 1.45; }
.conn-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.referral-note {
  font-size: 11px; color: #166534; font-weight: 600;
  background: #dcfce7; padding: 3px 8px; border-radius: 999px; white-space: nowrap;
}
.pro-badge {
  font-size: 11px; color: #92400e; font-weight: 600;
  background: #fef3c7; padding: 3px 8px; border-radius: 999px; white-space: nowrap;
}
.section-intro {
  font-size: 13px; color: var(--muted); margin: -8px 0 16px;
  padding: 12px 16px; background: #f9fafb; border-radius: 12px;
  border: 1px solid #e5e7eb; line-height: 1.5;
}

/* ---------- REVIEWS PAGE ---------- */

.review-card {
  padding: 20px 0;
  border-bottom: 1px solid #f0f0f0;
}
.review-card:first-child { padding-top: 0; }
.review-card:last-child  { border-bottom: none; padding-bottom: 0; }

.review-header {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 12px;
  margin-bottom: 10px; flex-wrap: wrap;
}
.review-meta { flex: 1; min-width: 0; }
.review-name { font-size: 16px; font-weight: 700; color: #111827; margin-bottom: 2px; }
.review-sub  { font-size: 12px; color: var(--muted); }

.stars      { display: flex; gap: 2px; color: #f59e0b; font-size: 16px; line-height: 1; flex-shrink: 0; }
.star-empty { color: #e5e7eb; }

.review-text {
  font-size: 14px; color: #374151; line-height: 1.55;
  margin-bottom: 10px; font-style: italic;
}
.review-footer { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.validated-badge {
  font-size: 11px; font-weight: 700;
  padding: 3px 8px; border-radius: 999px; white-space: nowrap;
}
.validated-badge.validated    { background: #dcfce7; color: #166534; }
.validated-badge.unverified   { background: #fef3c7; color: #92400e; }
.validated-badge.self-reported { background: #f3f4f6; color: #374151; }

.channel-chip {
  font-size: 11px; font-weight: 600; color: #374151;
  background: #f3f4f6; padding: 3px 8px; border-radius: 999px; white-space: nowrap;
}

.add-form         { display: none; flex-direction: column; gap: 14px; }
.add-form.open    { display: flex; }
.form-row         { display: flex; flex-direction: column; gap: 6px; }
.form-row label   { font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.form-input {
  width: 100%; border: 1px solid var(--line);
  border-radius: 12px; padding: 10px 14px;
  font-size: 15px; font-family: inherit; color: var(--text);
  background: #fff; box-sizing: border-box;
}
.form-input:focus          { outline: 2px solid #2f2f31; outline-offset: 2px; }
textarea.form-input        { min-height: 96px; resize: vertical; }

.star-selector { display: flex; gap: 6px; }
.star-btn {
  font-size: 24px; cursor: pointer; background: none;
  border: none; padding: 0; line-height: 1; transition: transform 0.1s;
}
.star-btn:hover { transform: scale(1.15); }
.fwd-copy { font-size: 12px; color: var(--muted); margin-top: 6px; }

/* ---------- PREFERENCES PAGE ---------- */

.pref-section { margin-bottom: 8px; }

.palette-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}
@media (min-width: 600px) { .palette-grid { grid-template-columns: repeat(7, 1fr); } }

.swatch {
  aspect-ratio: 1; border-radius: 12px; cursor: pointer;
  border: 3px solid transparent;
  display: flex; flex-direction: column;
  align-items: center; justify-content: flex-end;
  padding-bottom: 6px;
  transition: border-color 0.15s, transform 0.1s;
  position: relative;
}
.swatch:hover           { transform: scale(1.05); }
.swatch.selected        { border-color: #111827; }
.swatch-label  { font-size: 10px; font-weight: 700; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,0.5); letter-spacing: 0.04em; text-transform: uppercase; }
.swatch-check  { position: absolute; top: 6px; right: 6px; font-size: 14px; display: none; }
.swatch.selected .swatch-check { display: block; }

.temp-bar {
  height: 12px; border-radius: 999px;
  background: linear-gradient(to right, #f9a95a, #f0ede8, #6ab4f5);
  margin-bottom: 8px;
}

.toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 14px 0; border-bottom: 1px solid #f0f0f0;
}
.toggle-row:last-child { border-bottom: none; }
.toggle-label           { flex: 1; }
.toggle-label strong    { display: block; font-size: 15px; color: #111827; margin-bottom: 2px; }
.toggle-label span      { font-size: 13px; color: var(--muted); }

.toggle-switch { position: relative; width: 44px; height: 26px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute; inset: 0;
  background: #d1d5db; border-radius: 999px; cursor: pointer;
  transition: background 0.2s;
}
.toggle-slider::before {
  content: ""; position: absolute;
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; top: 3px; left: 3px;
  transition: transform 0.2s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.toggle-switch input:checked + .toggle-slider              { background: #2f2f31; }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(18px); }

.freq-select {
  appearance: none; border: 1px solid var(--line); background: #fff;
  border-radius: 999px; padding: 7px 14px; font-size: 13px;
  font-weight: 600; cursor: pointer; font-family: inherit;
  color: #374151; flex-shrink: 0;
}

/* ---------- STATS PAGE ---------- */

.value-hero {
  background: linear-gradient(135deg, #1f2933 0%, #2f3f4f 100%);
  border-radius: 22px; padding: 28px 24px; color: #fff; border: none;
}
.value-hero .eyebrow { color: rgba(255,255,255,0.5); }
.value-hero h2       { color: #fff; margin-bottom: 6px; }
.value-hero p        { color: rgba(255,255,255,0.65); margin: 0; }

.value-numbers {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 16px; margin-top: 20px;
}
.value-number {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px; padding: 18px;
}
.value-number .label  { font-size: 12px; color: rgba(255,255,255,0.55); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 8px; }
.value-number .number { font-size: 32px; font-weight: 700; color: #f9d94e; line-height: 1; margin-bottom: 4px; }
.value-number .sub    { font-size: 13px; color: rgba(255,255,255,0.5); }

.pref-slider-wrap { margin-bottom: 20px; }
.pref-slider-wrap label { display: flex; flex-direction: column; gap: 8px; font-size: 14px; font-weight: 600; color: #374151; }
.pref-row { display: flex; align-items: center; gap: 12px; }
.pref-row input[type=range] { flex: 1; accent-color: #2f2f31; }
.pref-value { min-width: 52px; text-align: right; font-size: 15px; font-weight: 700; color: #111827; }

.usage-stat {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 0; border-top: 1px solid #edf0f2;
}
.usage-stat:first-child  { border-top: none; padding-top: 4px; }
.usage-stat-icon {
  width: 40px; height: 40px; border-radius: 12px;
  background: #f3f4f6; display: flex; align-items: center;
  justify-content: center; font-size: 18px; flex-shrink: 0;
}
.usage-stat-copy         { flex: 1; min-width: 0; }
.usage-stat-copy strong  { display: block; font-size: 15px; color: #111827; }
.usage-stat-copy span    { font-size: 13px; color: var(--muted); }
.usage-stat-value        { font-size: 22px; font-weight: 700; color: #111827; }

/* ---------- UPGRADE PAGE ---------- */

.upgrade-tabs { display: flex; gap: 8px; margin-bottom: 24px; }
.upgrade-tab {
  appearance: none; border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 20px; font-size: 14px; font-weight: 600; cursor: pointer;
  background: var(--card); color: var(--muted);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.upgrade-tab.active { background: #1f2933; color: #fff; border-color: #1f2933; }

.selector-strip {
  display: flex; flex-direction: column; gap: 6px;
  margin-bottom: 16px; padding: 14px 16px;
  background: #f9fafb; border: 1px solid var(--line); border-radius: 14px;
}
.selector-strip label {
  font-size: 12px; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--muted); white-space: nowrap;
}
.selector-strip select {
  border: 1px solid var(--line); border-radius: 10px; padding: 8px 14px;
  font-size: 14px; font-weight: 600; background: var(--card);
  color: #111827; cursor: pointer; width: 100%; max-width: 400px;
}

.plan-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 560px) { .plan-grid                { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .plan-grid                { grid-template-columns: repeat(4, 1fr); } }
.plan-grid.two-col { grid-template-columns: 1fr; }
@media (min-width: 560px) { .plan-grid.two-col        { grid-template-columns: repeat(2, 1fr); } }
.plan-grid.three-col { grid-template-columns: 1fr; }
@media (min-width: 560px) { .plan-grid.three-col      { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .plan-grid.three-col      { grid-template-columns: repeat(3, 1fr); } }

.plan-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 20px;
  padding: 22px; display: flex; flex-direction: column; gap: 12px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.02), 0 4px 12px rgba(0,0,0,0.03);
}
.plan-card.featured { border: 2px solid #1f2933; background: #1f2933; color: #fff; }
.plan-card.featured p,
.plan-card.featured .plan-feature { color: rgba(255,255,255,0.65); border-color: rgba(255,255,255,0.1); }
.plan-card.featured .plan-feature strong { color: #fff; }
.plan-card.featured .plan-note          { color: rgba(255,255,255,0.4); }
.plan-card.current { border: 2px solid var(--accent); }

.plan-badge {
  display: inline-block; font-size: 11px; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  padding: 3px 9px; border-radius: 999px; margin-bottom: 2px;
}
.badge-current  { background: #fee2e2; color: #991b1b; }
.badge-featured { background: #f9d94e; color: #1f2933; }
.badge-popular  { background: #dbeafe; color: #1d4ed8; }

.plan-name { font-size: 18px; font-weight: 700; color: inherit; }
.plan-card.featured .plan-name  { color: #fff; }
.plan-price { font-size: 32px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; color: #1f2933; }
.plan-card.featured .plan-price { color: #f9d94e; }
.plan-price span { font-size: 13px; font-weight: 500; color: var(--muted); }
.plan-card.featured .plan-price span { color: rgba(255,255,255,0.45); }

.plan-features { display: flex; flex-direction: column; flex: 1; }
.plan-feature {
  display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
  padding: 8px 0; border-bottom: 1px solid #f0f0f0; font-size: 13px; color: var(--muted);
}
.plan-feature:last-child  { border-bottom: none; }
.plan-feature strong      { color: #111827; font-weight: 600; }
.plan-note { font-size: 12px; color: var(--muted); }

.org-feature-list { display: flex; flex-direction: column; gap: 0; }
.org-feature {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid #f0f0f0; font-size: 14px;
}
.org-feature:last-child { border-bottom: none; }
.org-feature .tick   { font-size: 13px; color: #166534; flex-shrink: 0; }
.org-feature .lock   { font-size: 13px; color: #9ca3af; flex-shrink: 0; }
.org-feature .label  { color: #111827; font-weight: 500; flex: 1; }
.org-feature .tier   { font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: #9ca3af; white-space: nowrap; }
.org-feature .tier.unlocked { color: #166534; }

.addon-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 20px;
  display: flex; flex-direction: column; gap: 8px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.02), 0 4px 12px rgba(0,0,0,0.03);
}
.addon-card.coming-soon { opacity: 0.6; }
.addon-name  { font-size: 15px; font-weight: 700; color: #111827; }
.addon-price { font-size: 13px; color: var(--muted); }
.addon-price strong { color: #111827; }

.booster-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 560px) { .booster-grid { grid-template-columns: repeat(3, 1fr); } }

.booster-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 20px;
  display: flex; flex-direction: column; gap: 8px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.02), 0 4px 12px rgba(0,0,0,0.03);
}
.booster-card.best { border: 2px solid #166534; background: #f0fdf4; }

.status-bar { border-radius: 20px; padding: 22px 26px; margin-bottom: 8px; }
.status-bar.dark { background: linear-gradient(135deg,#1f2933,#2f3f4f); color: #fff; }
.status-bar.dark .eyebrow          { color: rgba(255,255,255,0.45); }
.status-bar.dark h3                { color: #fff; margin-bottom: 4px; }
.status-bar.dark .progress-bar     { background: rgba(255,255,255,0.15); }
.status-bar.dark .progress-fill    { background: #f9d94e; }
.status-bar.dark .progress-meta    { color: rgba(255,255,255,0.65); }
.status-bar.dark .progress-meta span:last-child { color: #f9d94e; }

.status-bar-stat-label { font-size:11px;color:rgba(255,255,255,0.45);text-transform:uppercase;letter-spacing:0.06em;margin-bottom:4px; }
.status-bar-stat-value { font-size:16px;font-weight:700;color:#fff; }
.status-bar-stat-value.yellow { color:#f9d94e; }

.tip-box {
  border-radius: 16px; padding: 16px 20px; font-size: 13px;
  display: flex; gap: 12px; align-items: flex-start; margin-bottom: 8px;
}
.tip-box.blue   { background: #f0f9ff; border: 1px solid #bae6fd; color: #0369a1; }
.tip-box.yellow { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; }

/* ── Bookings filter bar enhancement ──────────────────── */
.filter-bar{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
  margin-bottom:16px;
}
.filter-group{
  display:flex;
  gap:6px;
  flex-wrap:wrap;
}
.filter-selects{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
}
.filter-select{
  appearance:none;
  -webkit-appearance:none;
  height:40px;
  padding:0 36px 0 14px;
  border:1.5px solid #d1d5db;
  border-radius:12px;
  font-size:13px;
  font-weight:600;
  color:#111827;
  background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%239ca3af' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center/10px no-repeat;
  font-family:inherit;
  cursor:pointer;
  outline:none;
  transition:border-color .15s, box-shadow .15s;
  box-shadow:0 1px 2px rgba(0,0,0,0.04);
}
.filter-select:hover{ border-color:#9ca3af; box-shadow:0 1px 4px rgba(0,0,0,0.08); }
.filter-select:focus{ border-color:#2f2f31; box-shadow:0 0 0 3px rgba(47,55,65,0.08); }

/* ── Icon button (inline table action) ─────────────────── */
.icon-btn{
  background:none;
  border:none;
  padding:3px 5px;
  cursor:pointer;
  color:var(--muted);
  font-size:12px;
  border-radius:4px;
  vertical-align:middle;
  line-height:1;
}
.icon-btn:hover{ background:#f3f4f6; color:#374151; }

/* ── FX rate cell ───────────────────────────────────────── */
.fx-rate-cell{
  font-size:12px;
  font-variant-numeric:tabular-nums;
  color:#6b7280;
}

/* ── Bookings totals row ────────────────────────────────── */
.totals-row td{
  background:#f9fafb;
  border-top:2px solid #e5e7eb;
  padding-top:12px;
  padding-bottom:12px;
  font-size:13px;
}

/* ── Modal overlay ──────────────────────────────────────── */
.modal-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.4);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:1000;
  padding:24px;
  box-sizing:border-box;
}
.modal-card{
  background:#fff;
  border-radius:16px;
  padding:24px;
  max-width:460px;
  width:100%;
  box-shadow:0 20px 60px rgba(0,0,0,0.15);
}
.modal-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  margin-bottom:16px;
  font-size:16px;
}
.modal-close-btn{
  background:none;
  border:none;
  cursor:pointer;
  color:var(--muted);
  font-size:16px;
  padding:4px;
  border-radius:6px;
  line-height:1;
}
.modal-close-btn:hover{ background:#f3f4f6; color:#111827; }

/* ── DEV BLOCKS ──────────────────────────────────────────────────────────── */
/* Elements marked data-dev-block are hidden by default.                      */
/* devBlocksToggle() in shell.js removes display:none when dev blocks are on. */
[data-dev-block]{ display:none; }
