:root {
  --bg: #f3f6fb;
  --bg-alt: #e8eef7;
  --surface: #ffffff;
  --surface-soft: #f7f9fc;
  --surface-dark: #162032;
  --text: #162131;
  --muted: #697586;
  --primary: #2563eb;
  --primary-strong: #1d4ed8;
  --secondary: #0f766e;
  --accent: #f59e0b;
  --danger: #dc2626;
  --violet: #7c3aed;
  --border: rgba(31, 42, 48, 0.1);
  --shadow-soft: 0 18px 40px rgba(22, 33, 49, 0.08);
  --shadow-strong: 0 26px 50px rgba(22, 33, 49, 0.12);
  --radius: 24px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(
      circle at top left,
      rgba(37, 99, 235, 0.16),
      transparent 24%
    ),
    radial-gradient(
      circle at top right,
      rgba(15, 118, 110, 0.12),
      transparent 22%
    ),
    linear-gradient(180deg, #f8fbff 0%, var(--bg) 50%, var(--bg-alt) 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.18) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.22), transparent 70%);
  pointer-events: none;
}

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

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

.container {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  padding: 16px 0;
}

.nav-wrap,
.site-nav,
.nav-actions,
.stat-grid,
.card-grid,
.footer-grid,
.detail-layout,
.admin-stats,
.admin-grid,
.hero-grid,
.auth-shell,
.dashboard-hero,
.dashboard-hero-metrics,
.health-grid {
  display: grid;
}

.nav-wrap {
  grid-template-columns: auto 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px 18px;
  background: rgba(255, 253, 249, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(10px);
}

.brand {
  display: inline-grid;
  gap: 2px;
  line-height: 0.9;
  font-family: "Cormorant Garamond", serif;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand small {
  font-family: "Manrope", sans-serif;
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.site-nav {
  grid-auto-flow: column;
  justify-content: center;
  gap: 10px;
}

.site-nav a,
.admin-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  color: var(--muted);
  border-radius: 999px;
  transition:
    background 0.24s ease,
    color 0.24s ease,
    transform 0.24s ease;
}

.site-nav a:hover,
.site-nav a.active,
.admin-link:hover {
  background: rgba(35, 78, 82, 0.1);
  color: var(--primary);
  transform: translateY(-1px);
}

.nav-actions {
  grid-auto-flow: column;
  gap: 10px;
  align-items: center;
}

.hero {
  padding: 56px 0 34px;
}

.hero-grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 26px;
  align-items: center;
}

.hero-copy h1,
.section-head h2,
.page-head h1,
.auth-intro h1,
.dashboard-hero h1 {
  margin: 0 0 16px;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.8rem, 5vw, 5rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  font-weight: 700;
  color: #10243a;
}

.hero-copy p,
.section-head p,
.page-head p,
.card p,
.detail-card p,
.service-card p,
.post-content,
.contact-card p,
.auth-intro p,
.footer-brand p,
.helper-text,
.rank-item span,
.stream-item p {
  color: var(--muted);
  line-height: 1.75;
}

.hero-card,
.card,
.detail-card,
.comment-box,
.service-card,
.contact-card,
.admin-card,
.stat-card,
.auth-panel,
.auth-intro {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.hero-card,
.card-content,
.detail-card,
.comment-box,
.service-card,
.contact-card,
.admin-card,
.stat-card,
.auth-panel,
.auth-intro {
  padding: 24px;
}

.admin-card {
  position: relative;
  overflow: hidden;
}

.admin-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.03),
    transparent 35%,
    rgba(15, 118, 110, 0.03)
  );
  pointer-events: none;
}

.hero-copy {
  padding-right: 6px;
}

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

.btn,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 999px;
  padding: 13px 22px;
  cursor: pointer;
  transition:
    transform 0.24s ease,
    box-shadow 0.24s ease,
    background 0.24s ease,
    color 0.24s ease;
}

.btn:hover,
button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 24px rgba(35, 78, 82, 0.14);
}

.btn-primary,
button,
.like-button.liked {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
}

.btn-secondary {
  color: var(--text);
  background: #fff;
  border: 1px solid rgba(31, 42, 48, 0.1);
}

.btn-sm {
  padding: 10px 16px;
  font-size: 0.95rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  border: 1px solid rgba(37, 99, 235, 0.12);
  font-size: 0.92rem;
  font-weight: 700;
}

.section {
  padding: 28px 0 56px;
}

.section-head,
.page-head {
  margin-bottom: 24px;
}

.page-head {
  max-width: 760px;
}

.stat-grid,
.card-grid,
.admin-stats,
.admin-grid {
  gap: 18px;
}

.stat-grid {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.stat-card strong,
.dashboard-hero-metrics strong,
.health-grid strong {
  display: block;
  margin-top: 8px;
  font-family: "Cormorant Garamond", serif;
  font-size: 2.25rem;
  line-height: 1;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  margin-bottom: 24px;
}

.search-wrap {
  position: relative;
  width: min(380px, 100%);
}

.search-wrap input,
.form-grid input,
.form-grid textarea,
.form-grid select,
.auth-panel input,
.auth-panel textarea,
.auth-panel select {
  width: 100%;
  padding: 15px 16px;
  border-radius: 16px;
  border: 1px solid rgba(31, 42, 48, 0.1);
  background: #fff;
  color: var(--text);
  outline: none;
  transition:
    border-color 0.24s ease,
    box-shadow 0.24s ease,
    transform 0.24s ease;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(35, 78, 82, 0.34);
  box-shadow: 0 0 0 5px rgba(35, 78, 82, 0.08);
  transform: translateY(-1px);
}

textarea {
  resize: vertical;
  min-height: 130px;
}

.search-results {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  z-index: 25;
  overflow: hidden;
  background: #fffdf9;
  border-radius: 20px;
  border: 1px solid rgba(31, 42, 48, 0.08);
  box-shadow: var(--shadow-strong);
}

.search-results a {
  display: block;
  padding: 14px 16px;
}

.search-results a:hover {
  background: rgba(35, 78, 82, 0.06);
}

.search-results a + a {
  border-top: 1px solid rgba(31, 42, 48, 0.06);
}

.card-grid {
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
}

.card,
.service-card,
.admin-card,
.detail-card,
.contact-card {
  transition:
    transform 0.28s ease,
    box-shadow 0.28s ease,
    border-color 0.28s ease;
}

.card:hover,
.service-card:hover,
.admin-card:hover,
.detail-card:hover,
.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-strong);
}

.card img,
.service-card img,
.detail-gallery img {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 16px;
}

.card-content {
  padding: 0;
}

.card h3,
.service-card h3,
.detail-card h1,
.auth-panel h2,
.admin-card h3 {
  margin: 0 0 12px;
}

.meta-row,
.card-actions,
.detail-meta,
.comment-head,
.auth-links,
.card-head,
.rank-item,
.stream-item {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.meta-row,
.detail-meta,
.comment-head,
.empty-state,
.helper-text {
  color: var(--muted);
  font-size: 0.95rem;
}

.card-actions {
  margin-top: 16px;
}

.like-button {
  color: var(--danger);
  background: rgba(184, 76, 92, 0.1);
  box-shadow: none;
}

.like-button.liked {
  box-shadow: 0 12px 24px rgba(35, 78, 82, 0.16);
}

.detail-layout {
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 24px;
}

.detail-gallery {
  display: grid;
  gap: 16px;
}

.detail-card h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.2rem, 4vw, 3.7rem);
  line-height: 0.98;
}

.comment-box {
  padding: 26px;
}

.comment-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.comment-item {
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(31, 42, 48, 0.08);
  background: #fff;
}

/* Admin Reply Styling for Comments */
.comment-item.comment-reply {
  margin-top: 10px;
  margin-left: 20px;
  padding: 14px 16px;
  border-radius: 14px;
  background: linear-gradient(
    135deg,
    rgba(53, 99, 235, 0.06),
    rgba(23, 199, 216, 0.04)
  );
  border: 1px solid rgba(53, 99, 235, 0.12);
}

.comment-item.comment-reply .comment-head {
  margin-bottom: 8px;
}

.comment-item.comment-reply .comment-head strong {
  color: #3563ff;
  font-size: 0.88rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.comment-item.comment-reply .comment-head strong i {
  font-size: 0.8rem;
}

.comment-item.comment-reply .comment-head span {
  font-size: 0.8rem;
  color: #8899a6;
}

.comment-item.comment-reply p {
  color: #41566e;
  line-height: 1.7;
  font-size: 0.95rem;
}

.form-grid {
  display: grid;
  gap: 14px;
}

.form-field {
  display: grid;
  gap: 8px;
}

.form-field label {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text);
}

.field-error {
  color: var(--danger);
  font-size: 0.88rem;
  font-weight: 600;
}

.is-invalid {
  border-color: rgba(220, 38, 38, 0.38) !important;
  box-shadow: 0 0 0 5px rgba(220, 38, 38, 0.08) !important;
}

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

.check-row {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 0.95rem;
}

.check-row input {
  width: 18px;
  height: 18px;
}

.auth-shell {
  grid-template-columns: minmax(0, 1fr) minmax(340px, 460px);
  gap: 22px;
  align-items: stretch;
}

.auth-intro,
.auth-panel {
  min-height: 100%;
}

.auth-intro {
  display: grid;
  align-content: center;
  gap: 18px;
  padding: 34px;
  background:
    linear-gradient(135deg, rgba(22, 32, 50, 0.96), rgba(37, 99, 235, 0.9)),
    radial-gradient(
      circle at top right,
      rgba(245, 158, 11, 0.2),
      transparent 26%
    );
  color: rgba(255, 255, 255, 0.94);
}

.auth-intro p,
.auth-intro .badge {
  color: rgba(255, 255, 255, 0.88);
}

.auth-intro .badge {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.14);
}

.auth-panel {
  padding: 30px;
}

.auth-links {
  justify-content: flex-start;
  margin-top: 16px;
}

.auth-links a {
  color: var(--primary);
  font-weight: 700;
}

.auth-feature-list {
  display: grid;
  gap: 12px;
}

.auth-feature-list div {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
}

.site-footer {
  margin-top: 44px;
  padding: 28px 0 54px;
}

.footer-grid {
  grid-template-columns: 1.3fr 0.8fr 0.9fr;
  gap: 18px;
  padding: 26px;
  background: linear-gradient(135deg, #162032, #1d4ed8);
  color: rgba(255, 255, 255, 0.92);
  border-radius: 28px;
  box-shadow: var(--shadow-strong);
}

.footer-brand h3,
.footer-links h4 {
  margin: 0 0 10px;
}

.footer-links p {
  margin: 8px 0;
  color: rgba(255, 255, 255, 0.74);
}

.admin-body {
  background:
    radial-gradient(
      circle at top left,
      rgba(37, 99, 235, 0.14),
      transparent 24%
    ),
    radial-gradient(
      circle at bottom right,
      rgba(15, 118, 110, 0.1),
      transparent 24%
    ),
    linear-gradient(180deg, #f8fbff 0%, #eef4fb 100%);
}

.admin-layout {
  display: block;
  min-height: 100vh;
}

.admin-topbar,
.admin-profile-chip,
.admin-page-head,
.page-actions,
.inline-form {
  display: flex;
  align-items: center;
}

.admin-sidebar {
  display: grid;
  align-content: start;
  gap: 10px;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 28px 22px;
  background: linear-gradient(180deg, #162032 0%, #1f3b79 100%);
  color: rgba(255, 255, 255, 0.92);
  box-shadow: 22px 0 40px rgba(22, 33, 49, 0.12);
  z-index: 60;
}

.admin-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.admin-sidebar .brand {
  color: #fff;
  margin-bottom: 14px;
}

.admin-sidebar a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  color: rgba(255, 255, 255, 0.78);
  border-radius: 16px;
  transition:
    background 0.24s ease,
    color 0.24s ease,
    transform 0.24s ease;
}

.admin-sidebar a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  transform: translateX(2px);
}

.admin-sidebar a.active {
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.28),
    rgba(15, 118, 110, 0.22)
  );
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.admin-content {
  margin-left: 280px;
  padding: 24px 28px 32px;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

.admin-overlay {
  position: fixed;
  inset: 0;
  background: rgba(16, 24, 40, 0.35);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  transition: 0.24s ease;
  z-index: 50;
}

.admin-topbar {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  padding: 14px 18px;
  border-radius: 20px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(245, 249, 255, 0.95)
  );
  box-shadow: var(--shadow-soft);
  position: sticky;
  top: 16px;
  z-index: 20;
}

.admin-topbar-copy {
  display: grid;
  gap: 4px;
}

.admin-topbar-copy span,
.admin-profile-chip span {
  color: var(--muted);
  font-size: 0.92rem;
}

.admin-profile-chip {
  gap: 12px;
  padding: 8px 10px;
  border-radius: 18px;
  background: var(--surface-soft);
}

.admin-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-weight: 800;
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.18);
}

.admin-avatar-sm {
  width: 44px;
  height: 44px;
  font-size: 0.92rem;
}

.admin-avatar-lg {
  width: 84px;
  height: 84px;
  font-size: 1.4rem;
}

.sidebar-toggle {
  display: none;
  width: 46px;
  height: 46px;
  padding: 0;
  border-radius: 14px;
}

.sidebar-close {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: none;
}

.admin-page-head {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.page-actions {
  gap: 12px;
  flex-wrap: wrap;
}

.inline-form {
  gap: 10px;
  flex-wrap: wrap;
}

.inline-form input {
  min-width: 220px;
}

.table-badge {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  font-weight: 700;
  font-size: 0.88rem;
}

/* ========== DASHBOARD PROFESSIONAL STYLES ========== */
/* Adds gradients, distinct card tones, improved spacing, and modern card layouts.
   Does not change any HTML structure or existing non-dashboard CSS. */

/* ---- Dashboard Hero Section ---- */
.dashboard-hero {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 2rem 2.4rem;
  margin-bottom: 1.8rem;
  border-radius: 28px;
  background:
    radial-gradient(
      circle at top right,
      rgba(245, 158, 11, 0.18),
      transparent 28%
    ),
    linear-gradient(135deg, #0f2b3d 0%, #1b4a6e 58%, #0f766e 100%);
  box-shadow: 0 20px 40px rgba(15, 43, 61, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.dashboard-hero-copy {
  display: grid;
  gap: 6px;
}

.dashboard-hero h1 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  font-weight: 700;
  color: #ffffff;
  margin: 6px 0 4px;
  letter-spacing: -0.02em;
  background: none;
  -webkit-text-fill-color: #ffffff;
}

.dashboard-hero .badge {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  backdrop-filter: blur(4px);
}

.dashboard-hero .helper-text {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.92rem;
  max-width: 480px;
  line-height: 1.6;
}

.dashboard-hero-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  overflow: hidden;
}

.hero-metric-item {
  display: grid;
  gap: 4px;
  padding: 1rem 1.4rem;
  text-align: center;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-metric-item:last-child {
  border-right: none;
}

.hero-metric-item span {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
}

.hero-metric-item strong {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.9rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1;
}

/* ---- Admin Stats Cards (different gradients per card) ---- */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.stat-card {
  background: white;
  border-radius: 28px;
  padding: 1.2rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  box-shadow:
    0 5px 15px rgba(0, 0, 0, 0.03),
    0 1px 2px rgba(0, 0, 0, 0.05);
  transition: all 0.25s ease;
  border: 1px solid rgba(0, 0, 0, 0.03);
}

.stat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 30px -12px rgba(0, 0, 0, 0.1);
}

.stat-icon {
  font-size: 2.2rem;
  width: 3rem;
  text-align: center;
}

.stat-card div span {
  font-size: 0.75rem;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: #5b6e8c;
}

.stat-card div strong {
  font-size: 1.8rem;
  font-weight: 700;
  line-height: 1.2;
  display: block;
}

/* individual card tones */
.card-tone-products {
  background: linear-gradient(135deg, #fef5e8, #fff1e0);
  border-left: 5px solid #f59e0b;
}
.card-tone-products .stat-icon {
  color: #f59e0b;
}

.card-tone-posts {
  background: linear-gradient(135deg, #eef2ff, #e6edfc);
  border-left: 5px solid #3b82f6;
}
.card-tone-posts .stat-icon {
  color: #3b82f6;
}

.card-tone-comments {
  background: linear-gradient(135deg, #ecfdf5, #e0faf0);
  border-left: 5px solid #10b981;
}
.card-tone-comments .stat-icon {
  color: #10b981;
}

.card-tone-messages {
  background: linear-gradient(135deg, #f5f0ff, #ede8ff);
  border-left: 5px solid #7c3aed;
}
.card-tone-messages .stat-icon {
  color: #7c3aed;
}

.dash-stat-row {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.dash-full-width {
  grid-column: 1 / -1;
}

.activity-stream-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.stream-badge-activity {
  background: linear-gradient(145deg, #fff5e9, #fef3e0);
  color: #d97706;
}

/* ---- Dashboard Grid (cards layout) ---- */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 1.8rem;
  margin-top: 1rem;
}

/* General admin card styling */
.admin-card {
  background: white;
  border-radius: 28px;
  padding: 1.5rem;
  box-shadow: 0 8px 20px -6px rgba(0, 0, 0, 0.05);
  transition: all 0.2s;
  border: 1px solid #f0f2f5;
  display: flex;
  flex-direction: column;
}

.admin-card:hover {
  box-shadow: 0 20px 30px -12px rgba(0, 0, 0, 0.08);
  border-color: #e9edf2;
}

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.2rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.card-head h3 {
  font-size: 1.25rem;
  font-weight: 600;
  background: linear-gradient(135deg, #1e293b, #2d3a4f);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  margin: 0;
}

.card-head .helper-text {
  font-size: 0.75rem;
  color: #6c7a91;
  margin-top: 0.2rem;
}

.card-head a {
  font-size: 0.8rem;
  font-weight: 500;
  color: #3b82f6;
  text-decoration: none;
  background: #eff6ff;
  padding: 0.3rem 0.9rem;
  border-radius: 40px;
  transition: all 0.2s;
}

.card-head a:hover {
  background: #3b82f6;
  color: white;
}

/* ---- Rank List (like mini tables) ---- */
.rank-list {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.rank-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 0;
  border-bottom: 1px solid #edf2f7;
  transition: background 0.2s;
}

.rank-item:last-child {
  border-bottom: none;
}

.rank-item:hover {
  background: #fafcff;
  padding-left: 0.5rem;
  border-radius: 16px;
}

.rank-item div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.rank-item strong {
  font-weight: 600;
  color: #1f2a44;
}

.rank-item span {
  font-size: 0.7rem;
  color: #6b7a8f;
}

.rank-item b {
  background: #f1f5f9;
  padding: 0.2rem 0.7rem;
  border-radius: 40px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #2563eb;
}

/* ---- Comment stream & activity feed ---- */
.comment-stream {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.stream-item {
  display: flex;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid #f0f2f5;
  transition: all 0.2s;
}

.stream-item:hover {
  background: #fefefe;
  padding-left: 0.5rem;
  border-radius: 20px;
}

.stream-badge {
  width: 2.2rem;
  height: 2.2rem;
  background: linear-gradient(145deg, #f0f4fe, #e9eefa);
  border-radius: 60%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.stream-item div strong {
  font-size: 0.85rem;
  font-weight: 700;
  color: #1f2a44;
  display: block;
}

.stream-item p {
  font-size: 0.8rem;
  color: #3e4a62;
  margin: 0.2rem 0;
  line-height: 1.4;
}

.stream-item .helper-text {
  font-size: 0.7rem;
  color: #8b9ab0;
}

/* ---- Chart cards specific ---- */
.chart-card canvas {
  max-height: 220px;
  width: 100%;
  margin-top: 0.5rem;
}

/* ---- Engagement split card custom (optional background) ---- */
.admin-card:has(#engagementChart) {
  background: linear-gradient(145deg, #ffffff, #fefdf9);
}

.stat-icon,
.stream-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  font-size: 1.1rem;
}

.panel-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(244, 248, 255, 0.96)
  );
  border: 1px solid rgba(37, 99, 235, 0.08);
  box-shadow: var(--shadow-soft);
}

/* ===== PROFESSIONAL TOOLBAR STYLES (layout preserved) ===== */
.toolbar-group {
  display: flex;

  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.toolbar-group input,
.toolbar-group select {
  min-width: 180px;
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    sans-serif;
  font-size: 0.875rem;
  line-height: 1.5;
  padding: 0.625rem 1rem;
  border-radius: 12px;
  border: 1px solid;
  transition: all 0.2s cubic-bezier(0.2, 0.9, 0.4, 1.1);
  background: #ffffff;
  outline: none;
  cursor: pointer;
}

.toolbar-group input[type="search"] {
  min-width: 280px;
  padding-left: 2.5rem;
  background: #ffffff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10.5' cy='10.5' r='7.5'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='15.8' y2='15.8'%3E%3C/line%3E%3C/svg%3E")
    no-repeat left 1rem center;
  background-size: 1rem;
  border-color: #e2e8f0;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.02),
    inset 0 1px 0 #ffffff;
}

.toolbar-group input[type="search"]:hover {
  border-color: #cbd5e1;
  background-color: #fefefe;
}

.toolbar-group input[type="search"]:focus {
  border-color: #3b82f6;
  box-shadow:
    0 0 0 3px rgba(59, 130, 246, 0.15),
    inset 0 1px 0 #ffffff;
  background-color: #ffffff;
}

.toolbar-group select {
  background: #ffffff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E")
    no-repeat right 1rem center;
  background-size: 1rem;
  appearance: none;
  -webkit-appearance: none;
  border-color: #e2e8f0;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.02),
    inset 0 1px 0 #ffffff;
  padding-right: 2.25rem;
  color: #1e293b;
  font-weight: 450;
}

.toolbar-group select:hover {
  border-color: #cbd5e1;
  background-color: #fafcff;
}

.toolbar-group select:focus {
  border-color: #3b82f6;
  box-shadow:
    0 0 0 3px rgba(59, 130, 246, 0.15),
    inset 0 1px 0 #ffffff;
}

/* placeholder styling */
.toolbar-group input[type="search"]::placeholder {
  color: #94a3b8;
  font-weight: 400;
  font-size: 0.8125rem;
  letter-spacing: -0.01em;
}

/* subtle transition for all interactive elements */
.toolbar-group input,
.toolbar-group select {
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background-color 0.2s;
}

/* optional: style for disabled or readonly states */
.toolbar-group input:disabled,
.toolbar-group select:disabled {
  background-color: #f8fafc;
  border-color: #e2edf2;
  color: #94a3b8;
  cursor: not-allowed;
}

/* ensure consistent height and alignment */
.toolbar-group input,
.toolbar-group select {
  height: 44px;
}

/* responsive touch-friendly adjustments (preserves layout) */
@media (max-width: 640px) {
  .toolbar-group input,
  .toolbar-group select {
    height: 42px;
    font-size: 0.85rem;
  }
  .toolbar-group input[type="search"] {
    min-width: 240px;
  }
}

.list-summary {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 600;
}

.pagination-shell {
  margin-top: 16px;
}

.admin-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(22, 33, 49, 0.08);
  box-shadow: var(--shadow-soft);
  transition: 0.22s ease;
}

.admin-page-link:hover,
.admin-page-link.active {
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  color: #fff;
  transform: translateY(-1px);
}

.table-empty {
  padding: 28px 16px;
  text-align: center;
  color: var(--muted);
}

.admin-grid {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.dashboard-grid {
  align-items: start;
}

.chart-card canvas {
  width: 100% !important;
  min-height: 290px;
}

.rank-list,
.comment-stream {
  display: grid;
  gap: 12px;
}

.rank-item,
.stream-item {
  padding: 14px 16px;
  border-radius: 18px;
  background: var(--surface-soft);
  border: 1px solid rgba(31, 42, 48, 0.06);
}

.rank-item strong,
.stream-item strong {
  display: block;
}

.rank-item b {
  color: var(--secondary);
}

.health-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.health-grid div {
  padding: 16px;
  border-radius: 18px;
  background: var(--surface-soft);
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* smooth scrolling on mobile */
}

.table-wrap table {
  width: 100%;
  min-width: 600px; /* enables horizontal scroll on small screens */
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 16px 14px;
  border-bottom: 1px solid rgba(31, 42, 48, 0.08);
  vertical-align: middle;
}

th {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
  background: rgba(37, 99, 235, 0.04);
  white-space: nowrap;
}

tbody tr:hover {
  background: rgba(37, 99, 235, 0.04);
}

.table-wrap {
  border-radius: 20px;
  border: 1px solid rgba(22, 33, 49, 0.08);
  background: #fff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.05);
}

.table-media-cell {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 220px;
}

.table-thumb {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: var(--shadow-soft);
}

.table-thumb-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
}

.table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  transition: 0.22s ease;
  box-shadow: var(--shadow-soft);
}

.action-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-strong);
}

.action-view {
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
}

.action-edit {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.action-delete {
  background: rgba(220, 38, 38, 0.1);
  color: var(--danger);
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border-radius: 20px;
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.08),
    rgba(15, 118, 110, 0.1)
  );
}

.profile-hero strong {
  display: block;
  font-size: 1.1rem;
}

/* Let the name/email text shrink & wrap instead of overflowing the chip */
.profile-hero > div {
  min-width: 0;
}

.profile-hero strong,
.profile-hero span {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.listing-shell {
  display: grid;
  gap: 6px;
}

.about-panel p {
  line-height: 1.85;
  color: var(--muted);
}

.brand-logo {
  object-fit: cover;
  background: #fff;
}

.flash,
.error-box,
.success-box {
  padding: 14px 16px;
  border-radius: 16px;
  margin-bottom: 18px;
}

.flash,
.success-box {
  background: rgba(95, 124, 101, 0.12);
  color: var(--accent);
  border: 1px solid rgba(95, 124, 101, 0.14);
}

.error-box {
  background: rgba(184, 76, 92, 0.1);
  color: var(--danger);
  border: 1px solid rgba(184, 76, 92, 0.14);
}

.auth-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.admin-auth-shell {
  width: min(1120px, 100%);
}

.reveal-item {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.72s ease,
    transform 0.72s ease;
}

.reveal-item.is-visible {
  opacity: 1;
  transform: translateY(0);
  justify-content: space-between;
}

.is-popping {
  animation: popIn 0.28s ease;
}

@keyframes popIn {
  0% {
    transform: scale(0.96);
  }
  65% {
    transform: scale(1.04);
  }
  100% {
    transform: scale(1);
  }
}

@media (max-width: 1024px) {
  .nav-wrap,
  .hero-grid,
  .detail-layout,
  .auth-shell,
  .dashboard-hero {
    grid-template-columns: 1fr;
  }

  .sidebar-toggle {
    display: inline-flex;
  }

  .sidebar-close {
    display: inline-flex;
  }

  .admin-sidebar {
    z-index: 60;
    transform: translateX(-100%);
    transition: transform 0.28s ease;
  }

  .sidebar-open .admin-sidebar {
    transform: translateX(0);
    -webkit-transform: translateX(0);
    -moz-transform: translateX(0);
    -ms-transform: translateX(0);
    -o-transform: translateX(0);
    opacity: 1;
    visibility: visible;
  }

  .sidebar-open .admin-overlay {
    opacity: 1;
    visibility: visible;
  }

  .admin-content {
    margin-left: 0;
    width: 100%;
  }

  .site-nav,
  .nav-actions {
    justify-content: start;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .table-wrap {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: scroll; /* force horizontal scroll */

    -webkit-overflow-scrolling: touch;
  }

  .table-wrap table {
    width: auto; /* important: don't force table to fit screen */
    min-width: 600px; /* bigger than mobile screen */
    border-collapse: collapse;
  }
}

@media (max-width: 720px) {
  .site-nav,
  .nav-actions {
    grid-auto-flow: row;
  }
  .table-wrap {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: scroll; /* force horizontal scroll */
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
  }

  .table-wrap table {
    width: auto; /* important: don't force table to fit screen */
    min-width: 600px; /* bigger than mobile screen */
    border-collapse: collapse;
  }

  .toolbar,
  .two-col,
  .health-grid,
  .admin-page-head {
    display: grid;
    grid-template-columns: 1fr;
  }

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

  .dashboard-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .dashboard-hero-metrics {
    width: 100%;
    justify-content: stretch;
  }

  .hero-metric-item {
    flex: 1;
  }

  .panel-toolbar,
  .toolbar-group {
    flex-direction: column;
    align-items: stretch;
  }

  .table-media-cell {
    min-width: 180px;
  }

  .admin-content {
    padding: 18px;
  }

  .admin-topbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .inline-form input {
    min-width: 100%;
  }

  .hero-copy h1,
  .section-head h2,
  .page-head h1,
  .auth-intro h1,
  .dashboard-hero h1 {
    font-size: clamp(2.2rem, 10vw, 3.6rem);
  }
}

/* === Settings, Profile, and Control Refinements === */
.brand-with-mark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  line-height: 1;
}

.brand-text {
  display: grid;
  gap: 3px;
}

.brand-logo-mark {
  width: 70px;
  height: 70px;
  border-radius: 16px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 22px rgba(15, 23, 42, 0.12);
}

.brand-logo-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Manrope", sans-serif;
  font-size: 0.92rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.footer-brand-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 10px;
}

.settings-layout {
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
}

.settings-preview-grid {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.settings-preview-grid div {
  padding: 16px;
  border-radius: 18px;
  background: linear-gradient(
    180deg,
    rgba(244, 248, 255, 0.98),
    rgba(255, 255, 255, 0.98)
  );
  border: 1px solid rgba(37, 99, 235, 0.08);
}

.settings-preview-grid span,
.form-note,
.toolbar-meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.password-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.password-change-panel {
  display: none;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(
    180deg,
    rgba(244, 248, 255, 0.98),
    rgba(255, 255, 255, 0.98)
  );
  border: 1px solid rgba(37, 99, 235, 0.08);
}

.password-change-panel.is-open {
  display: grid;
}

.file-input {
  min-width: 240px;
}

.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 999px;
  padding: 13px 22px;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  box-shadow: 0 14px 24px rgba(185, 28, 28, 0.18);
}

.btn-danger:hover {
  transform: translateY(-2px);
}

.action-restore {
  background: rgba(15, 118, 110, 0.12);
  color: var(--secondary);
}

.admin-sidebar-section {
  height: 1px;
  margin: 6px 0 2px;
  background: rgba(255, 255, 255, 0.1);
}

.inline-form {
  align-items: stretch;
}

.inline-form input[type="text"],
.inline-form input[type="file"] {
  height: 48px;
}

.toolbar-meta {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(37, 99, 235, 0.08);
}

input:disabled,
textarea:disabled,
select:disabled {
  background: #f5f7fb;
  color: #94a3b8;
  cursor: not-allowed;
}

@media (max-width: 900px) {
  .settings-layout,
  .settings-preview-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .brand-with-mark {
    gap: 10px;
  }

  .brand-logo-mark {
    width: 60px;
    height: 60px;
    border-radius: 14px;
  }

  .footer-brand-header,
  .password-actions {
    align-items: flex-start;
  }
}

/* === Public Content System Refinements === */
.settings-layout-wide {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
}

.settings-section-title {
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(37, 99, 235, 0.12);
  color: var(--primary);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.settings-copy-preview {
  margin-top: 18px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(
    180deg,
    rgba(245, 249, 255, 0.98),
    rgba(255, 255, 255, 0.98)
  );
  border: 1px solid rgba(37, 99, 235, 0.08);
}

.settings-copy-preview h4 {
  margin: 0 0 8px;
}

.hero-refined {
  padding-top: 64px;
  padding-bottom: 40px;
}

.hero-copy-refined {
  padding: 10px 0;
}

.hero-copy-refined p,
.page-head-refined p,
.section-head-refined p,
.about-showcase-copy p {
  max-width: 720px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-card-refined {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(241, 247, 255, 0.98)
  );
}

.stat-grid-hero . {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(246, 250, 255, 0.98)
  );
}

.section-soft {
  position: relative;
}

.section-soft::before {
  content: "";
  position: absolute;
  inset: 16px 0;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.68),
    rgba(232, 242, 255, 0.52)
  );
  border-top: 1px solid rgba(37, 99, 235, 0.05);
  border-bottom: 1px solid rgba(15, 118, 110, 0.05);
  pointer-events: none;
}

.section-soft > .container {
  position: relative;
  z-index: 1;
}

.about-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 22px;
  padding: 28px;
  border-radius: 30px;
  background: linear-gradient(
    135deg,
    rgba(17, 37, 58, 0.98),
    rgba(25, 78, 123, 0.94)
  );
  color: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-strong);
}

.about-showcase .badge {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.16);
}

.about-showcase-copy h2 {
  margin: 12px 0;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.2rem, 4vw, 3.5rem);
}

.about-showcase-copy p {
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.8;
}

.about-showcase-meta {
  display: grid;
  gap: 12px;
}

.about-showcase-meta div,
.contact-mini-stats div {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.about-showcase-meta span,
.contact-mini-stats span {
  display: block;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.86rem;
}

.about-showcase-meta strong,
.contact-mini-stats strong {
  display: block;
  margin-top: 6px;
  color: #fff;
}

.page-shell {
  padding-top: 34px;
}

.page-head-refined,
.section-head-refined {
  margin-bottom: 28px;
}

.page-head-refined .badge {
  margin-bottom: 12px;
}

.toolbar-refined {
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.94),
    rgba(244, 248, 255, 0.96)
  );
  box-shadow: var(--shadow-soft);
}

.search-wrap-refined input {
  border-radius: 18px;
}

.filter-panel {
  padding: 0;
}

.card-grid-refined {
  gap: 24px;
}

.card-media-wrap {
  position: relative;
}

.card-media-wrap img {
  margin-bottom: 0;
}

.card-chip {
  position: absolute;
  left: 16px;
  bottom: 16px;
  display: inline-flex;
  align-items: center;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.8);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

.product-card,
.post-card,
.service-card-refined {
  overflow: hidden;
  border-radius: 28px;
}

.product-card .card-content,
.post-card .card-content {
  padding: 20px 2px 4px;
}

.product-card-spotlight,
.post-card-featured {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(247, 250, 255, 0.98)
  );
  border: 1px solid rgba(37, 99, 235, 0.08);
}

.product-card .meta-row,
.post-card .meta-row {
  margin-bottom: 6px;
}

.product-card h3,
.post-card h3,
.service-card-refined h3 {
  font-size: 1.22rem;
}

.service-card-refined {
  padding: 18px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(245, 249, 255, 0.96)
  );
  border: 1px solid rgba(15, 118, 110, 0.08);
}

.service-card-refined img {
  margin-bottom: 18px;
}

.site-footer-refined {
  margin-top: 56px;
}

.detail-layout-refined {
  align-items: stretch;
}

.contact-card-refined,
.detail-card-refined {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(246, 250, 255, 0.98)
  );
}

.contact-direct-card {
  position: relative;
  overflow: hidden;
}

.contact-direct-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at top right,
    rgba(37, 99, 235, 0.08),
    transparent 28%
  );
  pointer-events: none;
}

.contact-mini-stats {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.contact-mini-stats div {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.05);
}

.contact-mini-stats span {
  color: var(--muted);
}

.contact-mini-stats strong {
  color: var(--text);
}

@media (max-width: 980px) {
  .settings-layout-wide,
  .about-showcase {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .toolbar-refined {
    padding: 16px;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .product-card .card-content,
  .post-card .card-content {
    padding-top: 18px;
  }
}

/* === Public Premium Visual Refresh === */
:root {
  --public-ink: #10243a;
  --public-navy: #103056;
  --public-sky: #dfeefe;
  --public-aqua: #dcf7f3;
  --public-gold: #f7b55d;
  --public-rose: #f08b86;
  --public-card-shadow: 0 24px 50px rgba(16, 36, 58, 0.12);
}

body {
  background:
    radial-gradient(
      circle at top left,
      rgba(16, 95, 170, 0.16),
      transparent 24%
    ),
    radial-gradient(
      circle at 85% 10%,
      rgba(15, 118, 110, 0.12),
      transparent 18%
    ),
    linear-gradient(180deg, #f7fbff 0%, #eef5fb 48%, #e7f0f9 100%);
}

.site-header {
  padding: 18px 0 10px;
}

.nav-wrap {
  padding: 16px 22px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.86);
  box-shadow: 0 16px 34px rgba(16, 36, 58, 0.08);
}

.site-nav a {
  font-weight: 700;
}

.site-nav a:hover,
.site-nav a.active {
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.12),
    rgba(15, 118, 110, 0.1)
  );
  color: var(--public-navy);
}

.hero-refined {
  padding-top: 72px;
  padding-bottom: 48px;
}

.hero-copy-refined h1 {
  max-width: 760px;
  color: var(--public-ink);
  text-shadow: 0 10px 24px rgba(255, 255, 255, 0.22);
}

.hero-copy-refined p {
  font-size: 1.05rem;
  color: #46607c;
}

.hero-card-refined {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--public-card-shadow);
}

.hero-card-refined::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      circle at top right,
      rgba(37, 99, 235, 0.15),
      transparent 32%
    ),
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.86),
      rgba(235, 245, 255, 0.82)
    );
  pointer-events: none;
}

.hero-card-refined > * {
  position: relative;
  z-index: 1;
}

.stat-grid-hero {
  gap: 14px;
}

.stat-grid-hero .stat-card {
  padding: 20px;
  border-radius: 22px;
  border: 1px solid rgba(37, 99, 235, 0.08);
  box-shadow: 0 18px 30px rgba(16, 36, 58, 0.06);
}

.stat-grid-hero .stat-card:nth-child(1) {
  background: linear-gradient(135deg, #ffffff, #eff7ff);
}

.stat-grid-hero .stat-card:nth-child(2) {
  background: linear-gradient(135deg, #ffffff, #eefcf7);
}

.stat-grid-hero .stat-card:nth-child(3) {
  background: linear-gradient(135deg, #ffffff, #fff5e9);
}

.about-showcase {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    radial-gradient(
      circle at top right,
      rgba(247, 181, 93, 0.18),
      transparent 26%
    ),
    linear-gradient(135deg, #10243b 0%, #154c70 58%, #0f766e 100%);
}

.about-showcase-meta div {
  backdrop-filter: blur(10px);
}

.section-head-refined h2,
.page-head-refined h1 {
  color: var(--public-ink);
}

.section-head-refined p,
.page-head-refined p {
  color: #55708d;
}

.toolbar-refined {
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 40px rgba(16, 36, 58, 0.08);
}

.card-grid-refined {
  gap: 26px;
}

.product-card,
.post-card,
.service-card-refined,
.detail-card-refined,
.comment-box-refined,
.contact-card-refined {
  box-shadow: var(--public-card-shadow);
}

.product-card,
.post-card {
  position: relative;
  border-radius: 30px;
  overflow: hidden;
}

.product-card::before,
.post-card::before,
.service-card-refined::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(255, 255, 255, 0.02) 44%,
    rgba(255, 255, 255, 0.34) 100%
  );
  pointer-events: none;
}

.product-card:hover,
.post-card:hover,
.service-card-refined:hover {
  transform: translateY(-10px) scale(1.01);
  box-shadow: 0 30px 56px rgba(16, 36, 58, 0.16);
}

.card-media-wrap {
  overflow: hidden;
  border-radius: 24px;
}

.card-media-wrap img,
.service-card-refined img,
.detail-gallery-frame img {
  transition:
    transform 0.55s ease,
    filter 0.45s ease;
}

.product-card:hover .card-media-wrap img,
.post-card:hover .card-media-wrap img,
.service-card-refined:hover img,
.detail-gallery-frame:hover img {
  transform: scale(1.06);
  filter: saturate(1.05) contrast(1.02);
}

.card-chip {
  background: rgba(16, 36, 58, 0.82);
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.18);
}

.product-card .card-content,
.post-card .card-content {
  position: relative;
  padding: 22px 2px 6px;
}

.product-card h3,
.post-card h3 {
  font-size: 1.28rem;
  color: var(--public-ink);
}

.product-card p,
.post-card p,
.service-card-refined p {
  color: #5e7691;
}

.product-card .meta-row,
.post-card .meta-row {
  color: #6b839e;
}

.like-button {
  border: 1px solid rgba(240, 139, 134, 0.18);
}

.like-button:hover {
  box-shadow: 0 16px 24px rgba(240, 139, 134, 0.14);
}

.service-card-refined {
  position: relative;
  padding: 20px;
  border-radius: 30px;
  overflow: hidden;
  background:
    radial-gradient(
      circle at top right,
      rgba(15, 118, 110, 0.08),
      transparent 28%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.98),
      rgba(240, 248, 255, 0.96)
    );
}

.service-card-refined:nth-child(3n + 1) {
  border-color: rgba(37, 99, 235, 0.1);
}

.service-card-refined:nth-child(3n + 2) {
  border-color: rgba(15, 118, 110, 0.12);
}

.service-card-refined:nth-child(3n + 3) {
  border-color: rgba(245, 158, 11, 0.12);
}

.service-card-refined h3 {
  color: var(--public-ink);
}

.page-head-refined,
.section-head-refined {
  max-width: 840px;
}

.detail-shell {
  padding-top: 30px;
}

.detail-layout-product,
.detail-layout-post {
  align-items: start;
}

.detail-gallery-refined {
  gap: 18px;
}

.detail-gallery-frame {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--public-card-shadow);
}

.detail-gallery-frame.is-primary {
  min-height: 100%;
}

.detail-gallery-frame img {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
}

.detail-card-refined {
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  background:
    radial-gradient(
      circle at top right,
      rgba(37, 99, 235, 0.08),
      transparent 22%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.99),
      rgba(244, 248, 255, 0.97)
    );
}

.detail-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.detail-inline-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(16, 36, 58, 0.06);
  color: #48627d;
  font-size: 0.88rem;
  font-weight: 700;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 20px 0 22px;
}

.detail-meta-grid div {
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(37, 99, 235, 0.08);
}

.detail-meta-grid span {
  display: block;
  color: #6d86a2;
  font-size: 0.86rem;
  margin-bottom: 8px;
}

.detail-meta-grid strong {
  font-size: 1.35rem;
  color: var(--public-ink);
}

.detail-copy,
.post-content-refined {
  color: #46607c;
  line-height: 1.92;
  font-size: 1rem;
}

.post-content-refined {
  padding: 2px 2px 4px;
}

.detail-actions {
  margin-top: 22px;
}

.comment-box-refined {
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.86);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(244, 248, 255, 0.96)
  );
}

.comment-box-refined h3 {
  margin-bottom: 16px;
  color: var(--public-ink);
}

.comment-item {
  border-radius: 20px;
  box-shadow: 0 14px 24px rgba(16, 36, 58, 0.04);
}

.search-results {
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(14px);
}

.footer-grid {
  background:
    radial-gradient(
      circle at top right,
      rgba(247, 181, 93, 0.18),
      transparent 24%
    ),
    linear-gradient(135deg, #10243b, #184669 58%, #0f766e 100%);
}

.footer-links a:hover {
  color: #fff;
}

@media (max-width: 1024px) {
  .detail-meta-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .hero-copy-refined p,
  .section-head-refined p,
  .page-head-refined p {
    font-size: 1rem;
  }

  .product-card:hover,
  .post-card:hover,
  .service-card-refined:hover {
    transform: translateY(-6px);
  }

  .detail-badge-row {
    align-items: flex-start;
  }
}

/* === Public pages CSS === */
.public-body {
  background: linear-gradient(180deg, #f8fbfd 0%, #f3f6f8 100%);
}

.public-body::before {
  display: none;
}

.public-header {
  padding: 18px 0 8px;
}

.public-nav-wrap {
  grid-template-columns: auto 1fr;
  gap: 28px;
  padding: 16px 22px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(16, 36, 58, 0.06);
  border-radius: 24px;
  box-shadow: 0 12px 30px rgba(16, 36, 58, 0.06);
  backdrop-filter: blur(10px);
}

.public-site-nav {
  justify-content: end;
  gap: 8px;
}

.public-site-nav a {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  color: #506173;
}

.public-site-nav a:hover,
.public-site-nav a.active {
  background: #eef3f7;
  color: #10243a;
  transform: none;
}

.public-section {
  padding: 34px 0 64px;
}

.alt-surface {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.56),
    rgba(244, 247, 249, 0.9)
  );
}

.alt-surface::before,
.section-soft::before {
  display: none;
}

.public-hero-section {
  padding: 48px 0 64px;
}

.public-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  align-items: center;
}

.public-hero-copy h1,
.public-page-head h1,
.public-section-head h2,
.about-page-grid h2 {
  margin: 0 0 14px;
  font-family: "Cormorant Garamond", serif;
  color: #10243a;
  letter-spacing: -0.02em;
}

.public-hero-copy h1 {
  font-size: clamp(3rem, 5vw, 4.7rem);
  line-height: 1;
}

.public-section-head h2 {
  font-size: clamp(2rem, 3.5vw, 3rem);
  line-height: 1.05;
}

.public-hero-copy p,
.public-page-head p,
.public-section-head p,
.public-panel p,
.post-body-clean p,
.card-body-clean p,
.service-card-clean p {
  color: #627181;
  line-height: 1.8;
}

.section-kicker {
  display: inline-block;
  margin-bottom: 14px;
  color: #6d7c89;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.public-actions-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.public-panel {
  padding: 28px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(16, 36, 58, 0.06);
  box-shadow: 0 16px 34px rgba(16, 36, 58, 0.06);
}

.hero-summary-panel {
  align-self: stretch;
}

.summary-stat-list {
  display: grid;
  gap: 14px;
}

.summary-stat-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 14px 0;
  border-bottom: 1px solid rgba(16, 36, 58, 0.08);
}

.summary-stat-item:last-child {
  border-bottom: none;
}

.summary-stat-item span {
  color: #6b7a88;
  font-size: 0.92rem;
}

.summary-stat-item strong {
  font-family: "Cormorant Garamond", serif;
  font-size: 2rem;
  color: #10243a;
}

.compact-head {
  max-width: 760px;
  margin-bottom: 30px;
}

.about-inline-panel {
  max-width: 920px;
}

.product-grid-clean,
.service-grid-clean {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
}

.product-card-clean,
.service-card-clean,
.post-card-clean {
  background: #fff;
  border: 1px solid rgba(16, 36, 58, 0.06);
  border-radius: 22px;
  overflow: hidden;
  transition:
    transform 0.24s ease,
    box-shadow 0.24s ease,
    border-color 0.24s ease;
  box-shadow: 0 14px 30px rgba(16, 36, 58, 0.05);
}

.product-card-clean:hover,
.service-card-clean:hover,
.post-card-clean:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 38px rgba(16, 36, 58, 0.09);
  border-color: rgba(16, 36, 58, 0.1);
}

.card-media-clean,
.post-media-clean {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #edf2f6;
}

.card-media-clean img,
.post-media-clean img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.product-card-clean:hover img,
.post-card-clean:hover img {
  transform: scale(1.03);
}

.card-body-clean,
.post-body-clean {
  padding: 18px;
}

.card-topline-clean,
.card-footer-clean {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.card-tag-clean,
.post-meta-clean {
  color: #738291;
  font-size: 0.84rem;
  font-weight: 600;
}

.card-topline-clean strong {
  color: #10243a;
  font-size: 1rem;
}

.card-body-clean h3,
.post-body-clean h3,
.service-card-clean h3 {
  margin: 12px 0 10px;
  font-size: 1.12rem;
  color: #10243a;
}

.card-body-clean h3 a,
.post-body-clean h3 a {
  color: inherit;
}

.card-footer-clean {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(16, 36, 58, 0.07);
  color: #72818f;
  font-size: 0.88rem;
}

.card-footer-clean a,
.post-link-clean {
  color: #10243a;
  font-weight: 700;
}

.post-list-clean {
  display: grid;
  gap: 18px;
}

.post-list-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.post-body-clean {
  display: grid;
  gap: 10px;
}

.service-card-clean {
  padding: 22px;
}

.service-icon-clean {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: #eef3f7;
  color: #10243a;
  font-size: 1.05rem;
}

.service-card-detailed p {
  margin: 0;
}

.catalog-toolbar-clean {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
  margin-bottom: 28px;
  background: #fff;
  border: 1px solid rgba(16, 36, 58, 0.06);
  border-radius: 20px;
  box-shadow: 0 12px 28px rgba(16, 36, 58, 0.04);
  position: sticky;
}

.search-wrap-clean {
  width: min(360px, 100%);
}

.catalog-filters-clean {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: min(520px, 100%);
}

.catalog-filters-clean select,
.catalog-filters-clean button {
  width: 100%;
}

.about-page-shell {
  padding-top: 28px;
}

.about-page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 22px;
}

.about-meta-panel {
  display: grid;
  gap: 14px;
}

.about-meta-item {
  padding: 14px 0;
  border-bottom: 1px solid rgba(16, 36, 58, 0.08);
}

.about-meta-item:last-child {
  border-bottom: none;
}

.about-meta-item span,
.contact-address-clean span {
  display: block;
  color: #738291;
  font-size: 0.84rem;
}

.about-meta-item strong,
.contact-address-clean strong {
  display: block;
  margin-top: 6px;
  color: #10243a;
}

.contact-layout-clean {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.9fr);
  gap: 22px;
}

.contact-links-clean {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.contact-links-clean a {
  color: #10243a;
  font-weight: 600;
}

.contact-address-clean {
  padding-top: 18px;
  border-top: 1px solid rgba(16, 36, 58, 0.08);
}

.public-footer-grid {
  grid-template-columns: 1.1fr 0.8fr 0.8fr;
  background: #10243a;
  border-radius: 24px;
  box-shadow: none;
}

.public-footer-grid p,
.public-footer-grid a,
.public-footer-grid h4,
.public-footer-grid h3 {
  color: rgba(255, 255, 255, 0.88);
}

@media (max-width: 960px) {
  .public-hero-grid,
  .about-page-grid,
  .contact-layout-clean,
  .public-footer-grid {
    grid-template-columns: 1fr;
  }

  .public-nav-wrap {
    grid-template-columns: 1fr;
  }

  .public-site-nav {
    justify-content: start;
  }
}

@media (max-width: 720px) {
  .public-site-nav {
    grid-auto-flow: row;
    justify-content: stretch;
  }

  .catalog-filters-clean {
    grid-template-columns: 1fr;
  }

  .public-actions-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .product-grid-clean,
  .service-grid-clean,
  .post-list-grid {
    grid-template-columns: 1fr;
  }
}

/* === Public Visual System v2 === */
.public-body {
  --pub-bg: #f6f8fc;
  --pub-surface: rgba(255, 255, 255, 0.86);
  --pub-surface-strong: #ffffff;
  --pub-text: #162033;
  --pub-muted: #61708a;
  --pub-line: rgba(22, 32, 51, 0.08);
  --pub-blue: #3563ff;
  --pub-cyan: #17c7d8;
  --pub-teal: #0f9d8d;
  --pub-orange: #ff8b45;
  --pub-pink: #ff5fa2;
  --pub-yellow: #ffc857;
  --pub-shadow: 0 24px 60px rgba(31, 47, 86, 0.12);
  --pub-shadow-soft: 0 18px 42px rgba(37, 58, 101, 0.08);
  background:
    radial-gradient(
      circle at top left,
      rgba(53, 99, 255, 0.12),
      transparent 28%
    ),
    radial-gradient(
      circle at top right,
      rgba(23, 199, 216, 0.12),
      transparent 24%
    ),
    linear-gradient(180deg, #f9fbff 0%, #f4f7fb 100%);
  color: var(--pub-text);
}

.public-body main {
  overflow: clip;
}

.public-body .section {
  padding: 92px 0;
}

.public-body .container {
  width: min(1180px, calc(100% - 32px));
}

.public-body .public-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 10px 0;
  background: linear-gradient(
    180deg,
    rgba(248, 250, 255, 0.94),
    rgba(248, 250, 255, 0.76)
  );
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
}

.public-body .public-nav-wrap {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 28px;
  padding: 10px 22px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 14px 40px rgba(24, 36, 68, 0.08);
}

.public-body .brand-with-mark {
  gap: 14px;
  transition: transform 0.28s ease;
}

.public-body .brand-with-mark:hover {
  transform: translateY(-1px);
}

.public-body .brand-logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 18px;
  object-fit: cover;
  box-shadow: 0 12px 24px rgba(53, 99, 255, 0.18);
}

.public-body .brand-logo-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--pub-blue), var(--pub-cyan));
  color: #fff;
  font-weight: 800;
}

.public-body .brand-text > span {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--pub-text);
}

.public-body .brand-text small {
  color: var(--pub-muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.public-body .public-site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.public-body .public-site-nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 18px;
  border-radius: 999px;
  color: var(--pub-muted);
  font-weight: 700;
  letter-spacing: -0.01em;
  transition:
    color 0.22s ease,
    background 0.22s ease,
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

.public-body .public-site-nav a::after {
  content: "";
  position: absolute;
  inset: auto 14px 8px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--pub-blue), var(--pub-cyan));
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.22s ease;
}

.public-body .public-site-nav a:hover,
.public-body .public-site-nav a.active {
  transform: translateY(-1px);
  background: #eef3f7;
  color: #10243a;
}

.public-body .public-site-nav a:hover::after,
.public-body .public-site-nav a.active::after {
  transform: scaleX(1);
}

.public-body .public-hero-section {
  padding: 54px 0 34px;
}

.public-body .public-hero-grid {
  display: grid;
  align-items: stretch;
}

.public-body .hero-grid-two-col {
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 28px;
  align-items: stretch;
}

.public-body .public-hero-copy,
.public-body .hero-summary-panel {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  box-shadow: var(--pub-shadow);
}

.public-body .public-hero-copy {
  padding: 42px;
  min-height: 100%;
  background:
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.94),
      rgba(255, 255, 255, 0.74)
    ),
    radial-gradient(
      circle at top right,
      rgba(255, 95, 162, 0.18),
      transparent 32%
    ),
    radial-gradient(
      circle at bottom left,
      rgba(53, 99, 255, 0.18),
      transparent 30%
    );
}

.public-body .public-hero-copy::before,
.public-body .hero-summary-panel::before {
  content: "";
  position: absolute;
  inset: auto -40px -50px auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(23, 199, 216, 0.24),
    transparent 68%
  );
  pointer-events: none;
}

.public-body .section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(53, 99, 255, 0.08);
  color: var(--pub-blue);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.public-body .public-hero-copy h1 {
  margin: 22px 0 18px;
  /* max-width: 11ch; */
  font-size: clamp(2.8rem, 4vw, 4.7rem);
  line-height: 0.96;
  letter-spacing: -0.05em;

  text-transform: capitalize;
}

.public-body .public-hero-copy h1 {
  color: #10243a;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  -webkit-text-fill-color: #10243a;
}

.public-body .public-hero-copy p,
.public-body .public-section-head p,
.public-body .card-body-clean p,
.public-body .post-body-clean p,
.public-body .service-card-clean p,
.public-body .about-inline-panel p,
.public-body .contact-info-panel-clean p,
.public-body .contact-form-panel-clean p {
  color: var(--pub-muted);
  font-size: 1rem;
  line-height: 1.8;
}

.public-body .public-actions-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.public-body .btn {
  min-height: 50px;
  padding: 14px 22px;
  border-radius: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  transition:
    transform 0.24s ease,
    box-shadow 0.24s ease,
    background 0.24s ease,
    color 0.24s ease;
}

.public-body .btn:hover {
  transform: translateY(-2px);
}

.public-body .btn-primary {
  background: linear-gradient(135deg, var(--pub-blue), var(--pub-cyan));
  color: #fff;
  box-shadow: 0 18px 36px rgba(53, 99, 255, 0.26);
}

.public-body .btn-secondary {
  background: rgba(255, 255, 255, 0.82);
  color: var(--pub-text);
  border: 1px solid rgba(22, 32, 51, 0.08);
  box-shadow: 0 12px 30px rgba(20, 34, 64, 0.08);
}

.public-body .hero-summary-panel {
  display: flex;
  align-items: flex-end;
  padding: 26px;
  min-height: 100%;
  background:
    linear-gradient(165deg, rgba(18, 32, 68, 0.98), rgba(25, 72, 132, 0.94)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0));
  color: #fff;
}

.public-body .summary-stat-list {
  width: 100%;
  display: grid;
  gap: 14px;
}

.public-body .summary-stat-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.public-body .summary-stat-item span {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 700;
}

.public-body .summary-stat-item strong {
  font-size: 1.8rem;
  line-height: 1;
  letter-spacing: -0.04em;
}

.public-body .public-section,
.public-body .alt-surface {
  position: relative;
}

.public-body .public-section-head {
  display: grid;
  gap: 14px;
  margin-bottom: 28px;
}

.public-body .public-section-head h2 {
  margin: 0;
  font-size: clamp(2rem, 2.6vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.public-body .compact-head {
  max-width: 760px;
}

.public-body .public-panel,
.public-body .about-inline-panel,
.public-body .about-copy-panel,
.public-body .about-meta-panel,
.public-body .contact-form-panel-clean,
.public-body .contact-info-panel-clean,
.public-body .detail-card-refined,
.public-body .comment-box-refined,
.public-body .catalog-toolbar-clean {
  border-radius: 28px;
  background: var(--pub-surface);
  border: 1px solid rgba(255, 255, 255, 0.86);
  box-shadow: var(--pub-shadow-soft);
  backdrop-filter: blur(16px);
}

.public-body .about-inline-panel,
.public-body .about-copy-panel,
.public-body .about-meta-panel,
.public-body .contact-form-panel-clean,
.public-body .contact-info-panel-clean,
.public-body .catalog-toolbar-clean {
  padding: 26px;
}

.public-body .product-grid-clean,
.public-body .service-grid-clean,
.public-body .post-list-grid,
.public-body .post-list-clean {
  display: grid;
  gap: 24px;
}

.public-body .product-grid-clean {
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
}

.public-body .service-grid-clean {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.public-body .post-list-grid {
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
}

.public-body .product-card-clean,
.public-body .service-card-clean,
.public-body .post-card-clean {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(247, 250, 255, 0.95)
  );
  border: 1px solid rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 45px rgba(30, 45, 82, 0.1);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease,
    border-color 0.3s ease;
}

.public-body .product-card-clean::before,
.public-body .service-card-clean::before,
.public-body .post-card-clean::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: linear-gradient(
    90deg,
    var(--pub-blue),
    var(--pub-cyan),
    var(--pub-orange)
  );
  opacity: 0.9;
}

.public-body .product-card-clean::after,
.public-body .post-card-clean::after {
  content: "";
  position: absolute;
  inset: 18px 18px auto auto;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(255, 95, 162, 0.12),
    transparent 70%
  );
  pointer-events: none;
}

.public-body .product-card-clean:hover,
.public-body .service-card-clean:hover,
.public-body .post-card-clean:hover {
  transform: translateY(-10px) scale(1.01);
  box-shadow: 0 28px 60px rgba(25, 42, 79, 0.16);
  border-color: rgba(53, 99, 255, 0.14);
}

.public-body .card-media-clean,
.public-body .post-media-clean {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  margin: 16px 16px 0;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(135deg, #eaf1ff, #effbff);
}

.public-body .card-media-clean::after,
.public-body .post-media-clean::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(7, 17, 34, 0) 35%,
    rgba(10, 19, 38, 0.18) 100%
  );
  opacity: 0;
  transition: opacity 0.28s ease;
}

.public-body .card-media-clean img,
.public-body .post-media-clean img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.public-body .product-card-clean:hover .card-media-clean::after,
.public-body .post-card-clean:hover .post-media-clean::after {
  opacity: 1;
}

.public-body .product-card-clean:hover img,
.public-body .post-card-clean:hover img {
  transform: scale(1.07);
}

.public-body .card-body-clean,
.public-body .post-body-clean {
  display: grid;
  gap: 12px;
  padding: 22px 22px 24px;
}

.public-body .card-topline-clean,
.public-body .card-footer-clean,
.public-body .post-meta-clean {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.public-body .card-tag-clean {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(23, 199, 216, 0.12);
  color: var(--pub-teal);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.public-body .card-topline-clean strong {
  font-size: 1.08rem;
  font-weight: 800;
  color: var(--pub-orange);
}

.public-body .card-body-clean h3,
.public-body .post-body-clean h3,
.public-body .service-card-clean h3,
.public-body .detail-card-refined h1,
.public-body .detail-card-refined h2 {
  margin: 0;
  font-size: 1.28rem;
  line-height: 1.22;
  letter-spacing: -0.03em;
  color: #10243a;
  background: none;
  -webkit-text-fill-color: #10243a;
}

.public-body .card-body-clean h3 a,
.public-body .post-body-clean h3 a,
.public-body .card-footer-clean a,
.public-body .post-link-clean,
.public-body .contact-links-clean a {
  color: inherit;
}

.public-body .card-footer-clean {
  margin-top: 4px;
  padding-top: 16px;
  border-top: 1px solid var(--pub-line);
  color: var(--pub-muted);
  font-size: 0.92rem;
}

.public-body .card-footer-clean a,
.public-body .post-link-clean {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--pub-blue);
}

.public-body .card-footer-clean a::after,
.public-body .post-link-clean::after {
  content: "\f061";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 0.85rem;
}

.public-body .post-meta-clean {
  justify-content: flex-start;
  color: var(--pub-muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.public-body .service-card-clean {
  padding: 26px;
}

.public-body .service-card-clean:nth-child(3n + 1) {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(242, 247, 255, 0.96)
  );
}

.public-body .service-card-clean:nth-child(3n + 2) {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(239, 252, 250, 0.96)
  );
}

.public-body .service-card-clean:nth-child(3n + 3) {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98),
    rgba(255, 247, 241, 0.96)
  );
}

.public-body .service-icon-clean {
  width: 62px;
  height: 62px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 20px;
  margin-bottom: 18px;
  font-size: 1.25rem;
  color: #fff;
  box-shadow: 0 16px 26px rgba(53, 99, 255, 0.18);
  background: linear-gradient(135deg, var(--pub-blue), var(--pub-cyan));
}

.public-body .service-card-clean:nth-child(3n + 2) .service-icon-clean {
  background: linear-gradient(135deg, var(--pub-teal), var(--pub-cyan));
}

.public-body .service-card-clean:nth-child(3n + 3) .service-icon-clean {
  background: linear-gradient(135deg, var(--pub-orange), var(--pub-pink));
}

.public-body .catalog-toolbar-clean {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(0, auto);
  gap: 18px;
  align-items: center;
}

.public-body .search-wrap-clean {
  width: 100%;
}

.public-body .search-wrap-clean input,
.public-body .catalog-filters-clean select,
.public-body .contact-form-panel-clean input,
.public-body .contact-form-panel-clean textarea,
.public-body .comment-box-refined input,
.public-body .comment-box-refined textarea {
  width: 100%;
  border-radius: 18px;
  border: 1px solid rgba(22, 32, 51, 0.1);
  background: rgba(248, 250, 255, 0.92);
  color: var(--pub-text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}

.public-body .search-wrap-clean input,
.public-body .catalog-filters-clean select {
  min-height: 52px;
  padding: 0 18px;
}

.public-body .contact-form-panel-clean input,
.public-body .contact-form-panel-clean textarea,
.public-body .comment-box-refined input,
.public-body .comment-box-refined textarea {
  padding: 14px 16px;
}

.public-body .search-wrap-clean input:focus,
.public-body .catalog-filters-clean select:focus,
.public-body .contact-form-panel-clean input:focus,
.public-body .contact-form-panel-clean textarea:focus,
.public-body .comment-box-refined input:focus,
.public-body .comment-box-refined textarea:focus {
  outline: none;
  border-color: rgba(53, 99, 255, 0.42);
  box-shadow: 0 0 0 4px rgba(53, 99, 255, 0.1);
  background: #fff;
}

.public-body .catalog-filters-clean {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: min(560px, 100%);
}

.public-body .catalog-filters-clean button {
  min-height: 52px;
  border-radius: 18px;
}

.public-body .about-page-grid,
.public-body .contact-layout-clean {
  display: grid;
  gap: 24px;
}

.public-body .about-page-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
}

.public-body .contact-layout-clean {
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.92fr);
}

.public-body .about-meta-item,
.public-body .contact-address-clean {
  padding-top: 16px;
  border-top: 1px solid var(--pub-line);
}

.public-body .about-meta-item:first-child,
.public-body .contact-address-clean:first-child {
  border-top: none;
  padding-top: 0;
}

.public-body .about-meta-item span,
.public-body .contact-address-clean span {
  color: var(--pub-muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.public-body .about-meta-item strong,
.public-body .contact-address-clean strong,
.public-body .contact-links-clean a {
  display: block;
  margin-top: 8px;
  color: var(--pub-text);
  font-weight: 800;
}

.public-body .contact-links-clean {
  display: grid;
  gap: 12px;
  margin: 20px 0;
}

.public-body .contact-links-clean a {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(53, 99, 255, 0.06);
  transition:
    transform 0.22s ease,
    background 0.22s ease;
}

.public-body .contact-links-clean a:hover {
  transform: translateY(-2px);
  background: rgba(53, 99, 255, 0.11);
}

.public-body .public-footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 0.8fr;
  gap: 22px;
  padding: 30px;
  border-radius: 32px;
  background:
    linear-gradient(155deg, rgba(17, 29, 58, 0.98), rgba(18, 61, 104, 0.94)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0));
  box-shadow: 0 28px 70px rgba(15, 27, 53, 0.18);
}

.public-body .public-footer-grid h3,
.public-body .public-footer-grid h4 {
  color: #fff;
}

.public-body .public-footer-grid p,
.public-body .public-footer-grid a {
  color: rgba(255, 255, 255, 0.76);
}

.public-body .public-footer-grid a:hover {
  color: #fff;
}

.public-body .detail-gallery-frame {
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--pub-shadow);
}

.public-body .detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.public-body .comment-item,
.public-body .comment-card {
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.88);
  box-shadow: 0 14px 30px rgba(31, 47, 86, 0.06);
}

/* Public Comment Reply Styling */
.public-body .comment-item.comment-reply {
  background: linear-gradient(
    135deg,
    rgba(53, 99, 235, 0.08),
    rgba(23, 199, 216, 0.06)
  );
  border: 1px solid rgba(53, 99, 235, 0.14);
  box-shadow: 0 10px 24px rgba(31, 47, 86, 0.08);
}

.public-body .comment-reply .comment-head strong {
  color: #3563ff;
  font-size: 0.86rem;
}

.public-body .comment-reply .comment-head strong i {
  margin-right: 4px;
}

.public-body .comment-reply p {
  font-size: 0.94rem;
  color: #4a5a7a;
}

.public-body .public-hero-copy,
.public-body .hero-summary-panel,
.public-body .product-card-clean,
.public-body .service-card-clean,
.public-body .post-card-clean,
.public-body .public-section-head,
.public-body .about-inline-panel,
.public-body .catalog-toolbar-clean,
.public-body .contact-form-panel-clean,
.public-body .contact-info-panel-clean,
.public-body .public-footer-grid {
  animation: publicRise 0.7s ease both;
}

.public-body .product-card-clean:nth-child(2),
.public-body .service-card-clean:nth-child(2),
.public-body .post-card-clean:nth-child(2) {
  animation-delay: 0.07s;
}

.public-body .product-card-clean:nth-child(3),
.public-body .service-card-clean:nth-child(3),
.public-body .post-card-clean:nth-child(3) {
  animation-delay: 0.14s;
}

.public-body .product-card-clean:nth-child(4),
.public-body .service-card-clean:nth-child(4),
.public-body .post-card-clean:nth-child(4) {
  animation-delay: 0.21s;
}

@keyframes publicRise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .public-body .public-hero-copy,
  .public-body .hero-summary-panel,
  .public-body .product-card-clean,
  .public-body .service-card-clean,
  .public-body .post-card-clean,
  .public-body .public-section-head,
  .public-body .about-inline-panel,
  .public-body .catalog-toolbar-clean,
  .public-body .contact-form-panel-clean,
  .public-body .contact-info-panel-clean,
  .public-body .public-footer-grid {
    animation: none;
  }

  .public-body .product-card-clean,
  .public-body .service-card-clean,
  .public-body .post-card-clean,
  .public-body .btn,
  .public-body .public-site-nav a,
  .public-body .card-media-clean img,
  .public-body .post-media-clean img {
    transition: none;
  }
}

@media (max-width: 980px) {
  .public-body .public-hero-grid,
  .public-body .about-page-grid,
  .public-body .contact-layout-clean,
  .public-body .public-footer-grid,
  .public-body .catalog-toolbar-clean {
    grid-template-columns: 1fr;
  }

  .public-body .public-nav-wrap {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .public-body .public-site-nav {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .public-body .section {
    padding: 74px 0;
  }

  .public-body .public-header {
    padding: 12px 0;
  }

  .public-body .public-nav-wrap,
  .public-body .public-hero-copy,
  .public-body .hero-summary-panel,
  .public-body .about-inline-panel,
  .public-body .about-copy-panel,
  .public-body .about-meta-panel,
  .public-body .contact-form-panel-clean,
  .public-body .contact-info-panel-clean,
  .public-body .catalog-toolbar-clean,
  .public-body .public-footer-grid {
    padding: 20px;
  }

  .public-body .public-site-nav {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .public-body .public-site-nav a {
    width: 100%;
  }

  .public-body .public-hero-copy h1 {
    max-width: none;
    font-size: clamp(2.3rem, 9vw, 3.4rem);
  }

  .public-body .product-grid-clean,
  .public-body .service-grid-clean,
  .public-body .post-list-grid {
    grid-template-columns: 1fr;
  }

  .public-body .catalog-filters-clean {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .public-body .public-actions-row {
    display: grid;
    grid-template-columns: 1fr;
  }
}

/* === Admin Content Manager Enhancements === */
.card-tone-content {
  background: linear-gradient(135deg, #7c3aed, #4f46e5);
  color: #fff;
}

.admin-stats-five {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.content-manager-grid {
  gap: 24px;
}

.content-quick-links {
  margin-bottom: 20px;
}

.content-link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.content-link-card {
  display: grid;
  gap: 10px;
  padding: 18px;
  border-radius: 20px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.92),
    rgba(241, 246, 255, 0.92)
  );
  border: 1px solid rgba(90, 116, 170, 0.14);
  color: #162131;
  box-shadow: 0 16px 34px rgba(26, 39, 68, 0.07);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

.content-link-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 40px rgba(26, 39, 68, 0.12);
}

.content-link-card i {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
}

.content-link-card span {
  color: #61708a;
  line-height: 1.6;
}

.content-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 90;
}

.content-modal.is-open {
  display: block;
}

/* .content-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
} */

.content-modal-dialog {
  position: relative;
  z-index: 1;
  width: min(720px, calc(100% - 28px));
  margin: 6vh auto 0;
}

.compact-links {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

/* === Public Interaction and Mobile Refinements === */
.public-body .public-nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--pub-blue), var(--pub-cyan));
  color: #fff;
  font-size: 1rem;
  box-shadow: 0 16px 28px rgba(53, 99, 255, 0.22);
  cursor: pointer;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.public-body .public-nav-toggle:hover {
  transform: scale(1.06);
  box-shadow: 0 20px 36px rgba(53, 99, 255, 0.3);
}

.public-body .public-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.36);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.24s ease,
    visibility 0.24s ease;
  z-index: 40;
}

.public-body.public-menu-open .public-nav-overlay {
  opacity: 1;
  visibility: visible;
}

.public-body .service-grid-home {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.public-body .service-media-clean {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  aspect-ratio: 4 / 3;
  margin-bottom: 18px;
  background: linear-gradient(135deg, #edf4ff, #f2fbff);
}

.public-body .service-media-clean img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.public-body .service-card-clean:hover .service-media-clean img {
  transform: scale(1.06);
}

.public-body .service-content-clean {
  display: grid;
  gap: 10px;
}

.public-body .post-list-home {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.public-body .post-card-compact .post-media-clean {
  aspect-ratio: 16 / 10;
}

.public-body .post-card-compact .post-body-clean {
  padding: 18px 18px 20px;
}

.public-body .catalog-filters-two {
  grid-template-columns: minmax(0, 1fr) auto;
  width: min(420px, 100%);
}

.public-body .public-list-summary {
  margin: 0 0 16px;
  color: var(--pub-muted);
  font-weight: 700;
}

.public-body .public-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 24px;
}

.public-body .public-page-link {
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(22, 32, 51, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--pub-text);
  font-weight: 800;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}

.public-body .public-page-link:hover,
.public-body .public-page-link.active {
  background: linear-gradient(135deg, var(--pub-blue), var(--pub-cyan));
  color: #fff;
  box-shadow: 0 14px 28px rgba(53, 99, 255, 0.22);
  transform: translateY(-2px);
}

.public-body .public-empty-state {
  grid-column: 1 / -1;
}

@media (max-width: 760px) {
  .public-body .catalog-filters-two,
  .public-body .catalog-filters-clean {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .content-modal-dialog {
    width: calc(100% - 20px);
    margin-top: 3vh;
  }
}

/* === Focused Contact Inbox + Public Menu Cleanup === */
.reply-source-box {
  padding: 16px 18px;
  margin-bottom: 16px;
  border-radius: 18px;
  background: rgba(37, 99, 235, 0.06);
  border: 1px solid rgba(37, 99, 235, 0.12);
}

.reply-source-box p {
  margin: 8px 0 0;
  color: #61708a;
  line-height: 1.7;
}

.badge-soft-green {
  background: rgba(15, 118, 110, 0.12);
  color: #0f766e;
}

.badge-soft-amber {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.public-body .public-nav-panel-head {
  display: none;
}

.public-body .public-nav-close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: rgba(53, 99, 255, 0.08);
  color: var(--pub-text);
}

/* === Premium Public Navigation Sidebar === */
@media (max-width: 980px) {
  .public-body .public-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    justify-self: end;
    z-index: 60;
  }

  .public-body .public-nav-wrap {
    grid-template-columns: 1fr auto;
    align-items: center;
    position: relative;
  }

  /* Let the brand shrink instead of pushing the toggle off-screen. */
  .public-body .public-nav-wrap .brand-with-mark {
    min-width: 0;
  }

  .public-body .public-nav-wrap .brand-text {
    min-width: 0;
    overflow: hidden;
  }

  .public-body .public-nav-wrap .brand-text span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .public-body .public-site-nav {
    position: fixed;
    top: 0;
    left: 0;
    height: 100dvh;
    width: min(340px, 88vw);
    padding: 24px 20px 32px;
    border-radius: 0 28px 28px 0;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 0 80px rgba(16, 36, 58, 0.15);
    transform: translateX(-105%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 70;
    /* Stack the links in a single vertical column (override the desktop
       horizontal flex-wrap row, which made them spill into two columns). */
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: flex-start;
    align-content: start;
    gap: 16px;
    overflow-y: auto;
    overflow-x: hidden;
    visibility: hidden;
  }

  .public-body .public-nav-panel-head {
    width: 100%;
    flex: 0 0 auto;
  }

  .public-body.public-menu-open .public-site-nav {
    transform: translateX(0);
    box-shadow: 24px 0 60px rgba(16, 36, 58, 0.18);
    -webkit-transform: translateX(0);
    -moz-transform: translateX(0);
    -ms-transform: translateX(0);
    -o-transform: translateX(0);
    visibility: visible;
    opacity: 1;
  }

  .public-body .public-nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(14, 23, 40, 0.48);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition:
      opacity 0.3s ease,
      visibility 0.3s ease;
    /* z-index: 65; */
  }

  .public-body.public-menu-open .public-nav-overlay {
    opacity: 1;
    visibility: visible;
  }

  .public-body .public-nav-panel-head {
    display: flex;
    gap: 40px;

    align-items: center;
    justify-content: space-between;
    padding: 8px 0 18px;
    border-bottom: 1px solid rgba(22, 32, 51, 0.08);
    margin-bottom: 8px;
  }

  .public-body .public-nav-panel-head strong {
    font-size: 1.1rem;
    font-weight: 800;
    color: #10243a;
    letter-spacing: -0.02em;
  }

  .public-body .public-nav-close {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: linear-gradient(
      135deg,
      rgba(53, 99, 235, 0.1),
      rgba(23, 199, 216, 0.08)
    );
    color: #10243a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
  }

  .public-body .public-nav-close:hover {
    background: linear-gradient(
      135deg,
      rgba(53, 99, 235, 0.18),
      rgba(23, 199, 216, 0.14)
    );
    transform: scale(1.05);
  }

  .public-body .public-site-nav a {
    width: 100%;
    min-height: 52px;
    padding: 14px 18px;
    border-radius: 16px;
    font-size: 1rem;
    font-weight: 700;
    justify-content: flex-start;
    transition: all 0.22s ease;
    position: relative;
  }

  .public-body .public-site-nav a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 0;
    border-radius: 4px;
    background: linear-gradient(180deg, #3563ff, #17c7d8);
    transition: height 0.22s ease;
  }

  .public-body .public-site-nav a:hover,
  .public-body .public-site-nav a.active {
    background: linear-gradient(
      135deg,
      rgba(53, 99, 235, 0.08),
      rgba(23, 199, 216, 0.06)
    );
    color: #10243a;
    transform: translateX(4px);
  }

  .public-body .public-site-nav a:hover::before,
  .public-body .public-site-nav a.active::before {
    height: 28px;
  }

  .public-body .public-site-nav a i {
    width: 28px;
    text-align: center;
    font-size: 1.05rem;
  }

  .public-body .public-site-nav .nav-cta {
    margin-top: 8px;
    padding-top: 16px;
    border-top: 1px solid rgba(22, 32, 51, 0.08);
  }

  .public-body .public-site-nav .nav-cta a {
    background: linear-gradient(135deg, #3563ff, #17c7d8);
    color: #fff;
    justify-content: center;
    box-shadow: 0 12px 24px rgba(53, 99, 235, 0.24);
  }

  .public-body .public-site-nav .nav-cta a:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(53, 99, 235, 0.28);
  }
}

/* === Final Layout and Reply Management Fixes === */
/* === Premium Admin Layout System === */
@media (min-width: 981px) {
  .admin-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    min-height: 100vh;
    position: relative;
  }

  .admin-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    z-index: 60;
    display: grid;
    align-content: start;
    overflow-y: auto;
    overflow-x: hidden;
  }

  .admin-sidebar-head {
    position: sticky;
    top: 0;
    z-index: 10;
    background: linear-gradient(180deg, #162032 0%, #1f3b79 100%);
    padding-bottom: 20px;
  }

  .admin-content {
    grid-column: 2;
    margin-left: 0;
    width: 100%;
    min-width: 0;
    padding: 28px 32px 40px;
    max-width: 100%;
    overflow-x: hidden;
  }

  .admin-content::before {
    content: "";
    position: fixed;
    top: 0;
    left: 280px;
    right: 0;
    height: 100vh;
    background:
      radial-gradient(
        circle at 20% 10%,
        rgba(37, 99, 235, 0.08),
        transparent 40%
      ),
      radial-gradient(
        circle at 80% 90%,
        rgba(15, 118, 110, 0.06),
        transparent 35%
      ),
      linear-gradient(180deg, #f4f7fb 0%, #eef2f7 100%);
    pointer-events: none;
    z-index: -1;
  }

  .admin-page-head,
  .admin-card,
  .dashboard-hero,
  .listing-shell,
  .admin-grid,
  .admin-stats {
    position: relative;
    z-index: 1;
    max-width: 100%;
  }

  /* Topbar must stay above all dashboard cards for notification dropdown to work */
  .admin-topbar {
    position: sticky;
    top: 16px;
    z-index: 999;
    max-width: 100%;
  }

  /* Subtle content wrapper */
  .admin-content > *:not(.admin-topbar):not(.listing-shell) {
    position: relative;
  }
}

.table-actions .action-btn + .action-btn {
  margin-left: 6px;
}

@media (max-width: 980px) {
  .public-body .public-site-nav {
    width: min(380px, 92vw);
    padding: 24px 18px 32px;
  }

  /* .public-body .public-nav-overlay {
    backdrop-filter: blur(5px);
  } */
}

/* ===================================================================
   NOTIFICATION SYSTEM
   =================================================================== */
.notif-bell-wrap {
  position: relative;
  display: inline-flex;
}

.notif-bell-btn {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(37, 99, 235, 0.08);
  color: #1e3a5f;
  font-size: 1.1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    background 0.18s ease,
    transform 0.18s ease;
  position: relative;
}

.notif-bell-btn:hover {
  background: rgba(37, 99, 235, 0.16);
  transform: scale(1.06);
}

.notif-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: #dc2626;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 18px;
  text-align: center;
  display: none;
  border: 2px solid #fff;
}

.notif-badge.is-visible {
  display: block;
}

/* Centered popup panel (modal-style, opens in the middle of the screen) */
.notif-dropdown {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 380px;
  max-width: calc(100vw - 32px);
  max-height: 72vh;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 30px 70px rgba(16, 36, 60, 0.28);
  border: 1px solid rgba(22, 32, 51, 0.08);
  z-index: 9999;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -50%) scale(0.96);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0.2s ease;
}

.notif-dropdown.is-open {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
  /* keep the base 9999 — never lower it while open, or it sinks behind cards */
  z-index: 9999;
}

.notif-dropdown-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px 14px;
  border-bottom: 1px solid rgba(22, 32, 51, 0.07);
  flex-shrink: 0;
}

.notif-dropdown-head strong {
  font-size: 0.95rem;
  font-weight: 800;
  color: #0f1f36;
}

.notif-mark-all {
  border: 0;
  background: none;
  color: #2563eb;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: background 0.16s;
}

.notif-mark-all:hover {
  background: rgba(37, 99, 235, 0.08);
}

.notif-list {
  overflow-y: auto;
  flex: 1;
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 18px;
  border-bottom: 1px solid rgba(22, 32, 51, 0.05);
  cursor: pointer;
  transition: background 0.16s;
  position: relative;
}

.notif-item:last-child {
  border-bottom: 0;
}

.notif-item:hover {
  background: rgba(37, 99, 235, 0.04);
}

.notif-item.is-unread {
  background: rgba(37, 99, 235, 0.05);
}

.notif-item.is-unread::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #2563eb;
}

.notif-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.notif-icon.type-comment {
  background: rgba(37, 99, 235, 0.1);
  color: #2563eb;
}
.notif-icon.type-contact {
  background: rgba(15, 118, 110, 0.1);
  color: #0f766e;
}
.notif-icon.type-reply {
  background: rgba(139, 92, 246, 0.1);
  color: #7c3aed;
}
.notif-icon.type-system {
  background: rgba(245, 158, 11, 0.1);
  color: #b45309;
}

.notif-body {
  flex: 1;
  min-width: 0;
}

.notif-body p {
  margin: 0 0 3px;
  font-size: 0.84rem;
  color: #1e3a5f;
  line-height: 1.45;
}

.notif-body span {
  font-size: 0.76rem;
  color: #6b7e97;
}

.notif-del-btn {
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: #9aaabf;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition:
    opacity 0.16s,
    background 0.16s;
  flex-shrink: 0;
}

.notif-item:hover .notif-del-btn {
  opacity: 1;
}

.notif-del-btn:hover {
  background: rgba(220, 38, 38, 0.1);
  color: #dc2626;
}

.notif-empty {
  text-align: center;
  padding: 40px 20px;
  color: #8899b4;
  font-size: 0.87rem;
}

.notif-empty i {
  font-size: 2rem;
  display: block;
  margin-bottom: 10px;
  opacity: 0.4;
}

.notif-dropdown-foot {
  padding: 12px 18px;
  border-top: 1px solid rgba(22, 32, 51, 0.07);
  text-align: center;
  flex-shrink: 0;
}

.notif-dropdown-foot a {
  font-size: 0.82rem;
  font-weight: 700;
  color: #2563eb;
  text-decoration: none;
}

.notif-dropdown-foot a:hover {
  text-decoration: underline;
}

@media (max-width: 520px) {
  .notif-dropdown {
    width: calc(100vw - 24px);
    right: -60px;
  }
}

/* ===================================================================
   ADMIN SIDEBAR v2 — grouped nav with section labels
   =================================================================== */

/* Sidebar brand (smaller logo) */
.sidebar-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #fff;
}

.sidebar-logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.18);
  flex-shrink: 0;
}

.sidebar-logo-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Manrope", sans-serif;
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #0f766e);
}

/* Navigation groups */
.sidebar-nav-group {
  display: grid;
  gap: 2px;
  margin-bottom: 4px;
}

.sidebar-nav-label {
  display: block;
  padding: 12px 14px 6px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
}

/* Sidebar links */
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
  position: relative;
}

.sidebar-link:hover {
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
  transform: translateX(3px);
}

.sidebar-link.active {
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.32),
    rgba(15, 118, 110, 0.22)
  );
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.sidebar-link.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 22px;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, #60a5fa, #34d399);
}

/* Icon bubble */
.sidebar-link-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.88rem;
  transition: background 0.2s ease;
}

.sidebar-link:hover .sidebar-link-icon,
.sidebar-link.active .sidebar-link-icon {
  background: rgba(255, 255, 255, 0.14);
}

/* Footer links */
.sidebar-footer-links {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: grid;
  gap: 2px;
}

.sidebar-link-ghost {
  color: rgba(255, 255, 255, 0.54);
}

.sidebar-link-danger:hover {
  background: rgba(220, 38, 38, 0.18);
  color: #fca5a5;
}

.sidebar-link-danger:hover .sidebar-link-icon {
  background: rgba(220, 38, 38, 0.2);
}

/* Keep sidebar scrollable and flex so footer sticks to bottom */
.admin-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 22px 14px;
}

/* Hero grid responsive */
@media (max-width: 860px) {
  .public-body .hero-grid-two-col {
    grid-template-columns: 1fr;
  }

  .public-body .hero-summary-panel {
    min-height: auto;
  }
}

/* ===================================================================
   ADMIN UI POLISH
   =================================================================== */

/* Topbar: cleaner page label */
.admin-topbar-copy strong {
  font-size: 1rem;
  font-weight: 800;
  color: #0f1f36;
  letter-spacing: -0.01em;
}

.admin-topbar-copy span {
  font-size: 0.82rem;
}

/* Sidebar head: tighter spacing */
.admin-sidebar-head {
  padding-bottom: 16px;
  margin-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Dashboard hero h1 size — greeting fits on one line */
.dashboard-hero h1 {
  font-size: clamp(1.7rem, 2.5vw, 2.3rem);
}

/* Topbar notification bell — align vertically */
.notif-bell-wrap {
  align-self: center;
}

/* Admin profile chip — more polished */
.admin-profile-chip strong {
  font-size: 0.88rem;
  font-weight: 800;
  color: #0f1f36;
}

/* Sidebar: ensure the footer links don't get cut */
@media (min-width: 981px) {
  .admin-sidebar {
    min-height: 100vh;
  }
}

/* ===================================================================
   PROFILE PAGE — stop card stretch, fix snapshot value overflow
   =================================================================== */
.profile-grid {
  align-items: start; /* snapshot card no longer stretches → no top gap */
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
}

.profile-grid .health-grid strong {
  font-family: "Manrope", sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1.35;
  margin-top: 6px;
  color: #0f1f36;
  word-break: break-word;
  overflow-wrap: anywhere; /* long emails wrap instead of overflowing */
}

.profile-grid .health-grid span {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
}

@media (max-width: 820px) {
  .profile-grid {
    grid-template-columns: 1fr;
  }
}

/* Settings: stop the Brand Preview card from stretching & bottom-aligning */
.settings-layout-wide {
  align-items: start;
}

/* Stack label over value in the preview tiles so they don't run together */
.settings-preview-grid > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.settings-preview-grid span {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.settings-layout-wide .settings-preview-grid strong {
  font-size: 0.95rem;
  word-break: break-word;
  overflow-wrap: anywhere;
}

/* ===================================================================
   DASHBOARD v3 — sectioned layout, traffic analytics, equal-height grids
   =================================================================== */

/* Section headers between dashboard blocks */
.dash-section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin: 2.4rem 0 0.2rem;
}

.dash-section-head h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: #0f1f36;
  margin: 0.35rem 0 0.2rem;
  letter-spacing: -0.01em;
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.08);
  padding: 6px 12px;
  border-radius: 40px;
}

/* Equal-height paired/triple grids — replaces the ragged auto-fit grid */
.dash-grid-2,
.dash-grid-3 {
  display: grid;
  gap: 1.6rem;
  margin-top: 1rem;
  align-items: stretch;
}

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

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

/* Wide chart + narrow companion */
.dash-grid-wide-left {
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
}

/* every card in these grids fills the row height evenly, content pinned to top */
.dash-grid-2 > .admin-card,
.dash-grid-3 > .admin-card {
  height: 100%;
  margin: 0;
  justify-content: flex-start;
}

/* lists/streams inside dashboard cards must start at the top, not stretch/center */
.dash-grid-2 .rank-list,
.dash-grid-3 .rank-list,
.dash-grid-2 .comment-stream,
.dash-grid-3 .comment-stream {
  align-self: stretch;
}

/* Traffic KPI strip */
.dash-traffic-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.2rem;
  margin-top: 1rem;
}

.traffic-kpi {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 22px;
  padding: 1.1rem 1.2rem;
  box-shadow: 0 8px 20px -10px rgba(16, 36, 60, 0.12);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.traffic-kpi:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 30px -14px rgba(16, 36, 60, 0.2);
}

.kpi-ic {
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  background: rgba(37, 99, 235, 0.1);
  color: #2563eb;
}

.kpi-ic-blue {
  background: rgba(37, 99, 235, 0.1);
  color: #2563eb;
}
.kpi-ic-green {
  background: rgba(15, 118, 110, 0.12);
  color: #0f766e;
}
.kpi-ic-amber {
  background: rgba(245, 158, 11, 0.14);
  color: #d97706;
}

.traffic-kpi .kpi-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6c7a91;
}

.traffic-kpi strong {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: #0f1f36;
  line-height: 1.1;
  margin: 2px 0;
}

.traffic-kpi small {
  font-size: 0.72rem;
  color: #8b9ab0;
}

.kpi-live {
  background: linear-gradient(135deg, #0f766e 0%, #115e59 100%);
  border-color: transparent;
}
.kpi-live .kpi-ic {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}
.kpi-live .kpi-label {
  color: rgba(255, 255, 255, 0.78);
}
.kpi-live strong {
  color: #fff;
}
.kpi-live small {
  color: rgba(255, 255, 255, 0.7);
}

/* Live pulse dot */
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  display: inline-block;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  animation: livePulse 1.8s infinite;
}
.kpi-live .live-dot {
  background: #6ee7b7;
  box-shadow: 0 0 0 0 rgba(110, 231, 183, 0.7);
}

.metric-live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

@keyframes livePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.6);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

.stream-badge-visitor {
  background: linear-gradient(145deg, #ecfdf5, #d1fae5);
  color: #0f766e;
}

/* Keep chart canvases from stretching cards unevenly */
.dash-grid-2 .chart-card canvas,
.dash-grid-wide-left .chart-card canvas {
  max-height: 240px;
}

/* Responsive */
@media (max-width: 1024px) {
  .dash-traffic-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .dash-grid-2,
  .dash-grid-3,
  .dash-grid-wide-left {
    grid-template-columns: 1fr;
  }
  .dash-traffic-kpis {
    grid-template-columns: 1fr;
  }
  .dash-section-head {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ===================================================================
   SOCIAL FEED — public posts as social-media cards
   =================================================================== */
.social-feed {
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 640px;
  margin: 0 auto;
}

.social-post {
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 22px;
  box-shadow: 0 10px 30px -18px rgba(16, 36, 60, 0.28);
  overflow: hidden;
  transition:
    box-shadow 0.25s ease,
    transform 0.25s ease;
}

.social-post:hover {
  box-shadow: 0 18px 40px -20px rgba(16, 36, 60, 0.34);
}

/* Header */
.sp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 6px;
}

.sp-author {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  min-width: 0;
}

.sp-avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid rgba(37, 99, 235, 0.12);
}

.sp-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #0f766e);
}

.sp-author-meta {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.sp-author-meta strong {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.96rem;
  font-weight: 800;
  color: #0f1f36;
}

.sp-verified {
  color: #2563eb;
  font-size: 0.82rem;
}

.sp-time {
  font-size: 0.78rem;
  color: #8b9ab0;
}

.sp-back {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #475569;
  background: #f1f5f9;
  text-decoration: none;
  transition:
    background 0.2s ease,
    color 0.2s ease;
  flex-shrink: 0;
}

.sp-back:hover {
  background: #2563eb;
  color: #fff;
}

/* Content */
.sp-content {
  padding: 4px 18px 12px;
}

.sp-title {
  margin: 0 0 6px;
  font-size: 1.18rem;
  font-weight: 800;
  line-height: 1.3;
}

.sp-title a {
  color: #0f1f36;
  text-decoration: none;
}

.sp-title a:hover {
  color: #2563eb;
}

.sp-title-lg {
  font-size: 1.6rem;
  font-family: "Cormorant Garamond", serif;
  font-weight: 700;
}

.sp-text {
  margin: 0;
  color: #44506a;
  font-size: 0.96rem;
  line-height: 1.65;
}

.sp-text-full {
  white-space: normal;
}

.sp-more {
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

.sp-more:hover {
  text-decoration: underline;
}

/* Media */
.sp-media {
  display: block;
  background: #0b1220;
}

.sp-media img {
  display: block;
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

.sp-media-single img {
  max-height: 640px;
}

/* Stats row */
.sp-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 12px 18px;
  border-bottom: 1px solid #f0f2f5;
  font-size: 0.82rem;
  color: #6c7a91;
}

.sp-stats b {
  color: #0f1f36;
  font-weight: 800;
}

.sp-stat-ic {
  color: #e0245e;
}

/* Action bar */
.sp-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 6px 10px;
  gap: 4px;
}

.sp-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 8px;
  border: 0;
  background: transparent;
  border-radius: 12px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 700;
  color: #5b6678;
  transition:
    background 0.18s ease,
    color 0.18s ease,
    transform 0.18s ease;
}

.sp-action:hover {
  background: #f3f6fb;
  color: #0f1f36;
}

.sp-action i {
  font-size: 1.02rem;
}

/* Like icon swap */
.sp-action .sp-ic-solid {
  display: none;
  color: #e0245e;
}

.sp-action.like-button.liked {
  color: #e0245e;
}

.sp-action.like-button.liked .sp-ic-line {
  display: none;
}

.sp-action.like-button.liked .sp-ic-solid {
  display: inline-block;
}

.sp-action.is-popping {
  transform: scale(1.12);
}

/* Comment panel */
.sp-comments {
  padding: 14px 18px 18px;
  border-top: 1px solid #f0f2f5;
  background: #fbfcfe;
}

.sp-comment-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.sp-comment-name {
  width: 100%;
  max-width: 240px;
  padding: 9px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-size: 0.88rem;
}

.sp-comment-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.sp-comment-row textarea {
  flex: 1;
  resize: none;
  padding: 11px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  font-size: 0.92rem;
  line-height: 1.4;
  min-height: 44px;
  font-family: inherit;
}

.sp-comment-row textarea:focus,
.sp-comment-name:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.sp-comment-send {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, #2563eb, #0f766e);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.sp-comment-send:hover {
  transform: scale(1.06);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.28);
}

.sp-comment-loading {
  padding: 10px 4px;
  color: #8b9ab0;
  font-size: 0.88rem;
}

/* Comment items inside the feed */
.sp-comment-list .comment-item {
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 14px;
  padding: 10px 14px;
  margin-bottom: 8px;
}

.sp-comment-list .comment-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.sp-comment-list .comment-head strong {
  font-size: 0.88rem;
  color: #0f1f36;
}

.sp-comment-list .comment-head span {
  font-size: 0.72rem;
  color: #94a3b8;
}

.sp-comment-list .comment-item p {
  margin: 4px 0 0;
  font-size: 0.9rem;
  color: #44506a;
  line-height: 1.5;
}

.sp-comment-list .comment-reply {
  background: rgba(37, 99, 235, 0.05);
  border-color: rgba(37, 99, 235, 0.15);
  margin-left: 18px;
}

.sp-comment-list .comment-reply strong {
  color: #2563eb;
}

/* Single post tweaks */
.social-feed-single {
  max-width: 720px;
}

.social-post-single .sp-comments {
  background: #fff;
}

/* Responsive */
@media (max-width: 680px) {
  .sp-actions .sp-action span {
    display: none;
  }
  .sp-title-lg {
    font-size: 1.35rem;
  }
}

/* ===================================================================
   SOCIAL GRID — product cards in social style, multi-column
   =================================================================== */
.social-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 22px;
  align-items: start;
}

/* In the grid, social cards are not width-constrained like the feed */
.social-grid .social-post {
  margin: 0;
}

/* Product card media height kept tidy for grid */
.product-social .sp-media {
  position: relative;
}

.product-social .sp-media img {
  max-height: 260px;
}

.sp-price-tag {
  position: absolute;
  left: 12px;
  bottom: 12px;
  background: rgba(15, 23, 42, 0.86);
  color: #fff;
  font-weight: 800;
  font-size: 0.92rem;
  padding: 6px 14px;
  border-radius: 40px;
  backdrop-filter: blur(4px);
}

.sp-cat-ic {
  color: #0f766e;
  font-size: 0.72rem;
}

/* ── Comment edit/delete tools ── */
.comment-head-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.comment-tools {
  display: inline-flex;
  gap: 4px;
}

.comment-tools button {
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 8px;
  background: #eef2f7;
  color: #64748b;
  font-size: 0.72rem;
  cursor: pointer;
  transition:
    background 0.18s ease,
    color 0.18s ease;
}

.comment-tools button:hover {
  background: #2563eb;
  color: #fff;
}

.comment-tools .js-comment-delete:hover {
  background: #dc2626;
}

@media (max-width: 560px) {
  .social-grid {
    grid-template-columns: 1fr;
  }
}

/* ===================================================================
   UNIFORM CARD SIZING (listing cards) + PRODUCT SINGLE extras
   =================================================================== */

/* Equal-size product grid cards: fixed media + clamped title/text.
   Base height becomes identical so align-items:start keeps them uniform,
   while an opened comment panel only grows its own card. */
.social-grid .sp-media img {
  height: 220px;
  width: 100%;
  object-fit: cover;
}

.social-grid .sp-title,
.social-feed:not(.social-feed-single) .sp-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.social-grid .sp-title {
  -webkit-line-clamp: 1;
  line-clamp: 1;
  min-height: 1.5em;
}

.social-grid .sp-text,
.social-feed:not(.social-feed-single) .sp-text {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.social-grid .sp-text {
  -webkit-line-clamp: 2;
  line-clamp: 2;
  min-height: 3em;
}

/* Posts feed: consistent media height + clamped preview text */
.social-feed:not(.social-feed-single) .sp-media img {
  height: 360px;
  width: 100%;
  object-fit: cover;
}

.social-feed:not(.social-feed-single) .sp-title {
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.social-feed:not(.social-feed-single) .sp-text {
  -webkit-line-clamp: 3;
  line-clamp: 3;
}

/* ── Product single page extras ── */
.sp-price-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 2px 0 10px;
  flex-wrap: wrap;
}

.sp-price {
  font-size: 1.4rem;
  font-weight: 800;
  color: #0f766e;
}

.sp-uid {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #64748b;
  background: #f1f5f9;
  padding: 4px 10px;
  border-radius: 40px;
}

.sp-thumbs {
  display: flex;
  gap: 10px;
  padding: 12px 18px 0;
  flex-wrap: wrap;
}

.sp-thumb {
  width: 64px;
  height: 64px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  background: #f1f5f9;
  transition:
    border-color 0.18s ease,
    transform 0.18s ease;
}

.sp-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sp-thumb:hover {
  transform: translateY(-2px);
}

.sp-thumb.is-active {
  border-color: #2563eb;
}

/* ===================================================================
   POSTS PAGE — feed + recent-posts aside (right rail)
   =================================================================== */
.posts-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
}

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

/* feed fills the main column (no longer centered page-wide) */
.posts-main .social-feed {
  max-width: 600px;
  margin: 0 auto;
}

.posts-aside {
  /* Sticky, but pinned BELOW the sticky search bar (header 92px + the
     full-width filter bar that sits above the layout) so the two never
     overlap as the feed scrolls. */
  position: sticky;
  top: 210px;
  align-self: start;
}

.aside-widget {
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 10px 30px -18px rgba(16, 36, 60, 0.22);
}

.aside-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f0f2f5;
  font-size: 1rem;
  font-weight: 800;
  color: #0f1f36;
}

.aside-title i {
  color: #2563eb;
}

.aside-recent {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.aside-recent a {
  display: flex;
  gap: 12px;
  padding: 8px;
  border-radius: 12px;
  text-decoration: none;
  transition: background 0.18s ease;
}

.aside-recent a:hover {
  background: #f3f6fb;
}

.aside-thumb {
  width: 54px;
  height: 54px;
  flex-shrink: 0;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(135deg, #eef2f7, #e2e8f0);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
}

.aside-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.aside-rp-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  justify-content: center;
}

.aside-rp-meta strong {
  font-size: 0.88rem;
  font-weight: 700;
  color: #0f1f36;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.aside-rp-meta span {
  font-size: 0.72rem;
  color: #8b9ab0;
  margin-top: 3px;
}

@media (max-width: 980px) {
  .posts-layout {
    grid-template-columns: 1fr;
  }
  .posts-aside {
    position: static;
    max-width: 600px;
    margin: 0 auto;
    width: 100%;
  }
}

/* ===================================================================
   SIDEBAR NOTIFICATION BADGE + NOTIFICATIONS PAGE
   =================================================================== */
.sidebar-link-badge {
  margin-left: auto;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  background: #e23744;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.sidebar-link-badge.is-visible {
  display: inline-flex;
}

.notif-page-card {
  padding: 0;
  overflow: hidden;
}

.notif-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 22px;
  border-bottom: 1px solid #eef2f7;
}

.notif-page-head strong {
  font-size: 0.95rem;
  color: #1e3a5f;
}

.notif-page-list {
  display: flex;
  flex-direction: column;
}

.notif-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 22px;
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
  transition: background 0.16s ease;
  position: relative;
}

.notif-row:last-child {
  border-bottom: 0;
}

.notif-row:hover {
  background: #f8fafc;
}

.notif-row.is-unread {
  background: rgba(37, 99, 235, 0.04);
}

.notif-row.is-unread::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #2563eb;
}

.notif-row-body {
  flex: 1;
  min-width: 0;
  text-decoration: none;
}

.notif-row-body p {
  margin: 0 0 4px;
  font-size: 0.9rem;
  color: #1e3a5f;
  line-height: 1.45;
}

.notif-row-body span {
  font-size: 0.78rem;
  color: #6b7e97;
}

.notif-row .action-btn {
  opacity: 0;
  transition: opacity 0.16s ease;
}

.notif-row:hover .action-btn {
  opacity: 1;
}

.notif-empty-lg {
  padding: 60px 20px;
}

/* ===================================================================
   STICKY PUBLIC SEARCH BAR + CENTERED ADD-USER CARD
   =================================================================== */
.public-body .public-filter-form {
  position: sticky;
  /* Sits just below the ~82px sticky site header. */
  top: 92px;
  z-index: 30;
}

/* Centered "Add User" form card */
.add-user-card {
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}
