/* ============================================================
   maryjaynearia.com — Master Stylesheet
   Bootstrap 5.3 base + custom styles
   ============================================================ */

/* ---- CSS Custom Properties ---- */
:root {
    --color-brand:       #17bed2;
    --color-brand-dark:  #0e9ab0;
    --color-heading:     #1a1f2e;
    --color-body:        #4a4f5e;
    --color-muted:       #8a8f9e;
    --color-bg:          #ffffff;
    --color-bg-subtle:   #f8f9fc;
    --color-border:      #e8eaf0;
    --color-footer-bg:   #1a1f2e;
    --font-heading:      'Playfair Display', Georgia, serif;
    --font-body:         'Hind', sans-serif;
    --nav-height:        72px;
    --transition:        0.3s ease;
    --radius:            6px;
    --shadow-sm:         0 2px 8px rgba(26,31,46,0.08);
    --shadow-md:         0 6px 24px rgba(26,31,46,0.12);
}

/* ---- Base ---- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--color-body);
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
}

/* ---- Skip link ---- */
.skip-link {
    position: absolute;
    top: -100px;
    left: 1rem;
    background: var(--color-brand);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    z-index: 9999;
    font-weight: 600;
    transition: top var(--transition);
}
.skip-link:focus { top: 1rem; }

/* ---- Typography ---- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--color-heading);
    line-height: 1.25;
    margin-bottom: 1rem;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 600; }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); font-weight: 600; }
h4 { font-size: 1.2rem; font-weight: 600; }

p {
    margin-bottom: 1.25rem;
    color: var(--color-body);
}
p:last-child { margin-bottom: 0; }

a {
    color: var(--color-brand);
    text-decoration: none;
    transition: color var(--transition);
}
a:hover, a:focus { color: var(--color-brand-dark); text-decoration: underline; }

strong { color: var(--color-heading); }

/* Brand accent underline for section headings */
.section-title {
    position: relative;
    padding-bottom: 0.75rem;
    margin-bottom: 1.5rem;
}
.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 48px;
    height: 3px;
    background: var(--color-brand);
    border-radius: 2px;
}
.section-title.text-center::after { left: 50%; transform: translateX(-50%); }

/* ---- Navigation ---- */
.site-header { position: relative; }

.navbar {
    background: #fff;
    height: var(--nav-height);
    padding: 0;
    border-bottom: 1px solid var(--color-border);
    transition: box-shadow var(--transition);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
}
.navbar.scrolled { box-shadow: var(--shadow-sm); }

.navbar-logo { height: 27px; width: 140px; }

.navbar-nav .nav-link {
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--color-heading);
    padding: 0.5rem 1rem;
    text-transform: uppercase;
    transition: color var(--transition);
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active { color: var(--color-brand); }

.navbar-nav .nav-link.active {
    border-bottom: 2px solid var(--color-brand);
}

/* Custom hamburger */
.navbar-toggler {
    border: none;
    padding: 0.25rem;
    background: transparent;
    display: flex;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.navbar-toggler:focus { box-shadow: none; }
.toggler-bar {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--color-heading);
    border-radius: 2px;
    transition: var(--transition);
}
.navbar-toggler[aria-expanded="true"] .toggler-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.navbar-toggler[aria-expanded="true"] .toggler-bar:nth-child(2) {
    opacity: 0;
}
.navbar-toggler[aria-expanded="true"] .toggler-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Dropdown */
.dropdown-menu {
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 0.5rem 0;
}
.dropdown-item {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-heading);
    padding: 0.6rem 1.25rem;
    transition: background var(--transition), color var(--transition);
}
.dropdown-item:hover { background: var(--color-bg-subtle); color: var(--color-brand); }

.badge-upcoming {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: var(--color-brand);
    color: #fff;
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    margin-left: 0.4rem;
    vertical-align: middle;
}

/* Offset content below fixed navbar */
main { padding-top: var(--nav-height); }

/* ---- Hero Section ---- */
.hero {
    background: var(--color-bg-subtle);
    padding: 5rem 0 0;
    overflow: hidden;
}

.hero-content { padding-bottom: 4rem; }

.hero-label {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-brand);
    margin-bottom: 1rem;
}

.hero h1 { margin-bottom: 0.5rem; }

.hero-subtitle {
    font-family: var(--font-heading);
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    font-weight: 400;
    font-style: italic;
    color: var(--color-muted);
    margin-bottom: 1.5rem;
    line-height: 1.4;
}

.hero-intro {
    font-size: 1.05rem;
    line-height: 1.75;
    max-width: 540px;
    margin-bottom: 2rem;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 2rem; }

.hero-social { display: flex; gap: 0.75rem; }
.hero-social .social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--color-border);
    border-radius: 50%;
    color: var(--color-heading);
    transition: var(--transition);
}
.hero-social .social-link:hover {
    background: var(--color-brand);
    border-color: var(--color-brand);
    color: #fff;
    text-decoration: none;
}

.hero-image-col {
    display: flex;
    align-items: flex-end;
    justify-content: center;
}
.hero-photo {
    max-height: 520px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    object-position: bottom;
    display: block;
    /* [GUIDE: Photo should be transparent PNG or image with clean bottom edge] */
}

/* ---- Buttons ---- */
.btn-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--color-brand);
    color: #fff;
    border: 2px solid var(--color-brand);
    padding: 0.7rem 1.75rem;
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}
.btn-brand:hover, .btn-brand:focus {
    background: var(--color-brand-dark);
    border-color: var(--color-brand-dark);
    color: #fff;
    text-decoration: none;
}

.btn-outline-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    color: var(--color-brand);
    border: 2px solid var(--color-brand);
    padding: 0.7rem 1.75rem;
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}
.btn-outline-brand:hover, .btn-outline-brand:focus {
    background: var(--color-brand);
    color: #fff;
    text-decoration: none;
}

/* ---- Content Sections ---- */
.section { padding: 5rem 0; }
.section-alt { background: var(--color-bg-subtle); }

.section-media-image {
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    display: block;
}

/* ---- Research Topic Cards ---- */
.research-cards { padding: 4rem 0; background: var(--color-bg); }

.research-card {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 2rem;
    height: 100%;
    transition: box-shadow var(--transition), transform var(--transition);
    position: relative;
    overflow: hidden;
}
.research-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: var(--color-brand);
}
.research-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.research-card-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1;
}

.research-card h3 {
    font-size: 1.15rem;
    margin-bottom: 0.75rem;
}

.research-card p { font-size: 0.95rem; }

.research-card .card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 1rem;
    color: var(--color-brand);
    text-decoration: none;
}
.research-card .card-link:hover { color: var(--color-brand-dark); text-decoration: none; }
.research-card .card-link::after { content: '→'; }

/* ---- Book Section ---- */
.book-cover-wrap {
    text-align: center;
}
.book-cover {
    max-width: 260px;
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    /* [GUIDE: Replace src with book cover image path] */
}
.book-cover-placeholder {
    max-width: 260px;
    width: 100%;
    min-height: 360px;
    background: var(--color-bg-subtle);
    border: 2px dashed var(--color-border);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-muted);
    font-size: 0.875rem;
    text-align: center;
    padding: 2rem;
    margin: 0 auto;
}

/* Larger cover variant used on the dedicated book page */
.book-cover-lg,
.book-cover-lg.book-cover-placeholder {
    max-width: 320px;
    min-height: 440px;
}

/* Book metadata stats bar */
.book-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    overflow: hidden;
    margin: 2rem 0;
}
.book-stat-item {
    flex: 1 1 160px;
    padding: 1rem 1.25rem;
    border-right: 1px solid var(--color-border);
    background: var(--color-bg);
}
.book-stat-item:last-child { border-right: none; }
.book-stat-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-muted);
    margin-bottom: 0.2rem;
}
.book-stat-value {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--color-heading);
}

/* Topics covered grid */
.topics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}
.topic-item {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 1rem 1.1rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font-size: 0.93rem;
    color: var(--color-body);
    transition: border-color var(--transition);
}
.topic-item:hover { border-color: var(--color-brand); }
.topic-item::before {
    content: '→';
    color: var(--color-brand);
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 1px;
}

@media (max-width: 575.98px) {
    .book-stats { flex-direction: column; }
    .book-stat-item { border-right: none; border-bottom: 1px solid var(--color-border); }
    .book-stat-item:last-child { border-bottom: none; }
}

/* ---- Internal nav cards (page links section) ---- */
.page-links-section { padding: 4rem 0; background: var(--color-bg-subtle); }

.page-link-card {
    display: block;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1.75rem;
    height: 100%;
    text-decoration: none;
    color: var(--color-body);
    transition: box-shadow var(--transition), transform var(--transition);
}
.page-link-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
    color: var(--color-body);
    text-decoration: none;
}
.page-link-card h4 {
    color: var(--color-heading);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    transition: color var(--transition);
}
.page-link-card:hover h4 { color: var(--color-brand); }
.page-link-card p { font-size: 0.9rem; margin-bottom: 0; }
.page-link-card .card-arrow {
    display: inline-block;
    margin-top: 1rem;
    color: var(--color-brand);
    font-weight: 600;
    font-size: 0.875rem;
}

/* ---- Explore Research (external links) ---- */
.explore-link {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--color-body);
    transition: var(--transition);
    height: 100%;
}
.explore-link:hover {
    border-color: var(--color-brand);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    color: var(--color-body);
}
.explore-link-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: var(--color-bg-subtle);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-brand);
    font-size: 1.25rem;
}
.explore-link h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--color-heading);
}
.explore-link p { font-size: 0.875rem; margin-bottom: 0; }

/* ---- Quote / callout ---- */
.callout {
    border-left: 4px solid var(--color-brand);
    padding: 1.25rem 1.5rem;
    background: var(--color-bg-subtle);
    border-radius: 0 var(--radius) var(--radius) 0;
    margin: 2rem 0;
}
.callout p { font-size: 1.05rem; font-style: italic; margin: 0; color: var(--color-heading); }

/* ---- Biography specific ---- */
.bio-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}
.bio-meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.9rem;
    color: var(--color-muted);
}
.bio-meta-item strong { color: var(--color-heading); }

/* ---- Page hero (inner pages) ---- */
.page-hero {
    background: var(--color-bg-subtle);
    padding: 4rem 0 3rem;
    border-bottom: 1px solid var(--color-border);
}
.page-hero-label {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-brand);
    margin-bottom: 0.75rem;
}
.page-hero p {
    font-size: 1.1rem;
    max-width: 640px;
    color: var(--color-body);
}

/* ---- Footer ---- */
.site-footer {
    background: var(--color-footer-bg);
    color: rgba(255,255,255,0.65);
    padding-top: 4rem;
}

.footer-top { padding-bottom: 3rem; border-bottom: 1px solid rgba(255,255,255,0.1); }

.footer-logo { height: 27px; width: auto; filter: brightness(0) invert(1); opacity: 0.9; }

.footer-tagline {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.55);
    margin-top: 1rem;
    max-width: 280px;
}

.footer-social { display: flex; gap: 0.6rem; margin-top: 1.25rem; }
.footer-social .social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    color: rgba(255,255,255,0.6);
    transition: var(--transition);
}
.footer-social .social-link:hover {
    background: var(--color-brand);
    border-color: var(--color-brand);
    color: #fff;
    text-decoration: none;
}

.footer-heading {
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 1.25rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}
.footer-links li { margin-bottom: 0.65rem; }
.footer-links a {
    color: rgba(255,255,255,0.65);
    font-size: 0.9rem;
    text-decoration: none;
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--color-brand); text-decoration: none; }
.footer-link-desc {
    display: block;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.4);
    margin-top: 0.1rem;
    line-height: 1.4;
}

.footer-bottom {
    padding: 1.5rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.footer-copy, .footer-location {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    margin: 0;
}
.footer-copy a { color: rgba(255,255,255,0.6); }
.footer-copy a:hover { color: var(--color-brand); }

/* ---- Back to top ---- */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 44px;
    height: 44px;
    background: var(--color-brand);
    color: #fff;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity var(--transition), visibility var(--transition), transform var(--transition), background var(--transition);
    z-index: 900;
    box-shadow: var(--shadow-sm);
}
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.back-to-top:hover { background: var(--color-brand-dark); }

/* ---- Collaborator Cards (Biography page) ---- */
.collaborator-card {
    display: flex;
    gap: 1.75rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 2rem;
    align-items: flex-start;
}

.collaborator-photo {
    flex-shrink: 0;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--color-border);
    background: var(--color-bg-subtle);
}

.collaborator-photo-placeholder {
    flex-shrink: 0;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: var(--color-bg-subtle);
    border: 2px dashed var(--color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-muted);
    font-size: 0.7rem;
    text-align: center;
    padding: 0.5rem;
    line-height: 1.3;
}

.collaborator-info h3 {
    font-size: 1.15rem;
    margin-bottom: 0.25rem;
}

.collaborator-role {
    font-size: 0.85rem;
    color: var(--color-brand);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.75rem;
    display: block;
}

.collaborator-info p { font-size: 0.95rem; margin-bottom: 0.75rem; }

.collaborator-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.collab-link {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-brand);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}
.collab-link:hover { color: var(--color-brand-dark); text-decoration: underline; }

@media (max-width: 575.98px) {
    .collaborator-card { flex-direction: column; align-items: center; text-align: center; }
    .collaborator-links { justify-content: center; }
}

/* ---- Findings list ---- */
.findings-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}
.findings-list li {
    padding: 0.6rem 0 0.6rem 1.5rem;
    position: relative;
    color: var(--color-body);
    border-bottom: 1px solid var(--color-border);
    font-size: 0.975rem;
}
.findings-list li:last-child { border-bottom: none; }
.findings-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--color-brand);
    font-weight: 700;
}

/* ---- Numbered Pillars (Research Philosophy page) ---- */
.pillar-list {
    counter-reset: pillar-counter;
    list-style: none;
    padding: 0;
    margin: 0;
}
.pillar-list li {
    counter-increment: pillar-counter;
    position: relative;
    padding: 1.5rem 1.5rem 1.5rem 5rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    background: var(--color-bg);
    transition: border-color var(--transition), box-shadow var(--transition);
}
.pillar-list li:hover {
    border-color: var(--color-brand);
    box-shadow: var(--shadow-sm);
}
.pillar-list li::before {
    content: counter(pillar-counter, decimal-leading-zero);
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--color-brand);
    line-height: 1;
    opacity: 0.85;
}
.pillar-list li h3 {
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
    color: var(--color-heading);
}
.pillar-list li p {
    font-size: 0.93rem;
    margin: 0;
    color: var(--color-body);
}

/* ---- Publication list (Media page) ---- */
.pub-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.pub-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    padding: 1.5rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    transition: box-shadow var(--transition);
}
.pub-item:hover { box-shadow: var(--shadow-sm); }
.pub-type-badge {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: var(--color-bg-subtle);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    font-size: 1.2rem;
    line-height: 1;
}
.pub-item-body { flex: 1; }
.pub-item-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}
.pub-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-brand);
}
.pub-status {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.15rem 0.5rem;
    border-radius: 3px;
}
.pub-status-published {
    background: #e8f7f0;
    color: #1a7a4a;
}
.pub-status-forthcoming {
    background: #fff4e0;
    color: #9a6200;
}
.pub-item-body h3 {
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}
.pub-item-body p { font-size: 0.93rem; margin-bottom: 0.6rem; }
.pub-item-link {
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-brand);
    text-decoration: none;
}
.pub-item-link:hover { color: var(--color-brand-dark); text-decoration: underline; }

/* Pending content placeholder (Media page) */
.media-pending {
    padding: 2.5rem;
    border: 2px dashed var(--color-border);
    border-radius: var(--radius);
    text-align: center;
    background: var(--color-bg-subtle);
}
.media-pending-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
    line-height: 1;
    opacity: 0.6;
}
.media-pending h3 {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
    color: var(--color-heading);
}
.media-pending p {
    font-size: 0.9rem;
    color: var(--color-muted);
    max-width: 420px;
    margin: 0 auto;
}

/* ---- Stay Updated CTA (Upcoming book page) ---- */
.update-cta {
    background: var(--color-bg);
    border: 2px solid var(--color-brand);
    border-radius: var(--radius);
    padding: 2.5rem;
    text-align: center;
}
.update-cta h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}
.update-cta p {
    color: var(--color-body);
    max-width: 480px;
    margin: 0 auto 1.5rem;
}
.update-cta-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
}

/* ---- Utility ---- */
.text-brand { color: var(--color-brand) !important; }
.bg-brand { background-color: var(--color-brand) !important; }
.divider { border: none; border-top: 1px solid var(--color-border); margin: 2rem 0; }

/* ---- Responsive ---- */
@media (max-width: 991.98px) {
    .navbar {
        height: auto;
        padding: 0.75rem 0;
    }
    main { padding-top: 64px; }

    .navbar-collapse {
        background: #fff;
        padding: 1rem 0;
        border-top: 1px solid var(--color-border);
        margin-top: 0.5rem;
    }
    .navbar-nav .nav-link {
        padding: 0.6rem 1rem;
        border-bottom: none;
    }
    .navbar-nav .nav-link.active {
        border-bottom: none;
        color: var(--color-brand);
    }
    .dropdown-menu { box-shadow: none; border: none; padding-left: 1rem; }
}

@media (max-width: 767.98px) {
    .hero { padding-top: 3rem; }
    .hero-content { padding-bottom: 2rem; }
    .hero-photo { max-height: 340px; }
    .section { padding: 3.5rem 0; }
    .page-hero { padding: 3rem 0 2rem; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .back-to-top { bottom: 1.25rem; right: 1.25rem; }
}

@media (max-width: 575.98px) {
    .hero h1 { font-size: 2rem; }
    .hero-actions { flex-direction: column; }
    .hero-actions .btn-brand,
    .hero-actions .btn-outline-brand { width: 100%; justify-content: center; }
}


/* =============================================================
   CONTACT PAGE
   ============================================================= */

/* ---- Learn-more links (homepage intro) ---- */
.learn-more-links {
    border-left: 3px solid var(--color-brand);
    padding-left: 1.25rem;
}
.learn-more-links ul li { margin-bottom: .35rem; }
.learn-more-links .card-link {
    font-size: .9375rem;
}

/* ---- Contact form inputs ---- */
.contact-label {
    display: block;
    font-weight: 600;
    font-size: .875rem;
    color: var(--color-heading);
    margin-bottom: .4rem;
}
.contact-label .req { color: var(--color-brand); }

.contact-input {
    display: block;
    width: 100%;
    padding: .6rem .9rem;
    font-size: .9375rem;
    font-family: inherit;
    color: var(--color-body);
    background: #fff;
    border: 1.5px solid var(--color-border);
    border-radius: 6px;
    transition: border-color .15s, box-shadow .15s;
    outline: none;
}
.contact-input:focus {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 3px rgba(23, 190, 210, .15);
}
.contact-textarea { resize: vertical; min-height: 140px; }

/* ---- Contact success / error notices ---- */
.contact-success {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    background: #ecfdf5;
    border: 1px solid #6ee7b7;
    border-radius: 8px;
    padding: 1rem 1.25rem;
    color: #065f46;
    margin-bottom: 1.5rem;
    font-size: .9375rem;
    line-height: 1.5;
}
.contact-error {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    padding: .85rem 1.25rem;
    color: #991b1b;
    margin-bottom: 1.5rem;
    font-size: .9rem;
}

/* ---- Contact info sidebar card ---- */
.contact-info-card {
    background: var(--color-bg-subtle);
    border: 1px solid var(--color-border);
    border-radius: 10px;
    padding: 2rem;
}
.contact-detail {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}
.contact-detail strong {
    display: block;
    font-size: .875rem;
    color: var(--color-heading);
    margin-bottom: .2rem;
}
.contact-detail-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    background: var(--color-brand);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1rem;
}
.contact-email-link {
    display: block;
    color: var(--color-brand);
    font-size: .9375rem;
    word-break: break-all;
    text-decoration: none;
}
.contact-email-link:hover { color: var(--color-brand-dark); text-decoration: underline; }
.contact-platform-link {
    display: block;
    color: var(--color-body);
    font-size: .875rem;
    text-decoration: none;
    margin-bottom: .15rem;
}
.contact-platform-link:hover { color: var(--color-brand); }
.contact-social { display: flex; gap: .75rem; }


/* =============================================================
   BLOG — Listing, cards, single post, filter bar
   ============================================================= */

/* ── Filter bar ── */
.blog-filter-bar {
    background: var(--color-bg-subtle);
    border-bottom: 1px solid var(--color-border);
    padding: 1.1rem 0;
}
.blog-filter-inner { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.blog-search-wrap { position: relative; flex: 1; min-width: 200px; }
.blog-search-icon {
    position: absolute; left: .8rem; top: 50%; transform: translateY(-50%);
    color: var(--color-muted); pointer-events: none;
}
.blog-search-input {
    width: 100%; padding: .55rem .9rem .55rem 2.25rem; font-size: .9rem;
    border: 1.5px solid var(--color-border); border-radius: 6px; outline: none;
    color: var(--color-body); background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.blog-search-input:focus { border-color: var(--color-brand); box-shadow: 0 0 0 3px rgba(23,190,210,.15); }
.blog-category-select {
    padding: .55rem .9rem; font-size: .9rem; border: 1.5px solid var(--color-border);
    border-radius: 6px; outline: none; color: var(--color-body); background: #fff;
    cursor: pointer; transition: border-color .15s;
}
.blog-category-select:focus { border-color: var(--color-brand); }
.btn-sm-brand {
    padding: .5rem 1rem; font-size: .875rem; border-radius: 6px; font-weight: 600;
    white-space: nowrap; text-decoration: none; cursor: pointer; border: none;
    display: inline-flex; align-items: center; transition: background .15s, color .15s;
}

/* ── Blog cards ── */
.blog-listing-section { background: var(--color-bg); }
.blog-card {
    background: #fff; border-radius: 10px; border: 1px solid var(--color-border);
    overflow: hidden; display: flex; flex-direction: column; height: 100%;
    transition: box-shadow .2s, transform .2s;
}
.blog-card:hover { box-shadow: 0 8px 28px rgba(0,0,0,.09); transform: translateY(-2px); }
.blog-card--premium { border-color: #fde68a; }
.blog-card-image-link { display: block; overflow: hidden; }
.blog-card-image { width: 100%; height: 200px; object-fit: cover; display: block; transition: transform .3s; }
.blog-card:hover .blog-card-image { transform: scale(1.03); }
.blog-card-image-placeholder {
    width: 100%; height: 200px; background: var(--color-bg-subtle);
    display: flex; align-items: center; justify-content: center; font-size: 2.5rem;
}
.blog-card-body { padding: 1.25rem 1.5rem 1.5rem; display: flex; flex-direction: column; flex: 1; }
.blog-card-meta { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-bottom: .65rem; }
.blog-card-category {
    font-size: .78rem; font-weight: 600; color: var(--color-brand); text-decoration: none;
    text-transform: uppercase; letter-spacing: .04em;
    background: rgba(23,190,210,.1); padding: .15rem .55rem; border-radius: 4px;
    transition: background .15s;
}
.blog-card-category:hover { background: rgba(23,190,210,.2); }
.blog-card-date { font-size: .8rem; color: var(--color-muted); margin-left: auto; }
.blog-premium-badge {
    font-size: .75rem; font-weight: 600; color: #92400e;
    background: #fef3c7; border: 1px solid #fde68a; border-radius: 4px;
    padding: .1rem .45rem; display: inline-flex; align-items: center; gap: .3rem;
}
.blog-card-title {
    font-family: 'Playfair Display', Georgia, serif; font-size: 1.1rem;
    font-weight: 700; line-height: 1.35; color: var(--color-heading); margin: 0 0 .65rem;
}
.blog-card-title a { color: inherit; text-decoration: none; transition: color .15s; }
.blog-card-title a:hover { color: var(--color-brand); }
.blog-card-excerpt { font-size: .9rem; color: var(--color-body); line-height: 1.6; margin: 0 0 1rem; flex: 1; }
.blog-card-link {
    display: inline-flex; align-items: center; gap: .4rem; font-size: .875rem;
    font-weight: 600; color: var(--color-brand); text-decoration: none; margin-top: auto;
    transition: color .15s, gap .15s;
}
.blog-card-link:hover { color: var(--color-brand-dark); gap: .6rem; }

/* ── Blog pagination ── */
.blog-pagination { display: flex; justify-content: center; align-items: center; gap: .4rem; margin-top: 3rem; flex-wrap: wrap; }
.blog-page-link {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 38px; height: 38px; padding: 0 .75rem;
    border: 1.5px solid var(--color-border); border-radius: 6px; font-size: .875rem;
    font-weight: 500; color: var(--color-body); text-decoration: none; background: #fff;
    transition: border-color .15s, background .15s, color .15s;
}
.blog-page-link:hover { border-color: var(--color-brand); color: var(--color-brand); }
.blog-page-link--active { background: var(--color-brand); border-color: var(--color-brand); color: #fff; }
.blog-empty { text-align: center; padding: 4rem 0; color: var(--color-muted); }
.blog-empty p { font-size: 1.1rem; margin-bottom: 1.5rem; }
.blog-card--hidden { border-color: #fca5a5; }
.blog-card-excerpt--locked { color: var(--color-muted); font-style: italic; font-size: .875rem; }
.blog-premium-badge--hidden { background: #fee2e2; border-color: #fca5a5; color: #991b1b; }
/* Access option selector in admin */
.access-option {
    border: 1.5px solid var(--color-border, #e8eaf0);
    border-radius: 8px;
    padding: .75rem 1rem;
    transition: border-color .15s, background .15s;
    cursor: pointer;
}
.access-option:hover { border-color: #17bed2; background: rgba(23,190,210,.04); }
.access-option--active { border-color: #17bed2; background: rgba(23,190,210,.06); }

/* =============================================================
   BLOG — Single post
   ============================================================= */

.breadcrumb-bar { background: var(--color-bg-subtle); border-bottom: 1px solid var(--color-border); padding: .65rem 0; }
.breadcrumb-list {
    list-style: none; margin: 0; padding: 0; display: flex; align-items: center;
    gap: .4rem; flex-wrap: wrap; font-size: .83rem; color: var(--color-muted);
}
.breadcrumb-list a { color: var(--color-muted); text-decoration: none; }
.breadcrumb-list a:hover { color: var(--color-brand); }
.breadcrumb-list li:last-child { color: var(--color-body); font-weight: 500; }

.post-hero { padding: 3.5rem 0 2rem; }
.post-meta-top { display: flex; align-items: center; gap: .65rem; flex-wrap: wrap; margin-bottom: 1rem; }
.post-category-badge {
    font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
    color: var(--color-brand); background: rgba(23,190,210,.1); border-radius: 4px;
    padding: .2rem .6rem; text-decoration: none;
}
.post-premium-badge {
    font-size: .78rem; font-weight: 600; color: #92400e;
    background: #fef3c7; border: 1px solid #fde68a; border-radius: 4px;
    padding: .2rem .55rem; display: inline-flex; align-items: center; gap: .3rem;
}
.post-date { font-size: .85rem; color: var(--color-muted); margin-left: auto; }
.post-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(1.75rem, 4vw, 2.75rem); font-weight: 700;
    line-height: 1.25; color: var(--color-heading); margin: 0 0 .75rem;
}
.post-subtitle { font-size: 1.15rem; color: var(--color-body); line-height: 1.6; margin: 0; }

.post-featured-image-wrap { padding-bottom: 2rem; }
.post-featured-image { width: 100%; height: auto; border-radius: 10px; display: block; max-height: 510px; object-fit: cover; }

.post-content-section { padding-top: 2.5rem; }
.post-body { line-height: 1.8; color: var(--color-body); }
.post-body h2, .post-body h3, .post-body h4 { font-family: 'Playfair Display', Georgia, serif; color: var(--color-heading); margin: 2rem 0 .75rem; }
.post-body h2 { font-size: 1.6rem; }
.post-body h3 { font-size: 1.3rem; }
.post-body p { margin: 0 0 1.25rem; }
.post-body a { color: var(--color-brand); }
.post-body a:hover { color: var(--color-brand-dark); }
.post-body ul, .post-body ol { margin: 0 0 1.25rem 1.25rem; }
.post-body li { margin-bottom: .4rem; }
.post-body blockquote {
    border-left: 3px solid var(--color-brand); margin: 1.5rem 0; padding: .75rem 1.25rem;
    background: var(--color-bg-subtle); border-radius: 0 6px 6px 0;
    font-style: italic; color: var(--color-heading);
}
.post-body img { max-width: 100%; height: auto; border-radius: 6px; margin: 1rem 0; }
.post-body--teaser { position: relative; max-height: 260px; overflow: hidden; }
.post-body--teaser::after {
    content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 100px;
    background: linear-gradient(transparent, #fff);
}

.post-tags { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--color-border); }
.post-tags-label { font-size: .85rem; color: var(--color-muted); font-weight: 600; }
.post-tag { font-size: .8rem; color: var(--color-body); background: var(--color-bg-subtle); border: 1px solid var(--color-border); border-radius: 20px; padding: .2rem .7rem; }

.premium-gate { margin-top: 2.5rem; }
.premium-gate-inner { background: var(--color-bg-subtle); border: 1px solid var(--color-border); border-radius: 12px; padding: 2.5rem; text-align: center; }
.premium-gate-icon { width: 64px; height: 64px; background: var(--color-brand); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 1.25rem; color: #fff; }
.premium-gate h2 { font-size: 1.4rem; color: var(--color-heading); margin-bottom: .75rem; }
.premium-gate p { color: var(--color-body); margin-bottom: 1.5rem; max-width: 500px; margin-left: auto; margin-right: auto; }
.premium-gate-actions { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }

.post-share-section { padding: 1.5rem 0; }
.post-share { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.post-share-label { font-size: .875rem; font-weight: 600; color: var(--color-muted); white-space: nowrap; }
.post-share-links { display: flex; gap: .5rem; flex-wrap: wrap; }
.share-btn { display: inline-flex; align-items: center; gap: .4rem; padding: .4rem .9rem; border-radius: 6px; font-size: .83rem; font-weight: 600; text-decoration: none; transition: opacity .15s; color: #fff; }
.share-btn:hover { opacity: .85; color: #fff; }
.share-btn--facebook { background: #1877f2; }
.share-btn--x        { background: #000; }
.share-btn--whatsapp { background: #25d366; }
.share-btn--email    { background: var(--color-body); }

.post-author-card { display: flex; gap: 1.25rem; align-items: flex-start; background: var(--color-bg-subtle); border: 1px solid var(--color-border); border-radius: 10px; padding: 1.5rem 2rem; }
.post-author-avatar { border-radius: 50%; flex-shrink: 0; }
.post-author-name { font-family: 'Playfair Display', Georgia, serif; font-size: 1.15rem; display: block; margin-bottom: .4rem; color: var(--color-heading); }
.post-author-bio { font-size: .9rem; color: var(--color-body); margin-bottom: .5rem; }

@media (max-width: 575.98px) {
    .blog-card-image, .blog-card-image-placeholder { height: 180px; }
    .post-author-card { flex-direction: column; }
    .post-author-avatar { width: 56px !important; height: 56px !important; }
    .premium-gate-inner { padding: 1.75rem 1.25rem; }
}



/* =============================================================
   PHASE 12 — Auth, Subscribe, Member, Earnings chart
   ============================================================= */

/* ── Nav account area ── */
.nav-account-area {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-left: 1rem;
    padding-left: 1rem;
    border-left: 1px solid var(--color-border);
}
.nav-account-link { font-size: .875rem !important; }
.nav-subscriber-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    background: var(--color-brand);
    color: #fff;
    border-radius: 50%;
    font-size: .6rem;
    font-weight: 700;
    margin-left: .25rem;
}
.btn-nav-subscribe {
    padding: .35rem .9rem;
    font-size: .8rem;
    font-weight: 700;
    background: var(--color-brand);
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    white-space: nowrap;
    transition: background .15s;
}
.btn-nav-subscribe:hover { background: var(--color-brand-dark); color: #fff; }

/* ── Auth forms ── */
.auth-form { background: var(--color-bg-subtle); border: 1px solid var(--color-border); border-radius: 10px; padding: 2rem; }
.btn-sm-inline { padding: .4rem 1rem; font-size: .875rem; font-weight: 600; border-radius: 6px; text-decoration: none; display: inline-flex; align-items: center; cursor: pointer; border: none; transition: background .15s, color .15s; }
.w-100.d-block.text-center.btn-brand { display: block !important; text-align: center; padding: .7rem; font-size: 1rem; border-radius: 6px; cursor: pointer; border: none; }

/* ── Subscribe page ── */
.subscribe-plan-card {
    background: #fff;
    border: 2px solid var(--color-brand);
    border-radius: 14px;
    padding: 2.5rem 2rem;
    text-align: center;
}
.subscribe-plan-price { margin-bottom: 1.5rem; line-height: 1; }
.subscribe-currency { font-size: 1.25rem; font-weight: 700; color: var(--color-muted); vertical-align: top; margin-top: .6rem; display: inline-block; }
.subscribe-amount { font-size: 3.5rem; font-weight: 800; color: var(--color-heading); font-family: 'Playfair Display', Georgia, serif; }
.subscribe-period { font-size: 1rem; color: var(--color-muted); margin-left: .25rem; }
.subscribe-features {
    list-style: none;
    padding: 0;
    margin: 0 0 1.75rem;
    text-align: left;
}
.subscribe-features li {
    padding: .4rem 0;
    font-size: .9375rem;
    color: var(--color-body);
    border-bottom: 1px solid var(--color-border);
}
.subscribe-features li::before { content: '✓'; color: var(--color-brand); font-weight: 700; margin-right: .6rem; }
.subscribe-auth-prompt { background: var(--color-bg-subtle); border-radius: 8px; padding: 1.25rem; }
.subscribe-auth-prompt p { margin-bottom: 1rem; font-size: .9rem; color: var(--color-muted); }

/* ── Member area ── */
.member-status-card {
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    border: 1.5px solid var(--color-border);
}
.member-status-card--active { background: #f0fdf4; border-color: #86efac; }
.member-status-card--inactive { background: var(--color-bg-subtle); }
.member-status-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: var(--color-brand);
    color: #fff;
}
.member-status-card--inactive .member-status-icon { background: var(--color-muted); }
.member-status-title { font-family: 'Playfair Display', Georgia, serif; font-size: 1.1rem; color: var(--color-heading); margin: 0 0 .5rem; }
.member-status-desc { font-size: .875rem; color: var(--color-body); margin-bottom: .75rem; }
.member-cancel-link { font-size: .8rem; color: var(--color-muted); text-decoration: underline; cursor: pointer; }
.member-cancel-link:hover { color: #dc3545; }

/* ── Earnings bar chart ── */
.earnings-chart {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 160px;
    border-bottom: 2px solid var(--color-border);
    padding-bottom: 0;
    margin-bottom: .5rem;
    overflow-x: auto;
}
.earnings-bar-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    min-width: 42px;
    height: 100%;
    justify-content: flex-end;
}
.earnings-bar-amount { font-size: .6rem; color: var(--color-brand); font-weight: 700; margin-bottom: 2px; text-align: center; white-space: nowrap; }
.earnings-bar {
    width: 100%;
    background: var(--color-border);
    border-radius: 4px 4px 0 0;
    min-height: 2px;
    transition: background .2s;
}
.earnings-bar:hover { background: var(--color-brand-dark); }
.earnings-bar-label { font-size: .6rem; color: var(--color-muted); text-align: center; margin-top: 4px; white-space: nowrap; transform: rotate(-35deg); transform-origin: top center; display: block; height: 28px; overflow: hidden; }

@media (max-width: 767.98px) {
    .nav-account-area { border-left: none; padding-left: 0; margin-left: 0; flex-wrap: wrap; }
    .auth-form { padding: 1.5rem 1.25rem; }
    .subscribe-plan-card { padding: 2rem 1.25rem; }
    .member-status-card { flex-direction: column; }
}


/* =============================================================
   CONTENT IMAGES — biography, research, parasites
   ============================================================= */

.biography-author-photo {
    width: 100%;
    max-width: 520px;
    height: auto;
    border-radius: 10px;
    display: block;
    margin: 0 auto;
}
.biography-photo-caption {
    display: block;
    text-align: center;
    font-size: .85rem;
    color: var(--color-muted);
    margin-top: .75rem;
    font-style: italic;
    line-height: 1.5;
}
.book-figure { margin: 2rem 0 1rem; }
.book-figure-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}
.content-figure { margin: 1.75rem 0; }
.content-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}
.parasite-image-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 1.5rem 0;
}
@media (max-width: 575.98px) {
    .parasite-image-pair { grid-template-columns: 1fr; }
}
