:root {
  --bg: #f3f1ec;
  --card: #f8f7f3;
  --surface: #ffffff;
  --border: #e6e3dc;
  --ink: #111614;
  --ink-2: #4a504d;
  --muted: #5f6562;            /* 5.2:1 on --bg (WCAG 1.4.3) */
  --field-border: #7d827f;     /* 3.4:1 on --bg (WCAG 1.4.11) */
  --line: #e3e5ea;
  --dark: #0e1916;
  --green: #22a447;
  --green-bg: #e3f5e6;
  --amber-bg: #fff1cc;
  --amber: #7a5000;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(17, 22, 20, .04), 0 4px 16px rgba(17, 22, 20, .04);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 110px; } /* keep focused/anchored content clear of the sticky header (WCAG 2.4.11) */
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* Accessibility */
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.final-cta :focus-visible { outline-color: #fff; }
.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  padding: 12px 18px; border-radius: 8px; background: var(--dark); color: #fff; font-weight: 600;
}
.skip-link:focus { top: 12px; }
#main:focus { outline: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .btn:hover, .card:hover { transform: none; }
}

.container { width: min(1280px, 100% - 48px); margin-inline: auto; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 22px; border-radius: 999px;
  font-size: 15px; font-weight: 600; white-space: nowrap;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-dark { background: var(--dark); color: #fff; }
.btn-dark:hover { background: #1d2c28; box-shadow: 0 6px 18px rgba(14, 25, 22, .2); }
.btn-ghost { border: 1px solid var(--border); background: var(--card); }
.btn-ghost:hover { background: #fff; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 10; background: rgba(243, 241, 236, .88); backdrop-filter: blur(10px); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 92px; gap: 24px; }
.logo { font-size: 28px; font-weight: 700; letter-spacing: -.03em; }
.nav-links { display: flex; gap: 44px; font-size: 16px; font-weight: 500; color: var(--ink-2); }
.nav-links a { position: relative; padding: 6px 0; }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-links a.active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--ink); border-radius: 2px;
}
.nav-actions { display: flex; align-items: center; gap: 14px; }
.nav-links .nav-login { display: none; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--ink); }

/* Hero */
.hero { display: grid; grid-template-columns: 1fr 1.05fr; gap: 56px; align-items: center; padding: 28px 0 56px; }
.eyebrow { margin: 0 0 18px; font-size: 14px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.hero h1 { margin: 0 0 32px; font-size: clamp(44px, 6vw, 84px); line-height: 1.02; font-weight: 700; letter-spacing: -.045em; max-width: 11ch; }
.lead { margin: 0; max-width: 34ch; font-size: clamp(17px, 1.6vw, 21px); color: var(--ink-2); line-height: 1.6; }
.hero-media { position: relative; border-radius: 22px; overflow: hidden; aspect-ratio: 16 / 10; background: #cfd8c6; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-badge {
  position: absolute; top: 5%; right: 2.5%;
  display: flex; align-items: center; gap: 14px;
  padding: 16px 22px; background: #fff; border-radius: 14px; box-shadow: var(--shadow);
  font-size: 15px; font-weight: 500; line-height: 1.4;
}

/* Apps grid */
.apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding-bottom: 32px; }
.card {
  display: flex; flex-direction: column; min-width: 0;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px 22px 22px; box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.card:hover { transform: translateY(-3px); background: #fbfaf7; box-shadow: 0 12px 32px rgba(17, 22, 20, .08); }
.card:hover .card-arrow { background: var(--dark); color: #fff; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 18px; }
.card-icon {
  display: grid; place-items: center; width: 56px; height: 56px;
  background: #ebe9e3; border-radius: 12px;
}
.card-icon svg { width: 28px; height: 28px; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card-icon svg.filled { fill: var(--ink); stroke: none; }
.card-icon svg .fill { fill: var(--ink); stroke: none; }
.card-arrow {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: #ebe9e3; font-size: 18px; transition: background .2s ease, color .2s ease;
}
.card h2 { margin: 0 0 6px; font-size: 21px; font-weight: 700; letter-spacing: -.02em; line-height: 1.3; }
.card > p { margin: 0 0 20px; color: var(--ink-2); font-size: 16px; line-height: 1.5; max-width: 34ch; }

/* Previews (shared) */
.preview {
  margin-top: auto; min-height: 184px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--border); overflow: hidden;
}
.lines { flex: 1; min-width: 0; display: grid; gap: 2px; line-height: 1.3; }
.lines b, .lines small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lines b { font-size: 12px; font-weight: 600; color: var(--ink); }
.lines small { font-size: 11px; color: var(--muted); }
.pill { font-size: 12px; font-weight: 600; padding: 4px 12px; border-radius: 999px; }
.pill-green { background: var(--green-bg); color: #1b7a37; }
.pill-amber { background: var(--amber-bg); color: var(--amber); }
.avatar { flex: none; width: 30px; height: 30px; border-radius: 50%; background: #c7a589; }
.avatar.a1 { background: radial-gradient(circle at 50% 38%, #b98767 0 30%, transparent 31%), radial-gradient(circle at 50% 110%, #2c3a44 0 48%, #e7e3dc 49%); }
.avatar.a2 { background: radial-gradient(circle at 50% 38%, #a8765a 0 30%, transparent 31%), radial-gradient(circle at 50% 110%, #5a4a3c 0 48%, #e5e0d8 49%); }
.avatar.a3 { background: radial-gradient(circle at 50% 38%, #c08f6c 0 30%, transparent 31%), radial-gradient(circle at 50% 110%, #3d4f45 0 48%, #e8e4dc 49%); }

/* Residents society */
.preview-society { display: grid; grid-template-columns: 0.75fr 1fr; }
.mini-menu { list-style: none; margin: 0; padding: 14px 12px; display: grid; gap: 10px; font-size: 12px; color: var(--ink-2); }
.mini-menu li { display: flex; align-items: center; gap: 10px; }
.mini-menu li i { width: 12px; height: 12px; border-radius: 3px; background: var(--ink); }
.mini-menu li i.dot-g { background: var(--green); }
.society-photo { position: relative; }
.society-photo img { width: 100%; height: 100%; object-fit: cover; }
.society-tag {
  position: absolute; left: 6%; right: 6%; bottom: 8%;
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; background: #fff; border-radius: 8px;
  font-size: 12.5px; font-weight: 600; line-height: 1.35; box-shadow: var(--shadow);
}
.society-tag b { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--dark); color: #fff; font-size: 14px; }

/* Purchase */
.preview-purchase { display: grid; grid-template-columns: 0.32fr 1fr; background: #f3f2ee; }
.side-lines { padding: 16px 10px; display: grid; gap: 4px; align-content: start; font-size: 11px; color: var(--ink-2); }
.side-lines span { padding: 5px 6px; border-radius: 5px; }
.side-lines .on { background: #fff; color: var(--ink); font-weight: 600; }
.pr-panel { background: #fff; border-left: 1px solid var(--border); padding: 14px 16px; font-size: 12px; }
.pr-panel strong { display: block; font-size: 13px; margin-bottom: 10px; }
.tabs { display: flex; gap: 22px; border-bottom: 1px solid var(--border); margin-bottom: 6px; color: var(--ink-2); }
.tabs span { padding-bottom: 8px; }
.tabs .on { color: var(--ink); border-bottom: 2px solid var(--ink); }
.pr-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f0efeb; }
.pr-row:last-child { border-bottom: 0; }

/* Split previews (image/left + content/right) */
.preview-split { display: grid; grid-template-columns: 0.85fr 1fr; gap: 16px; padding: 10px; align-items: center; }
.thumb { width: 100%; height: 164px; object-fit: cover; border-radius: 8px; }
.checklist, .stock { display: grid; gap: 14px; padding-right: 8px; }
.checklist div, .stock div { display: flex; align-items: center; gap: 12px; position: relative; }
.stock { gap: 16px; font-size: 12px; }
.stock .item { flex: 1; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stock b { font-size: 12px; font-weight: 600; }
.check { flex: none; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--green); color: #fff; font-size: 12px; font-weight: 700; }
.cam { position: absolute; right: 0; bottom: -30px; width: 28px; height: 28px; padding: 5px; border: 1px solid var(--border); border-radius: 6px; fill: none; stroke: var(--ink); stroke-width: 1.8; }
.sd { flex: none; width: 12px; height: 12px; border-radius: 50%; }
.sd.g { background: var(--green); } .sd.y { background: #f2a516; } .sd.o { background: #f26b1d; } .sd.r { background: #e5372b; }
.video-thumb { height: 164px; border-radius: 8px; overflow: hidden; }
.video-thumb { position: relative; }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; }
.video-thumb .play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255, 255, 255, .92); box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}
.video-thumb .play::before { content: ""; margin-left: 3px; border-left: 12px solid var(--ink); border-top: 8px solid transparent; border-bottom: 8px solid transparent; }
.review { display: grid; gap: 6px; padding-right: 8px; }
.review .stars { color: #f2a516; font-size: 13px; letter-spacing: 1px; }
.review q { font-size: 13px; line-height: 1.45; color: var(--ink); quotes: "“" "”"; }
.review small { font-size: 11px; color: var(--muted); }

/* Vendor list */
.preview-list { padding: 8px 20px; display: grid; align-content: center; }
.vrow { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid #f0efeb; }
.vrow:last-child { border-bottom: 0; }
.initials { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #eceef1; color: var(--muted); font-size: 11px; font-weight: 600; }
.status { flex: none; display: flex; align-items: center; gap: 6px; margin-left: 12px; font-size: 11px; font-weight: 500; color: #1b7a37; }
.status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }

/* WhatsApp chat */
.preview-chat { background: #f2f4f6; padding: 22px 20px; display: grid; gap: 18px; align-content: center; }
.chat-in { display: flex; align-items: center; gap: 12px; }
.wa { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #25d366; }
.wa svg { width: 24px; height: 24px; }
.bubble { max-width: 72%; padding: 9px 12px; background: #fff; border-radius: 4px 10px 10px 10px; font-size: 12px; line-height: 1.4; color: var(--ink); }
.bubble.out { justify-self: end; max-width: 78%; background: #d4f3d8; border-radius: 10px 4px 10px 10px; }

/* Invoice */
.preview-invoice { padding: 22px 20px; display: grid; gap: 22px; align-content: start; min-height: 150px; }
.inv-head { display: flex; justify-content: space-between; align-items: center; }
.inv-head strong { font-size: 17px; }
.inv-rows { margin: 0; display: grid; gap: 8px; font-size: 12px; }
.inv-rows div { display: flex; justify-content: space-between; gap: 12px; }
.inv-rows dt { color: var(--muted); }
.inv-rows dd { margin: 0; font-weight: 600; }

/* HR calendar */
.calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px 2px; place-items: center; font-size: 10px; color: var(--ink-2); }
.calendar span { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; }
.calendar .dow { color: var(--muted); font-weight: 600; }
.calendar .today { background: #1d4ed8; color: #fff; font-weight: 600; }
.calendar .leave { background: #e6eefc; color: #2f5bd8; }
.people { display: grid; gap: 14px; padding-left: 14px; border-left: 1px solid var(--border); }
.people div { display: flex; align-items: center; gap: 12px; }

/* CTA */
.cta {
  display: grid; grid-template-columns: 1fr 1fr; align-items: center;
  background: #ebe8e1; border-radius: 20px; overflow: hidden; margin: 8px 0 40px;
}
.cta-copy { padding: 40px 48px; }
.cta h2 { margin: 0 0 8px; font-size: clamp(28px, 3vw, 40px); letter-spacing: -.03em; line-height: 1.15; }
.cta p { margin: 0 0 26px; color: var(--ink-2); font-size: 17px; }
.cta-media { height: 100%; min-height: 220px; }
.cta-media img { width: 100%; height: 100%; object-fit: cover; }

/* Footer */
.site-footer { padding: 32px 0 32px; font-size: 14px; }
.footer-top, .footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px 32px; }
.footer-top { align-items: flex-start; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.footer-bottom { align-items: center; padding-top: 20px; }
.footer-about { display: grid; gap: 6px; }
.footer-about .logo { font-size: 26px; }
.footer-about p, .footer-bottom p { margin: 0; }
.footer-company { color: var(--ink); }
.footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; color: var(--ink-2); }
.footer-links a { padding: 4px 0; }
.footer-links a:hover { color: var(--ink); }
.muted { color: var(--muted); }

/* Responsive */
@media (max-width: 1100px) {
  .apps { grid-template-columns: repeat(2, 1fr); }
  .nav-links { gap: 28px; }
}
@media (max-width: 860px) {
  .menu-toggle { display: block; }
  .nav-actions .btn-ghost { display: none; }
  .nav-links {
    display: none; position: absolute; top: 72px; left: 16px; right: 16px;
    flex-direction: column; gap: 4px; padding: 12px;
    background: #fff; border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,.08);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px; border-radius: 8px; }
  .nav-links a:hover { background: var(--bg); }
  .nav-links a.active::after { display: none; }
  .nav-links .nav-login { display: block; margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--border); border-radius: 0 0 8px 8px; font-weight: 600; color: var(--ink); }
  .nav { height: 72px; }
  .hero { grid-template-columns: 1fr; gap: 32px; padding-top: 16px; }
  .cta { grid-template-columns: 1fr; }
  .cta-copy { padding: 32px 24px; }
}
@media (max-width: 640px) {
  .container { width: calc(100% - 32px); }
  .apps { grid-template-columns: minmax(0, 1fr); }
  .logo { font-size: 24px; }
  .nav-actions .btn-dark { padding: 9px 16px; font-size: 14px; }
  .apps { grid-template-columns: 1fr; }
  .hero-badge { padding: 10px 14px; font-size: 13px; gap: 10px; }
}

/* Very narrow screens / 400% zoom: keep everything within 320px (WCAG 1.4.10, 1.4.12) */
@media (max-width: 480px) {
  .btn { white-space: normal; text-align: center; justify-content: center; }
  .nav { gap: 10px; }
  .nav-actions { gap: 6px; }
  .logo { font-size: 22px; }
  .nav-actions .btn-dark { padding: 8px 14px; font-size: 14px; }
  .nav-actions .btn-dark span { display: none; }
  .menu-toggle { padding: 6px; }
}
