/*
Theme Name: Orchard Home
Description: Orchard Home (orchardhome.com.sg) — design B. Lightweight, no page builder, PHP 8.x. Keeps all existing URLs and content.
Version: 1.0.2
Requires at least: 6.5
Requires PHP: 8.1
Text Domain: orchardhome
*/

:root {
  --bg: #12110F;
  --surface: #1C1A17;
  --surface-2: #2A2620;
  --line: #2E2A24;
  --line-2: #3A352D;
  --text: #F2EDE4;
  --text-2: #D6CFC3;
  --muted: #B8AFA2;
  --gold: #C9A86A;
  --gold-link: #D9BC82;
  --gold-hover: #EBD3A3;
  --stone: #EDE8E0;
  --ink: #1C1A17;
  --ink-2: #4A453E;
  --red: #C9182B;
  --serif: 'Bodoni Moda', Georgia, 'Times New Roman', serif;
  --sans: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --wrap: 1280px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.65;
}
img { max-width: 100%; height: auto; }
a { color: var(--gold-link); }
a:hover { color: var(--gold-hover); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.oh-wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.oh-skip { position: absolute; left: -9999px; top: 0; background: var(--gold); color: var(--bg); padding: 12px 16px; z-index: 100; }
.oh-skip:focus { left: 16px; top: 16px; }
.oh-eyebrow { margin: 0 0 16px; font-size: 14px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
.oh-h1 { margin: 0 0 20px; font-family: var(--serif); font-weight: 500; font-size: clamp(40px, 6vw, 72px); line-height: 1.05; }
.oh-h2 { margin: 0 0 20px; font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4vw, 48px); line-height: 1.1; }
.oh-lead { font-size: 20px; color: var(--text-2); max-width: 640px; margin: 0 0 32px; }
.oh-muted { color: var(--muted); }

/* Buttons */
.oh-btn { display: inline-block; padding: 16px 30px; font-weight: 600; letter-spacing: 0.03em; text-decoration: none; border: 1px solid transparent; font-size: 17px; line-height: 1.2; }
.oh-btn--gold { background: var(--gold); color: var(--bg); }
.oh-btn--gold:hover { background: var(--gold-hover); color: var(--bg); }
.oh-btn--line { border-color: var(--text); color: var(--text); }
.oh-btn--line:hover { border-color: var(--gold); color: var(--gold-hover); }
.oh-btn--ink { background: var(--ink); color: var(--text); }
.oh-btn--ink:hover { background: #000; color: var(--text); }
.oh-btns { display: flex; flex-wrap: wrap; gap: 16px; }

/* Header */
.oh-header { border-bottom: 1px solid var(--line); background: var(--bg); position: relative; z-index: 10; }
.oh-header__in { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; }
.oh-logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); }
.oh-logo:hover { color: var(--text); }
.oh-logo__mark { width: 40px; height: 40px; border-radius: 50%; background: var(--red); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 18px; flex: none; }
.oh-logo__text { font-family: var(--serif); font-size: 24px; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.oh-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 28px; }
.oh-nav a { color: var(--text); text-decoration: none; font-size: 15px; font-weight: 500; letter-spacing: 0.04em; }
.oh-nav a:hover, .oh-nav .current-menu-item > a { color: var(--gold-hover); }
.oh-header__cta { border: 1px solid var(--gold); color: var(--text); text-decoration: none; padding: 11px 20px; font-size: 15px; font-weight: 600; white-space: nowrap; }
.oh-header__cta:hover { background: var(--gold); color: var(--bg); }
.oh-mnav { display: none; }
.oh-mnav summary { list-style: none; cursor: pointer; border: 1px solid var(--line-2); padding: 10px 14px; font-size: 15px; font-weight: 600; }
.oh-mnav summary::-webkit-details-marker { display: none; }
.oh-mnav[open] .oh-mnav__panel { display: block; }
.oh-mnav__panel { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); border-bottom: 1px solid var(--line); padding: 8px 24px 24px; }
.oh-mnav__panel ul { list-style: none; margin: 0; padding: 0; }
.oh-mnav__panel a { display: block; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--text); text-decoration: none; font-size: 17px; }
@media (max-width: 1020px) {
  .oh-nav, .oh-header__cta { display: none; }
  .oh-mnav { display: block; }
}

/* Hero */
.oh-hero { position: relative; min-height: 600px; background: var(--surface-2) center / cover no-repeat; display: flex; align-items: flex-end; }
.oh-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(18,17,15,0.25) 0%, rgba(18,17,15,0.85) 100%); }
.oh-hero > .oh-wrap { position: relative; width: 100%; padding-top: 120px; padding-bottom: 80px; }
.oh-hero--page { min-height: 380px; }
.oh-hero--page > .oh-wrap { padding-bottom: 56px; }
.oh-crumbs { margin: 0 0 16px; font-size: 14px; color: var(--muted); }
.oh-crumbs a { color: var(--muted); }

/* Sections */
.oh-section { padding: 88px 0; }
.oh-section--line { border-top: 1px solid var(--line); }
.oh-section--stone { background: var(--stone); color: var(--ink); }
.oh-section--stone .oh-eyebrow { color: #7A5C22; }
.oh-section--stone a { color: #6B4F1C; }
.oh-section--surface { background: var(--surface); }
.oh-section__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 36px; }
.oh-section__head .oh-h2 { margin: 0; }

/* Area grid */
.oh-areas { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.oh-area { background: var(--bg); padding: 36px 28px; }
.oh-area__d { display: block; font-size: 13px; letter-spacing: 0.16em; color: var(--gold); }
.oh-area__n { display: block; font-family: var(--serif); font-size: 32px; margin: 8px 0; }
.oh-area__s { font-size: 15px; color: var(--muted); }

/* Steps (owners) */
.oh-split { display: flex; flex-wrap: wrap; gap: 64px; align-items: center; }
.oh-split > * { flex: 1 1 440px; min-width: 0; }
.oh-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; }
.oh-step { border-top: 2px solid var(--ink); padding-top: 16px; }
.oh-step__n { font-family: var(--serif); font-size: 32px; }
.oh-step p { margin: 8px 0 0; font-size: 16px; }

/* Cards */
.oh-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 32px 28px; }
.oh-card { display: block; text-decoration: none; color: var(--text); }
.oh-card:hover { color: var(--text); }
.oh-card:hover .oh-card__t { color: var(--gold-hover); }
.oh-card__img { aspect-ratio: 4 / 3; background: var(--surface-2); overflow: hidden; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 14px; }
.oh-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.oh-card__tag { display: inline-block; margin: 18px 0 6px; font-size: 12px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold); }
.oh-card__t { margin: 18px 0 4px; font-family: var(--serif); font-size: 26px; font-weight: 500; line-height: 1.2; }
.oh-card__tag + .oh-card__t { margin-top: 0; }
.oh-card__m { margin: 0; font-size: 15px; color: var(--muted); }

/* News list */
.oh-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.oh-list li { border-bottom: 1px solid var(--line); }
.oh-list a { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 20px 0; color: var(--text); text-decoration: none; }
.oh-list a:hover { color: var(--gold-hover); }
.oh-list__t { font-family: var(--serif); font-size: 22px; flex: 1 1 520px; }
.oh-list__d { font-size: 14px; color: var(--muted); }

/* About */
.oh-about__img { flex: 0 1 360px !important; aspect-ratio: 4 / 5; background: var(--surface-2); overflow: hidden; }
.oh-about__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.oh-facts { list-style: none; margin: 0; padding: 0; font-size: 15px; color: var(--muted); }
.oh-facts li { padding: 6px 0; }

/* Page layout */
.oh-main { padding: 72px 0 96px; }
.oh-layout { display: flex; flex-wrap: wrap; gap: 56px; }
.oh-layout__main { flex: 999 1 640px; min-width: 0; }
.oh-layout__side { flex: 1 1 300px; min-width: 0; }
.oh-panel { background: var(--stone); color: var(--ink); padding: 32px; position: sticky; top: 24px; }
.oh-panel h2 { margin: 0 0 8px; font-family: var(--serif); font-weight: 500; font-size: 28px; }
.oh-panel p { margin: 0 0 20px; font-size: 16px; color: var(--ink-2); }
.oh-panel small { display: block; margin-top: 20px; font-size: 13px; color: var(--ink-2); }

/* Facts strip (property / condo) */
.oh-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); border-bottom: 1px solid var(--line); }
.oh-stat { padding: 28px 0; }
.oh-stat__l { display: block; font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.oh-stat__v { font-family: var(--serif); font-size: 30px; color: var(--gold); }

/* Gallery */
.oh-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 0 0 48px; }
.oh-gallery a { display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface-2); }
.oh-gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }
.oh-gallery a:first-child { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
.oh-video { position: relative; aspect-ratio: 16 / 9; margin: 0 0 48px; background: var(--surface-2); }
.oh-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Agent box */
.oh-agent { display: flex; gap: 20px; align-items: center; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 24px 0; margin: 48px 0 0; }
.oh-agent img { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; }
.oh-agent p { margin: 0; font-size: 15px; color: var(--muted); }
.oh-agent strong { display: block; font-family: var(--serif); font-size: 24px; font-weight: 500; color: var(--text); }

/* Prose (page / post content, incl. legacy markup) */
.oh-prose { font-size: 18px; color: var(--text-2); }
.oh-prose > *:first-child { margin-top: 0; }
.oh-prose h1, .oh-prose h2, .oh-prose h3, .oh-prose h4 { font-family: var(--serif); font-weight: 500; color: var(--text); line-height: 1.2; margin: 1.6em 0 0.6em; }
.oh-prose h1 { font-size: 40px; } .oh-prose h2 { font-size: 34px; } .oh-prose h3 { font-size: 26px; } .oh-prose h4 { font-size: 21px; }
.oh-prose p, .oh-prose ul, .oh-prose ol { margin: 0 0 1.1em; }
.oh-prose li { margin-bottom: 0.35em; }
.oh-prose strong, .oh-prose b { color: var(--text); }
.oh-prose blockquote { margin: 1.5em 0; padding: 4px 0 4px 24px; border-left: 2px solid var(--gold); color: var(--text); font-style: italic; }
.oh-prose table { width: 100%; border-collapse: collapse; margin: 0 0 1.5em; font-size: 16px; display: block; overflow-x: auto; }
.oh-prose th, .oh-prose td { padding: 12px 16px; border: 1px solid var(--line-2); text-align: left; vertical-align: top; }
.oh-prose th, .oh-prose thead td { color: var(--muted); font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 600; }
.oh-prose img { display: block; margin: 0 0 1.2em; }
.oh-prose figure { margin: 0 0 1.5em; }
.oh-prose figcaption, .oh-prose .wp-caption-text { font-size: 14px; color: var(--muted); margin-top: 6px; }
.oh-prose iframe { max-width: 100%; }
.oh-prose hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.oh-prose .alignleft { float: left; margin: 0 24px 16px 0; max-width: 50%; }
.oh-prose .alignright { float: right; margin: 0 0 16px 24px; max-width: 50%; }
.oh-prose .aligncenter { margin-left: auto; margin-right: auto; }
.oh-prose::after { content: ""; display: table; clear: both; }
@media (max-width: 640px) { .oh-prose .alignleft, .oh-prose .alignright { float: none; margin: 0 0 16px; max-width: 100%; } }

/* Legacy Bootstrap 3 classes used inside old page content */
.oh-prose .row { display: flex; flex-wrap: wrap; margin: 0 -12px; }
.oh-prose [class*="col-xs-"], .oh-prose [class*="col-sm-"], .oh-prose [class*="col-md-"], .oh-prose [class*="col-lg-"] { width: 100%; padding: 0 12px; }
@media (min-width: 768px) {
  .oh-prose .col-sm-3 { width: 25%; } .oh-prose .col-sm-4 { width: 33.333%; } .oh-prose .col-sm-6 { width: 50%; } .oh-prose .col-sm-8 { width: 66.666%; } .oh-prose .col-sm-9 { width: 75%; } .oh-prose .col-sm-12 { width: 100%; }
}
@media (min-width: 992px) {
  .oh-prose .col-md-3, .oh-prose .col-lg-3 { width: 25%; } .oh-prose .col-md-4, .oh-prose .col-lg-4 { width: 33.333%; } .oh-prose .col-md-6, .oh-prose .col-lg-6 { width: 50%; } .oh-prose .col-md-8, .oh-prose .col-lg-8 { width: 66.666%; } .oh-prose .col-md-9, .oh-prose .col-lg-9 { width: 75%; } .oh-prose .col-md-12, .oh-prose .col-lg-12 { width: 100%; }
}
.oh-prose .img-responsive { max-width: 100%; height: auto; }
.oh-prose .pull-left { float: left; } .oh-prose .pull-right { float: right; }
.oh-prose .text-center { text-align: center; } .oh-prose .text-right { text-align: right; }
.oh-prose .clearfix::after { content: ""; display: table; clear: both; }
.oh-prose .table { display: table; }
.oh-prose .btn { display: inline-block; padding: 12px 22px; border: 1px solid var(--gold); color: var(--text); text-decoration: none; }

body.page-template-fullwidth .oh-layout__main { flex-basis: 760px; }

/* Pagination */
.oh-pager { margin-top: 48px; }
.oh-pager .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.oh-pager .page-numbers { display: inline-block; min-width: 44px; padding: 10px 14px; border: 1px solid var(--line-2); color: var(--text); text-decoration: none; text-align: center; }
.oh-pager .page-numbers.current { background: var(--gold); color: var(--bg); border-color: var(--gold); }

/* Footer */
.oh-footer { border-top: 1px solid var(--line); font-size: 15px; color: var(--muted); }
.oh-footer__in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; padding-top: 48px; padding-bottom: 48px; }
.oh-footer__brand { font-family: var(--serif); font-size: 22px; color: var(--text); letter-spacing: 0.06em; text-transform: uppercase; }
.oh-footer p { margin: 8px 0 0; }
.oh-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 24px; }
.oh-footer a { color: var(--muted); }
.oh-footer a:hover { color: var(--gold-hover); }

.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

/* Shortcode fallbacks */
.oh-prose .oh-sc-column { margin: 0 0 1.2em; }
.oh-prose .oh-sc-cards { margin: 1.5em 0; }
.oh-prose .oh-sc-cards .oh-card__t { margin-top: 18px; }
