* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  padding: 0;
  background: #ecfdf5;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

button {
  cursor: pointer;
}

.title {
  color: #5C6AC4;
}

/* Local utility styles replacing the Tailwind CDN dependency. */
.w-full { width: 100%; }
.max-w-md { max-width: 28rem; }
.max-w-sm { max-width: 24rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.hidden { display: none !important; }
.flex { display: flex; }
.grid { display: grid; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.flex-col { flex-direction: column; }
.gap-1 { gap: .25rem; }
.gap-2 { gap: .5rem; }
.gap-3 { gap: .75rem; }
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.inset-0 { inset: 0; }
.z-50 { z-index: 50; }
.z-40 { z-index: 40; }
.z-30 { z-index: 30; }
.cursor-pointer { cursor: pointer; }

/* Core local utilities used by the application. */
.h-screen { height: 100vh; }
.h-\[100dvh\] { height: 100dvh; }
.min-h-\[80vh\] { min-height: 80vh; }
.h-10 { height: 2.5rem; }
.w-10 { width: 2.5rem; }
.w-16 { width: 4rem; }
.h-16 { height: 4rem; }
.h-40 { height: 10rem; }
.w-40 { width: 10rem; }
.w-44 { width: 11rem; }
.h-44 { height: 11rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-3 { padding: .75rem; }
.px-3 { padding-left: .75rem; padding-right: .75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-5 { padding-left: 1.25rem; padding-right: 1.25rem; }
.py-2 { padding-top: .5rem; padding-bottom: .5rem; }
.py-3 { padding-top: .75rem; padding-bottom: .75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.flex-1 { flex: 1 1 0%; }
.flex-none { flex: none; }
.overflow-hidden { overflow: hidden; }
.overflow-y-auto { overflow-y: auto; }
.text-center { text-align: center; }
.text-white { color: #fff; }
.text-gray-400 { color: #9ca3af; }
.text-gray-500 { color: #6b7280; }
.text-gray-600 { color: #4b5563; }
.text-gray-700 { color: #374151; }
.text-gray-800 { color: #1f2937; }
.text-brand-500 { color: #10b981; }
.text-brand-600, .text-brand-700 { color: #047857; }
.bg-white { background: #fff; }
.bg-gray-50 { background: #f9fafb; }
.bg-gray-100 { background: #f3f4f6; }
.bg-brand-700 { background: #047857; }
.bg-brand-600 { background: #059669; }
.bg-black\/60 { background: rgb(0 0 0 / 60%); }
.border { border-width: 1px; border-style: solid; }
.border-gray-100 { border-color: #f3f4f6; }
.border-gray-200 { border-color: #e5e7eb; }
.rounded-xl { border-radius: .75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-3xl { border-radius: 1.5rem; }
.shadow-sm { box-shadow: 0 1px 3px rgb(0 0 0 / 10%); }
.shadow-xl, .shadow-2xl { box-shadow: 0 15px 35px rgb(0 0 0 / 18%); }
.space-y-2 > * + * { margin-top: .5rem; }
.space-y-3 > * + * { margin-top: .75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.col-span-2 { grid-column: span 2 / span 2; }
.top-4 { top: 1rem; }
.left-1\/2 { left: 50%; }
.-translate-x-1\/2 { transform: translateX(-50%); }

/* Fallback visual styles for the authentication controls. */
.app-login-button {
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border: 1px solid #047857;
  border-radius: 0.75rem;
  background: #047857;
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.25rem;
  box-shadow: 0 8px 18px rgba(4, 120, 87, 0.25);
  transition: background-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.app-login-button:hover {
  background: #065f46;
  box-shadow: 0 10px 22px rgba(4, 120, 87, 0.35);
}

.app-login-button:active {
  transform: translateY(1px);
}

.app-login-button:focus-visible,
.app-logout-button:focus-visible {
  outline: 3px solid #fbbf24;
  outline-offset: 2px;
}

.app-logout-button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.5rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 0.75rem;
  background: #ffffff;
  color: #065f46;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1rem;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.app-logout-button:hover {
  background: #fef3c7;
  color: #92400e;
}

.app-logout-button:active {
  transform: translateY(1px);
}

/* Unggah foto anggota */
.member-photo-upload-field {
  padding: .7rem;
  border: 1px dashed #a7f3d0;
  border-radius: .85rem;
  background: #f0fdf8;
}

.member-photo-action-button {
  min-height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .25rem;
  padding: .35rem .55rem;
  border: 1px solid #a7f3d0;
  border-radius: .65rem;
  background: #ecfdf5;
  color: #047857;
  font-size: .68rem;
  font-weight: 700;
  cursor: pointer;
}

.member-photo-action-button:hover {
  background: #d1fae5;
  border-color: #10b981;
}

.member-photo-detail-action {
  width: auto;
  min-width: 10rem;
  margin: 0 auto;
  background: #ecfdf5;
  color: #065f46;
  border-color: #10b981;
}

.member-photo-status {
  margin: .35rem 0 0;
  color: #64748b;
  font-size: .65rem;
  line-height: 1.2;
  text-align: center;
}

#detail-member-photo-file {
  display: none !important;
}

#anggota-container > .bg-white {
  min-width: 0;
}

#anggota-container .anggota-card-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.portal-photo-upload-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .2rem;
  width: 100%;
  margin-top: .35rem;
  padding: .3rem .4rem;
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: .6rem;
  background: rgba(255, 255, 255, .16);
  color: #fff;
  font-size: .62rem;
  font-weight: 700;
  cursor: pointer;
}

.portal-photo-upload-button:hover {
  background: rgba(255, 255, 255, .28);
}

.anggota-card-actions {
  flex: 0 0 auto;
}

/* Member card media */
.member-card-info {
  min-width: 0;
  flex: 1 1 auto;
}

.member-card-info h4,
.member-card-info p {
  overflow-wrap: anywhere;
}

.member-photo { 
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #047857;
  background: #d1fae5;
  border: 2px solid rgba(255, 255, 255, 0.75);
}

.member-photo i {
  font-size: 1.75rem;
}

.member-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.member-photo-small {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  border-color: #a7f3d0;
}

.member-photo-large {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 1.25rem;
  color: #065f46;
}

.member-photo-modal {
  width: 4.75rem;
  height: 4.75rem;
  border-radius: 1.25rem;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

/* Duka cost checklist */
.duka-cost-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 6.5rem;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem;
  border: 1px solid #fde68a;
  border-radius: 0.75rem;
  background: #ffffff;
  font-size: 0.7rem;
}

.duka-cost-item.is-selected {
  border-color: #f59e0b;
  background: #fffbeb;
}

.duka-cost-item input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  accent-color: #d97706;
}

.duka-cost-label {
  min-width: 0;
  color: #78350f;
  font-weight: 600;
}

.duka-item-amount {
  width: 100%;
  min-width: 0;
  padding: 0.4rem 0.5rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.55rem;
  font-size: 0.7rem;
  outline: none;
}

.duka-item-amount:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 2px #fde68a;
}

.duka-item-amount:disabled {
  background: #f3f4f6;
  color: #9ca3af;
}

/* The utility class is also defined here so visibility does not depend on CDN loading. */
.hidden {
  display: none !important;
}

/* Dashboard summary layout */
.dashboard-summary-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(3, minmax(0, 1fr));
  gap: .75rem;
  width: 100%;
}

.dashboard-summary-card {
  display: block;
  min-width: 0;
  min-height: 8.5rem;
  padding: 1rem;
  overflow: hidden;
}

.dashboard-balance-card {
  display: block !important;
  min-height: 9.5rem;
  padding: 1.1rem;
  background: linear-gradient(135deg, #047857, #065f46) !important;
  color: #ffffff !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.dashboard-balance-card h3,
.dashboard-balance-card p,
.dashboard-balance-card span,
.dashboard-balance-card i {
  visibility: visible;
}

.dashboard-summary-card p,
.dashboard-summary-card h3 {
  overflow-wrap: anywhere;
}

@media (max-width: 420px) {
  .dashboard-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-balance-card {
    grid-column: 1 / -1;
    min-height: 9.5rem;
  }
}

/* Polished application theme */
:root {
  --brand-900: #064e3b;
  --brand-800: #065f46;
  --brand-700: #047857;
  --brand-600: #059669;
  --brand-500: #10b981;
  --ink: #172033;
  --muted: #64748b;
  --line: #e2e8f0;
  --surface: #ffffff;
  --soft: #f1f8f5;
  --shadow-soft: 0 8px 24px rgba(15, 23, 42, .06);
  --shadow-card: 0 12px 30px rgba(15, 23, 42, .08);
}

body {
  background:
    radial-gradient(circle at 10% 0%, rgba(167, 243, 208, .7), transparent 28rem),
    linear-gradient(135deg, #f0fdf8 0%, #f8fafc 52%, #ecfdf5 100%);
  color: var(--ink);
}

#app-shell {
  background: #f8fafc;
  box-shadow: 0 24px 70px rgba(6, 78, 59, .16);
}

#main-header {
  position: sticky;
  top: 0;
  min-height: 4.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: .75rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(255, 255, 255, .96);
  color: var(--ink);
  border-bottom: 1px solid rgba(226, 232, 240, .9);
  box-shadow: 0 8px 24px rgba(15, 23, 42, .08);
  backdrop-filter: blur(16px);
  z-index: 30;
}

#main-header > div:first-child {
  width: auto;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex: 0 0 auto;
}

#main-header h1 {
  color: var(--brand-900);
  font-size: 1.05rem;
  letter-spacing: .1em;
}

#main-header #user-role-label {
  color: var(--muted);
}

.website-header-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(.75rem, 2vw, 1.5rem);
  margin-left: auto;
}

.website-header-nav a {
  color: #475569;
  font-size: .78rem;
  font-weight: 700;
  text-decoration: none;
  transition: color .18s ease;
}

.website-header-nav a:hover {
  color: var(--brand-700);
}

.website-header-nav button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  min-height: 2.4rem;
  padding: .55rem 1rem;
  border: 0;
  border-radius: .75rem;
  background: var(--brand-700);
  color: #fff;
  font-size: .75rem;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(4, 120, 87, .2);
}

.website-header-nav button:hover {
  background: var(--brand-800);
}

#main-header > div:last-child {
  flex: 1 1 auto;
  justify-content: flex-end;
  min-width: 0;
}

/* Aksi dan notifikasi berada pada baris terpisah tepat di bawah header. */
.header-action-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .65rem;
  min-height: 3.25rem;
  padding: .45rem 1.25rem;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid #dbeafe;
  box-shadow: 0 4px 12px rgba(15, 23, 42, .06);
}

.header-action-buttons {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: .4rem;
  margin-left: auto;
}

.header-action-row .app-header-toast {
  flex: 1 1 auto;
  max-width: min(22rem, 62%);
}

.header-action-row .app-header-toast-content {
  background: #064e3b;
  border-color: #047857;
}

/* Header portal anggota: aksi dan notifikasi berada di bawah identitas STM. */
#main-header.member-portal-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: .65rem;
  align-items: stretch;
}

#main-header.member-portal-header > div:first-child {
  width: 100%;
}

#main-header.member-portal-header > div:last-child {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: .4rem;
}

#main-header.member-portal-header .app-header-toast {
  order: 1;
  max-width: min(100%, 22rem);
}

#main-header.member-portal-header #btn-member-portal {
  order: 2;
}

#main-header.member-portal-header #btn-logout {
  order: 3;
}

.app-header-toast {
  min-width: 0;
  max-width: min(16rem, 42vw);
  transition: opacity .25s ease, transform .25s ease;
}

.app-header-toast-content {
  display: flex;
  align-items: center;
  gap: .4rem;
  min-width: 0;
  padding: .5rem .7rem;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: .75rem;
  background: rgba(15, 23, 42, .82);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  line-height: 1rem;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .18);
}

.app-header-toast-content i {
  flex: 0 0 auto;
  color: #6ee7b7;
  font-size: 1rem;
}

.app-header-toast-content span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#main-container {
  padding: 1.25rem;
  background: linear-gradient(180deg, #f8fafc 0%, #f0fdf8 100%);
}

#main-container > section:not(#sec-login) > div:first-child h2,
#view-broadcast > div:first-child h2 {
  letter-spacing: -.025em;
}

.bg-white {
  background: rgba(255, 255, 255, .94);
}

.bg-white.rounded-2xl,
.bg-white.rounded-3xl {
  border-color: rgba(226, 232, 240, .9);
  box-shadow: var(--shadow-soft);
}

#sec-login > div {
  border: 0;
  box-shadow: var(--shadow-card);
  padding: 2rem;
}

#sec-login h2 {
  color: var(--brand-900);
  font-size: 1.45rem;
}

#sec-login .w-16 {
  background: linear-gradient(135deg, #d1fae5, #ecfdf5);
  box-shadow: 0 8px 18px rgba(16, 185, 129, .15);
}

input, textarea, select {
  background-color: #fff;
  color: var(--ink);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

input:focus, textarea:focus, select:focus {
  border-color: var(--brand-500) !important;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, .14);
}

button {
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, color .18s ease;
}

button:hover {
  transform: translateY(-1px);
}

button:active {
  transform: translateY(0);
}

.app-login-button {
  min-height: 50px;
  border: 0;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--brand-700), var(--brand-500));
  box-shadow: 0 10px 20px rgba(5, 150, 105, .22);
}

.app-login-button:hover {
  background: linear-gradient(135deg, var(--brand-800), var(--brand-600));
}

#nav-pengurus {
  padding-top: .65rem;
  padding-bottom: .7rem;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 -8px 20px rgba(15, 23, 42, .05);
}

#nav-pengurus button {
  border-radius: .9rem;
}

#nav-pengurus button:hover {
  background: #ecfdf5;
}

.member-photo {
  box-shadow: inset 0 0 0 1px rgba(4, 120, 87, .08);
}

#view-portal-member .bg-gradient-to-br {
  box-shadow: 0 16px 32px rgba(6, 78, 59, .2);
}

/* Tombol simpan perubahan profil anggota */
.app-profile-save-button {
  width: 100%;
  min-height: 3.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  margin-top: .25rem;
  padding: .85rem 1rem;
  border: 2px solid #047857;
  border-radius: 1rem;
  background: linear-gradient(135deg, #047857, #059669);
  color: #ffffff !important;
  font-size: .85rem;
  font-weight: 800;
  line-height: 1.25rem;
  box-shadow: 0 8px 18px rgba(4, 120, 87, .28);
}

.app-profile-save-button i {
  font-size: 1.15rem;
}

.app-profile-save-button:hover {
  background: linear-gradient(135deg, #065f46, #047857);
  box-shadow: 0 10px 22px rgba(4, 120, 87, .38);
}

.app-profile-save-button:focus-visible {
  outline: 3px solid #fbbf24;
  outline-offset: 3px;
}

/* Tombol pembayaran pada kartu QRIS anggota */
.member-payment-button {
  width: 100%;
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .7rem 1rem;
  border: 1px solid #047857;
  border-radius: .85rem;
  background: linear-gradient(135deg, #059669, #047857);
  color: #fff;
  font-size: .75rem;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(4, 120, 87, .2);
}

.member-payment-button:hover {
  background: linear-gradient(135deg, #047857, #065f46);
}

/* Modal surfaces */
[id^="modal-"] {
  background: rgba(15, 23, 42, .62);
  padding: 1rem;
}

[id^="modal-"] > div {
  max-height: calc(100dvh - 2rem);
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, .65);
  box-shadow: 0 24px 70px rgba(15, 23, 42, .25);
  animation: modal-in .2s ease-out;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(10px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

#toast > div {
  box-shadow: 0 12px 30px rgba(15, 23, 42, .22);
}

/* Kontras tombol navigasi bawah */
#nav-pengurus button {
  min-height: 3.25rem;
  color: #64748b !important;
  background: #ffffff;
  border: 1px solid transparent;
}

#nav-pengurus button.text-brand-600,
#nav-pengurus button.text-brand-700 {
  color: #ffffff !important;
  background: #047857 !important;
  border-color: #065f46 !important;
  box-shadow: 0 5px 12px rgba(4, 120, 87, .28);
}

#nav-pengurus button:not(.text-brand-600):not(.text-brand-700) {
  color: #334155 !important;
  background: #ffffff !important;
  border-color: #e2e8f0;
}

#nav-pengurus button:hover {
  color: #ffffff !important;
  background: #059669 !important;
  border-color: #047857 !important;
}

#nav-pengurus button:not(.text-brand-600):not(.text-brand-700):hover {
  color: #065f46 !important;
  background: #d1fae5 !important;
  border-color: #6ee7b7;
}

#nav-pengurus button span,
#nav-pengurus button i {
  color: inherit;
}

/* Teks tombol aksi selalu kontras dengan latarnya */
button.bg-white,
button.bg-gray-100 {
  color: #374151;
}

button.bg-emerald-100,
button.bg-brand-50 {
  color: #065f46;
}

/* Warna tombol aksi: utility lokal agar teks putih selalu memiliki latar kontras. */
.bg-amber-500 { background-color: #f59e0b; }
.bg-amber-600 { background-color: #d97706; }
.bg-amber-700 { background-color: #b45309; }
.bg-emerald-500 { background-color: #10b981; }
.bg-emerald-600 { background-color: #059669; }
.bg-emerald-700 { background-color: #047857; }
.bg-rose-600 { background-color: #e11d48; }
.bg-rose-700 { background-color: #be123c; }
.bg-blue-600 { background-color: #2563eb; }
.bg-blue-700 { background-color: #1d4ed8; }

button.bg-amber-600,
button.bg-emerald-600,
button.bg-rose-600,
button.bg-blue-600,
button.bg-brand-600 {
  color: #ffffff !important;
  border-color: transparent;
  font-weight: 700;
}

button.bg-amber-600:hover { background-color: #b45309 !important; }
button.bg-emerald-600:hover,
button.bg-brand-600:hover { background-color: #047857 !important; }
button.bg-rose-600:hover { background-color: #be123c !important; }
button.bg-blue-600:hover { background-color: #1d4ed8 !important; }

/* Navigasi aktif/nonaktif dibuat tegas dan tidak bergantung pada CDN. */
#nav-pengurus button {
  color: #334155 !important;
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
}

#nav-pengurus button.text-brand-600,
#nav-pengurus button.text-brand-700 {
  color: #ffffff !important;
  background: #047857 !important;
  border-color: #064e3b !important;
  box-shadow: 0 6px 14px rgba(4, 120, 87, .32);
}

#nav-pengurus button.text-brand-600:hover,
#nav-pengurus button.text-brand-700:hover {
  color: #ffffff !important;
  background: #065f46 !important;
}

#nav-pengurus button:not(.text-brand-600):not(.text-brand-700):hover {
  color: #064e3b !important;
  background: #d1fae5 !important;
  border-color: #10b981 !important;
}

@media (max-width: 420px) {
  #main-container { padding: 1rem; }
  #sec-login > div { padding: 1.35rem; }
  #main-header { padding-left: 1rem; padding-right: 1rem; }
  .duka-cost-item { grid-template-columns: auto minmax(0, 1fr); }
  .duka-item-amount { grid-column: 2; }
}

/* Tombol aksi anggota baru */
.new-member-action-button {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: .5rem .75rem;
  border: 1px solid #047857;
  border-radius: .75rem;
  background: #059669;
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1rem;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(4, 120, 87, .2);
}

.new-member-action-button:hover {
  background: #047857;
  border-color: #064e3b;
}

.member-exit-action-button {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: .5rem .75rem;
  border: 1px solid #be123c;
  border-radius: .75rem;
  background: #e11d48;
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1rem;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(225, 29, 72, .2);
}

.member-exit-action-button:hover {
  background: #be123c;
  border-color: #9f1239;
}

/* Tombol Pemutihan: oranye tegas agar berbeda dari Anggota Keluar. */
.bg-orange-600 { background-color: #ea580c; }
.bg-orange-700 { background-color: #c2410c; }

.member-writeoff-action-button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: .25rem;
  padding: .5rem .75rem;
  border: 1px solid #c2410c !important;
  border-radius: .75rem;
  background: #ea580c !important;
  color: #ffffff !important;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1rem;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(234, 88, 12, .28);
}

.member-writeoff-action-button:hover {
  background: #c2410c !important;
  border-color: #9a3412 !important;
}

/* Tombol eksekusi pemutihan: oranye hanya saat siap dijalankan. */
#btn-eksekusi-pemutihan:not(:disabled) {
  background: #ea580c !important;
  border: 1px solid #c2410c !important;
  color: #ffffff !important;
  opacity: 1 !important;
  cursor: pointer;
  box-shadow: 0 5px 12px rgba(234, 88, 12, .28);
}

#btn-eksekusi-pemutihan:not(:disabled):hover {
  background: #c2410c !important;
  border-color: #9a3412 !important;
}

#btn-eksekusi-pemutihan:disabled {
  background: #cbd5e1 !important;
  border-color: #94a3b8 !important;
  color: #64748b !important;
  opacity: .7 !important;
  cursor: not-allowed;
  box-shadow: none;
}

.dashboard-outstanding-card {
  border: 3px solid #f97316 !important;
  box-shadow: 0 2px 10px rgba(249, 115, 22, .32) !important;
}

.dashboard-outstanding-card p,
.dashboard-outstanding-card .ph-warning {
  color: #ea580c !important;
}

.new-member-requirements-highlight {
  animation: new-member-highlight 1.2s ease;
}

@keyframes new-member-highlight {
  0%, 100% { box-shadow: var(--shadow-soft); }
  45% { box-shadow: 0 0 0 4px rgba(16, 185, 129, .28), var(--shadow-card); }
}

/* Kartu kewajiban anggota baru */
.new-member-requirements-card {
  padding: 1rem;
  border: 1px solid #a7f3d0;
  border-radius: 1rem;
  background: linear-gradient(135deg, #ecfdf5, #ffffff);
  box-shadow: var(--shadow-soft);
}

.new-member-requirements-heading {
  display: flex;
  align-items: center;
  gap: .7rem;
  margin-bottom: .8rem;
}

.new-member-requirements-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 auto;
  border-radius: .75rem;
  background: #047857;
  color: #fff;
  font-size: 1.15rem;
}

.new-member-requirements-heading h3 {
  margin: 0;
  color: #064e3b;
  font-size: .85rem;
  font-weight: 800;
}

.new-member-requirements-heading p {
  margin: .15rem 0 0;
  color: #64748b;
  font-size: .68rem;
}

.new-member-requirements-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .55rem;
}

.new-member-requirement-item {
  min-width: 0;
  padding: .65rem;
  border: 1px solid #d1fae5;
  border-radius: .75rem;
  background: rgba(255, 255, 255, .8);
}

.new-member-requirement-item span {
  display: block;
  color: #64748b;
  font-size: .65rem;
  line-height: 1.2;
}

.new-member-requirement-item strong {
  display: block;
  margin-top: .25rem;
  color: #047857;
  font-size: .78rem;
  overflow-wrap: anywhere;
}

.new-member-requirements-note {
  display: flex;
  align-items: center;
  gap: .3rem;
  margin: .75rem 0 0;
  color: #047857;
  font-size: .65rem;
}

@media (max-width: 520px) {
  .anggota-header-actions {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-end;
  }
}

@media (max-width: 360px) {
  .new-member-requirements-grid { grid-template-columns: 1fr; }
}

/* Samakan ukuran seluruh tombol aksi pada menu Anggota. */
.anggota-header-actions > button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .25rem;
  min-height: 2.5rem;
  height: 2.5rem;
  padding: .5rem .75rem;
  border-width: 1px;
  border-style: solid;
  border-radius: .75rem;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1rem;
  white-space: nowrap;
  box-sizing: border-box;
}

.anggota-header-actions > button i {
  font-size: 1rem;
  line-height: 1;
}

@media (max-width: 520px) {
  .anggota-header-actions > button {
    flex: 1 1 auto;
  }
}

/* Responsive mobile layout */
@media (max-width: 639px) {
  body {
    overflow-x: hidden;
  }

  #app-shell {
    width: 100%;
    min-width: 0;
  }

  #main-header {
    min-height: 68px;
    padding: .75rem 1rem;
    gap: .65rem;
  }

  #main-header > div:first-child {
    min-width: 0;
    gap: .6rem;
  }

  #main-header > div:first-child > div:first-child {
    width: 3.25rem;
    height: 3.25rem;
    flex: 0 0 auto;
    font-size: 1.7rem;
  }

  #main-header h1 {
    font-size: 1.05rem;
    white-space: nowrap;
  }

  #main-header p {
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  #main-header > div:last-child {
    gap: .35rem;
  }

  .header-action-row {
    align-items: stretch;
    padding: .45rem .9rem;
  }

  .header-action-row .app-header-toast {
    width: auto;
    max-width: 58%;
  }

  .header-action-buttons {
    flex: 0 0 auto;
  }

  .app-logout-button {
    min-height: 34px;
    padding: .4rem .6rem;
    font-size: .68rem;
  }

  #main-container {
    padding: .9rem;
    padding-bottom: 1.25rem;
  }

  #main-container > section:not(#sec-login) {
    min-width: 0;
  }

  #sec-login {
    min-height: calc(100dvh - 7rem);
    padding: .5rem 0;
  }

  #sec-login > div {
    padding: 1.25rem;
    border-radius: 1.35rem;
  }

  .dashboard-heading,
  #view-kas > div:first-child {
    align-items: flex-start;
    gap: .75rem;
  }

  .dashboard-heading > span {
    flex: 0 0 auto;
  }

  .dashboard-summary-card {
    min-height: 7.5rem;
    padding: .8rem;
  }

  .dashboard-summary-card p {
    font-size: .68rem;
  }

  .dashboard-summary-card .text-sm {
    font-size: .78rem;
  }

  .anggota-header-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: .5rem;
  }

  .anggota-header-actions > button {
    width: 100%;
    min-width: 0;
    height: auto;
    min-height: 2.75rem;
    padding: .5rem .4rem;
    white-space: normal;
    text-align: center;
  }

  .anggota-header-actions > button:last-child {
    grid-column: 1 / -1;
  }

  #view-anggota .bg-white.p-3\.5,
  #kas-history-list .bg-white.p-3\.5 {
    align-items: flex-start;
    gap: .65rem;
  }

  #view-anggota .bg-white.p-3\.5 > div:first-child,
  #kas-history-list .bg-white.p-3\.5 > div:first-child {
    min-width: 0;
  }

  #view-anggota .bg-white.p-3\.5 h4,
  #view-anggota .bg-white.p-3\.5 p,
  #kas-history-list .bg-white.p-3\.5 h4,
  #kas-history-list .bg-white.p-3\.5 p {
    overflow-wrap: anywhere;
  }

  #view-anggota .bg-white.p-3\.5 > button {
    flex: 0 0 auto;
  }

  #view-anggota .anggota-card-actions {
    flex: 0 0 auto;
    max-width: 7rem;
  }

  #view-anggota .member-photo-action-button {
    min-width: 2.5rem;
    padding-left: .4rem;
    padding-right: .4rem;
  }

  #view-anggota .member-photo-action-button span {
    display: none;
  }

  #view-kas > div:first-child {
    flex-wrap: wrap;
  }

  #view-kas > div:first-child > button {
    width: 100%;
  }

  #view-pengaturan > .bg-amber-50 {
    align-items: flex-start;
    flex-direction: column;
  }

  #view-pengaturan > .bg-amber-50 button {
    width: 100%;
  }

  #nav-pengurus {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: .2rem;
    padding: .45rem .4rem calc(.45rem + env(safe-area-inset-bottom));
  }

  #nav-pengurus button {
    min-height: 3rem;
    padding: .35rem .15rem;
  }

  #nav-pengurus button i {
    font-size: 1.15rem;
  }

  #nav-pengurus button span {
    font-size: .58rem;
  }

  [id^="modal-"] {
    align-items: flex-end;
    padding: .65rem;
  }

  [id^="modal-"] > div {
    width: 100%;
    max-width: none;
    max-height: calc(100dvh - 1.3rem);
    padding: 1rem;
    border-radius: 1.35rem;
  }

  .duka-cost-item {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .duka-item-amount {
    grid-column: 2;
  }

  .member-photo-large {
    width: 3.75rem;
    height: 3.75rem;
  }

  #view-portal-member .grid-cols-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 380px) {
  #main-container {
    padding-left: .7rem;
    padding-right: .7rem;
  }

  #main-header {
    padding-left: .75rem;
    padding-right: .75rem;
  }

  .header-action-row .app-header-toast {
    flex: 1 1 45%;
    max-width: 55%;
  }

  .header-action-buttons {
    width: auto;
    margin-left: auto;
  }

  .header-action-buttons .app-logout-button {
    flex: 0 1 auto;
  }

  #main-header h1 {
    font-size: .92rem;
  }

  #main-header p {
    font-size: .62rem;
  }

  .anggota-header-actions {
    grid-template-columns: 1fr;
  }

  .anggota-header-actions > button:last-child {
    grid-column: auto;
  }

  .dashboard-summary-grid {
    gap: .5rem;
  }

  .dashboard-summary-card {
    padding: .7rem;
  }
}

/* Kontras kartu digital anggota: tetap terbaca walaupun utility CSS lokal digunakan. */
#view-portal-member > .bg-gradient-to-br {
  background: linear-gradient(135deg, #064e3b 0%, #047857 52%, #064e3b 100%) !important;
  color: #ffffff !important;
}

#view-portal-member > .bg-gradient-to-br h3,
#view-portal-member > .bg-gradient-to-br p,
#view-portal-member > .bg-gradient-to-br span {
  color: #ffffff !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#view-portal-member > .bg-gradient-to-br #mportal-id,
#view-portal-member > .bg-gradient-to-br #mportal-alamat,
#view-portal-member > .bg-gradient-to-br #mportal-badge-status {
  color: #ffffff !important;
}

#view-portal-member > .bg-gradient-to-br #mportal-id,
#view-portal-member > .bg-gradient-to-br #mportal-alamat {
  text-shadow: 0 1px 2px rgba(0, 0, 0, .35);
}

#view-portal-member > .bg-gradient-to-br #mportal-badge-status {
  background: #10b981 !important;
  border: 1px solid rgba(255, 255, 255, .35);
}

/* Posisi identitas header benar-benar terpusat terhadap lebar header. */
#main-header {
  position: relative;
  min-height: 104px;
}

#main-header > div:first-child {
  width: max-content;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
}

#main-header > div:first-child > div:first-child {
  width: 4.5rem;
  height: 4.5rem;
  flex: 0 0 4.5rem;
  font-size: 2.35rem;
}

#main-header h1 {
  font-size: 1.5rem;
}

/* Tombol tetap di kanan tanpa menggeser identitas dari titik tengah. */
#main-header:not(.member-portal-header) > div:last-child {
  position: absolute;
  top: 50%;
  right: 1.25rem;
  transform: translateY(-50%);
}

/* Pada portal anggota, aksi tetap berada di bawah identitas. */
#main-header.member-portal-header > div:first-child {
  width: 100%;
}

#main-header.member-portal-header > div:last-child {
  position: static;
  transform: none;
}

@media (max-width: 639px) {
  #view-portal-member > .bg-gradient-to-br {
    padding: 1rem;
  }

  #view-portal-member > .bg-gradient-to-br h3 {
    font-size: 1.05rem;
    line-height: 1.25rem;
  }

  #view-portal-member > .bg-gradient-to-br .mt-6 {
    margin-top: 1.25rem;
  }
}

/* Override mobile sebelumnya agar identitas tetap benar-benar di tengah. */
@media (max-width: 639px) {
  #main-header {
    min-height: 92px;
  }

  #main-header > div:first-child {
    width: max-content;
    max-width: calc(100% - 1rem);
    margin-left: auto;
    margin-right: auto;
  }

  #main-header > div:first-child > div:first-child {
    width: 4rem;
    height: 4rem;
    flex-basis: 4rem;
    font-size: 2.05rem;
  }

  #main-header h1 {
    font-size: 1.2rem;
  }

  #main-header:not(.member-portal-header) > div:last-child {
    right: .75rem;
  }

  #main-header.member-portal-header > div:first-child {
    width: max-content;
    max-width: calc(100% - 1rem);
    margin-left: 0;
    margin-right: auto;
  }
}

/* Identitas STM Amanah ditempatkan di sisi kiri header. */
#main-header > div:first-child {
  width: max-content;
  max-width: calc(100% - 1rem);
  margin-left: 0;
  margin-right: auto;
  justify-content: flex-start;
}

#main-header.member-portal-header > div:first-child {
  width: max-content;
  max-width: calc(100% - 1rem);
  margin-left: 0;
  margin-right: auto;
}

/* Paksa identitas STM Amanah benar-benar menempel di kiri header. */
#main-header > div:first-child {
  align-self: flex-start !important;
  justify-self: start !important;
  margin-left: 0 !important;
  margin-right: auto !important;
  text-align: left !important;
  justify-content: flex-start !important;
}

#main-header.member-portal-header > div:first-child {
  align-self: start !important;
  justify-self: start !important;
  margin-left: 0 !important;
  margin-right: auto !important;
  text-align: left !important;
  justify-content: flex-start !important;
}

/* Halaman awal publik sebelum login */
#sec-landing {
  max-width: 46rem;
  margin: 0 auto;
  padding-top: .25rem;
  padding-bottom: 1rem;
}

#sec-landing > div:first-child {
  position: relative;
  isolation: isolate;
  border: 1px solid rgba(167, 243, 208, .55);
  background: linear-gradient(135deg, #064e3b 0%, #047857 52%, #065f46 100%);
  box-shadow: 0 18px 38px rgba(6, 78, 59, .22);
}

#sec-landing > div:first-child::after {
  content: '';
  position: absolute;
  right: -4rem;
  bottom: -5rem;
  width: 13rem;
  height: 13rem;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 50%;
  box-shadow: 0 0 0 1.5rem rgba(255, 255, 255, .04), 0 0 0 3rem rgba(255, 255, 255, .025);
  pointer-events: none;
}

#sec-landing > div:first-child > .relative {
  z-index: 1;
}

#sec-landing h2 {
  max-width: 38rem;
  color: #fff;
  letter-spacing: -.04em;
  text-wrap: balance;
}

#sec-landing h3,
#sec-landing h4 {
  letter-spacing: -.015em;
}

#sec-landing > div:first-child p {
  color: #d1fae5;
}

#sec-landing > div:first-child button:first-of-type {
  border: 1px solid #fbbf24;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .16);
}

#sec-landing > div:first-child button:first-of-type:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .22);
}

.landing-app-preview {
  position: relative;
  margin: 1.25rem auto 0;
  width: min(100%, 42rem);
  overflow: hidden;
  border: 1px solid rgba(167, 243, 208, .8);
  border-radius: 1rem;
  background: #f8fafc;
  box-shadow: 0 18px 34px rgba(6, 78, 59, .2);
  color: #172033;
  transform: perspective(1100px) rotateX(1deg);
}

.landing-preview-toolbar {
  display: flex;
  align-items: center;
  gap: .65rem;
  min-height: 2.2rem;
  padding: .45rem .7rem;
  background: #064e3b;
  color: #d1fae5;
  font-size: .58rem;
  font-weight: 700;
}

.landing-preview-dots { display: flex; gap: .25rem; }
.landing-preview-dots span { width: .42rem; height: .42rem; border-radius: 50%; background: #6ee7b7; opacity: .8; }
.landing-preview-title { flex: 1; text-align: center; letter-spacing: .03em; }
.landing-preview-live { display: inline-flex; align-items: center; gap: .2rem; color: #fcd34d; }

.landing-preview-body { display: flex; min-height: 15rem; }
.landing-preview-sidebar {
  display: flex;
  flex: 0 0 7rem;
  flex-direction: column;
  gap: .35rem;
  padding: .75rem .45rem;
  background: #ecfdf5;
  border-right: 1px solid #d1fae5;
}
.landing-preview-brand { display: flex; align-items: center; gap: .35rem; margin: 0 .3rem .6rem; color: #064e3b; font-size: .8rem; font-weight: 800; }
.landing-preview-brand i { color: #f59e0b; font-size: 1rem; }
.landing-preview-nav { display: flex; align-items: center; gap: .35rem; padding: .45rem .35rem; border-radius: .45rem; color: #64748b; font-size: .55rem; font-weight: 700; }
.landing-preview-nav i { font-size: .8rem; }
.landing-preview-nav.active { background: #047857; color: #fff; }
.landing-preview-content { flex: 1; min-width: 0; padding: .85rem; background: #f8fafc; }
.landing-preview-heading, .landing-preview-table-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.landing-preview-heading strong, .landing-preview-table-head strong { display: block; color: #172033; font-size: .72rem; }
.landing-preview-heading small { display: block; margin-top: .18rem; color: #64748b; font-size: .48rem; }
.landing-preview-secure { display: inline-flex; align-items: center; gap: .2rem; padding: .3rem .4rem; border-radius: 999px; background: #d1fae5; color: #047857; font-size: .48rem; font-weight: 800; white-space: nowrap; }
.landing-preview-cards { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: .45rem; margin: .8rem 0; }
.landing-preview-card { min-width: 0; min-height: 4.6rem; padding: .6rem; border: 1px solid #e2e8f0; border-radius: .65rem; background: #fff; box-shadow: 0 3px 8px rgba(15, 23, 42, .05); }
.landing-preview-card.balance { background: linear-gradient(135deg, #047857, #065f46); color: #fff; border-color: transparent; }
.landing-preview-card small { display: block; overflow: hidden; color: #64748b; font-size: .45rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.landing-preview-card.balance small { color: #d1fae5; }
.landing-preview-card strong { display: block; margin-top: .45rem; overflow: hidden; color: #047857; font-size: .72rem; text-overflow: ellipsis; white-space: nowrap; }
.landing-preview-card.balance strong { color: #fff; }
.landing-preview-card span { display: block; margin-top: .3rem; color: #94a3b8; font-size: .42rem; }
.landing-preview-card.balance span { color: #a7f3d0; }
.landing-preview-card.warning { border-color: #fed7aa; }
.landing-preview-card.warning strong { color: #ea580c; }
.landing-preview-table { padding: .7rem; border: 1px solid #e2e8f0; border-radius: .65rem; background: #fff; }
.landing-preview-table-head { padding-bottom: .45rem; border-bottom: 1px solid #f1f5f9; }
.landing-preview-table-head span { color: #047857; font-size: .48rem; font-weight: 700; }
.landing-preview-row { display: flex; align-items: center; gap: .45rem; padding: .5rem 0 0; color: #334155; font-size: .52rem; }
.landing-preview-row > i { display: grid; place-items: center; width: 1.35rem; height: 1.35rem; border-radius: .4rem; background: #d1fae5; color: #047857; }
.landing-preview-row > i.expense { background: #ffe4e6; color: #e11d48; }
.landing-preview-row span { flex: 1; font-weight: 700; }
.landing-preview-row small { display: block; margin-top: .12rem; color: #94a3b8; font-size: .42rem; font-weight: 500; }
.landing-preview-row b { color: #047857; font-size: .5rem; white-space: nowrap; }
.landing-preview-row b.expense-text { color: #e11d48; }

#landing-features > div:first-child {
  padding: .25rem .5rem;
}

#landing-features .grid > div {
  min-height: 8.5rem;
  border-color: rgba(167, 243, 208, .75);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

#landing-features .grid > div:hover {
  transform: translateY(-3px);
  border-color: #6ee7b7;
  box-shadow: 0 12px 24px rgba(6, 78, 59, .1);
}

#landing-features .grid > div h4 {
  color: #064e3b;
}

#sec-landing ol {
  padding-left: 1rem;
}

#sec-landing ol strong {
  color: #92400e;
}

/* Footer landing page: identitas layanan, privasi, dan tanggung jawab pengguna. */
.landing-footer {
  margin-top: 1.25rem;
  padding: 1.25rem;
  border: 1px solid #cbd5e1;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #064e3b 0%, #065f46 58%, #047857 100%);
  color: #d1fae5;
  box-shadow: 0 14px 30px rgba(6, 78, 59, .16);
}

.landing-footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.25rem;
  align-items: start;
}

.landing-footer-brand {
  display: flex;
  align-items: center;
  gap: .65rem;
}

.landing-footer-mark {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: .8rem;
  background: rgba(255, 255, 255, .14);
  color: #fcd34d;
  font-size: 1.2rem;
  overflow: hidden;
}

.landing-footer-logo img {
  width: 100%;
  height: 100%;
  display: block;
  padding: .3rem;
  object-fit: contain;
  object-position: center;
  background: #ffffff;
  border-radius: .6rem;
}

.landing-footer-brand strong,
.landing-footer-brand span {
  display: block;
}

.landing-footer-brand strong {
  color: #fff;
  font-size: .85rem;
  font-weight: 800;
}

.landing-footer-brand span {
  margin-top: .15rem;
  color: #a7f3d0;
  font-size: .62rem;
}

.landing-footer-description {
  max-width: 31rem;
  margin: .75rem 0 0;
  color: #d1fae5;
  font-size: .68rem;
  line-height: 1.55;
}

.landing-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .45rem;
}

.landing-footer-links a {
  padding: .4rem .55rem;
  border: 1px solid rgba(167, 243, 208, .4);
  border-radius: .6rem;
  color: #ecfdf5;
  font-size: .62rem;
  font-weight: 700;
  text-decoration: none;
}

.landing-footer-links a:hover {
  background: rgba(255, 255, 255, .14);
  border-color: #a7f3d0;
}

.landing-footer-notice {
  display: flex;
  align-items: flex-start;
  gap: .55rem;
  margin-top: 1rem;
  padding: .75rem;
  border: 1px solid rgba(167, 243, 208, .35);
  border-radius: .8rem;
  background: rgba(2, 44, 34, .24);
}

.landing-footer-notice > i {
  flex: 0 0 auto;
  margin-top: .1rem;
  color: #fcd34d;
  font-size: 1rem;
}

.landing-footer-notice p {
  margin: 0;
  color: #d1fae5;
  font-size: .62rem;
  line-height: 1.55;
}

.landing-footer-notice strong {
  color: #fff;
}

.landing-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  margin-top: 1rem;
  padding-top: .8rem;
  border-top: 1px solid rgba(167, 243, 208, .25);
  color: #a7f3d0;
  font-size: .58rem;
}

.landing-footer-compliance {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  color: #fcd34d;
  font-weight: 700;
}

@media (max-width: 639px) {
  .landing-footer {
    padding: 1rem;
  }

  .landing-footer-main {
    grid-template-columns: 1fr;
    gap: .85rem;
  }

  .landing-footer-links {
    justify-content: flex-start;
  }

  .landing-footer-bottom {
    align-items: flex-start;
    flex-direction: column;
    gap: .35rem;
  }
}

@media (max-width: 639px) {
  #sec-landing {
    padding-top: 0;
  }

  #sec-landing > div:first-child {
    padding: 1.25rem;
    border-radius: 1.35rem;
  }

  #sec-landing h2 {
    font-size: 1.65rem;
    line-height: 1.15;
  }

  #sec-landing .grid {
    gap: .55rem;
  }

  .landing-app-preview { margin-top: .9rem; transform: none; }
  .landing-preview-body { min-height: 13rem; }
  .landing-preview-sidebar { flex-basis: 4.25rem; padding-left: .3rem; padding-right: .3rem; }
  .landing-preview-brand { justify-content: center; margin-left: 0; margin-right: 0; }
  .landing-preview-brand span, .landing-preview-nav { font-size: 0; justify-content: center; }
  .landing-preview-nav i { font-size: .9rem; }
  .landing-preview-content { padding: .6rem; }
  .landing-preview-cards { gap: .3rem; margin: .6rem 0; }
  .landing-preview-card { padding: .45rem; min-height: 4.2rem; }
  .landing-preview-card strong { font-size: .58rem; }
  .landing-preview-table { padding: .55rem; }

  #landing-features .grid > div {
    min-height: 9rem;
    padding: .75rem;
  }
}

@media (max-width: 380px) {
  #sec-landing h2 {
    font-size: 1.45rem;
  }

  #sec-landing > div:first-child {
    padding: 1rem;
  }
}

/* Tombol aksi pada kotak judul: ringkas, sejajar, dan bergeser ke kanan. */
#sec-landing > div:first-child .relative > div:last-child {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
  margin-top: .25rem;
}

#sec-landing > div:first-child .relative > div:last-child button {
  width: auto;
  min-height: 2.15rem;
  padding: .45rem .75rem;
  border: 2px solid #064e3b;
  border-radius: .7rem;
  background: #d1fae5;
  color: #064e3b;
  font-size: .68rem;
  font-weight: 800;
  line-height: 1rem;
  box-shadow: 0 3px 8px rgba(6, 78, 59, .12);
}

#sec-landing > div:first-child .relative > div:last-child button:first-child {
  background: #a7f3d0;
  color: #064e3b;
}

#sec-landing > div:first-child .relative > div:last-child button:hover {
  background: #fcd34d;
  border-color: #022c22;
  box-shadow: 0 5px 12px rgba(6, 78, 59, .2);
}

@media (max-width: 639px) {
  #sec-landing > div:first-child .relative > div:last-child {
    justify-content: flex-end;
  }
}

@media (prefers-reduced-motion: reduce) {
  #landing-features .grid > div,
  #sec-landing > div:first-child button:first-of-type {
    transition: none;
  }
}

/* Header website publik yang responsif */
#main-header {
  position: sticky !important;
  top: 0;
  min-height: 4.5rem !important;
  height: auto;
  display: flex !important;
  align-items: center;
  justify-content: space-between !important;
  gap: 1rem;
  padding: .75rem clamp(1rem, 4vw, 2.5rem) !important;
  background: rgba(255, 255, 255, .96) !important;
  color: var(--ink) !important;
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .08);
  backdrop-filter: blur(16px);
}

#main-header > div:first-child {
  position: static !important;
  width: auto !important;
  max-width: 100%;
  min-width: 0;
  margin: 0 !important;
  display: flex;
  align-items: center;
  justify-content: flex-start !important;
  flex: 0 1 auto;
}

#main-header > div:first-child > div:first-child {
  width: 2.85rem !important;
  height: 2.85rem !important;
  flex-basis: 2.85rem !important;
  font-size: 1.5rem !important;
  background: linear-gradient(135deg, #d1fae5, #ecfdf5) !important;
  color: var(--brand-700) !important;
  border-color: #a7f3d0 !important;
}

#main-header h1 {
  color: var(--brand-900) !important;
  font-size: 1.25rem !important;
  letter-spacing: .06em;
  line-height: 1.15;
}

#main-header #user-role-label {
  color: #64748b !important;
}

#main-header > .website-header-nav {
  position: static !important;
  display: flex !important;
  width: auto !important;
  max-width: none;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(.65rem, 2vw, 1.4rem);
  margin: 0 0 0 auto !important;
  transform: none !important;
  flex: 0 0 auto;
}

@media (max-width: 639px) {
  #main-header {
    padding: .65rem .85rem !important;
  }

  #main-header > .website-header-nav {
    gap: .35rem;
  }

  #main-header > .website-header-nav a {
    display: none;
  }

  #main-header > .website-header-nav button {
    min-height: 2.25rem;
    padding: .5rem .7rem;
    font-size: .68rem;
  }

  #main-header h1 {
    font-size: 1.05rem !important;
    line-height: 1.15;
  }

  #main-header p {
    font-size: .62rem;
  }
}

@media (max-width: 380px) {
  #main-header > div:first-child > div:first-child {
    width: 2.5rem !important;
    height: 2.5rem !important;
    flex-basis: 2.5rem !important;
  }

  #main-header h1 {
    font-size: .98rem !important;
    line-height: 1.15;
  }
}

/* Ilustrasi pembayaran iuran di meja pelayanan */
.landing-payment-scene {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(17rem, 1.1fr);
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  overflow: hidden;
  border: 1px solid #fde68a;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #fffbeb, #fff 55%, #ecfdf5);
  box-shadow: 0 14px 30px rgba(120, 53, 15, .08);
}
.landing-payment-copy { min-width: 0; }
.landing-payment-copy h3 { margin: .5rem 0 .4rem; color: #78350f; font-size: 1.2rem; line-height: 1.2; letter-spacing: -.03em; }
.landing-payment-copy p { margin: 0; color: #64748b; font-size: .7rem; line-height: 1.55; }
.landing-scene-art { position: relative; min-height: 13rem; overflow: hidden; border-radius: 1rem; background: #dbeafe; }
.landing-people-photo {
  min-height: 13rem;
  background: #dbeafe;
}

.landing-people-photo img {
  width: 100%;
  height: 100%;
  min-height: 13rem;
  display: block !important;
  object-fit: cover;
  object-position: center center;
  border-radius: inherit;
  background: #dbeafe;
}

.landing-people-photo {
  display: block;
  width: 100%;
  min-height: 13rem;
}

.landing-people-photo img {
  opacity: 1;
  visibility: visible;
}

@media (max-width: 639px) {
  .landing-people-photo,
  .landing-people-photo img {
    min-height: 12rem;
  }
}
.landing-scene-window { position: absolute; top: 1rem; left: 50%; width: 7rem; height: 4.25rem; border: .45rem solid #fff; border-radius: .45rem; background: #bfdbfe; transform: translateX(-50%); box-shadow: 0 3px 8px rgba(15, 23, 42, .1); }
.landing-scene-window span { display: inline-block; width: .35rem; height: .35rem; margin: .3rem .05rem 0; border-radius: 50%; background: #f59e0b; }
.landing-person { position: absolute; bottom: 3.25rem; z-index: 2; text-align: center; }
.landing-person-admin { left: 10%; }
.landing-person-member { right: 10%; }
.landing-person-head { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; margin: auto; border: 3px solid #fff; border-radius: 50%; background: #fbbf8a; color: #78350f; font-size: 1.3rem; box-shadow: 0 3px 6px rgba(15, 23, 42, .15); }
.landing-person-body { display: grid; place-items: center; width: 4.3rem; height: 4.2rem; margin-top: -.15rem; border-radius: 1.3rem 1.3rem .5rem .5rem; background: #047857; color: #d1fae5; font-size: 1.65rem; box-shadow: 0 4px 8px rgba(15, 23, 42, .14); }
.landing-person-member .landing-person-body { background: #2563eb; color: #dbeafe; }
.landing-person-arm { position: absolute; right: -.6rem; bottom: .65rem; width: 2rem; height: .55rem; border-radius: 999px; background: #fbbf8a; transform: rotate(-18deg); }
.landing-person-member .landing-person-arm { right: auto; left: -.6rem; transform: rotate(18deg); }
.landing-scene-desk { position: absolute; right: 7%; bottom: 1.35rem; left: 7%; z-index: 3; height: 2.3rem; border-radius: .55rem; background: #92400e; box-shadow: 0 5px 8px rgba(120, 53, 15, .2); }
.landing-scene-laptop { position: absolute; bottom: 1.25rem; left: 50%; display: grid; place-items: center; width: 5.2rem; height: 3.15rem; border: .25rem solid #172033; border-radius: .35rem; background: #ecfdf5; color: #047857; font-size: .55rem; font-weight: 800; transform: translateX(-50%); }
.landing-scene-laptop i { color: #10b981; font-size: .9rem; }
.landing-scene-payment { position: absolute; right: .35rem; bottom: .35rem; display: flex; align-items: center; gap: .25rem; padding: .3rem; border-radius: .4rem; background: #fff; color: #047857; font-size: .42rem; box-shadow: 0 3px 6px rgba(15, 23, 42, .14); }
.landing-scene-payment i { font-size: .9rem; }
.landing-scene-smile-badge { position: absolute; top: .7rem; right: .65rem; display: inline-flex; align-items: center; gap: .2rem; padding: .3rem .45rem; border-radius: 999px; background: #047857; color: #fff; font-size: .48rem; font-weight: 800; box-shadow: 0 3px 8px rgba(6, 78, 59, .18); }
.landing-scene-smile-badge i { color: #fcd34d; }

/* Mockup ponsel pada halaman publik */
.landing-mobile-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 15rem;
  align-items: center;
  gap: 1.5rem;
  min-height: 24rem;
  padding: 1.25rem 1.5rem 0;
  overflow: hidden;
  border: 1px solid #a7f3d0;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 58%, #dbeafe 100%);
  box-shadow: 0 14px 30px rgba(6, 78, 59, .1);
}

.landing-mobile-copy { min-width: 0; }
.landing-mobile-kicker {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  color: #047857;
  font-size: .62rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.landing-mobile-copy h3 {
  margin: .55rem 0 .45rem;
  color: #064e3b;
  font-size: 1.35rem;
  line-height: 1.15;
  letter-spacing: -.035em;
}
.landing-mobile-copy p {
  max-width: 20rem;
  margin: 0;
  color: #64748b;
  font-size: .72rem;
  line-height: 1.6;
}
.landing-mobile-points {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  margin-top: .9rem;
}
.landing-mobile-points span {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  color: #047857;
  font-size: .62rem;
  font-weight: 700;
}
.landing-mobile-points i { color: #10b981; font-size: .85rem; }

.landing-phone {
  position: relative;
  justify-self: center;
  width: 12rem;
  height: 23rem;
  padding: .45rem;
  border: 3px solid #172033;
  border-radius: 1.75rem 1.75rem 1.4rem 1.4rem;
  background: #0f172a;
  box-shadow: 0 18px 28px rgba(15, 23, 42, .28), 0 0 0 5px rgba(255,255,255,.72);
  transform: rotate(2deg) translateY(.6rem);
}
.landing-phone::after {
  content: '';
  position: absolute;
  top: 4.5rem;
  right: -.28rem;
  width: .18rem;
  height: 2.5rem;
  border-radius: 0 .2rem .2rem 0;
  background: #334155;
}
.landing-phone-speaker {
  position: absolute;
  top: .7rem;
  left: 50%;
  z-index: 2;
  width: 3.4rem;
  height: .25rem;
  border-radius: 999px;
  background: #334155;
  transform: translateX(-50%);
}
.landing-phone-screen {
  position: relative;
  height: 100%;
  overflow: hidden;
  padding: .75rem .65rem .5rem;
  border-radius: 1.3rem 1.3rem 1rem 1rem;
  background: #f8fafc;
  color: #172033;
  font-size: .52rem;
}
.landing-phone-status, .landing-phone-topbar, .landing-phone-section-title, .landing-phone-card-top, .landing-phone-card-bottom, .landing-phone-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.landing-phone-status { color: #64748b; font-size: .45rem; font-weight: 700; }
.landing-phone-topbar { margin-top: .7rem; color: #064e3b; font-size: .7rem; }
.landing-phone-topbar strong { font-size: .66rem; }
.landing-phone-welcome { margin-top: 1rem; }
.landing-phone-welcome small { display: block; color: #64748b; font-size: .5rem; }
.landing-phone-welcome strong { display: block; margin-top: .2rem; color: #172033; font-size: .88rem; }
.landing-phone-card {
  margin-top: .7rem;
  padding: .7rem;
  border-radius: .8rem;
  background: linear-gradient(135deg, #064e3b, #059669);
  color: #fff;
  box-shadow: 0 6px 12px rgba(6, 78, 59, .2);
}
.landing-phone-card-top { color: #a7f3d0; font-size: .42rem; font-weight: 800; letter-spacing: .04em; }
.landing-phone-card > strong { display: block; margin-top: .9rem; font-size: .72rem; }
.landing-phone-card > small { color: #d1fae5; font-size: .46rem; }
.landing-phone-card-bottom { margin-top: .85rem; padding-top: .45rem; border-top: 1px solid rgba(255,255,255,.2); color: #d1fae5; font-size: .45rem; }
.landing-phone-card-bottom b { padding: .18rem .3rem; border-radius: .3rem; background: #10b981; color: #fff; font-size: .43rem; }
.landing-phone-section-title { margin-top: .85rem; color: #172033; font-size: .58rem; }
.landing-phone-section-title span { color: #047857; font-size: .45rem; font-weight: 700; }
.landing-phone-mini-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .4rem; margin-top: .45rem; }
.landing-phone-mini-grid div { padding: .5rem; border: 1px solid #e2e8f0; border-radius: .55rem; background: #fff; }
.landing-phone-mini-grid i { color: #10b981; font-size: .75rem; }
.landing-phone-mini-grid small, .landing-phone-mini-grid strong { display: block; }
.landing-phone-mini-grid small { margin-top: .25rem; color: #64748b; font-size: .42rem; }
.landing-phone-mini-grid strong { margin-top: .15rem; color: #047857; font-size: .56rem; }
.landing-phone-payment { display: flex; align-items: center; gap: .4rem; margin-top: .55rem; padding: .55rem; border-radius: .6rem; background: #fff; box-shadow: 0 3px 8px rgba(15,23,42,.05); }
.landing-phone-payment > i:first-child { color: #2563eb; font-size: .95rem; }
.landing-phone-payment span { flex: 1; min-width: 0; }
.landing-phone-payment strong, .landing-phone-payment small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.landing-phone-payment strong { color: #172033; font-size: .48rem; }
.landing-phone-payment small { margin-top: .15rem; color: #64748b; font-size: .4rem; }
.landing-phone-payment > i:last-child { color: #94a3b8; }
.landing-phone-nav { position: absolute; right: .65rem; bottom: .45rem; left: .65rem; padding: .5rem .65rem .15rem; border-top: 1px solid #e2e8f0; color: #94a3b8; font-size: .8rem; }
.landing-phone-nav .active { color: #047857; }

@media (max-width: 639px) {
  .landing-payment-scene { grid-template-columns: 1fr; padding: 1rem; }
  .landing-payment-copy { text-align: center; }
  .landing-scene-art { min-height: 12rem; }
  .landing-mobile-showcase { grid-template-columns: minmax(0, 1fr) 10rem; gap: .55rem; min-height: 21rem; padding: 1rem .75rem 0; }
  .landing-mobile-copy h3 { font-size: 1rem; }
  .landing-mobile-copy p { font-size: .62rem; }
  .landing-mobile-points { display: grid; gap: .3rem; }
  .landing-phone { width: 9rem; height: 18rem; border-radius: 1.35rem; }
  .landing-phone-screen { border-radius: 1rem; padding: .55rem .45rem .35rem; }
  .landing-phone-topbar { margin-top: .55rem; }
  .landing-phone-welcome { margin-top: .7rem; }
  .landing-phone-card { margin-top: .5rem; padding: .5rem; }
  .landing-phone-card > strong { margin-top: .6rem; font-size: .58rem; }
  .landing-phone-card-bottom { margin-top: .55rem; padding-top: .3rem; }
  .landing-phone-section-title { margin-top: .55rem; }
  .landing-phone-mini-grid { gap: .25rem; margin-top: .3rem; }
  .landing-phone-mini-grid div { padding: .35rem; }
  .landing-phone-payment { margin-top: .35rem; padding: .35rem; }
}

@media (max-width: 380px) {
  .landing-mobile-showcase { grid-template-columns: 1fr; padding-bottom: 0; }
  .landing-mobile-copy { text-align: center; }
  .landing-mobile-copy p { margin-right: auto; margin-left: auto; }
  .landing-mobile-points { justify-content: center; display: flex; }
  .landing-phone { width: 10rem; height: 19rem; }
}

/* Gradasi yang lebih kuat untuk kotak pembayaran dan area fotonya. */
.landing-payment-scene {
  border: 1px solid rgba(52, 211, 153, .55);
  background:
    radial-gradient(circle at 92% 12%, rgba(253, 224, 71, .3), transparent 25%),
    linear-gradient(135deg, #34d399 0%, #6ee7b7 48%, #ecfdf5 100%);
  box-shadow: 0 14px 30px rgba(6, 78, 59, .12);
}

.landing-payment-copy h3,
.landing-payment-copy p,
.landing-payment-copy .landing-mobile-kicker {
  color: #064e3b;
}

.landing-payment-copy .landing-mobile-kicker i {
  color: #fcd34d;
}

.landing-scene-art {
  border: 3px solid rgba(255, 255, 255, .75);
  background:
    linear-gradient(135deg, rgba(6, 78, 59, .35), rgba(16, 185, 129, .08)),
    linear-gradient(135deg, #bfdbfe, #d1fae5 55%, #fef3c7);
  box-shadow: 0 10px 22px rgba(6, 78, 59, .22);
}

.landing-people-photo img {
  border-radius: .75rem;
}

/* Kotak pembayaran: hijau aplikasi dengan transisi ke putih. */
.landing-payment-scene {
  background:
    radial-gradient(circle at 8% 18%, rgba(255, 255, 255, .82), transparent 22%),
    radial-gradient(circle at 92% 8%, rgba(255, 255, 255, .78), transparent 25%),
    radial-gradient(circle at 78% 100%, rgba(255, 255, 255, .72), transparent 28%),
    linear-gradient(125deg, #86efac 0%, #bbf7d0 23%, #ffffff 46%, #ffffff 70%, #ecfdf5 100%);
}

.landing-payment-copy h3 {
  color: #713f12;
}

@media (max-width: 639px) {
  .landing-payment-scene {
    background:
      radial-gradient(circle at 8% 10%, rgba(250, 204, 21, .78), transparent 25%),
      radial-gradient(circle at 92% 82%, rgba(253, 224, 71, .62), transparent 28%),
      linear-gradient(160deg, #86efac 0%, #bbf7d0 24%, #fef3c7 43%, #ffffff 74%, #ecfdf5 100%);
  }
}

/* Kotak judul utama: gradasi palet hijau aplikasi menuju putih. */
#sec-landing > div:first-child {
  background:
    radial-gradient(circle at 8% 12%, rgba(16, 185, 129, .3), transparent 30%),
    radial-gradient(circle at 92% 88%, rgba(255, 255, 255, .92), transparent 36%),
    linear-gradient(120deg, #059669 0%, #10b981 30%, #d1fae5 62%, #ffffff 100%);
  border: 1px solid rgba(5, 150, 105, .35);
  box-shadow: 0 12px 28px rgba(6, 78, 59, .12);
}

#sec-landing > div:first-child p {
  color: #064e3b;
}

#sec-landing > div:first-child h2,
#sec-landing > div:first-child h3,
#sec-landing > div:first-child h4 {
  color: #064e3b;
}
