/* Shared JomLepak brand accents; status colors retain their meaning. */
:root, [data-bs-theme=light] {
  --primary: #c94b0a;
  --primary-dark: #a83b06;
  --primary-soft: #fff3eb;
  --blue: #c94b0a;
  --tblr-primary: #c94b0a;
  --tblr-primary-rgb: 201, 75, 10;
  --tblr-link-color: #c94b0a;
  --tblr-link-hover-color: #a83b06;
  --tblr-link-color-rgb: 201, 75, 10;
  --tblr-link-hover-color-rgb: 168, 59, 6;
}
.btn-primary {
  --tblr-btn-bg: #c94b0a;
  --tblr-btn-border-color: #c94b0a;
  --tblr-btn-hover-bg: #a83b06;
  --tblr-btn-hover-border-color: #a83b06;
  --tblr-btn-active-bg: #a83b06;
  --tblr-btn-active-border-color: #a83b06;
  --tblr-btn-disabled-bg: #c94b0a;
  --tblr-btn-disabled-border-color: #c94b0a;
  --tblr-btn-color: #fff;
  --tblr-btn-hover-color: #fff;
  --tblr-btn-active-color: #fff;
  --tblr-btn-focus-shadow-rgb: 201, 75, 10;
  background-color: #c94b0a;
  border-color: #c94b0a;
}
.btn-primary:hover, .btn-primary:active { background-color: #a83b06; border-color: #a83b06; }
.btn-outline-primary {
  color: #c94b0a;
  border-color: #c94b0a;
  --tblr-btn-hover-bg: #c94b0a;
  --tblr-btn-active-bg: #a83b06;
}
.btn-outline-primary:hover, .btn-outline-primary:active { color: #fff; background: #c94b0a; border-color: #c94b0a; }
.form-control:focus, .form-select:focus { border-color: #e0956c; box-shadow: 0 0 0 .25rem rgba(201, 75, 10, .15); }
.form-check-input:checked { background-color: #c94b0a; border-color: #c94b0a; }
.page-item.active .page-link { background-color: #c94b0a; border-color: #c94b0a; color: #fff; }
.brand-mark.has-logo, .brand-image.has-logo, .auth-card-logo .brand-mark.has-logo { background: #fff; border: 0; border-radius: 0; }
.brand-mark.has-logo img, .brand-image.has-logo img { object-fit: contain; }
.android-app-prompt__install:hover { background: #a83b06; border-color: #a83b06; }
.android-app-prompt__continue { color: #c94b0a; border-color: #c94b0a; }

/* Shared full-width layout and flat surfaces, matching the home page. */
:root {
  --social-bg: #f5f6f8;
  --lte-body: #f5f6f8;
  --surface: #fff;
  --surface-soft: #f7f7f8;
  --text: #20252c;
  --muted: #65707d;
  --line: #dce1e7;
  --shadow: 0 4px 16px rgba(32, 37, 44, .02);
  --page-gutter: clamp(20px, 4vw, 64px);
}
body, body.admin-login-body, body.bos-adminlte {
  margin: 0;
  background: #f5f6f8;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
/* Apply square corners to controls and panels, preserving avatar/circle indicators. */
body :is(button, input:not([type=radio]):not([type=checkbox]), textarea, select,
  .btn, .card, .panel, .badge, .alert, .dropdown-menu, .modal-content,
  [class$="-card"], [class*="-card "], [class$="-panel"], [class*="-panel "],
  [class$="-button"], [class*="-button "], .primary-action, .secondary-action,
  .rail-link, .nav-link, .page-link, .admin-login-layout, .admin-login-visual,
  .brand-mark, .brand-image, .auth-clean-layout, .login-alert, .small-box,
  .info-box, .event-date-badge, .post-media, .post-media img) {
  border-radius: 0 !important;
}
body :is(.social-shell, .events-shell, .group-shell, .profile-shell,
  .notifications-shell, .policy-shell) {
  width: 100%;
  max-width: none;
  margin-inline: 0;
  padding: 28px var(--page-gutter) 40px;
  min-width: 0;
}
body .social-shell { grid-template-columns: 260px minmax(0, 1fr) 300px; }
body .social-topbar { width: 100%; padding-inline: var(--page-gutter); background: #fff; backdrop-filter: none; }
body :is(.policy-card, .profile-card, .post-card, .event-card, .group-card,
  .admin-form-panel, .card, .admin-login-card) { box-shadow: var(--shadow); }
body :is(.social-shell, .events-shell, .group-shell, .profile-shell,
  .notifications-shell, .opportunity-page-grid) > * { min-width: 0; }
body .policy-card { padding: clamp(20px, 3vw, 40px); }
body .policy-card :is(p, li) { max-width: 90ch; }
body .site-legal-footer {
  width: 100%; max-width: none; margin-inline: 0;
  border-top: 1px solid var(--line); background: #fff;
  padding: 24px var(--page-gutter);
}
body.admin-login-body .admin-login-shell { width: 100%; padding: 40px var(--page-gutter); }
body.admin-login-body .admin-login-layout {
  display: grid;
  width: 100%; max-width: none; min-height: 0;
  border: 1px solid var(--line); box-shadow: var(--shadow); background: #fff;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
body.admin-login-body .auth-clean-layout { grid-template-columns: minmax(0, 1fr); }
body.admin-login-body .admin-login-card {
  min-width: 0; padding: clamp(24px, 4vw, 64px);
  box-shadow: none; border: 0; background: #fff;
}
body.admin-login-body .admin-login-card > * {
  width: 100%; max-width: 560px; margin-inline: auto;
}
body.admin-login-body .admin-login-card > .auth-card-logo { width: auto; }
body.admin-login-body .admin-login-visual {
  background: #f5f6f8; color: var(--text);
  padding: clamp(24px, 4vw, 64px);
  border-right: 1px solid var(--line);
  align-content: center; gap: 40px; text-align: center;
}
body.admin-login-body .admin-login-brand { justify-self: center; color: var(--text); }
body.admin-login-body .admin-login-copy :is(h1, p) { margin-inline: auto; color: var(--text); }
body.admin-login-body .admin-login-copy > span { color: var(--primary); }
body.admin-login-body .admin-login-copy p { color: var(--muted); }
body.bos-adminlte .content { padding: 28px var(--page-gutter) 40px; }
body.bos-adminlte .content > .container-fluid { width: 100%; max-width: none; }
@media (max-width: 1180px) {
  body .social-shell { grid-template-columns: 240px minmax(0, 1fr); }
}
@media (max-width: 820px) {
  :root { --page-gutter: 20px; }
  body .social-shell { grid-template-columns: minmax(0, 1fr); }
  body :is(.social-shell, .events-shell, .group-shell, .profile-shell,
    .notifications-shell, .policy-shell) { padding-block: 20px 32px; }
  body.admin-login-body .admin-login-shell { padding: 24px var(--page-gutter); }
  body.admin-login-body .admin-login-layout { grid-template-columns: minmax(0, 1fr); }
  body.admin-login-body .admin-login-visual { border-right: 0; border-bottom: 1px solid var(--line); padding: 24px; }
  body.admin-login-body .admin-login-card { padding: 24px 20px; }
  body.bos-adminlte .content { padding: 20px var(--page-gutter) 32px; }
}

body .policy-card a { color: var(--primary); }
body .policy-card a:hover { color: var(--primary-dark); }

/* Social navigation and feed hierarchy. */
body .social-topbar {
  min-height: 68px;
  gap: 16px;
  box-shadow: 0 1px 3px rgba(32, 37, 44, .06);
  grid-template-columns: auto minmax(0, 1fr) auto;
}
body .social-topbar:has(> .topbar-search) {
  grid-template-columns: auto minmax(160px, 240px) minmax(0, 1fr) auto;
}
body .topbar-search input { background: #f0f2f5; height: 42px; font-size: 14px; }
body .topbar-tabs { display: flex; gap: 4px; align-self: stretch; min-width: 0; }
body .topbar-tabs a {
  width: auto; min-width: 54px; max-width: 104px; flex: 1;
  height: 54px; align-content: center; gap: 3px;
  border-bottom: 3px solid transparent;
  font-size: 10px; font-weight: 600; text-decoration: none;
}
body .topbar-tabs a:hover { background: #f0f2f5; color: var(--text); }
body .topbar-tabs a.is-active { background: transparent; color: var(--primary); border-bottom-color: var(--primary); }
body .topbar-tabs svg { width: 23px; height: 23px; }
body .social-shell { gap: 28px; padding-top: 24px; }
body .social-shell :is(.left-rail, .right-rail) { position: sticky; top: 96px; }
body .social-shell .left-rail .user-card { background: transparent; border: 0; box-shadow: none; padding: 12px 8px; }
body .social-shell .rail-link { min-height: 48px; padding: 10px 12px; font-size: 14px; font-weight: 600; }
body .social-shell .rail-link:hover { background: #e9ebee; }
body .social-shell .rail-link.is-current { background: var(--primary-soft); color: var(--primary); border-left: 3px solid var(--primary); }
body :is(.feed-list, .feed-column) { gap: 18px; }
body .post-card { border: 1px solid var(--line); background: #fff; box-shadow: 0 1px 2px rgba(32, 37, 44, .06); }
body .post-header { padding: 16px; }
body .post-header strong { font-size: 14px; font-weight: 650; }
body .post-body { font-size: 15px; line-height: 1.65; }
body .post-actions { border-top: 1px solid var(--line); }
body .post-actions button { min-height: 42px; font-size: 13px; font-weight: 600; }
body .post-actions button:hover { background: #f0f2f5; }
body .composer-form textarea { background: #f0f2f5; font-size: 15px; }
body .social-shell .right-rail .section-title { color: var(--muted); font-size: 15px; }
body .group-badge { background: var(--primary-soft); color: var(--primary); }
body.admin-login-body .social-login-layout {
  border: 0; background: transparent; box-shadow: none;
  grid-template-columns: minmax(0, 1fr) minmax(380px, 40%);
  gap: clamp(32px, 5vw, 80px); align-items: center;
}
.login-intro { text-align: center; padding: 32px 0; }
.login-intro-brand { display: inline-flex; align-items: center; gap: 16px; color: var(--primary); text-decoration: none; font-size: clamp(38px, 4.5vw, 64px); font-weight: 750; letter-spacing: -2px; }
.login-intro-brand img { object-fit: contain; }
.login-intro > p { max-width: 440px; margin: 18px auto 0; font-size: 22px; line-height: 1.5; color: var(--text); }
body.admin-login-body .social-login-layout .admin-login-card { border: 1px solid var(--line); padding: 32px; box-shadow: 0 2px 8px rgba(32, 37, 44, .06); }
body.admin-login-body .social-login-layout .auth-card-logo { display: none; }
@media (max-width: 1180px) {
  body .social-topbar:has(> .topbar-search) { grid-template-columns: auto minmax(0, 1fr) auto; }
  body .social-topbar:has(> .topbar-search) .topbar-tabs { grid-column: 1 / -1; grid-row: 2; justify-content: center; }
  body .social-shell :is(.left-rail, .right-rail) { top: 150px; }
}
@media (max-width: 820px) {
  body .social-topbar, body .social-topbar:has(> .topbar-search) { grid-template-columns: auto minmax(0, 1fr); gap: 4px 12px; padding-block: 8px 0; }
  body .social-topbar .topbar-tabs { display: flex; grid-column: 1 / -1; grid-row: 2; overflow-x: auto; justify-content: flex-start; }
  body .topbar-tabs a { min-width: 48px; height: 52px; font-size: 9px; }
  body .topbar-tabs svg { width: 21px; height: 21px; }
  body .social-shell { gap: 16px; }
  body.admin-login-body .social-login-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .login-intro { padding: 8px 0; }
  .login-intro-brand { font-size: 36px; gap: 10px; }
  .login-intro-brand img { width: 48px; height: 48px; }
  .login-intro > p { max-width: 310px; font-size: 17px; margin-top: 10px; }
  body.admin-login-body .social-login-layout .admin-login-card { padding: 24px 20px; }
}
body .business-type-icon { background: var(--primary-soft); color: var(--primary); }
body .business-type-filter a:is(:hover, :focus-visible, .is-active) { background: var(--primary-soft); border-color: #e9af8d; color: var(--primary); }
@media (max-width: 820px) {
  body .social-topbar .topbar-link-button { width: auto; padding-inline: 12px; font-size: 14px; }
}

/* People lists sit directly on the page, without an inner scroll frame. */
body .social-shell .right-rail {
  position: static;
  max-height: none;
  overflow: visible;
}
body .right-rail .sidebar-people {
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
body .sidebar-people + .sidebar-people { border-top: 1px solid var(--line); padding-top: 18px; }
body .sidebar-people .section-title { padding-inline: 8px; }
body .sidebar-people .contact-filter { background: #e9ebee; }
body .sidebar-people .contact-item:hover { background: #e9ebee; }
