/* Custom Styles for PharmStudies Theme - Replacing Tailwind */

:root {
    --primary-color: #2563eb;
    /* blue-600 */
    --primary-light: #eff6ff;
    /* blue-50 */
    --text-dark: #111827;
    /* gray-900 */
    --text-muted: #6b7280;
    /* gray-500 */
    --border-color: #f3f4f6;
    /* gray-100 */
    --bg-light: #f8fafc;
    /* slate-50 */
    --white: #ffffff;
    --radius-xl: 1rem;
    /* rounded-2xl */
    --radius-lg: 0.75rem;
    /* rounded-xl */
    --navy-mix: #0B1E46;
    /* 70% Black + 30% Blue (approx) */
    --navy-mix-light: #eff1f5;
    /* Light version */
}

.text-navy-mix {
    color: var(--navy-mix) !important;
}

/* Contrast Improvements */
.text-gray-400 {
    color: #64748b !important;
    /* Darker slate-500 instead of gray-400 */
}

.text-gray-500 {
    color: #4b5563 !important;
    /* Darker gray-600 instead of gray-500 */
}

.bg-navy-mix-light {
    background-color: #EFF6FF !important;
    color: var(--navy-mix) !important;
}

/* =========================================
   Global Utilities
   ========================================= */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.text-center {
    text-align: center;
}

.hidden {
    display: none;
}

/* Screen Reader Text Utility */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: #f1f1f1;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

.flex {
    display: flex;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-4 {
    gap: 1rem;
}

.gap-6 {
    gap: 1.5rem;
}

.w-full {
    width: 100%;
}

/* =========================================
   Single Post Header
   ========================================= */
.single-header-section {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 3rem 1rem;
}

.header-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.header-icon-box {
    width: 4rem;
    height: 4rem;
    background-color: var(--primary-light);
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem auto;
    color: var(--primary-color);
}

.single-title {
    font-size: 2.25rem;
    /* 3xl */
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .single-title {
        font-size: 3rem;
        /* 5xl */
    }
}

.single-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* =========================================
   Single Post Content
   ========================================= */
.single-content-section {
    background-color: rgba(248, 250, 252, 0.5);
    /* slate-50/50 */
    padding: 3rem 1rem;
    min-height: 60vh;
}

.content-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1.5rem;
    /* rounded-3xl */
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

@media (min-width: 768px) {
    .content-card {
        padding: 2.5rem;
    }
}

@media (max-width: 768px) {
    .single-content-section {
        padding-left: 0;
        padding-right: 0;
    }

    .content-card {
        border-radius: 0;
        border-left: 0;
        border-right: 0;
    }
}

/* =========================================
   Download Box
   ========================================= */
.download-box {
    background-color: rgba(239, 246, 255, 0.5);
    /* blue-50/50 */
    border: 1px solid rgba(219, 234, 254, 0.5);
    /* blue-100/50 */
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    margin-bottom: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    justify-content: space-between;
}

@media (min-width: 640px) {
    .download-box {
        flex-direction: row;
        text-align: left;
    }
}

.download-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.download-icon {
    width: 3rem;
    height: 3rem;
    background-color: var(--white);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.download-text h3 {
    font-weight: 600;
    color: var(--text-dark);
    margin: 0;
}

.download-text p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin: 0;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}

.btn-blue-gradient {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: var(--white);
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.5);
}

.btn-blue-gradient:hover {
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
    color: var(--white);
    text-decoration: none;
}

.btn-outline-gray {
    border: 1px solid #e5e7eb;
    color: #374151;
    background: transparent;
}

.btn-outline-gray:hover {
    background-color: #f9fafb;
    color: var(--text-dark);
}

.btn-outline-blue {
    border: 1px solid #bfdbfe;
    color: #1d4ed8;
    background: transparent;
}

.btn-outline-blue:hover {
    background-color: #eff6ff;
}

/* =========================================
   Typography (replaces prose)
   ========================================= */
.entry-content {
    line-height: 1.75;
    color: #334155;
    /* slate-700 */
    font-size: 1.125rem;
    /* lg */
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
    color: var(--text-dark);
    font-weight: 700;
    margin-top: 2em;
    margin-bottom: 1em;
    line-height: 1.3;
}

.entry-content h1 {
    font-size: 2.25em;
}

.entry-content h2 {
    font-size: 1.5em;
}

/* prose-2xl equivalent ~1.5rem/24px base? prose-h2 is usually 1.5em */
.entry-content h3 {
    font-size: 1.25em;
}

.entry-content h4 {
    font-size: 1.125em;
}

.entry-content p {
    margin-bottom: 1.5em;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1.5em;
    padding-left: 1.625em;
}

.entry-content ul {
    list-style-type: disc;
}

.entry-content ol {
    list-style-type: decimal;
}

.entry-content li {
    margin-bottom: 0.5em;
}

.entry-content strong {
    color: var(--text-dark);
    font-weight: 600;
}

.entry-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.entry-content a:hover {
    text-decoration: underline;
}

.entry-content img {
    border-radius: var(--radius-xl);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    margin-bottom: 2em;
    max-width: 100%;
    height: auto;
}

.entry-content blockquote {
    border-left: 4px solid var(--primary-color);
    background-color: rgba(239, 246, 255, 0.3);
    padding: 1rem;
    font-style: italic;
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    margin-bottom: 1.5rem;
}

.entry-content code {
    background-color: var(--primary-light);
    color: #1e40af;
    /* blue-800 */
    padding: 0.2em 0.4em;
    border-radius: 0.25rem;
    font-size: 0.875em;
    font-weight: 600;
}

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2em;
}

.entry-content th,
.entry-content td {
    border: 1px solid var(--border-color);
    padding: 0.75rem;
    text-align: left;
}

.entry-content th {
    background-color: var(--bg-light);
    font-weight: 600;
}

/* =========================================
   Navigation
   ========================================= */
.post-navigation {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.nav-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 640px) {
    .nav-buttons {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* =========================================
   Notes Page Grid (Semesters)
   ========================================= */
.notes-section {
    background-color: rgba(248, 250, 252, 0.5);
    /* slate-50/50 */
    padding: 3rem 1rem;
    min-height: 60vh;
}

.notes-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
    .notes-header {
        text-align: left;
    }
}

.notes-header h2 {
    font-size: 1.25rem;
    /* xl */
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.notes-header p {
    font-size: 0.875rem;
    /* sm */
    color: var(--text-muted);
}

.notes-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .notes-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .notes-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.semester-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1.5rem;
    padding: 1.5rem;
    position: relative;
    transition: all 0.3s;
}

.semester-card:hover {
    border-color: #bfdbfe;
    /* blue-200 */
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1);
}

.sem-card-link {
    position: absolute;
    inset: 0;
    z-index: 10;
}

.sem-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.sem-number-box {
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--white);
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.sem-arrow-box {
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    background-color: #f9fafb;
    /* gray-50 */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.semester-card:hover .sem-arrow-box {
    background-color: var(--primary-light);
}

.sem-arrow {
    width: 1rem;
    height: 1rem;
    color: #9ca3af;
    /* gray-400 */
    transition: all 0.2s;
}

.semester-card:hover .sem-arrow {
    color: var(--primary-color);
    transform: translateX(2px);
}

.sem-title {
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.sem-count {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    /* xs */
    font-weight: 500;
    color: var(--text-muted);
    background-color: #f9fafb;
    /* gray-50 */
    padding: 0.25rem 0.5rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    width: fit-content;
}

.sem-subject-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.subject-item {
    font-size: 0.875rem;
    /* sm */
    color: #9ca3af;
    /* gray-400 */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.subject-dot {
    width: 0.25rem;
    height: 0.25rem;
    border-radius: 9999px;
    background-color: #93c5fd;
    /* blue-300 */
    flex-shrink: 0;
}

.more-subjects {
    font-size: 0.75rem;
    /* xs */
    color: var(--primary-color);
    font-weight: 600;
    padding-left: 0.75rem;
    padding-top: 0.25rem;
}

.gradient-text {
    background: linear-gradient(90deg, var(--text-dark) 0%, var(--text-dark) 60%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* =========================================
   Header & Navigation
   ========================================= */
.site-header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.5);
    position: sticky;
    top: 0;
    z-index: 50;
    transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.header-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
    height: 4rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.site-logo {
    height: 2rem;
    width: auto;
}

.site-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
}

/* Desktop Nav */
.desktop-nav {
    display: none;
}

@media (min-width: 768px) {
    .desktop-nav {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
}

.menu-item {
    position: relative;
}

.menu-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 0.75rem;
    color: #64748b;
    font-weight: 500;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all 0.2s;
}

.menu-link:hover {
    color: var(--primary-color);
    background-color: var(--primary-light);
}

.menu-icon {
    width: 1rem;
    height: 1rem;
}

/* Mobile Nav Toggle */
.mobile-menu-toggle {
    display: flex;
    padding: 0.5rem;
    color: #64748b;
    background: transparent;
    border: none;
    cursor: pointer;
}

@media (min-width: 768px) {
    .mobile-menu-toggle {
        display: none;
    }
}

/* Mobile Menu */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 40;
}

.mobile-menu-overlay.open {
    display: block;
}

.mobile-menu-container {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 80%;
    max-width: 20rem;
    background-color: var(--white);
    z-index: 50;
    padding: 1.5rem;
    box-shadow: -4px 0 15px rgba(0, 0, 0, 0.1);
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
}

.mobile-menu-container.open {
    transform: translateX(0);
}

/* =========================================
   Home Page Sections
   ========================================= */
.hero-section {
    position: relative;
    overflow: hidden;
    background-color: var(--white);
    padding: 5rem 1rem;
    text-align: center;
}

.bg-blob {
    position: absolute;
    border-radius: 9999px;
    filter: blur(64px);
    opacity: 0.4;
    z-index: 0;
}

.blob-1 {
    top: -10rem;
    right: -10rem;
    width: 24rem;
    height: 24rem;
    background-color: #dbeafe;
    /* blue-100 */
}

.blob-2 {
    bottom: -10rem;
    left: -10rem;
    width: 24rem;
    height: 24rem;
    background-color: #e0e7ff;
    /* indigo-100 */
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 64rem;
    margin: 0 auto;
}

.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 1rem;
    background-color: var(--primary-light);
    border: 1px solid #dbeafe;
    border-radius: 9999px;
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 2rem;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 4rem;
    }
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--text-muted);
    max-width: 42rem;
    margin: 0 auto 2.5rem auto;
    line-height: 1.6;
}

/* Stats Section */
.stats-section {
    padding: 4rem 1rem;
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 64rem;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
}

.stat-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem auto;
}

.icon-blue {
    background-color: #eff6ff;
    color: #2563eb;
}

.icon-indigo {
    background-color: #eef2ff;
    color: #4f46e5;
}

.icon-sky {
    background-color: #f0f9ff;
    color: #0284c7;
}

.stat-value {
    font-size: 1.875rem;
    font-weight: 800;
    color: var(--text-dark);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* =========================================
    Single Post Layout (Refined & Widened)
   ========================================= */
.single-header-section {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 3rem 1rem;
}

.header-content {
    max-width: 1100px;
    /* Widened from 800px */
    margin: 0 auto;
    text-align: center;
}

.header-icon-box {
    width: 4rem;
    height: 4rem;
    background-color: var(--primary-light);
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem auto;
    color: var(--primary-color);
}

.single-title {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .single-title {
        font-size: 3rem;
    }
}

.single-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.single-content-section {
    background-color: rgba(248, 250, 252, 0.5);
    /* slate-50/50 */
    padding: 3rem 1rem;
    min-height: 60vh;
}

.content-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1.5rem;
    max-width: 1100px;
    /* Widened from 800px */
    margin: 0 auto;
    padding: 1.5rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

@media (min-width: 768px) {
    .content-card {
        padding: 3rem;
        /* Increased padding for better spacing */
    }
}

/* Download Box */
.download-box {
    background-color: rgba(239, 246, 255, 0.5);
    border: 1px solid rgba(219, 234, 254, 0.5);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    margin-bottom: 3rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    justify-content: space-between;
}

@media (min-width: 640px) {
    .download-box {
        flex-direction: row;
        text-align: left;
    }
}

.download-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.download-icon {
    width: 3rem;
    height: 3rem;
    background-color: var(--white);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.download-text h3 {
    font-weight: 600;
    color: var(--text-dark);
    margin: 0;
}

.download-text p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin: 0;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-lg);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}

.btn-blue-gradient {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: var(--white);
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.5);
}

.btn-blue-gradient:hover {
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
    color: var(--white);
    text-decoration: none;
}

.btn-outline-gray {
    border: 1px solid #e5e7eb;
    color: #374151;
    background: transparent;
}

.btn-outline-gray:hover {
    background-color: #f9fafb;
    color: var(--text-dark);
}

.btn-outline-blue {
    border: 1px solid #bfdbfe;
    color: #1d4ed8;
    background: transparent;
}

.btn-outline-blue:hover {
    background-color: #eff6ff;
}

/* Typography (replaces prose) */
.entry-content {
    line-height: 1.75;
    color: #334155;
    font-size: 1.125rem;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
    color: var(--text-dark);
    font-weight: 700;
    margin-top: 2em;
    margin-bottom: 1em;
    line-height: 1.3;
}

.entry-content h1 {
    font-size: 2.25em;
}

.entry-content h2 {
    font-size: 1.5em;
}

.entry-content h3 {
    font-size: 1.25em;
}

.entry-content h4 {
    font-size: 1.125em;
}

.entry-content p {
    margin-bottom: 1.5em;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1.5em;
    padding-left: 1.625em;
}

.entry-content ul {
    list-style-type: disc;
}

.entry-content ol {
    list-style-type: decimal;
}

.entry-content li {
    margin-bottom: 0.5em;
}

.entry-content strong {
    color: var(--text-dark);
    font-weight: 600;
}

.entry-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.entry-content a:hover {
    text-decoration: underline;
}

.entry-content img {
    border-radius: var(--radius-xl);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    margin-bottom: 2em;
    max-width: 100%;
    height: auto;
}

.entry-content blockquote {
    border-left: 4px solid var(--primary-color);
    background-color: rgba(239, 246, 255, 0.3);
    padding: 1rem;
    font-style: italic;
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    margin-bottom: 1.5rem;
}

.entry-content code {
    background-color: var(--primary-light);
    color: #1e40af;
    padding: 0.2em 0.4em;
    border-radius: 0.25rem;
    font-size: 0.875em;
    font-weight: 600;
}

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2em;
}

.entry-content th,
.entry-content td {
    border: 1px solid var(--border-color);
    padding: 0.75rem;
    text-align: left;
}

.entry-content th {
    background-color: var(--bg-light);
    font-weight: 600;
}

/* Navigation */
.post-navigation {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.nav-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 640px) {
    .nav-buttons {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* =========================================
   Footer
   ========================================= */
.site-footer {
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
    padding-top: 4rem;
    padding-bottom: 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }
}

.footer-description {
    color: var(--text-muted);
    line-height: 1.6;
    margin: 1.5rem 0;
    max-width: 24rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.75rem;
    background-color: var(--bg-light);
    color: #64748b;
    transition: all 0.2s;
}

.social-link:hover {
    background-color: var(--primary-light);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.footer-heading {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-menu a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-menu a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: #9ca3af;
    font-size: 0.875rem;
}

/* Archive & More */
.archive-header {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 3rem 1rem;
    text-align: center;
}

.breadcrumb-bar {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
}

.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #9ca3af;
}

.breadcrumb-nav a {
    color: inherit;
    text-decoration: none;
}

.breadcrumb-nav a:hover {
    color: var(--primary-color);
}

.empty-state {
    text-align: center;
    padding: 5rem 1rem;
    background-color: var(--white);
    border-radius: 1rem;
    border: 1px solid var(--border-color);
}

/* =========================================
   Dynamic Subject & Unit Cards
   ========================================= */
.subject-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-decoration: none;
}

.subject-card:hover {
    border-color: #bfdbfe;
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
}

.subject-icon-box {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    background-color: var(--navy-mix-light);
    color: var(--navy-mix);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.subject-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.subject-meta {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.unit-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

.unit-card:hover {
    border-color: #bfdbfe;
    box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.1);
}

.unit-number-box {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    background-color: #eff6ff;
    color: #2563eb;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.unit-content {
    flex: 1;
}

.unit-title {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.unit-desc {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.arrow-icon {
    color: #cbd5e1;
    transition: transform 0.2s, color 0.2s;
}

.unit-card:hover .arrow-icon {
    color: #2563eb;
    transform: translateX(4px);
}

/* =========================================
   Semester Subject Card (Specific Override)
   ========================================= */
.semester-subject-card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    position: relative;
    /* Ensure proper stacking */
    overflow: hidden;
    /* Clean corners */
    min-height: 5rem;
}

.semester-subject-card:hover {
    border-color: #3b82f6;
    /* Blue-500 */
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
    z-index: 10;
}

.semester-subject-number {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    background-color: #eff6ff;
    /* Blue-50 */
    color: #2563eb;
    /* Blue-600 */
    font-weight: 700;
    font-size: 1.125rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.semester-subject-content {
    flex: 1;
    min-width: 0;
    /* Prevent text overflow issues */
}

.semester-subject-title {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
    line-height: 1.3;
    display: block;
}

.semester-subject-subtitle {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: block;
}

.semester-arrow-icon {
    color: #cbd5e1;
    /* Slate-300 */
    transition: transform 0.2s, color 0.2s;
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    /* Ensure SVG layout */
    align-items: center;
    justify-content: center;
}

.semester-subject-card:hover .semester-arrow-icon {
    color: #2563eb;
    transform: translateX(4px);
}

/* =========================================
   Unit List Dot (Specific Override)
   ========================================= */
.unit-list-item-dot {
    width: 6px;
    height: 6px;
    background-color: #3b82f6;
    /* Blue-500 */
    border-radius: 50%;
    margin-top: 0.5rem;
    flex-shrink: 0;
    display: inline-block;
}

/* =========================================
   Search Results Scrollbar
   ========================================= */
#desktop-search-results::-webkit-scrollbar,
#mobile-search-results::-webkit-scrollbar {
    width: 6px;
}

#desktop-search-results::-webkit-scrollbar-track,
#mobile-search-results::-webkit-scrollbar-track {
    background: #f1f5f9;
}

#desktop-search-results::-webkit-scrollbar-thumb,
#mobile-search-results::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 3px;
}

#desktop-search-results::-webkit-scrollbar-thumb:hover,
#mobile-search-results::-webkit-scrollbar-thumb:hover {
    background-color: #94a3b8;
}


/* =========================================
   Contact Form 7 Styles - Enhanced Modern Design
   ========================================= */

/* Use ID for High Specificity */
#contact-form-container .wpcf7 {
    margin: 0;
}

#contact-form-container .wpcf7-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Remove default paragraph margins */
#contact-form-container .wpcf7-form p {
    margin: 0 0 1.25rem 0;
}

#contact-form-container .wpcf7-form br {
    display: none;
}

/* Labels */
#contact-form-container .wpcf7-form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

/* Input and Textarea Base Styles */
/* Input and Textarea Base Styles */
#contact-form-container .wpcf7-form input[type="text"],
#contact-form-container .wpcf7-form input[type="email"],
#contact-form-container .wpcf7-form input[type="tel"],
#contact-form-container .wpcf7-form input[type="url"],
#contact-form-container .wpcf7-form input[type="number"],
#contact-form-container .wpcf7-form input[type="date"],
#contact-form-container .wpcf7-form textarea,
#contact-form-container .wpcf7-form select,
#contact-form-container input.wpcf7-form-control,
#contact-form-container textarea.wpcf7-form-control,
input.wpcf7-text,
input.wpcf7-email,
input.wpcf7-number,
textarea.wpcf7-textarea {
    width: 100%;
    padding: 0.875rem 1rem !important;
    font-size: 1rem !important;
    line-height: 1.5;
    color: #111827 !important;
    background-color: #f9fafb !important;
    border: 2px solid #e5e7eb !important;
    border-radius: 0.75rem !important;
    transition: all 0.2s ease;
    font-family: inherit;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    height: auto;
    /* Prevent height collapse */
    min-height: 48px;
    display: block;
    box-sizing: border-box;
}

/* Focus States */
#contact-form-container .wpcf7-form input:focus,
#contact-form-container .wpcf7-form textarea:focus,
#contact-form-container .wpcf7-form select:focus {
    outline: none;
    background-color: #ffffff !important;
    border-color: #2563eb !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}

/* Textarea Specific */
#contact-form-container .wpcf7-form textarea {
    min-height: 150px !important;
    resize: vertical;
    padding: 1rem !important;
}

/* Submit Button - Premium Style */
#contact-form-container .wpcf7-form input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem !important;
    font-size: 1rem !important;
    font-weight: 600;
    color: #ffffff !important;
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%) !important;
    border: none !important;
    border-radius: 0.75rem !important;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.3), 0 2px 4px -1px rgba(37, 99, 235, 0.1);
    width: auto !important;
    min-width: 180px;
    margin-top: 0.5rem;
    height: auto !important;
    text-transform: none;
}

#contact-form-container .wpcf7-form input[type="submit"]:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%) !important;
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.4), 0 4px 6px -2px rgba(37, 99, 235, 0.2);
    transform: translateY(-2px);
}

/* Form Row for Side-by-Side Fields */
#contact-form-container .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

/* Responsive */
@media (max-width: 768px) {
    #contact-form-container .form-row {
        grid-template-columns: 1fr;
    }

    #contact-form-container .wpcf7-form input[type="submit"] {
        width: 100% !important;
    }
}

/* Fix span layouts */
#contact-form-container .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
}