/* StayHQ — shared styles. Guest view + Admin view + Edit mode. */

/* ── Reset ───────────────────────────────────────────────────────────────────*/
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Theme CSS variables (defaults = 'default' theme) ────────────────────────*/
:root {
  --bg:           #f7f7f9;
  --card-bg:      #ffffff;
  --text:         #1a1a2e;
  --text-muted:   #6b6b7b;
  --accent:       #7c5cff;
  --font-head:    'Inter', sans-serif;
  --font-body:    'Inter', sans-serif;
  --tint-entry:     #ede7ff;
  --tint-wifi:      #e3f0ff;
  --tint-contact:   #e2f7ea;
  --tint-info:      #fff4e0;
  --tint-howto:     #e0f5f0;
  --tint-emergency: #ffe5e5;
  --tint-food:      #ffeede;
  --tint-default:   #f0eaff;

  /* Admin palette (separate, never overridden by themes) */
  --a-bg:        #f4f4f8;
  --a-card:      #ffffff;
  --a-primary:   #7c3aed;
  --a-text:      #111827;
  --a-muted:     #6b7280;
  --a-border:    #e5e7eb;
  --a-danger:    #dc2626;

  --font:   -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius: 16px;
  --shadow: 0 2px 8px rgba(0,0,0,0.06);
}

html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body { font-family: var(--font-body); background: var(--bg); color: var(--text); line-height: 1.55; min-height: 100vh; }

.hidden { display: none !important; }

/* ── Icon tint classes (themed) ──────────────────────────────────────────────*/
.icon-tint-entry     { background: var(--tint-entry);     color: var(--accent); }
.icon-tint-wifi      { background: var(--tint-wifi);      color: #1a7fc1; }
.icon-tint-contact   { background: var(--tint-contact);   color: #1a9a50; }
.icon-tint-info      { background: var(--tint-info);      color: #b87a00; }
.icon-tint-howto     { background: var(--tint-howto);     color: #1a8c7a; }
.icon-tint-emergency { background: var(--tint-emergency); color: #dc2626; }
.icon-tint-food      { background: var(--tint-food);      color: #c2410c; }
.icon-tint-default   { background: var(--tint-default);   color: var(--accent); }

/* ══════════════════════════════════════════════════════════════════════════════
   GUEST SHELL
══════════════════════════════════════════════════════════════════════════════ */
body.guest-body { background: var(--bg); }
#guest-app      { max-width: 480px; margin: 0 auto; background: var(--bg); min-height: 100vh; }

.guest-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: var(--card-bg); border-bottom: 1px solid rgba(0,0,0,0.06);
  position: sticky; top: 0; z-index: 100; gap: 12px;
}
.guest-nav-logo { font-size: 1.05rem; font-weight: 800; color: var(--accent); font-family: var(--font-head); white-space: nowrap; }

/* Install button in nav */
#nav-install-slot { flex-shrink: 0; position: relative; }
.nav-install-btn {
  background: rgba(0,0,0,0.50); backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.15); border-radius: 10px;
  color: #fff; padding: 6px 12px; font-size: .75rem; font-weight: 700; cursor: pointer;
  white-space: nowrap; font-family: var(--font-body); line-height: 1;
}
.nav-install-btn:active { background: rgba(0,0,0,0.70); }
.install-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 999;
  display: flex; align-items: flex-end; justify-content: center; padding: 16px;
}
.install-modal {
  background: #fff; border-radius: 20px; padding: 28px 24px 20px;
  width: 100%; max-width: 400px; text-align: center;
  box-shadow: 0 8px 40px rgba(0,0,0,.2);
}
.install-modal-icon { font-size: 2.2rem; margin-bottom: 10px; }
.install-modal-title { font-size: 1.1rem; font-weight: 800; color: #1a1a2e; margin-bottom: 16px; }
.install-modal-body { text-align: left; font-size: .9rem; color: #444; line-height: 1.7; margin-bottom: 20px; }
.install-modal-body p { margin: 0 0 8px; }
.install-modal-close {
  background: var(--accent); color: #fff; border: none; border-radius: 12px;
  padding: 12px 32px; font-size: .95rem; font-weight: 700; cursor: pointer; width: 100%;
}

/* Hero chips — door code + wifi on hero */
.hero-chips {
  position: absolute; bottom: 12px; left: 12px; right: 12px;
  display: flex; gap: 6px; z-index: 2;
}
.hero-chip {
  background: rgba(0,0,0,0.50); backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.15); border-radius: 10px;
  color: #fff; cursor: pointer; font-family: var(--font-body);
  padding: 7px 9px; display: flex; flex-direction: row; align-items: center; gap: 7px;
  text-align: left; flex: 1;
}
.hero-chip:active { background: rgba(0,0,0,0.70); }
.hero-chip-icon  { font-size: 1.1rem; flex-shrink: 0; }
.hero-chip-text  { display: flex; flex-direction: column; gap: 0; min-width: 0; }
.hero-chip-label { font-size: .50rem; font-weight: 600; opacity: .70; text-transform: uppercase; letter-spacing: .05em; }
.hero-chip-value { font-size: .72rem; font-weight: 800; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hero-chip-hint  { font-size: .46rem; opacity: .60; margin-top: 1px; }

/* Change-photo button in admin hero edit */
.hero-change-photo-btn {
  margin-top: 10px; background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.4); border-radius: 999px;
  color: #fff; font-size: .8rem; font-weight: 600;
  padding: 7px 16px; cursor: pointer; font-family: var(--font);
}

/* Image picker grid */
.img-picker-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 4px 0 8px; }
.img-picker-thumb {
  aspect-ratio: 4/3; border-radius: 10px;
  background-size: cover; background-position: center;
  border: 2px solid transparent; cursor: pointer; position: relative; overflow: hidden;
  transition: border-color .15s;
}
.img-picker-thumb.selected { border-color: var(--a-primary); box-shadow: 0 0 0 2px var(--a-primary); }

/* Extra section icon picker */
.icon-picker-grid { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 0 8px; }
.icon-picker-btn { width: 44px; height: 44px; border: 2px solid transparent; border-radius: 10px; background: var(--a-surface); font-size: 1.3rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: border-color .15s, background .15s; }
.icon-picker-btn:hover { background: var(--a-hover); }
.icon-picker-btn.selected { border-color: var(--a-primary); background: var(--a-bg); }

.img-picker-label {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: rgba(0,0,0,0.5); color: #fff;
  font-size: .68rem; font-weight: 600; padding: 4px 6px; text-align: center;
}

/* ── Hero ────────────────────────────────────────────────────────────────────*/
.guest-hero {
  position: relative; min-height: 240px;
  background: url('../images/beach (2).png') center center / cover no-repeat;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  padding: 32px 28px 80px; text-align: center;
}
.guest-hero-overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,.22), rgba(0,0,0,.50)); }
.guest-hero-content { position: relative; color: #fff; width: 100%; }
.guest-hero-title { font-size: 2.4rem; font-weight: 800; letter-spacing: -.5px; text-shadow: 0 2px 6px rgba(0,0,0,.3); margin-bottom: 10px; font-family: var(--font-head); }
.guest-hero-sub   { font-size: 1rem; line-height: 1.6; text-shadow: 0 1px 3px rgba(0,0,0,.25); opacity: .95; font-family: var(--font-body); }

/* ── Edit-mode hero inputs ───────────────────────────────────────────────────*/
.hero-edit-hint { font-size: .7rem; color: rgba(255,255,255,.7); text-transform: uppercase; letter-spacing: .6px; margin-bottom: 12px; font-weight: 600; }
.hero-edit-input {
  display: block; width: 100%;
  background: rgba(255,255,255,.15); border: 1.5px solid rgba(255,255,255,.4);
  border-radius: 10px; padding: 10px 14px; color: #fff;
  font-size: 1.15rem; font-weight: 700; font-family: var(--font); margin-bottom: 8px;
}
.hero-edit-input::placeholder  { color: rgba(255,255,255,.5); }
.hero-edit-input:focus         { outline: none; border-color: #fff; background: rgba(255,255,255,.22); }
.hero-edit-textarea {
  display: block; width: 100%;
  background: rgba(255,255,255,.1); border: 1.5px dashed rgba(255,255,255,.4);
  border-radius: 10px; padding: 9px 14px; color: rgba(255,255,255,.9);
  font-size: .92rem; font-family: var(--font); resize: none;
}
.hero-edit-textarea::placeholder { color: rgba(255,255,255,.45); }
.hero-edit-textarea:focus        { outline: none; border-color: rgba(255,255,255,.7); }

/* ── Guide body ──────────────────────────────────────────────────────────────*/
.guide-body { padding: 0 0 48px; background: var(--bg); }

/* ── Section groups ──────────────────────────────────────────────────────────*/
.section-group       { padding: 32px 16px 0; }
.section-group-title {
  font-size: .72rem; font-weight: 800; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .1em;
  margin-bottom: 14px; font-family: var(--font-head);
  padding-bottom: 8px; border-bottom: 1px solid rgba(0,0,0,0.06);
}

/* Primary section (Entry & Essentials) gets stronger treatment */
.section-group--primary .section-group-title {
  font-size: .72rem; color: var(--accent);
  border-bottom-color: var(--accent); border-bottom-width: 2px;
}
.section-group--primary .grid-card-icon-circle { width: 62px; height: 62px; font-size: 28px; }
.section-group--primary .grid-card { min-height: 160px; }

/* ── Tile grid — auto-sizes by card count ────────────────────────────────────*/
.tile-grid          { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); }
.tile-grid--1col    { grid-template-columns: 1fr; }
.tile-grid--2col    { grid-template-columns: repeat(2, 1fr); }
.tile-grid--3col    { grid-template-columns: repeat(3, 1fr); }
.tile-grid--4col    { grid-template-columns: repeat(4, 1fr); }
/* Center a lone orphan in a 3-col grid */
.tile-grid--3col > *:last-child:nth-child(3n+1) { grid-column: 2; }

.grid-card {
  background: var(--card-bg); border: none; border-radius: var(--radius);
  padding: 22px 10px 24px; text-align: center; cursor: pointer;
  font-family: var(--font-body); position: relative;
  transition: transform .12s, box-shadow .12s;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: center;
  min-height: 150px; width: 100%;
}
.grid-card:active { transform: scale(.97); box-shadow: none; }

/* Edit mode: subtle solid border on all cards */
.edit-mode .grid-card { border: 1.5px solid #ede9fe; }

.grid-card-icon-circle { width: 56px; height: 56px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 26px; margin-bottom: 12px; flex-shrink: 0; line-height: 1; }
.grid-card-name        { font-size: .85rem; font-weight: 700; color: var(--text); line-height: 1.3; margin-bottom: 6px; font-family: var(--font-head); }
.grid-card-desc        { font-size: .73rem; color: var(--text-muted); line-height: 1.5; }
.grid-card-arrow       { position: absolute; bottom: 8px; right: 11px; font-size: 1.1rem; color: var(--text-muted); opacity: .6; }

/* Add card */
.grid-card--add {
  border: 1.5px solid #ede9fe !important; background: #faf8ff;
  display: flex; align-items: center; justify-content: center; min-height: 130px;
}
.edit-mode .grid-card--add { border-color: #ede9fe !important; }
.grid-card-add-label { font-size: .85rem; font-weight: 600; color: var(--accent); }

/* ── Rebook card ─────────────────────────────────────────────────────────────*/
.rebook-grid-card {
  background: #f0ecff; border: 1.5px solid #ddd6fe; border-radius: var(--radius);
  padding: 20px 10px 22px; text-align: center; font-family: var(--font-body);
  display: flex; flex-direction: column; align-items: center; text-decoration: none;
  box-shadow: var(--shadow);
}
.rebook-btn-inline {
  margin-top: 12px; display: inline-block; background: var(--accent); color: #fff;
  border-radius: 999px; padding: 9px 16px; font-size: .78rem; font-weight: 700; text-decoration: none;
}

/* ── Local Spots ─────────────────────────────────────────────────────────────*/
.spots-list { display: flex; flex-direction: column; gap: 10px; }
.spot-row-card {
  background: var(--card-bg); border: none; border-radius: var(--radius);
  padding: 14px 16px; display: flex; align-items: center; gap: 14px;
  box-shadow: var(--shadow);
}
.edit-mode .spot-row-card { border: 1.5px dashed #c4b5fd; }
.spot-row-icon  { width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.spot-row-info  { flex: 1; min-width: 0; }
.spot-row-name  { font-size: .93rem; font-weight: 700; color: var(--text); font-family: var(--font-head); }
.spot-row-blurb { font-size: .8rem; color: var(--text-muted); margin-top: 2px; line-height: 1.4; }
.spot-row-btn {
  flex-shrink: 0; background: var(--accent); color: #fff; text-decoration: none;
  border-radius: 999px; padding: 8px 14px; font-size: .8rem; font-weight: 700; white-space: nowrap;
}
.spot-edit-btn {
  flex-shrink: 0; background: var(--tint-default); color: var(--accent); border: none;
  border-radius: 999px; padding: 8px 14px; font-size: .8rem; font-weight: 600; cursor: pointer; white-space: nowrap;
}
.add-row-btn {
  width: 100%; padding: 12px; border: 1.5px solid #ede9fe; border-radius: 12px;
  background: #faf8ff; color: var(--accent); font-weight: 600; font-size: .9rem; cursor: pointer; margin-top: 6px;
  font-family: var(--font-body);
}
.add-row-btn:hover { border-color: #c4b5fd; background: var(--tint-default); }

/* ── Bottom sheet ────────────────────────────────────────────────────────────*/
.sheet-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 300;
  display: flex; align-items: flex-end; animation: fadeIn .15s;
}
.sheet-overlay.hidden { display: none; }
.sheet {
  background: var(--card-bg); border-radius: 22px 22px 0 0; width: 100%; max-width: 480px;
  margin: 0 auto; max-height: 88vh; overflow-y: auto; animation: slideUp .22s ease-out;
}
@keyframes slideUp { from { transform: translateY(60px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes fadeIn  { from { opacity: 0; } to { opacity: 1; } }
.sheet-handle { width: 40px; height: 4px; background: #e5e7eb; border-radius: 2px; margin: 14px auto 0; }
.sheet-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; border-bottom: 1px solid rgba(0,0,0,0.06);
}
.sheet-header-left { display: flex; align-items: center; gap: 12px; }
.sheet-icon-circle { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.sheet-title { font-size: 1.05rem; font-weight: 700; color: var(--text); font-family: var(--font-head); }
.sheet-close { background: #f3f4f6; border: none; border-radius: 50%; width: 32px; height: 32px; cursor: pointer; font-size: .9rem; color: #6b7280; display: flex; align-items: center; justify-content: center; }
.sheet-content { padding: 20px; color: var(--text); font-family: var(--font-body); }

/* ── Sheet content: view mode ────────────────────────────────────────────────*/
.door-code-box   { background: var(--accent); color:#fff; border-radius:14px; padding:20px; margin-bottom:16px; text-align:center; }
.door-code-label { font-size:.75rem; text-transform:uppercase; letter-spacing:.6px; opacity:.85; margin-bottom:8px; }
.door-code-value { font-size:2.6rem; font-weight:800; letter-spacing:8px; font-family: var(--font-head); }
.door-code-expired { background:#f1f3f5; border-radius:12px; padding:16px; text-align:center; color:var(--text-muted); font-size:.9rem; margin-bottom:14px; }

.info-row        { display:flex; flex-direction:column; gap:5px; padding:14px 0; border-bottom:1px solid rgba(0,0,0,0.06); }
.info-row:last-child { border-bottom:none; }
.info-label      { font-size:.72rem; text-transform:uppercase; letter-spacing:.5px; color:var(--text-muted); font-weight:600; }
.info-value      { font-size:.97rem; white-space:pre-wrap; line-height:1.5; color:var(--text); }

.wifi-copy-btn   { margin-top:14px; width:100%; background:var(--accent); color:#fff; border:none; border-radius:999px; padding:13px; font-size:.95rem; font-weight:700; cursor:pointer; font-family:var(--font-body); }
.wifi-copy-btn.copied { background:#16a34a; }

.contact-btns-list { display:flex; flex-direction:column; gap:10px; }
.contact-btn  { display:flex; align-items:center; gap:12px; padding:14px 18px; border-radius:14px; font-size:1rem; font-weight:700; text-decoration:none; border:none; cursor:pointer; width:100%; text-align:left; box-sizing:border-box; }
.contact-btn-call      { background:var(--tint-entry);     color:var(--accent); }
.contact-btn-text      { background:var(--tint-wifi);      color:#1a7fc1; }
.contact-btn-email     { background:var(--tint-contact);   color:#1a9a50; }
.contact-btn-whatsapp  { background:#e7f9ee;               color:#128c3e; }
.contact-btn-airbnb    { background:#fff0ee;               color:#e0533b; }
.contact-btn-vrbo      { background:#eef4ff;               color:#1859e0; }
.contact-btn-other     { background:var(--tint-default);   color:var(--accent); }


/* Feedback form */
.feedback-intro    { font-size:.9rem; color:var(--text-muted); margin-bottom:14px; line-height:1.5; }
.feedback-textarea { width:100%; border:1.5px solid rgba(0,0,0,.1); border-radius:12px; padding:12px 14px; font-size:.95rem; font-family:var(--font-body); color:var(--text); resize:vertical; box-sizing:border-box; background:var(--card-bg); }
.feedback-textarea:focus { outline:none; border-color:var(--accent); }
.feedback-submit-btn { width:100%; margin-top:12px; background:var(--accent); color:#fff; border:none; border-radius:12px; padding:13px; font-size:.95rem; font-weight:700; cursor:pointer; font-family:var(--font-body); }
.feedback-submit-btn:disabled { opacity:.6; cursor:default; }

.accordion-list {}
.accordion-btn  { width:100%; background:none; border:none; border-top:1px solid rgba(0,0,0,0.06); padding:15px 0; cursor:pointer; display:flex; align-items:center; gap:10px; text-align:left; font-family:var(--font-body); font-size:.95rem; font-weight:600; color:var(--text); }
.accordion-item:first-child .accordion-btn { border-top:none; }
.acc-chevron    { margin-left:auto; color:var(--text-muted); font-size:.8rem; transition:transform .2s; }
.accordion-btn[aria-expanded="true"] .acc-chevron { transform:rotate(180deg); }
.accordion-body { display:none; padding:0 0 16px; font-size:.93rem; color:var(--text-muted); white-space:pre-wrap; line-height:1.65; }
.accordion-body.open { display:block; }

.checkout-rebook-banner { display:block; background:var(--accent); color:#fff; border-radius:12px; padding:14px 18px; font-size:.92rem; line-height:1.5; text-align:center; text-decoration:none; margin-bottom:14px; }
.checkout-rebook-banner:active { opacity:.85; }
.checkout-time-banner { background:var(--tint-food); border-radius:12px; padding:14px 18px; font-size:1.05rem; color:var(--text); margin-bottom:16px; text-align:center; }
.checkout-time-banner strong { font-size:1.4rem; display:block; margin-top:4px; color:var(--accent); }
.checkout-instructions { font-size:.95rem; white-space:pre-wrap; line-height:1.7; color:var(--text); }

/* ── Sheet content: edit mode ────────────────────────────────────────────────*/
.edit-field-group { margin-bottom: 16px; }
.edit-label       { display: block; font-size: .83rem; font-weight: 600; color: var(--a-text); margin-bottom: 6px; }
.edit-input {
  width: 100%; border: 1.5px solid #e5e7eb; border-radius: 9px;
  padding: 11px 14px; font-family: var(--font); font-size: .95rem; color: var(--a-text);
  background: #fff; outline: none; transition: border-color .15s;
}
.edit-input:focus   { border-color: var(--a-primary); }
.edit-textarea      { width: 100%; border: 1.5px solid #e5e7eb; border-radius: 9px; padding: 11px 14px; font-family: var(--font); font-size: .93rem; color: var(--a-text); background: #fff; resize: vertical; min-height: 80px; outline: none; }
.edit-textarea:focus { border-color: var(--a-primary); }
.edit-hint          { font-size: .78rem; color: var(--a-muted); margin-top: 5px; }
.edit-sub-item      { background: #f7f9fb; border-radius: 10px; padding: 14px; border: 1px solid var(--a-border); margin-bottom: 10px; }

/* ── Guest footer ────────────────────────────────────────────────────────────*/
.guest-footer       { text-align:center; padding:36px 24px 52px; color:var(--text); font-size:.9rem; line-height:1.8; font-family:var(--font-body); }
.guest-footer-heart { font-size:1.3rem; color:var(--accent); margin:10px 0 6px; }
.guest-footer-brand { font-size:.78rem; color:var(--text-muted); margin-top:4px; }

/* ── Loading / Not found ─────────────────────────────────────────────────────*/
.loading { display:flex; flex-direction:column; align-items:center; justify-content:center; padding:80px 24px; gap:16px; color:var(--text-muted); }
.spinner { width:36px; height:36px; border:3px solid rgba(0,0,0,0.1); border-top-color:var(--accent); border-radius:50%; animation:spin .7s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
.not-found { text-align:center; padding:60px 24px; color:var(--text-muted); }
.not-found h2 { font-size:1.3rem; margin-bottom:10px; color:var(--text); font-family:var(--font-head); }

/* ══════════════════════════════════════════════════════════════════════════════
   ADMIN SHELL (never affected by guest themes)
══════════════════════════════════════════════════════════════════════════════ */
body.admin-body { background: var(--a-bg); color: var(--a-text); font-family: var(--font); }
#admin-app { max-width: 680px; margin: 0 auto; padding: 0 0 60px; }

/* ── Admin Tabs ──────────────────────────────────────────────────────────── */
.admin-tabs { display:flex; gap:4px; background:#f3f0ff; border-radius:14px; padding:4px; margin-bottom:20px; }
.admin-tab { flex:1; background:none; border:none; border-radius:10px; padding:10px 8px; font-size:.85rem; font-weight:700; color:var(--a-muted); cursor:pointer; transition:all .15s; position:relative; white-space:nowrap; }
.admin-tab.active { background:#fff; color:var(--a-primary); box-shadow:0 1px 4px rgba(0,0,0,.1); }
.admin-tab-badge { display:inline-block; background:#ef4444; color:#fff; border-radius:999px; font-size:.65rem; font-weight:800; padding:1px 6px; margin-left:4px; vertical-align:middle; }
.admin-tab-badge.hidden { display:none; }

.topbar { background:var(--a-primary); color:#fff; padding:14px 20px; display:flex; align-items:center; gap:12px; position:sticky; top:0; z-index:100; }
.topbar-logo   { font-weight:800; font-size:1.1rem; }
.topbar-title  { flex:1; font-size:.95rem; font-weight:600; opacity:.9; }
.topbar-logout { background:rgba(255,255,255,.18); color:#fff; border:none; border-radius:999px; padding:6px 14px; font-size:.82rem; cursor:pointer; }
.topbar-help   { color:rgba(255,255,255,.85); font-size:.82rem; font-weight:600; text-decoration:none; margin-right:8px; }
.topbar-help:hover { color:#fff; }
.topbar .nav-install-btn { background:rgba(255,255,255,.18); color:#fff; border:none; border-radius:999px; padding:6px 14px; font-size:.82rem; font-weight:700; cursor:pointer; white-space:nowrap; }
.topbar .nav-install-btn:hover { background:rgba(255,255,255,.3); }
.ios-install-tooltip { position:absolute; right:0; top:calc(100% + 8px); background:#1a1a2e; color:#fff; font-size:.8rem; border-radius:8px; padding:10px 14px; white-space:nowrap; z-index:999; box-shadow:0 4px 16px rgba(0,0,0,.2); }
@media (max-width:480px) { .nav-install-btn { padding:6px 10px; font-size:.75rem; } }

.admin-screen { padding: 20px; }

/* ── Landing page ─────────────────────────────────────────────────────────── */
.landing-wrap { background:#fff; font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif; }

/* Nav */
.landing-nav { background:linear-gradient(90deg,#4a2fa8,#7c5cff); display:flex; align-items:center; justify-content:space-between; padding:14px 28px; position:sticky; top:0; z-index:100; }
.landing-nav-logo { color:#fff; font-size:1.15rem; font-weight:800; }
.landing-nav-login { background:transparent; color:#fff; border:2px solid rgba(255,255,255,.7); border-radius:8px; padding:8px 22px; font-size:.88rem; font-weight:700; cursor:pointer; }
.landing-nav-login:hover { background:rgba(255,255,255,.12); }

/* Hero */
.landing-hero { background:linear-gradient(135deg,#e8e0ff 0%,#f3eeff 50%,#faf8ff 100%); padding:48px 28px 0; display:flex; flex-direction:column; align-items:center; gap:0; }
.landing-hero-text { text-align:center; max-width:520px; }
.landing-badge { display:inline-flex; align-items:center; gap:6px; background:#fff; border:1px solid #d4c8ff; color:#6a45e8; font-size:.78rem; font-weight:600; border-radius:999px; padding:6px 16px; margin-bottom:20px; box-shadow:0 1px 4px rgba(0,0,0,.06); }
.landing-headline { font-size:2.2rem; font-weight:800; line-height:1.18; color:#1a1a2e; margin-bottom:16px; }
.landing-headline-accent { color:#7c5cff; }
.landing-sub { font-size:.97rem; color:#5a5a72; line-height:1.72; margin-bottom:28px; }
.landing-cta { display:inline-block; background:#7c5cff; color:#fff; border:none; border-radius:10px; padding:15px 34px; font-size:1rem; font-weight:800; cursor:pointer; margin-bottom:10px; box-shadow:0 4px 14px rgba(124,92,255,.35); }
.landing-cta:hover { background:#6a4ee0; }
.landing-free-note { font-size:.82rem; color:#7a7a9a; margin-bottom:0; }

/* Phone */
.landing-phone-wrap { display:flex; justify-content:center; padding:32px 0 0; }
.landing-phone-frame { background:#0e0e0e; border-radius:50px; padding:16px 12px 12px; box-shadow:0 40px 100px rgba(60,30,160,.28), 0 0 0 1px rgba(255,255,255,.08); width:260px; position:relative; }
.landing-phone-notch { width:90px; height:24px; background:#0e0e0e; border-radius:0 0 18px 18px; margin:0 auto 8px; border:3px solid #1a1a1a; }
.landing-phone-screen { width:100%; height:500px; border-radius:36px; overflow:hidden; background:#f7f7f9; }
.landing-phone-img { width:100%; display:block; }

/* Info strip */
.landing-strip { background:#fff; padding:36px 28px; text-align:center; border-top:1px solid #ede8ff; border-bottom:1px solid #ede8ff; }
.landing-strip-title { font-size:1.15rem; font-weight:800; color:#1a1a2e; margin-bottom:24px; }
.landing-strip-icons { display:flex; justify-content:space-around; flex-wrap:nowrap; gap:8px; }
.strip-icon { display:flex; flex-direction:column; align-items:center; gap:8px; font-size:.7rem; font-weight:600; color:#6b6b7b; min-width:44px; }
.strip-icon span { font-size:1.5rem; background:#f0eaff; border-radius:14px; width:50px; height:50px; display:flex; align-items:center; justify-content:center; }

/* Feature cards */
.landing-features-section { background:#f7f7fb; padding:44px 24px; }
.landing-section-title { font-size:1.25rem; font-weight:800; color:#1a1a2e; text-align:center; margin-bottom:28px; }
.landing-cards { display:flex; flex-direction:column; gap:16px; }
.landing-card { background:#fff; border-radius:18px; padding:28px 22px; box-shadow:0 2px 16px rgba(0,0,0,.06); text-align:center; }
.landing-card-icon { width:60px; height:60px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:1.5rem; margin:0 auto 16px; }
.landing-card strong { font-size:.97rem; font-weight:700; color:#1a1a2e; display:block; margin-bottom:8px; }
.landing-card p { font-size:.88rem; color:#6b6b7b; line-height:1.65; margin:0; }

/* Auth section */
.landing-auth-section { background:linear-gradient(145deg,#e8e0ff,#f0ebff,#f8f5ff); padding:44px 24px; display:flex; flex-direction:column; gap:32px; }
.landing-auth-headline { font-size:1.6rem; font-weight:800; color:#1a1a2e; line-height:1.25; margin-bottom:12px; }
.landing-auth-sub { font-size:.93rem; color:#5a5a72; line-height:1.65; margin-bottom:18px; }
.landing-auth-bullets { list-style:none; display:flex; flex-direction:column; gap:10px; font-size:.92rem; color:#2a2a3a; font-weight:600; }
.landing-auth-bullets li::before { content:''; }
.landing-auth-form-title { font-size:1.05rem; font-weight:800; color:#1a1a2e; margin-bottom:4px; }
.auth-card { background:#fff; border-radius:18px; padding:28px 24px; box-shadow:0 6px 24px rgba(0,0,0,.1); }
.auth-card-title { font-size:1.2rem; font-weight:800; margin-bottom:4px; }

/* Footer */
.landing-footer { background:#fff; text-align:center; padding:32px 24px; border-top:1px solid #ede8ff; }
.landing-footer strong { display:block; font-size:1.05rem; font-weight:800; color:#1a1a2e; margin-bottom:8px; }
.landing-footer p { font-size:.82rem; color:#9090aa; }

/* ── Responsive: side-by-side hero + cards on wider screens ───────────────── */
@media (min-width: 700px) {
  .landing-hero { flex-direction:row; align-items:flex-end; padding:60px 48px 0; gap:40px; justify-content:center; }
  .landing-hero-text { text-align:left; max-width:440px; flex-shrink:0; }
  .landing-sub { margin-left:0; margin-right:0; }
  .landing-phone-wrap { padding:0; }
  .landing-cards { flex-direction:row; }
  .landing-card { flex:1; }
  .landing-auth-section { flex-direction:row; align-items:flex-start; max-width:900px; margin:0 auto; padding:60px 48px; gap:48px; }
  .landing-auth-left { flex:1; }
  .auth-card { flex:1; }
  .landing-strip-icons { gap:20px; }
  .strip-icon { font-size:.78rem; }
}

.auth-card { background:var(--a-card); padding:32px 28px; }
.auth-card-title { font-size:1.2rem; font-weight:800; margin-bottom:4px; }
.auth-card h1 { font-size:1.4rem; margin-bottom:6px; }
.auth-card .sub { color:var(--a-muted); font-size:.9rem; margin-bottom:24px; }
.auth-toggle { display:flex; background:var(--a-bg); border-radius:999px; padding:4px; margin-bottom:24px; }
.auth-toggle-btn { flex:1; border:none; background:none; padding:9px; border-radius:999px; font-size:.9rem; cursor:pointer; color:var(--a-muted); font-weight:600; }
.auth-toggle-btn.active { background:#fff; color:var(--a-primary); box-shadow:0 1px 4px rgba(0,0,0,.12); }
.field { margin-bottom:18px; }
.field label { display:block; font-size:.83rem; font-weight:600; margin-bottom:6px; color:var(--a-text); }
.field input, .field textarea, .field select { width:100%; border:1.5px solid var(--a-border); border-radius:9px; padding:11px 14px; font-family:var(--font); font-size:.95rem; color:var(--a-text); background:#fff; outline:none; }
.field input:focus, .field textarea:focus, .field select:focus { border-color:var(--a-primary); }
.error-msg { color:var(--a-danger); font-size:.88rem; padding:10px 14px; background:#fdecea; border-radius:8px; margin-bottom:16px; display:none; }
.error-msg.show { display:block; }

.btn { display:inline-flex; align-items:center; justify-content:center; gap:7px; border:none; border-radius:999px; cursor:pointer; font-family:var(--font); font-weight:600; transition:opacity .15s; }
.btn:active { opacity:.8; }
.btn-primary   { background:var(--a-primary); color:#fff; padding:12px 24px; font-size:.95rem; }
.btn-secondary { background:#e8f0ef; color:var(--a-primary); padding:10px 20px; font-size:.88rem; }
.btn-danger    { background:#fdecea; color:var(--a-danger); padding:8px 16px; font-size:.85rem; }
.btn-ghost     { background:transparent; color:var(--a-primary); padding:8px 16px; font-size:.88rem; border:1.5px solid var(--a-primary); }
.btn-danger    { background:transparent; color:var(--a-danger); padding:8px 16px; font-size:.88rem; border:1.5px solid var(--a-danger); border-radius:10px; cursor:pointer; font-weight:600; }
.btn-full { width:100%; }
.btn-lg   { padding:15px 28px; font-size:1.05rem; border-radius:14px; }

.prop-list { display:flex; flex-direction:column; gap:12px; margin-top:20px; }
.admin-tip-banner { background:#f0eaff; border:1px solid #ddd5ff; border-radius:10px; padding:10px 14px; font-size:.85rem; color:#4a30b0; font-weight:500; margin-bottom:14px; }
.prop-card { background:var(--a-card); border-radius:14px; box-shadow:0 2px 12px rgba(0,0,0,.08); padding:16px 18px; display:flex; flex-direction:column; gap:10px; }
.prop-card-top { display:flex; align-items:center; gap:14px; }
.prop-icon    { font-size:28px; flex-shrink:0; }
.prop-info    { flex:1; min-width:0; }
.prop-name    { font-weight:700; font-size:1rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.prop-id      { font-size:.75rem; color:var(--a-muted); margin-top:2px; }
.prop-actions { display:flex; gap:8px; flex-wrap:wrap; }
.prop-actions .btn { font-size:.8rem; padding:8px 14px; }

#screen-edit { padding: 0; }
#edit-guide-container { padding: 20px; overflow-y: auto; }
.edit-top-actions { display:flex; gap:8px; margin-bottom:12px; flex-wrap:wrap; }

.save-bar { position:sticky; bottom:0; background:var(--a-bg); border-top:1px solid var(--a-border); padding:14px 20px; display:flex; align-items:center; gap:14px; }
.saved-msg { color:#16a34a; font-weight:600; font-size:.92rem; display:none; }
.saved-msg.show { display:inline; }

.back-link { display:inline-flex; align-items:center; gap:6px; color:var(--a-primary); font-weight:600; font-size:.9rem; cursor:pointer; background:none; border:none; padding:4px 0; margin-bottom:20px; font-family:var(--font); }
.remove-btn { background:none; border:none; color:var(--a-muted); cursor:pointer; font-size:.8rem; padding:4px 8px; border-radius:6px; font-family:var(--font); }
.remove-btn:hover { background:#fdecea; color:var(--a-danger); }

.modal-overlay { position:fixed; inset:0; background:rgba(0,0,0,.45); z-index:200; display:flex; align-items:flex-end; justify-content:center; animation:fadeIn .15s; }
.modal-overlay.hidden { display:none; }
.modal-sheet { background:#fff; border-radius:20px 20px 0 0; width:100%; max-width:500px; max-height:70vh; overflow-y:auto; padding:20px; animation:slideUp .2s ease-out; }
.modal-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; }
.modal-title { font-size:1rem; font-weight:700; }
.modal-close { background:#f0f2f5; border:none; border-radius:50%; width:30px; height:30px; cursor:pointer; font-size:1rem; display:flex; align-items:center; justify-content:center; }
.qr-modal-body { text-align:center; padding:8px 0 20px; }
.qr-property-name { font-size:1.1rem; font-weight:700; margin-bottom:16px; }
.qr-actions { display:flex; gap:10px; justify-content:center; margin-top:18px; flex-wrap:wrap; }

/* ── Responsive ──────────────────────────────────────────────────────────────*/
@media (max-width: 400px) {
  .tile-grid  { gap: 8px; }
  .grid-card  { padding: 16px 6px 18px; }
  .grid-card-icon-circle { width: 48px; height: 48px; font-size: 24px; }
  .grid-card-name { font-size: .76rem; }
  .grid-card-desc { font-size: .67rem; }
}

/* ── Repeat stay inbox (admin) ───────────────────────────────────────────────*/
#repeat-stay-inbox .form-card { background:var(--a-card); border:1px solid var(--a-border); border-radius:12px; padding:14px 16px; }

@media (max-width: 640px) {
  .prop-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
  .prop-actions .btn { width: 100%; text-align: center; font-size: .8rem; padding: 9px 6px; }
}

/* Owner page */
body.owner-body { background: var(--a-bg); font-family: var(--font); }
#owner-app { max-width: 680px; margin: 0 auto; padding: 0 0 60px; }
.stat-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; margin-top:20px; }
.stat-card { background:var(--a-card); border-radius:14px; box-shadow:0 2px 12px rgba(0,0,0,.08); padding:20px; }
.stat-value { font-size:2rem; font-weight:800; color:var(--a-primary); }
.stat-label { font-size:.82rem; color:var(--a-muted); margin-top:4px; }
.form-card  { background:var(--a-card); border-radius:14px; box-shadow:0 2px 12px rgba(0,0,0,.08); padding:22px; margin-bottom:14px; }
.type-table { width:100%; border-collapse:collapse; margin-top:8px; }
.type-table th, .type-table td { text-align:left; padding:10px 12px; border-bottom:1px solid var(--a-border); font-size:.9rem; }
.type-table th { color:var(--a-muted); font-weight:600; font-size:.78rem; text-transform:uppercase; }
.type-table td:last-child { font-weight:700; color:var(--a-primary); text-align:right; }
