/* Blue and white color layer.
   Preserves the original frontend layout and component geometry. */

:where(.frontend-shell,.member-shell,.ep-auth-body,.auth-shell) {
  --blue: #2563eb;
  --blue-700: #1d4ed8;
  --blue-50: #eff6ff;
  --teal: #3b82f6;
  --indigo: #1d4ed8;
  --amber: #60a5fa;
  --bg: #f7faff;
  --surface: #ffffff;
  --surface-2: #eff6ff;
  --surface-3: #dbeafe;
  --line: #cfe0f5;
  --text: #10213d;
  --muted: #526987;
  --soft: #eaf3ff;
}

:where(.frontend-shell,.member-shell,.ep-auth-body,.auth-shell).theme-dark {
  --bg: #071426;
  --surface: #0d2039;
  --surface-2: #122a49;
  --surface-3: #17365d;
  --line: #294b74;
  --text: #f5f9ff;
  --muted: #b4c8e1;
  --soft: #102f58;
}

body.frontend-shell,
body.member-shell,
body.auth-shell { background-color: var(--bg); }

body.frontend-shell {
  background-image:
    radial-gradient(circle at top left,rgba(37,99,235,.14),transparent 32%),
    linear-gradient(180deg,var(--bg),var(--bg));
}

body.frontend-shell .btn-primary,
body.member-shell .btn-primary,
body.ep-auth-body :is(.ep-auth-submit,.ep-register-submit) {
  background-image: linear-gradient(135deg,#2563eb,#1d4ed8) !important;
  background-color: #2563eb !important;
  color: #fff !important;
}

body.frontend-shell .brand-mark,
body.member-shell .brand-mark,
body.ep-auth-body .brand-mark {
  background-image: linear-gradient(135deg,#2563eb,#1e40af) !important;
}

body.frontend-shell :is(.hero-visual,.showcase-copy,.guide-hero>div:first-child,.journal-highlight) {
  background-image: linear-gradient(135deg,rgba(255,255,255,.92),rgba(219,234,254,.78)) !important;
}

body.frontend-shell.theme-dark :is(.hero-visual,.showcase-copy,.guide-hero>div:first-child,.journal-highlight) {
  background-image: linear-gradient(135deg,rgba(13,32,57,.96),rgba(18,42,73,.92)) !important;
}

body.frontend-shell .hero-orb.primary,
body.frontend-shell .visual-icon-stack,
body.frontend-shell .announcement-card,
body.frontend-shell .catalog-stack-card,
body.frontend-shell .catalog-stack-card.c1,
body.frontend-shell .catalog-stack-card.c2,
body.frontend-shell .catalog-stack-card.c3 {
  background-image: linear-gradient(135deg,#2563eb,#1d4ed8) !important;
}

body.frontend-shell .hero-orb.accent { color: #2563eb !important; }
body.frontend-shell .hero-line { background-image: linear-gradient(90deg,transparent,rgba(37,99,235,.48),transparent) !important; }

body.frontend-shell :is(.cover-blue,.cover-teal,.cover-cyan,.cover-purple,.cover-amber,.cover-indigo,.cover-orange,.cover-red) {
  background-image: linear-gradient(135deg,#1e40af,#3b82f6) !important;
}

body.frontend-shell .cover-slate { background-image: linear-gradient(135deg,#1e3a5f,#0f2747) !important; }

body.frontend-shell :is(.category-chip .ti,.stat-icon,.service-icon,.article-icon,.thesis-icon,.guide-card>span,.testimonial-icon) {
  background-color: rgba(37,99,235,.1) !important;
  color: #2563eb !important;
}

body.frontend-shell :is(.chip:not(.success):not(.warning):not(.danger),.popular-chips a,.thesis-tags span) {
  background-color: #eff6ff;
  color: #345478;
}

body.frontend-shell.theme-dark :is(.chip:not(.success):not(.warning):not(.danger),.popular-chips a,.thesis-tags span) {
  background-color: #17365d;
  color: #d5e6fa;
}

body.frontend-shell .site-footer { background-color: #f8fbff; }
body.frontend-shell.theme-dark .site-footer { background-color: #08182d; }

/* Contact page keeps its original layout, with a blue and white palette. */
body.frontend-shell .ep-contact-hero {
  background-image: linear-gradient(135deg,#ffffff 0%,#eff6ff 52%,#dbeafe 100%) !important;
  border-color: #bfdbfe !important;
}

body.frontend-shell .ep-contact-hero::before,
body.frontend-shell .ep-contact-hero::after,
body.frontend-shell .ep-contact-panel::before {
  background-image: radial-gradient(circle,rgba(37,99,235,.18),rgba(37,99,235,0) 70%) !important;
}

body.frontend-shell .ep-contact-orb,
body.frontend-shell .ep-contact-heading .ti,
body.frontend-shell .ep-service-actions a.primary {
  background-image: linear-gradient(135deg,#2563eb,#1d4ed8) !important;
}

body.frontend-shell .ep-contact-panel,
body.frontend-shell .ep-contact-stat,
body.frontend-shell .ep-service-actions a { background-color: #fff !important; }

body.frontend-shell .ep-service-card,
body.frontend-shell .ep-contact-note {
  background-image: linear-gradient(135deg,#ffffff,#eff6ff) !important;
  border-color: #bfdbfe !important;
}

body.frontend-shell .ep-service-card .ti {
  background-color: #eff6ff !important;
  color: #2563eb !important;
}

/* Authentication pages retain their previous split composition. */
body.ep-auth-body {
  background-color: #eff6ff !important;
  background-image: linear-gradient(135deg,#eff6ff,#ffffff) !important;
}

body.ep-auth-body :is(.ep-auth-board,.ep-register-board,.ep-auth-pane-form,.ep-register-form-pane,.ep-auth-card-pro,.ep-register-card) {
  --ep-auth-blue: #2563eb;
}

body.ep-auth-body :is(.ep-auth-pane-hero,.ep-register-media) {
  background-color: #0f2f5f !important;
  background-image: linear-gradient(145deg,#0f2f5f,#1d4ed8) !important;
}

body.ep-auth-body :is(.ep-auth-pane-hero,.ep-register-media) :is(h1,h2,h3,.brand-lockup,.brand-text) { color: #ffffff !important; }
body.ep-auth-body :is(.ep-auth-pane-hero,.ep-register-media) p { color: #dbeafe !important; }
body.ep-auth-body :is(.ep-auth-copyright,.ep-auth-benefits small) { color: #bfdbfe !important; }
body.ep-auth-body :is(.ep-auth-benefits strong,.ep-register-quick-features strong) { color: #ffffff !important; }
body.ep-auth-body :is(.ep-auth-badge,.ep-register-badge) {
  color: #ffffff !important;
  background-color: rgba(255,255,255,.12) !important;
  border-color: rgba(255,255,255,.22) !important;
}
body.ep-auth-body :is(.ep-register-mini-link,.ep-auth-register a,.ep-auth-form-meta a) { color: #2563eb !important; }

body.ep-auth-body :is(.ep-auth-input,.ep-register-input,.ep-auth-outline-btn,.ep-register-upload) {
  border-color: #bfdbfe !important;
  background-color: #ffffff !important;
}

body.ep-auth-body :is(.ep-auth-input,.ep-register-input):focus-within {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 4px rgba(37,99,235,.12) !important;
}

body.ep-auth-body :is(.sso-icon,.upload-icon,.ep-register-icon,.ep-register-quick-features article>span) {
  background-color: #eff6ff !important;
  background-image: none !important;
  color: #2563eb !important;
}

/* Member area: original component dimensions, consistent blue surfaces. */
body.member-shell .app-sidebar {
  background-image: linear-gradient(180deg,#ffffff,#eff6ff) !important;
  border-right-color: #bfdbfe !important;
}

body.member-shell.theme-dark .app-sidebar {
  background-image: linear-gradient(180deg,#0d2039,#071426) !important;
  border-right-color: #294b74 !important;
}

body.member-shell .side-nav a:is(.is-active,.active),
body.member-shell .side-nav a:hover {
  background-color: rgba(37,99,235,.12) !important;
  color: #1d4ed8 !important;
}

body.member-shell :is(.kpi-card,.member-panel,.member-table-card,.member-loan-card,.profile-card,.member-card) {
  border-color: rgba(37,99,235,.16);
}

@media (max-width: 900px) {
  body.frontend-shell .detail-layout { grid-template-columns: minmax(0,1fr); }
  body.frontend-shell .detail-main,
  body.frontend-shell .detail-side { min-width: 0; }
}

@media (prefers-reduced-motion: reduce) {
  :where(.frontend-shell,.member-shell,.ep-auth-body) *,
  :where(.frontend-shell,.member-shell,.ep-auth-body) *::before,
  :where(.frontend-shell,.member-shell,.ep-auth-body) *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Repository data grid: stable spacing, readable metadata, no card overlap. */
body.frontend-shell .repository-tabs{
  gap:10px;
  margin-top:18px;
  margin-bottom:24px;
}
body.frontend-shell .repository-layout{
  grid-template-columns:280px minmax(0,1fr);
  gap:28px;
  margin-top:0;
  align-items:start;
}
body.frontend-shell .repository-verified-card{
  top:94px;
  border-radius:16px;
}
body.frontend-shell .thesis-results{
  display:grid;
  gap:20px;
  min-width:0;
}
body.frontend-shell .repository-layout .result-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  min-width:0;
  padding:16px 18px;
  border-radius:16px;
}
body.frontend-shell .repository-layout .result-toolbar>strong{
  display:grid;
  grid-template-columns:38px minmax(0,1fr);
  grid-template-rows:auto auto;
  column-gap:11px;
  min-width:0;
  color:var(--text);
  line-height:1.25;
}
body.frontend-shell .repository-layout .result-toolbar>strong>span{
  grid-row:1/3;
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  border-radius:12px;
  color:var(--blue);
  background:rgba(37,99,235,.1);
}
body.frontend-shell .repository-layout .result-toolbar>strong small{
  display:block;
  margin-top:3px;
  color:var(--muted);
  font-size:11px;
  font-weight:800;
}
body.frontend-shell .repository-layout .result-toolbar>div{
  display:flex;
  flex-wrap:wrap;
  gap:9px;
}
body.frontend-shell .repository-card-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:18px;
  align-items:stretch;
  min-width:0;
}
body.frontend-shell .repository-card{
  display:flex;
  flex-direction:column;
  gap:14px;
  min-width:0;
  height:100%;
  padding:22px;
  overflow:hidden;
  border-radius:16px;
}
body.frontend-shell .repository-card-head{min-width:0;}
body.frontend-shell .repository-card h3{
  min-height:2.6em;
  overflow-wrap:anywhere;
  text-wrap:pretty;
}
body.frontend-shell .repository-meta{
  display:grid;
  gap:9px;
  min-width:0;
  padding:12px 0;
}
body.frontend-shell .repository-meta>span{
  display:grid;
  grid-template-columns:20px minmax(0,1fr);
  gap:8px;
  align-items:start;
  min-width:0;
  color:var(--muted);
}
body.frontend-shell .repository-meta .ti{
  --ti-size:1rem;
  width:1rem;
  height:1rem;
  margin-top:2px;
  color:var(--blue);
}
body.frontend-shell .repository-meta b{
  min-width:0;
  color:inherit;
  font-size:12px;
  line-height:1.45;
  font-weight:750;
  overflow-wrap:anywhere;
}
body.frontend-shell .repository-card .thesis-tags{
  align-items:center;
  gap:7px;
}
body.frontend-shell .repository-card .thesis-tags span{
  display:inline-flex;
  align-items:center;
  gap:6px;
  min-width:0;
}
body.frontend-shell .repository-card .thesis-tags .ti{
  --ti-size:.9rem;
  width:.9rem;
  height:.9rem;
  color:var(--blue);
}
body.frontend-shell .repository-card .card-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin-top:auto;
  padding-top:4px;
}
body.frontend-shell .repository-card .card-actions .btn{
  width:100%;
  min-width:0;
}
body.frontend-shell.theme-dark .repository-layout .result-toolbar>strong>span{
  color:#bfdbfe;
  background:rgba(59,130,246,.16);
}
@media (max-width:1080px){
  body.frontend-shell .repository-layout{grid-template-columns:250px minmax(0,1fr);gap:20px;}
  body.frontend-shell .repository-card-grid{gap:16px;}
}
@media (max-width:900px){
  body.frontend-shell .repository-layout{grid-template-columns:1fr;}
  body.frontend-shell .repository-verified-card{position:static;top:auto;}
}
@media (max-width:640px){
  body.frontend-shell .repository-tabs{display:grid;grid-template-columns:1fr 1fr;}
  body.frontend-shell .repository-tabs a{width:100%;justify-content:flex-start;}
  body.frontend-shell .repository-card-grid{grid-template-columns:1fr;gap:14px;}
  body.frontend-shell .repository-layout .result-toolbar{align-items:stretch;flex-direction:column;}
  body.frontend-shell .repository-layout .result-toolbar>div{display:grid;grid-template-columns:1fr 1fr;}
  body.frontend-shell .repository-card{padding:18px;}
}

/* Beranda: stronger blue-white direction with an editorial, image-led hero. */
body.frontend-shell .home-page-modern {
  --home-blue: var(--frontend-primary, #1557c8);
  --home-blue-deep: #0a3f9e;
  --home-blue-soft: #eaf3ff;
  --home-line: #cfe1f8;
  /* padding and bg now handled by beranda-premium.css */
  padding: 0;
  background-color: transparent;
}


body.frontend-shell .home-page-modern .sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

body.frontend-shell .home-hero {
  display: grid;
  grid-template-columns: minmax(0,.95fr) minmax(0,1.05fr);
  min-height: 500px;
  overflow: hidden;
  border: 1px solid #b9d5f5;
  border-radius: 18px;
  background: var(--home-blue-deep);
  box-shadow: 0 18px 44px rgba(14,78,164,.13);
}

body.frontend-shell .home-hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: clamp(34px,4.5vw,58px);
  color: #fff;
  background-color: var(--home-blue-deep);
}

body.frontend-shell .home-hero-kicker {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 8px;
  margin-bottom: 18px;
  color: #dbeafe;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

body.frontend-shell .home-hero-kicker .ti { --ti-size: 1.1rem; }

body.frontend-shell .home-hero h1 {
  max-width: 590px;
  margin: 0;
  color: #fff;
  font-size: clamp(40px,4vw,54px);
  font-weight: 950;
  line-height: 1.02;
  letter-spacing: -.04em;
  text-wrap: balance;
}

body.frontend-shell .home-hero-copy > p {
  max-width: 550px;
  margin: 22px 0 28px;
  color: #dbeafe;
  font-size: 16px;
  line-height: 1.7;
}

body.frontend-shell .home-hero-search {
  width: 100%;
  max-width: 610px;
  min-height: 64px;
  margin: 0;
  padding: 7px;
  border: 1px solid rgba(255,255,255,.32);
  border-radius: 13px;
  background: #fff;
  box-shadow: none;
}

body.frontend-shell .home-hero-search input {
  min-width: 0;
  padding-left: 13px;
  color: #102a4d;
  font-size: 14px;
}

body.frontend-shell .home-hero-search input::placeholder { color: #71839c; }
body.frontend-shell .home-hero-search .btn {
  min-width: 138px;
  border-radius: 9px;
  background: var(--home-blue);
  box-shadow: none;
}

body.frontend-shell .home-hero-search:focus-within {
  outline: 3px solid rgba(255,255,255,.36);
  outline-offset: 3px;
}

body.frontend-shell .home-hero-media {
  position: relative;
  min-width: 0;
  min-height: 500px;
  margin: 0;
  overflow: hidden;
  background-color: #dbeafe;
}

body.frontend-shell .home-hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg,rgba(10,63,158,.22),rgba(10,63,158,0) 38%);
}

body.frontend-shell .home-hero-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

body.frontend-shell .home-discovery-rail {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 58px;
  margin-top: 14px;
  padding: 9px 14px;
  border: 1px solid var(--home-line);
  border-radius: 13px;
  background: #fff;
}

body.frontend-shell .home-discovery-rail > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
  color: #17365d;
  font-size: 12px;
  font-weight: 900;
}

body.frontend-shell .home-discovery-rail .popular-chips {
  margin: 0;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: thin;
}

body.frontend-shell .home-discovery-rail .popular-chips a {
  flex: 0 0 auto;
  padding: 7px 11px;
  border: 1px solid #cfe1f8;
  background: #eef6ff;
  color: var(--frontend-primary, #1557c8);
}

body.frontend-shell .home-page-modern .category-strip {
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 10px;
  margin-top: 24px;
}

body.frontend-shell .home-page-modern .category-chip {
  min-height: 76px;
  padding: 13px 14px;
  border-color: var(--home-line);
  border-radius: 13px;
  background: #fff;
  box-shadow: none;
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}

body.frontend-shell .home-page-modern .category-chip .ti {
  border-radius: 10px;
  color: var(--home-blue);
  background: var(--home-blue-soft);
}

body.frontend-shell .home-page-modern .category-chip:hover {
  border-color: #87b6eb;
  background: #f4f9ff;
  transform: translateY(-2px);
}

body.frontend-shell .home-page-modern .section-block { padding: 68px 0 0; }
body.frontend-shell .home-page-modern .section-heading { margin-bottom: 22px; }
body.frontend-shell .home-page-modern .section-heading h2 {
  color: #102a4d;
  font-size: clamp(26px,3vw,38px);
  line-height: 1.12;
  letter-spacing: -.035em;
}

body.frontend-shell .home-page-modern .section-heading > a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--home-blue);
  font-weight: 900;
}

body.frontend-shell .home-page-modern .featured-grid {
  grid-template-columns: repeat(5,minmax(0,1fr));
  gap: 14px;
}

body.frontend-shell .home-page-modern .collection-card {
  border: 1px solid var(--home-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: none;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}

body.frontend-shell .home-page-modern .collection-card:hover {
  border-color: #87b6eb;
  transform: translateY(-3px);
  box-shadow: 0 14px 28px rgba(14,78,164,.1);
}

body.frontend-shell .home-page-modern .book-cover {
  height: 210px;
  margin: 10px;
  border-radius: 10px;
}

body.frontend-shell .home-page-modern .collection-body { padding: 2px 12px 14px; }
body.frontend-shell .home-page-modern .collection-body h3 { font-size: 14px; }
body.frontend-shell .home-page-modern .collection-body .chip {
  align-self: flex-start;
  border: 1px solid #cfe1f8;
  background: #eef6ff;
  color: var(--frontend-primary, #1557c8);
}

body.frontend-shell .home-page-modern .stats-strip {
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 0;
  margin-top: 68px;
  padding: 13px;
  border-radius: 16px;
  background: var(--home-blue-deep);
}

body.frontend-shell .home-page-modern .stats-strip > div {
  padding: 20px 22px;
  border: 0;
  border-right: 1px solid rgba(255,255,255,.18);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.frontend-shell .home-page-modern .stats-strip > div:last-child { border-right: 0; }
body.frontend-shell .home-page-modern .stat-icon {
  width: 50px;
  height: 50px;
  border-radius: 11px;
  background: rgba(255,255,255,.13);
  color: #fff;
}

body.frontend-shell .home-page-modern .stats-strip strong { color: #fff; }
body.frontend-shell .home-page-modern .stats-strip small { color: #dbeafe; }

body.frontend-shell .home-page-modern .service-grid {
  grid-template-columns: repeat(4,minmax(0,1fr));
  grid-template-rows: repeat(2,minmax(150px,auto));
  gap: 14px;
}

body.frontend-shell .home-page-modern .service-card {
  position: relative;
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: none;
  transition: border-color .2s ease, transform .2s ease, background-color .2s ease;
}

body.frontend-shell .home-page-modern .service-card-lead {
  grid-column: span 2;
  grid-row: span 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(28px,4vw,46px);
  border-color: var(--home-blue-deep);
  background: var(--home-blue-deep);
  color: #fff;
}

body.frontend-shell .home-page-modern .service-card .service-icon {
  width: 50px;
  height: 50px;
  margin-bottom: 22px;
  border-radius: 11px;
  color: var(--home-blue);
  background: var(--home-blue-soft);
}

body.frontend-shell .home-page-modern .service-card-lead .service-icon {
  width: 62px;
  height: 62px;
  color: #fff;
  background: rgba(255,255,255,.13);
}

body.frontend-shell .home-page-modern .service-card h3 {
  color: #102a4d;
  font-size: 18px;
  line-height: 1.2;
}

body.frontend-shell .home-page-modern .service-card-lead h3 {
  max-width: 520px;
  color: #fff;
  font-size: clamp(28px,3.2vw,43px);
  letter-spacing: -.035em;
}

body.frontend-shell .home-page-modern .service-card p {
  margin-top: 8px;
  color: #61738b;
  line-height: 1.65;
}

body.frontend-shell .home-page-modern .service-card-lead p {
  max-width: 560px;
  color: #dbeafe;
  font-size: 15px;
}

body.frontend-shell .home-page-modern .service-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  margin-top: 26px;
  color: #fff;
  font-weight: 900;
}

body.frontend-shell .home-page-modern .service-card:hover {
  border-color: #87b6eb;
  background: #f4f9ff;
  transform: translateY(-2px);
}

body.frontend-shell .home-page-modern .service-card-lead:hover {
  border-color: #0a3f9e;
  background: #0847b4;
}

body.frontend-shell .home-page-modern .home-duo-grid { gap: 14px; }
body.frontend-shell .home-page-modern .home-list-panel {
  padding: 22px;
  border: 1px solid var(--home-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: none;
}

body.frontend-shell .home-page-modern .home-list-panel::before { display: none; }
body.frontend-shell .home-page-modern .panel-kicker { color: var(--home-blue); }
body.frontend-shell .home-page-modern .mini-link {
  border-color: #cfe1f8;
  border-radius: 9px;
  background: #eef6ff;
  color: var(--home-blue);
}

body.frontend-shell .home-page-modern :is(.home-mini-card,.download-rank-card) {
  border-width: 0 0 1px;
  border-color: #e0ebf8;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.frontend-shell .home-page-modern :is(.home-mini-card,.download-rank-card):last-child { border-bottom: 0; }
body.frontend-shell .home-page-modern :is(.home-mini-card,.download-rank-card):hover {
  background: #f4f9ff;
  box-shadow: none;
  transform: translateX(3px);
}

body.frontend-shell .home-page-modern .download-rank-card[class*="tone-"] :is(.download-icon,b) {
  color: var(--home-blue);
  background: var(--home-blue-soft);
}

body.frontend-shell .home-page-modern .testimonial-grid-pro {
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 14px;
}

body.frontend-shell .home-page-modern .testimonial-card-pro {
  min-height: 220px;
  padding: 24px;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: none;
}

body.frontend-shell .home-page-modern .testimonial-card-pro:first-child { grid-column: 1 / -1; }
body.frontend-shell .home-page-modern .testimonial-card-pro::before { display: none; }
body.frontend-shell .home-page-modern .quote-mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--home-blue);
  box-shadow: none;
}

body.frontend-shell .home-page-modern .testimonial-user-row img { border-radius: 12px; }

body.frontend-shell.theme-dark .home-page-modern {
  --home-blue: #60a5fa;
  --home-blue-deep: #0b3374;
  --home-blue-soft: #17365d;
  --home-line: #294b74;
  background: #071426;
}

body.frontend-shell.theme-dark .home-page-modern :is(.home-discovery-rail,.category-chip,.collection-card,.service-card,.home-list-panel,.testimonial-card-pro) {
  border-color: var(--home-line);
  background: #0d2039;
}

body.frontend-shell.theme-dark .home-page-modern :is(.section-heading h2,.service-card h3) { color: #f4f8ff; }
body.frontend-shell.theme-dark .home-page-modern :is(.service-card p,.home-discovery-rail > span) { color: #abc3df; }
body.frontend-shell.theme-dark .home-page-modern :is(.home-mini-card,.download-rank-card) { border-color: #294b74; }
body.frontend-shell.theme-dark .home-page-modern :is(.home-mini-card,.download-rank-card):hover { background: #132d4d; }
body.frontend-shell.theme-dark .home-page-modern .service-card-lead,
body.frontend-shell.theme-dark .home-page-modern .home-hero-copy { background: #0b3374; }
body.frontend-shell.theme-dark .home-page-modern .home-hero { border-color: #39679d; background: #0b3374; }

@media (max-width: 1100px) {
  body.frontend-shell .home-hero { grid-template-columns: minmax(0,.95fr) minmax(0,1.05fr); min-height: 470px; }
  body.frontend-shell .home-hero-media { min-height: 470px; }
  body.frontend-shell .home-hero h1 { font-size: clamp(38px,5vw,52px); }
  body.frontend-shell .home-page-modern .featured-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  body.frontend-shell .home-page-modern .service-grid { grid-template-columns: repeat(2,minmax(0,1fr)); grid-template-rows: auto; }
  body.frontend-shell .home-page-modern .service-card-lead { grid-column: 1 / -1; grid-row: auto; min-height: 300px; }
}

@media (max-width: 760px) {
  body.frontend-shell .home-page-modern { padding-top: 18px; }
  body.frontend-shell .home-hero { grid-template-columns: 1fr; min-height: 0; border-radius: 15px; }
  body.frontend-shell .home-hero-copy { padding: 32px 22px; }
  body.frontend-shell .home-hero h1 { font-size: clamp(36px,11vw,48px); }
  body.frontend-shell .home-hero-copy > p { margin: 18px 0 24px; font-size: 15px; }
  body.frontend-shell .home-hero-search { min-height: 0; padding: 6px; }
  body.frontend-shell .home-hero-media { min-height: 280px; max-height: 340px; }
  body.frontend-shell .home-discovery-rail { align-items: flex-start; flex-direction: column; gap: 8px; padding: 12px; }
  body.frontend-shell .home-discovery-rail .popular-chips { width: 100%; }
  body.frontend-shell .home-discovery-rail .popular-chips a { min-height: 44px; align-items: center; }
  body.frontend-shell .home-page-modern .category-strip { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.frontend-shell .home-page-modern .featured-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.frontend-shell .home-page-modern .book-cover { height: 190px; }
  body.frontend-shell .home-page-modern .stats-strip { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.frontend-shell .home-page-modern .stats-strip > div:nth-child(2) { border-right: 0; }
  body.frontend-shell .home-page-modern .stats-strip > div:nth-child(-n+2) { border-bottom: 1px solid rgba(255,255,255,.18); }
  body.frontend-shell .home-page-modern .service-grid,
  body.frontend-shell .home-page-modern .testimonial-grid-pro { grid-template-columns: 1fr; }
  body.frontend-shell .home-page-modern .service-card-lead,
  body.frontend-shell .home-page-modern .testimonial-card-pro:first-child { grid-column: auto; }
  body.frontend-shell .home-page-modern .service-card-lead { min-height: 330px; }
  body.frontend-shell .home-page-modern .section-block { padding-top: 52px; }
  body.frontend-shell .home-page-modern .section-heading > a { min-height: 44px; }
  body.frontend-shell .home-page-modern .favorite-toggle-btn { width: 44px; height: 44px; }
  body.frontend-shell .home-page-modern .card-actions .btn { min-height: 44px; }
}

@media (max-width: 520px) {
  body.frontend-shell .home-hero-search { flex-direction: column; }
  body.frontend-shell .home-hero-search .btn { width: 100%; min-height: 46px; }
  body.frontend-shell .home-page-modern .category-strip { grid-template-columns: 1fr; }
  body.frontend-shell .home-page-modern .featured-grid { grid-template-columns: 1fr; }
  body.frontend-shell .home-page-modern .book-cover { height: 290px; }
  body.frontend-shell .home-page-modern .stats-strip { grid-template-columns: 1fr; }
  body.frontend-shell .home-page-modern .stats-strip > div { border-right: 0; border-bottom: 1px solid rgba(255,255,255,.18); }
  body.frontend-shell .home-page-modern .stats-strip > div:last-child { border-bottom: 0; }
  body.frontend-shell .home-page-modern .section-heading { align-items: flex-start; }
}

/* Global frontend navigation and footer. */
body.frontend-shell {
  overflow-x: clip;
  overflow-y: visible;
}

body.frontend-shell .site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  width: 100%;
  margin: 0;
  border: 0;
  border-bottom: 1px solid #cfe1f8;
  border-radius: 0;
  background: #fff;
  box-shadow: 0 4px 8px rgba(14,78,164,.06);
}

body.frontend-shell .site-header .header-row {
  min-height: 72px;
  padding: 0;
}

body.frontend-shell .site-header .brand-lockup {
  flex: 0 1 190px;
  color: #102a4d;
}

body.frontend-shell .site-header .brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--frontend-primary, #1557c8);
  box-shadow: none;
}

body.frontend-shell .site-header .brand-text {
  font-size: 12px;
  line-height: 1.08;
  letter-spacing: -.015em;
}

body.frontend-shell .site-header .main-nav {
  align-self: stretch;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 2px;
}

body.frontend-shell .site-header .main-nav > a {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin: 0;
  padding: 0 11px;
  border-radius: 0;
  color: #526981;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
  transition: color .2s cubic-bezier(.16,1,.3,1), background-color .2s cubic-bezier(.16,1,.3,1);
}

body.frontend-shell .site-header .main-nav > a::after {
  content: "";
  position: absolute;
  right: 11px;
  bottom: 0;
  left: 11px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--frontend-primary, #1557c8);
  opacity: 0;
  transform: scaleX(.45);
  transition: opacity .2s cubic-bezier(.16,1,.3,1), transform .2s cubic-bezier(.16,1,.3,1);
}

body.frontend-shell .site-header .main-nav > a:hover {
  color: var(--frontend-primary, #1557c8);
  background: #f4f9ff;
}

body.frontend-shell .site-header .main-nav > a:is(.is-active,.active) {
  color: #0a4aad;
  background: transparent;
}

body.frontend-shell .site-header .main-nav > a:is(.is-active,.active)::after {
  opacity: 1;
  transform: scaleX(1);
}

body.frontend-shell .site-header .header-actions { gap: 8px; }
body.frontend-shell .site-header :is(.theme-toggle,.mobile-nav-toggle) {
  width: 44px;
  height: 44px;
  border: 1px solid #cfe1f8;
  border-radius: 10px;
  background: #f7fbff;
  color: #17365d;
  transition: border-color .2s cubic-bezier(.16,1,.3,1), color .2s cubic-bezier(.16,1,.3,1), background-color .2s cubic-bezier(.16,1,.3,1), transform .15s ease;
}

body.frontend-shell .site-header :is(.theme-toggle,.mobile-nav-toggle):hover {
  border-color: #87b6eb;
  background: #eaf3ff;
  color: var(--frontend-primary, #1557c8);
}

body.frontend-shell .site-header :is(.theme-toggle,.mobile-nav-toggle):active,
body.frontend-shell .site-header .header-account-link:active { transform: translateY(1px); }

body.frontend-shell .site-header .header-account-link {
  min-height: 44px;
  margin: 0;
  padding: 10px 17px;
  border: 1px solid var(--frontend-primary, #1557c8);
  border-radius: 10px;
  background: var(--frontend-primary, #1557c8);
  box-shadow: none;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

body.frontend-shell .site-header .header-account-link:hover {
  border-color: #0a4aad;
  background: #0a4aad;
}

body.frontend-shell .site-header :is(a,button):focus-visible,
body.frontend-shell .site-footer a:focus-visible {
  outline: 3px solid rgba(21,87,200,.32);
  outline-offset: 3px;
}

body.frontend-shell .site-header .main-nav > .mobile-nav-account,
body.frontend-shell .mobile-nav-scrim { display: none; }

body.frontend-shell.theme-dark .site-header {
  border-bottom-color: #294b74;
  background: #0a1b31;
  box-shadow: 0 4px 8px rgba(2,10,22,.22);
}

body.frontend-shell.theme-dark .site-header .brand-lockup { color: #f4f8ff; }
body.frontend-shell.theme-dark .site-header .main-nav > a { color: #a9bfd9; }
body.frontend-shell.theme-dark .site-header .main-nav > a:hover { color: #dbeafe; background: #112b49; }
body.frontend-shell.theme-dark .site-header .main-nav > a:is(.is-active,.active) { color: #8ec5ff; background: transparent; }
body.frontend-shell.theme-dark .site-header .main-nav > a::after { background: #60a5fa; }
body.frontend-shell.theme-dark .site-header :is(.theme-toggle,.mobile-nav-toggle) {
  border-color: #294b74;
  background: #0d2039;
  color: #dbeafe;
}

body.frontend-shell .site-footer {
  margin-top: 84px;
  border-top: 1px solid #b9d5f5;
  background: #eef6ff;
  color: #102a4d;
}

body.frontend-shell .footer-shell {
  display: grid;
  grid-template-columns: minmax(0,.88fr) minmax(0,1.35fr);
  gap: clamp(48px,7vw,92px);
  padding: clamp(56px,7vw,82px) 0;
}

body.frontend-shell .footer-intro {
  min-width: 0;
  padding-right: clamp(32px,5vw,64px);
  border-right: 1px solid #c4daf4;
}

body.frontend-shell .footer-intro .brand-lockup {
  display: inline-flex;
  margin-bottom: 30px;
  color: #102a4d;
}

body.frontend-shell .footer-intro .brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: var(--frontend-primary, #1557c8);
  box-shadow: none;
}

body.frontend-shell .footer-intro h2 {
  max-width: 520px;
  margin: 0;
  color: #102a4d;
  font-size: clamp(28px,3.2vw,42px);
  font-weight: 950;
  line-height: 1.08;
  letter-spacing: -.035em;
  text-wrap: balance;
}

body.frontend-shell .footer-intro > p {
  max-width: 55ch;
  margin: 18px 0 26px;
  color: #526981;
  font-size: 14px;
  line-height: 1.75;
  text-wrap: pretty;
}

body.frontend-shell .footer-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

body.frontend-shell .footer-actions a { margin: 0; }
body.frontend-shell .footer-primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 11px 16px;
  border-radius: 10px;
  background: var(--frontend-primary, #1557c8);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  transition: background-color .2s cubic-bezier(.16,1,.3,1), transform .15s ease;
}

body.frontend-shell .footer-primary-action:hover { background: #0a4aad; color: #fff; }
body.frontend-shell .footer-primary-action:active { transform: translateY(1px); }
body.frontend-shell .footer-directory {
  display: grid;
  grid-template-columns: minmax(110px,.7fr) minmax(145px,.85fr) minmax(210px,1.35fr);
  gap: clamp(28px,4vw,54px);
  align-content: start;
  min-width: 0;
}

body.frontend-shell .site-footer h3 {
  margin: 4px 0 20px;
  color: #17365d;
  font-size: 13px;
  font-weight: 950;
  letter-spacing: .01em;
}

body.frontend-shell .footer-nav-group a {
  display: flex;
  align-items: center;
  min-height: 34px;
  margin: 0;
  color: #526981;
  font-size: 13px;
  font-weight: 700;
  transition: color .2s cubic-bezier(.16,1,.3,1), transform .2s cubic-bezier(.16,1,.3,1);
}

body.frontend-shell .footer-nav-group a:hover {
  color: var(--frontend-primary, #1557c8);
  transform: translateX(3px);
}

body.frontend-shell .footer-contact { min-width: 0; }
body.frontend-shell .footer-contact > :is(a,div) {
  display: grid;
  grid-template-columns: 36px minmax(0,1fr);
  column-gap: 11px;
  min-width: 0;
  margin: 0 0 16px;
  color: #526981;
}

body.frontend-shell .footer-contact > :is(a,div) > span {
  grid-row: 1 / 3;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: #dbeafe;
  color: var(--frontend-primary, #1557c8);
}

body.frontend-shell .footer-contact strong {
  color: #17365d;
  font-size: 12px;
  line-height: 1.35;
}

body.frontend-shell .footer-contact small {
  min-width: 0;
  color: #526981;
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

body.frontend-shell .footer-contact a:hover small { color: var(--frontend-primary, #1557c8); }
body.frontend-shell .footer-legal {
  border-top: 1px solid #c4daf4;
  background: #e5f1ff;
}

body.frontend-shell .footer-legal-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 64px;
  color: #526981;
  font-size: 12px;
  font-weight: 700;
}

body.frontend-shell .footer-legal-inner > div { display: flex; align-items: center; gap: 20px; }
body.frontend-shell .footer-legal-inner a { margin: 0; color: #36536f; font-weight: 800; }
body.frontend-shell .footer-legal-inner a:hover { color: var(--frontend-primary, #1557c8); }

body.frontend-shell.theme-dark .site-footer {
  border-top-color: #294b74;
  background: #0a1b31;
  color: #eef6ff;
}

body.frontend-shell.theme-dark .footer-intro { border-right-color: #294b74; }
body.frontend-shell.theme-dark .footer-intro :is(.brand-lockup,h2),
body.frontend-shell.theme-dark .site-footer h3,
body.frontend-shell.theme-dark .footer-contact strong { color: #f4f8ff; }
body.frontend-shell.theme-dark .footer-intro > p,
body.frontend-shell.theme-dark .footer-nav-group a,
body.frontend-shell.theme-dark .footer-contact small { color: #abc3df; }
body.frontend-shell.theme-dark .footer-contact > :is(a,div) > span { background: #17365d; color: #8ec5ff; }
body.frontend-shell.theme-dark .footer-legal { border-top-color: #294b74; background: #071426; }
body.frontend-shell.theme-dark .footer-legal-inner { color: #91acc9; }
body.frontend-shell.theme-dark .footer-legal-inner a { color: #abc3df; }

@media (max-width: 1100px) {
  body.frontend-shell .site-header .header-row { gap: 10px; }
  body.frontend-shell .site-header .brand-lockup { flex-basis: 160px; }
  body.frontend-shell .site-header .main-nav > a { padding-inline: 8px; font-size: 12px; }
  body.frontend-shell .footer-shell { grid-template-columns: minmax(0,.78fr) minmax(0,1.22fr); gap: 44px; }
  body.frontend-shell .footer-directory { gap: 26px; }
}

@media (max-width: 900px) {
  body.frontend-shell .site-header .header-row { position: relative; min-height: 64px; }
  body.frontend-shell .site-header .brand-lockup { flex: 1 1 auto; order: 1; }
  body.frontend-shell .site-header .header-actions { order: 2; }
  body.frontend-shell .site-header .mobile-nav-toggle { display: inline-grid; order: 3; }
  body.frontend-shell .site-header .header-account-link { display: none; }
  body.frontend-shell .site-header .main-nav {
    position: fixed;
    top: 72px;
    right: 12px;
    left: 12px;
    z-index: 42;
    display: grid;
    grid-template-columns: 1fr;
    align-content: start;
    gap: 2px;
    max-height: calc(100dvh - 88px);
    padding: 10px;
    overflow-y: auto;
    border: 1px solid #cfe1f8;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 4px 8px rgba(14,78,164,.14);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity .2s cubic-bezier(.16,1,.3,1), transform .2s cubic-bezier(.16,1,.3,1);
  }
  body.frontend-shell.nav-open .site-header .main-nav { opacity: 1; pointer-events: auto; transform: translateY(0); }
  body.frontend-shell .site-header .main-nav > a {
    justify-content: flex-start;
    min-height: 48px;
    padding: 0 14px;
    border-radius: 10px;
    font-size: 14px;
  }
  body.frontend-shell .site-header .main-nav > a::after { display: none; }
  body.frontend-shell .site-header .main-nav > a:is(.is-active,.active) { background: #eaf3ff; color: #0a4aad; }
  body.frontend-shell .site-header .main-nav > .mobile-nav-account {
    display: inline-flex;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
    background: var(--frontend-primary, #1557c8);
    color: #fff;
    font-weight: 900;
  }
  body.frontend-shell .site-header .main-nav > .mobile-nav-account:hover { background: #0a4aad; color: #fff; }
  body.frontend-shell .mobile-nav-scrim {
    position: fixed;
    inset: 64px 0 0;
    z-index: 35;
    width: 100%;
    height: auto;
    border: 0;
    border-radius: 0;
    background: rgba(7,20,38,.48);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s cubic-bezier(.16,1,.3,1);
  }
  body.frontend-shell.nav-open .mobile-nav-scrim { display: block; opacity: 1; pointer-events: auto; }
  body.frontend-shell.theme-dark .site-header .main-nav { border-color: #294b74; background: #0d2039; box-shadow: 0 4px 8px rgba(2,10,22,.3); }
  body.frontend-shell.theme-dark .site-header .main-nav > a:is(.is-active,.active) { background: #17365d; color: #8ec5ff; }
  body.frontend-shell .footer-shell { grid-template-columns: 1fr; gap: 40px; }
  body.frontend-shell .footer-intro { padding: 0 0 40px; border-right: 0; border-bottom: 1px solid #c4daf4; }
  body.frontend-shell.theme-dark .footer-intro { border-bottom-color: #294b74; }
  body.frontend-shell .footer-directory { grid-template-columns: repeat(2,minmax(0,1fr)); }
  body.frontend-shell .footer-contact { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  body.frontend-shell .site-header .header-row { width: calc(100% - 24px); }
  body.frontend-shell .site-header .brand-mark { width: 38px; height: 38px; }
  body.frontend-shell .site-header :is(.theme-toggle,.mobile-nav-toggle) { width: 44px; height: 44px; }
  body.frontend-shell .footer-directory { grid-template-columns: 1fr; gap: 30px; }
  body.frontend-shell .footer-contact { grid-column: auto; }
  body.frontend-shell .footer-nav-group a { min-height: 44px; }
  body.frontend-shell .footer-actions { align-items: stretch; flex-direction: column; gap: 4px; }
  body.frontend-shell .footer-primary-action { justify-content: center; width: 100%; }
  body.frontend-shell .footer-legal-inner { align-items: flex-start; flex-direction: column; justify-content: center; padding: 18px 0; }
}

@media (prefers-reduced-transparency: reduce) {
  body.frontend-shell .site-header { background: #fff; }
  body.frontend-shell.theme-dark .site-header { background: #0a1b31; }
}

/* Uploaded horizontal brand: larger, transparent, and free from tile styling. */
:is(body.frontend-shell,body.member-shell,body.ep-auth-body) .brand-lockup.has-logo .brand-text { display: none; }
:is(body.frontend-shell,body.member-shell,body.ep-auth-body) .brand-mark.has-image {
  overflow: visible;
  border: 0 !important;
  border-radius: 0;
  background: transparent !important;
  box-shadow: none !important;
}
:is(body.frontend-shell,body.member-shell,body.ep-auth-body) .brand-mark.has-image .brand-logo-image {
  width: 100%;
  height: 100%;
  padding: 0;
  border-radius: 0;
  object-fit: contain;
}
body.frontend-shell .site-header .brand-lockup.has-logo { flex: 0 0 230px; }
body.frontend-shell .site-header .brand-mark.has-image { width: 220px; height: 64px; }
body.frontend-shell .footer-intro .brand-mark.has-image { width: min(280px,100%); height: 80px; }
body.member-shell .app-sidebar .brand-mark.has-image { width: 220px; height: 68px; }
body.ep-auth-body .brand-mark.has-image { width: min(270px,100%); height: 80px; }
:is(body.frontend-shell,body.member-shell,body.ep-auth-body).theme-dark .brand-logo-image {
  filter: brightness(1.75) saturate(.9) drop-shadow(0 1px 1px rgba(255,255,255,.35));
}

@media (max-width: 760px) {
  body.frontend-shell .site-header .brand-lockup.has-logo { flex-basis: 180px; }
  body.frontend-shell .site-header .brand-mark.has-image { width: 174px; height: 52px; }
  body.frontend-shell .footer-intro .brand-mark.has-image { width: min(240px,100%); height: 70px; }
}

/* Navbar brand lockup: restore the uploaded logo and its database tagline. */
body.frontend-shell .site-header .brand-lockup.has-logo {
  display:grid;
  grid-template-columns:minmax(0,190px);
  align-content:center;
  gap:0;
  flex:0 0 210px;
  min-height:64px;
}
body.frontend-shell .site-header .brand-lockup.has-logo .brand-mark.has-image {
  width:190px;
  height:43px;
  justify-self:start;
}
body.frontend-shell .site-header .brand-lockup.has-logo .brand-text {
  display:block;
  min-width:0;
  margin:-2px 0 0 43px;
}
body.frontend-shell .site-header .brand-lockup.has-logo .brand-text strong { display:none; }
body.frontend-shell .site-header .brand-lockup.has-logo .brand-text small {
  display:block;
  overflow:hidden;
  color:#405b78;
  font-size:9px;
  font-weight:800;
  line-height:1.2;
  text-overflow:ellipsis;
  white-space:nowrap;
}
body.frontend-shell.theme-dark .site-header .brand-lockup.has-logo .brand-text small { color:#c7daf3; }

@media (max-width:1100px) {
  body.frontend-shell .site-header .brand-lockup.has-logo {
    grid-template-columns:minmax(0,168px);
    flex-basis:180px;
  }
  body.frontend-shell .site-header .brand-lockup.has-logo .brand-mark.has-image { width:168px; height:39px; }
  body.frontend-shell .site-header .brand-lockup.has-logo .brand-text { margin-left:39px; }
}

@media (max-width:760px) {
  body.frontend-shell .site-header .brand-lockup.has-logo {
    grid-template-columns:minmax(0,172px);
    flex:1 1 auto;
    min-height:58px;
  }
  body.frontend-shell .site-header .brand-lockup.has-logo .brand-mark.has-image { width:172px; height:39px; }
  body.frontend-shell .site-header .brand-lockup.has-logo .brand-text { margin-left:34px; }
  body.frontend-shell .site-header .brand-lockup.has-logo .brand-text small { font-size:8px; letter-spacing:-.01em; }
}

/* Purposeful frontend motion and icon system. */
body.frontend-shell {
  --motion-fast: 160ms;
  --motion-base: 220ms;
  --motion-slow: 480ms;
  --motion-ease: cubic-bezier(.16,1,.3,1);
}

body.frontend-shell .site-header .main-nav > a {
  gap: 7px;
}

body.frontend-shell .site-header .main-nav > a > .ti {
  margin: 0;
  color: #7891aa;
  transition: color var(--motion-base) var(--motion-ease), transform var(--motion-base) var(--motion-ease);
}

body.frontend-shell .site-header .main-nav > a:is(:hover,.is-active,.active) > .ti {
  color: var(--frontend-primary, #1557c8);
  transform: translateY(-1px);
}

body.frontend-shell.theme-dark .site-header .main-nav > a > .ti { color: #7895b5; }
body.frontend-shell.theme-dark .site-header .main-nav > a:is(:hover,.is-active,.active) > .ti { color: #8ec5ff; }
body.frontend-shell .site-header .main-nav > .mobile-nav-account > .ti { color: currentColor; }
body.frontend-shell.theme-dark .site-header .main-nav > .mobile-nav-account,
body.frontend-shell.theme-dark .site-header .main-nav > .mobile-nav-account > .ti { color: #fff; }

body.frontend-shell :is(.theme-toggle,.mobile-nav-toggle) {
  position: relative;
  overflow: hidden;
}

body.frontend-shell :is(.theme-action-dark,.theme-action-light,.nav-action-open,.nav-action-close) {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  transition: opacity var(--motion-base) var(--motion-ease), transform var(--motion-base) var(--motion-ease);
}

body.frontend-shell :is(.theme-action-light,.nav-action-close) {
  opacity: 0;
  transform: rotate(-45deg) scale(.72);
}

body.frontend-shell.theme-dark .theme-action-dark,
body.frontend-shell.nav-open .nav-action-open {
  opacity: 0;
  transform: rotate(45deg) scale(.72);
}

body.frontend-shell.theme-dark .theme-action-light,
body.frontend-shell.nav-open .nav-action-close {
  opacity: 1;
  transform: rotate(0) scale(1);
}

body.frontend-shell :is(
  .btn,
  .category-chip,
  .collection-card,
  .service-card,
  .home-mini-card,
  .download-rank-card,
  .testimonial-card-pro,
  .guide-card,
  .thesis-card,
  .repository-card,
  .article-card,
  .journal-highlight,
  .panel-card
) {
  transition-property: transform, box-shadow, border-color, background-color, color;
  transition-duration: var(--motion-base);
  transition-timing-function: var(--motion-ease);
}

body.frontend-shell :is(.btn,.footer-primary-action,.section-heading > a,.service-link,.mini-link,.related-see-all) .ti {
  transition: transform var(--motion-base) var(--motion-ease);
}

body.frontend-shell :is(.btn,.footer-primary-action,.category-chip,.collection-card,.service-card,.home-mini-card,.download-rank-card,.journal-highlight):active {
  transform: translateY(1px) scale(.985);
  transition-duration: var(--motion-fast);
}

body.frontend-shell :is(.home-hero-media,.book-cover,.mini-book-cover-img,.testimonial-user-row > img) {
  overflow: hidden;
}

/* Rating database pada kartu Buku dan E-Book. */
body.frontend-shell .collection-rating {
  display:flex;
  align-items:center;
  gap:7px;
  min-width:0;
  margin-top:7px;
  color:#b45309;
  font-size:12px;
  line-height:1;
}

body.frontend-shell .collection-rating-stars {
  display:inline-flex;
  align-items:center;
  gap:2px;
  flex:0 0 auto;
}

body.frontend-shell .collection-rating-stars .ti {
  --ti-size:1rem;
  display:inline-grid;
  color:#f59e0b;
}

body.frontend-shell .collection-rating-stars .is-filled .ti-svg {
  fill:currentColor;
}

body.frontend-shell .collection-rating-stars .is-empty {
  color:#cbd5e1;
}

body.frontend-shell .collection-rating strong {
  color:var(--text);
  font-size:12px;
  font-variant-numeric:tabular-nums;
  white-space:nowrap;
}

body.frontend-shell .collection-rating-label {
  color:var(--muted);
  white-space:nowrap;
}

body.frontend-shell.theme-dark .collection-rating-stars .is-empty {
  color:#475569;
}

body.frontend-shell :is(.home-hero-media,.book-cover) img {
  transition: transform var(--motion-slow) var(--motion-ease);
}

body.frontend-shell .footer-contact > :is(a,div) > span {
  transition: transform var(--motion-base) var(--motion-ease), background-color var(--motion-base) var(--motion-ease), color var(--motion-base) var(--motion-ease);
}

@media (hover: hover) and (pointer: fine) {
  body.frontend-shell :is(.category-chip,.collection-card,.service-card,.home-mini-card,.download-rank-card,.testimonial-card-pro,.guide-card,.thesis-card,.repository-card,.article-card,.journal-highlight):hover {
    transform: translateY(-3px);
    border-color: rgba(37,99,235,.3);
    box-shadow: 0 12px 24px rgba(14,78,164,.11);
  }

  body.frontend-shell :is(.btn,.footer-primary-action,.section-heading > a,.service-link,.mini-link,.related-see-all):hover .ti:last-child {
    transform: translateX(3px);
  }

  body.frontend-shell .home-hero-media:hover img,
  body.frontend-shell .collection-card:hover .book-cover img {
    transform: scale(1.025);
  }

  body.frontend-shell .footer-contact > a:hover > span {
    transform: translateY(-2px);
    background: #c9e1ff;
  }
}

@media (max-width: 1100px) and (min-width: 901px) {
  body.frontend-shell .site-header .main-nav > a { gap: 5px; }
  body.frontend-shell .site-header .main-nav > a > .ti { --ti-size: 1rem; }
}

@media (max-width: 900px) {
  body.frontend-shell .site-header .main-nav > a { gap: 10px; }
  body.frontend-shell .site-header .main-nav > a > .ti { --ti-size: 1.2rem; }
}

@media (prefers-reduced-motion: reduce) {
  body.frontend-shell *,
  body.frontend-shell *::before,
  body.frontend-shell *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
