/* ==================================
   Base
================================== */

:root {
    --navy: #08111f;
    --slate: #182433;
    --blue: #0098ff;
    --gold: #d4b16a;
    --light: #f8fafc;
    --text: #1e293b;
    --border: #e2e8f0;
}

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

body {
    margin: 0;
    font-family: Inter, sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text);
    background: var(--light);
}

a {
    text-decoration: none;
    color: var(--blue);
    transition: all 0.3s ease;
}

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

.container {
    width: min(1200px, 92%);
    margin: 0 auto;
}

/* ==================================
   Header
================================== */

.site-header {
    position: sticky;
    top: 0;
    z-index: 999;
    background: #ffffff;
border-bottom: 1px solid var(--border);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 80px;
}

.site-branding h1,
.site-branding a {
    margin: 0;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 700;
}

.site-branding img {
    max-height: 60px;
    width: auto;
}

.menu li {
    position: relative;
}

.menu .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;

    min-width: 300px;

    margin: 0;
    padding: 0.75rem 0;

    list-style: none;

    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 8px;

    box-shadow: 0 10px 30px rgba(0,0,0,.15);

    z-index: 9999;
}

.menu li:hover > .sub-menu {
    display: block;
}

.menu .sub-menu li {
    margin: 0;
}

.menu .sub-menu a {
    display: block;
    padding: 12px 20px;

    color: var(--navy);
    font-size: 0.9rem;
    text-transform: none;
    letter-spacing: normal;
}

.menu .sub-menu a:hover {
    background: #f8fafc;
    color: var(--blue);
}

.menu .sub-menu .sub-menu {
    top: 0;
    left: 100%;
}


.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

.site-branding {
    flex-shrink: 0;
}

.primary-nav {
    margin-left: auto;
}


/* ==================================
   Navigation
================================== */

.menu,
.primary-nav ul {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu li,
.primary-nav ul li {
    position: relative;
}

.menu a,
.primary-nav a {
    color: var(--navy);
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.menu a:hover,
.primary-nav a:hover {
    color: var(--blue);
}

/* ==================================
   Hero
================================== */

.hero {
    padding: 7rem 0;
    background: linear-gradient(
        135deg,
        var(--navy) 0%,
        var(--slate) 100%
    );
    color: #fff;
}

.hero h1 {
    max-width: 800px;
    margin-bottom: 1rem;
    font-size: clamp(3rem, 5vw, 4.5rem);
    line-height: 1.1;
    font-weight: 700;
}

.hero p {
    max-width: 700px;
    font-size: 1.2rem;
    opacity: 0.9;
}


.hero .container {
    max-width: 1100px;
    margin: 0 auto;
}
/* ==================================
   Buttons
================================== */

.button {
    display: inline-block;
    margin-top: 1.5rem;
    padding: 14px 28px;
    border-radius: 8px;
    background: var(--blue);
    color: #fff;
    font-weight: 600;
}

.button:hover {
    opacity: 0.9;
}

/* ==================================
   Metrics
================================== */

.metrics {
    padding: 4rem 0;
    background: #fff;
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    text-align: center;
}

.metric h2 {
    margin-bottom: 0.5rem;
    font-size: 3rem;
    color: var(--blue);
}

.metric p {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.85rem;
}

/* ==================================
   Footer
================================== */

.site-footer {
    margin-top: 4rem;
    padding: 3rem 0;
    text-align: center;
    background: var(--navy);
    color: #fff;
}


/* ==================================
   Footer
================================== */

.site-footer {
    background: var(--navy);
    color: #fff;
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
}

.footer-column h3,
.footer-column h4 {
    margin-top: 0;
    color: #fff;
}

.footer-column ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-column li {
    margin-bottom: 0.75rem;
}

.footer-column a {
    color: rgba(255,255,255,0.8);
}

.footer-column a:hover {
    color: var(--gold);
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
}

.about-kant {
    padding: 6rem 0;
    background: #f6f1e7;
    color: var(--navy);
}


.about-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
}


.single-post article {
    max-width: 1300px;
    margin: 0 auto;
}

.single-post p {
    line-height: 1.9;
}

.single-post h2,
.single-post h3 {
    margin-top: 2.5rem;
}


#reading-progress {

    position: fixed;

    top: 0;
    left: 0;

    height: 3px;

    width: 0;

    background: var(--blue);

    z-index: 9999;
}


.menu-toggle {
    display: none;
    background: none;
    border: 0;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}


body {
    font-family: 'Inter', sans-serif;
}

.paper-content {
    font-family: 'Merriweather', serif;
}

.page-content {
    padding: 5rem 0;
}

.page-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: var(--navy);
    margin-bottom: 2rem;
}



.repository-search {
    margin: 3rem 0;
}

.repository-search form {
    display: flex;
    gap: 1rem;
}

.repository-search input {
    flex: 1;
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.repository-search button {
    padding: 1rem 1.5rem;
}

.repository-tags {
    margin-bottom: 3rem;
}

.repository-tags h2 {
    margin-bottom: 1rem;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.tag-pill {
    display: inline-block;
    padding: 0.6rem 1rem;
    border-radius: 999px;
    background: #f3f4f6;
    text-decoration: none;
    color: inherit;
}

.tag-pill:hover {
    background: var(--blue);
    color: white;
}

.poliacconomic-container.mind-dependent-ledgers-section {
    max-width: 1300px !important;
    width: min(1300px, 95vw);
    margin: 0 auto;
    padding: 20px;
}

.poliacconomic-container.political-ledgers-section {
    max-width: 1100px !important;
    width: 100%;
    margin: 0 auto;
}

.poliacconomic-container.economic-ledgers-section {
    max-width: 1100px !important;
    width: 100%;
    margin: 0 auto;
}
.poliacconomic-container.natural-ledgers-section {
    max-width: 1100px !important;
    width: 100%;
    margin: 0 auto;
}

.poliacconomic-container.biological-ledgers-section {
    max-width: 1100px !important;
    width: 100%;
    margin: 0 auto;
}



.poliacconomic-container .services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 25px;
}

.poliacconomic-table-container {
    max-width: 1300px;
    margin: 0 auto;
}

.matrix-data-table {
    width: 100%;
    font-size: 0.85rem;
}

.matrix-data-table th {
    font-size: 0.85rem;
}

.matrix-data-table td {
    font-size: 0.8rem;
    padding: 8px 10px;
    vertical-align: top;
}

.cell-identity {
    font-size: 0.8rem;
}

.cell-formula {
    font-size: 0.75rem;
    word-break: break-word;
    overflow-wrap: anywhere;
}

/* Shrink MathJax formulas */
.cell-formula mjx-container {
    font-size: 80% !important;
}

/* Optional: narrow first column */
.cell-idx {
    width: 50px;
    white-space: nowrap;
}


.theme-header p {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #f7fafc;
    margin: 0;
    max-width: 1100px;
    font-weight: 400;
    opacity: 0.95;
    font-style: normal;
}

.ledger-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  gap: 24px;
  margin-top: 30px;
}

.ledger-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
  transition: all 0.25s ease;
}

.ledger-card:hover {
  transform: translateY(-4px);
  border-color: #cbd5e1;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
}

.ledger-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.ledger-id {
  width: 56px;
  height: 56px;
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #0f172a;
  color: #ffffff;

  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
}

.ledger-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.45;
}



@media (max-width: 768px) {

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

  .ledger-card {
    padding: 20px;
  }

  .ledger-id {
    width: 48px;
    height: 48px;
    font-size: 0.75rem;
  }

  .ledger-card-title {
    font-size: 1rem;
  }

  /* MathJax container */
.ledger-formula mjx-container {
    width: 100% !important;
    max-width: 100%;
    overflow-x: hidden !important;

    font-size: 80% !important;

    display: flex !important;
    justify-content: center;
}

}


.ledger-formula {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 18px;
text-align: center;
    overflow: hidden;
    width: 100%;
}


/* Force displayed equations to fit card width */
.ledger-formula mjx-math {
    max-width: 100%;
    white-space: normal !important;
}


pre {
    overflow-x: auto;
    overflow-y: hidden;

    max-width: 100%;

    padding: 1rem;
    border-radius: 8px;

    background: #f8fafc;
    border: 1px solid #e2e8f0;

    -webkit-overflow-scrolling: touch;
}

.paper-content img,
.wp-post-image,
.featured-image img {
    display: block;
    width: 100%;
    max-width: 500px;
    height: auto;
    margin: 2rem auto;
    border-radius: 8px;
}



/* Prevent overflow in all content */
.paper-content img {
    max-width: 100%;
}

.research-mission-quote {
    max-width: 900px;
    margin: 3rem auto;
    padding: 1.5rem 2rem;

    font-family: "Inter", sans-serif;
    font-size: 1.125rem;
    line-height: 1.8;
    font-weight: 400;

    color: #334155;
    text-align: center;

    border-left: 4px solid #0f172a;
    background: #f8fafc;

    font-style: normal;
}

.page-body p {
    font-size: 0.875rem;
    line-height: 1.8;
}

.page-body {
    max-width: 1100px;
    font-family: Merriweather, serif;
    font-size: 0.875rem;
    line-height: 1.8;
}

