:root {
  --global-bg-color: #FCFCFA;           /* was #fff — warm off-white */
  --global-footer-bg-color: #f2f3f3;
  --global-dark-border-color: #dadada;
  --global-text-color: #21242A;         /* was #494e52 — near-black */
  --global-text-color-light: #8e959f;
  --global-link-underline: #C9C6BF;     /* quiet link underline */
}

.head {
    text-align: left;
    margin-bottom: 4em;
    margin-left: 0em;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5em; 
}

.head .site-title {
    font-size: 1.6em;
    margin: 0;
}

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

.head-link {
    font-size: 1em;
    font-weight: 400;
    color: var(--global-text-color);
    text-decoration: none;
    padding: 0.25em 0.6em;
    border-radius: 4px;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.head-link:hover,
.head-link:focus {
    color: #222;
    background-color: #f2f3f3;
}

.theme-toggle {
    font-size: 1em;
    color: var(--global-text-color);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25em 0.6em;
    border-radius: 4px;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.theme-toggle:hover,
.theme-toggle:focus {
    color: #222;
    background-color: #f2f3f3;
}

::selection {
  background: black;
  color: white;
}

html {
    scroll-behavior: smooth;
    box-sizing: border-box;
    background-color: var(--global-bg-color);
    font-size: 17px;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    height: 100%;
    color-scheme: light dark;
}

body {
    font-family: "Helvetica Neue", Helvetica, Arial, -apple-system, Roboto, sans-serif;
    font-weight: 400;
    font-size: 16px;
    color: var(--global-text-color);
    background-color: var(--global-bg-color);
    margin: 0;
    padding: 0;
    line-height: 1.6; 
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Main layout container */
.layout {
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 2.5em 4em 4em 2em; 
    flex: 1; 
    width: 100%;
    box-sizing: border-box;
}

/* Content wrapper for sidebar + main layout */
.content-wrapper {
    display: flex;
    gap: 1.5em; 
    align-items: flex-start;
}

/* Sidebar styling */
.sidebar {
    flex: 0 0 280px; /* Fixed width sidebar */
    position: sticky;
    top: 2em;
}

.author-avatar {
    margin-bottom: 1.5em;
}

.author-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: block;
    margin-left: 0;
    margin-right: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.author-photo:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.author-info {
    text-align: left;
}

.author-name {
    margin: 0 0 0.5em 0;
    font-size: 1.3em;
    font-weight: 600;
    color: var(--global-text-color);
    text-align: left;
}

.author-bio {
    margin: 0 0 0.2em 0;
    color: var(--global-text-color-light);
    font-size: 0.95em;
    line-height: 1.4;
}

.author-links {
    display:  flex;
    flex-direction: column;
    gap: 0.01em;
    align-items: flex-start; 
}

/* Main content area */
.main-content {
    flex: 1;
    min-width: 0; 
    padding-right: 4em;
}

.conference-banner {
    margin-bottom: 2.2em;
    padding: 1.1em 1.2em;
    border: 1px solid rgba(204, 0, 51, 0.22);
    border-radius: 16px;
    background: rgba(204, 0, 51, 0.08);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.conference-banner__eyebrow {
    margin: 0 0 0.35em 0;
    font-size: 0.82em;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--global-text-color-light);
}

.conference-banner__title {
    margin: 0 0 0.35em 0;
    font-size: 1.25em;
    color: var(--global-text-color);
}

.conference-banner__text {
    margin: 0 0 0.65em 0;
}

.conference-banner__text--small {
    margin-bottom: 0;
    font-size: 0.95em;
}

.conference-banner a {
    color: var(--global-text-color);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.conference-banner a:hover,
.conference-banner a:focus {
    color: #222;
}
/* Page sections */
.page.content {
    margin-bottom:2.5em; 
    padding: 0;
}

h1,h2,h3,h4,h5,h6 {
    margin: 2em 0 1em; 
    line-height: 1.3; 
    font-family: "Helvetica Neue", Helvetica, Arial, -apple-system, Roboto, sans-serif;
    font-weight: bold;
}

h1 {
    margin-top: 0;
    margin-bottom: 0.5em;
    font-size: 2.2em; 
}

h2 {
    font-size: 1.4em; 
    margin-top: 0; 
    color: var(--global-text-color);
}

h3 {
    font-size: 1.15em;
    margin-top: 0;
}

h4 {
    font-size: .75em
}

h5 {
    font-size: .75em
}

h6 {
    font-size: .75em
}

p {
    margin-bottom: 1.3em;
    line-height: 1.65;
    font-size: 1.02em; 
}

ol, ul {
    margin-bottom: 1em;
    padding-left: 2em;
}

li {
    margin-bottom: 0.1em;
    line-height: 1.5;
}


/* Links: subtle underline by default, accent color on hover */
.page a {
  color: var(--global-text-color);
  text-decoration: underline;
  text-decoration-color: var(--global-link-underline);
  text-underline-offset: 3px;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.page a:hover,
.page a:focus {
  color: #CC0033;
  text-decoration-color: #CC0033;
}

/* Highlight links: same hierarchy as normal links, brand color on hover */
.highlight-link-rutgers,
.highlight-link-heat,
.highlight-link-hunter {
  color: var(--global-text-color) !important;
  text-decoration: underline;
  text-decoration-color: var(--global-link-underline);
  text-underline-offset: 3px;
  background: none;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.highlight-link-rutgers:hover,
.highlight-link-rutgers:focus {
  color: #CC0033 !important; /* Rutgers red */
  text-decoration-color: #CC0033 !important;
}

.highlight-link-heat:hover,
.highlight-link-heat:focus {
  color: #D76852 !important; /* Heat red/orange */
  text-decoration-color: #D76852 !important;
}

.highlight-link-hunter:hover,
.highlight-link-hunter:focus {
  color: #5f259f !important;
  text-decoration-color: #5f259f !important;
}

/* Mobile header hidden by default */
.mobile-header {
    display: none;
    align-items: center;
    gap: 0.7em;
    padding: 1.2em 1.2em 0.7em 1.2em;
    background: #fff;
    position: relative;
    border-bottom: none;
}

.mobile-photo {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 0.7em;
}

.mobile-header-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-right: 1em;
}

.mobile-name {
    font-size: 1.08em;
    font-weight: 600;
    color: var(--global-text-color);
    line-height: 1.1;
    letter-spacing: 0.01em;
    display: block;
}

.mobile-bio {
    font-size: 0.97em;
    color: var(--global-text-color-light);
    line-height: 1.2;
    margin-top: 0.15em;
    display: block;
}

/* Compact mobile contact icons under name */
.mobile-contact-icons {
    display: flex;
    gap: 0.6em;
    margin-top: 0.35em;
}
.mobile-contact-icons .contact-link {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: var(--global-text-color);
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}
.mobile-contact-icons .contact-link:hover,
.mobile-contact-icons .contact-link:focus {
    background: #f6f8fa;
    color: #222;
    transform: translateY(-1px);
}
.mobile-contact-icons .contact-link i {
    font-size: 1.1em;
    width: auto;
    text-align: center;
}

/* --- Responsive Embeds --- */
img, embed, iframe {
    max-width: 100%;
    height: auto;
    display: block;
}

.page embed,
.page iframe {
    width: 100%;
    min-height: 500px;
    height: 800px;
    max-height: 90vh;
    margin: 0 auto;
    display: block;
}

@media (max-width: 800px) {
    .page embed,
    .page iframe {
        display: none !important;
    }
}

@media (max-width: 1000px) {
    .layout {
        padding: 1.5em 1em;
    }
    .main-content {
        padding-right: 0;
    }
    .conference-banner {
        margin-right: 0;
    }
}

@media (max-width: 800px) {
    .sidebar {
        display: none;
    }
    .mobile-header {
        display: flex;
        align-items: center;
        gap: 1em;
        padding: 1.2em 1em 0.7em 1em;
    }
    .mobile-photo {
        width: 80px;
        height: 80px;
        border-radius: 50%;
        object-fit: cover;
        margin-right: 0.7em;
    }
    .mobile-header-info {
        display: flex;
        flex-direction: column;
        justify-content: center;
        margin-right: 1em;
    }
    .mobile-name {
        display: block;
    }
    .mobile-bio {
        display: block;
    }
    .main-content {
        padding: 0 0.7em;
    }
    .page__inner-wrap {
        padding: 0;
    }
    h1 { font-size: 1.6em; }
    h2 { font-size: 1.2em; }
    h3 { font-size: 1.05em; }
}

@media (max-width: 768px) {
    .layout {
        padding: 1.5em 1em;
    }
}

@media (max-width: 480px) {
    .layout {
        padding: 1em 0.8em;
    }
    
    .author-photo {
        width: 120px;
        height: 120px;
    }
    
    .author-links {
        gap: 0.7em;
    }
    
    .contact-link {
        width: 35px;
        height: 35px;
    }
}

/* Make lists and paragraphs readable on mobile */
.page.content {
    font-size: 1em;
    line-height: 1.6;
    word-break: break-word;
    margin-bottom: 2em;
}

/* ===== CONTACT LINK ANIMATIONS ===== */

/* Desktop sidebar contact links */
.contact-link {
    display: flex;
    align-items: center;
    gap: 0.8em;
    padding: 0.4em 0;
    color: var(--global-text-color);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.9em;
    justify-self: flex-start;
    position: relative;
}

.contact-link:hover {
    color: var(--global-text-color-light);
    transform: translateX(5px);
}

.contact-link i {
    width: 20px;
    text-align: left;
    font-size: 1.1em;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.contact-link:hover i {
    transform: scale(1.15) rotate(5deg);
    transition: transform 0.3s ease;
}

.contact-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--global-text-color-light);
    transition: width 0.3s ease;
}

.contact-link:hover::after {
    width: 100%;
}

/* ===== BUTTON ANIMATIONS ===== */
/* ===== LINK HOVER ANIMATIONS (Enhanced) ===== */
.highlight-link-hunter,
.highlight-link-rutgers,
.highlight-link-heat {
    transition: all 0.3s ease;
}

/* Add subtle pulse effect when hovering */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.highlight-link-hunter:hover,
.highlight-link-rutgers:hover,
.highlight-link-heat:hover {
    animation: pulse 0.5s ease;
}


/* ===== BACK TO TOP BUTTON ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    background: var(--global-text-color);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.5em;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--global-text-color-light);
    transform: translateY(-5px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

.back-to-top:active {
    transform: translateY(-2px);
}

/* Mobile adjustments */
@media (max-width: 800px) {
    .back-to-top {
        width: 40px;
        height: 40px;
        bottom: 20px;
        right: 20px;
        font-size: 1.3em;
    }
}

/* ===== PROJECT CARDS ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.2em;
    margin-top: 1em;
}

.project-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--global-dark-border-color);
    border-radius: 10px;
    overflow: hidden;
    background: var(--global-bg-color);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover,
.project-card:focus-within {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
}

.project-thumb {
    display: block;
    height: 170px;
    text-decoration: none;
}

.project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-body {
    display: flex;
    flex-direction: column;
    gap: 0.55em;
    padding: 0.95em 1.05em 1.05em;
    flex: 1;
}

.project-title {
    margin: 0;
    font-size: 1em;
    line-height: 1.35;
}

.project-title a {
    color: var(--global-text-color);
    text-decoration: none;
}

.project-title a:hover,
.project-title a:focus {
    color: var(--global-text-color);
    text-decoration: underline;
}

.project-desc {
    margin: 0;
    font-size: 0.86em;
    line-height: 1.55;
    color: var(--global-text-color-light);
    flex: 1;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35em;
}

.project-tags span {
    font-size: 0.72em;
    padding: 0.18em 0.65em;
    border: 1px solid var(--global-dark-border-color);
    border-radius: 999px;
    color: var(--global-text-color-light);
    white-space: nowrap;
}

.project-links {
    display: flex;
    gap: 1em;
}

.project-links a {
    font-size: 0.82em;
    color: var(--global-text-color);
    text-decoration: none;
}

.project-links a:hover,
.project-links a:focus {
    color: var(--global-text-color);
    text-decoration: underline;
}

.project-links i {
    margin-right: 0.3em;
}

/* ===== DARK MODE =====
   Manual override via html[data-theme]; OS preference applies when no theme is stored. */
html[data-theme="light"] {
    color-scheme: light;
}

html[data-theme="dark"] {
    color-scheme: dark;
    --global-bg-color: #1a1a1a;
    --global-footer-bg-color: #242424;
    --global-dark-border-color: #3a3a3a;
    --global-text-color: #d4d4d4;
    --global-text-color-light: #8e959f;
    --global-link-underline: #4A4E55;
}

html[data-theme="dark"] .mobile-header {
    background: #1a1a1a;
}

html[data-theme="dark"] .head-link:hover,
html[data-theme="dark"] .head-link:focus,
html[data-theme="dark"] .theme-toggle:hover,
html[data-theme="dark"] .theme-toggle:focus {
    background-color: #2a2a2a;
    color: #eee;
}

html[data-theme="dark"] .back-to-top {
    background: #d4d4d4;
    color: #1a1a1a;
}

html[data-theme="dark"] .back-to-top:hover {
    background: #b0b0b0;
}

html[data-theme="dark"] .conference-banner {
    border-color: rgba(204, 0, 51, 0.35);
    background: rgba(204, 0, 51, 0.12);
}

@media (prefers-color-scheme: dark) {
    html:not([data-theme="light"]) {
        --global-bg-color: #1a1a1a;
        --global-footer-bg-color: #242424;
        --global-dark-border-color: #3a3a3a;
        --global-text-color: #d4d4d4;
        --global-text-color-light: #8e959f;
        --global-link-underline: #4A4E55;
    }

    html:not([data-theme="light"]) .mobile-header {
        background: #1a1a1a;
    }

    html:not([data-theme="light"]) .head-link:hover,
    html:not([data-theme="light"]) .head-link:focus,
    html:not([data-theme="light"]) .theme-toggle:hover,
    html:not([data-theme="light"]) .theme-toggle:focus {
        background-color: #2a2a2a;
        color: #eee;
    }

    html:not([data-theme="light"]) .back-to-top {
        background: #d4d4d4;
        color: #1a1a1a;
    }

    html:not([data-theme="light"]) .back-to-top:hover {
        background: #b0b0b0;
    }

    html:not([data-theme="light"]) .conference-banner {
        border-color: rgba(204, 0, 51, 0.35);
        background: rgba(204, 0, 51, 0.12);
    }
}

.pub-list {
  display: flex;
  flex-direction: column;
  gap: 1em;
  margin: 0;
  padding: 0;
}

.pub-item {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 1em;
  font-size: 0.97em;
  line-height: 1.6;
}

.pub-year {
  color: var(--global-text-color-light);
  font-variant-numeric: tabular-nums;
}

.pub-item strong { font-weight: 600; }

.pub-intro {
  color: var(--global-text-color-light);
  font-size: 0.94em;
  margin-top: -0.5em;
}

@media (max-width: 480px) {
  .pub-item { grid-template-columns: 52px 1fr; gap: 0.8em; }
}
