/* ============================================================
   page-styles.css
   New component styles for the Rodney S. Ruoff portfolio.
   Builds on styles.css + shared-styles.css (design tokens live
   in their :root / .light-theme blocks). This file only adds the
   components the multi-page site needs and never redefines tokens.
   ============================================================ */

/* ---------- Layout helpers ---------- */
.container-narrow {
    max-width: 860px;
    margin: 0 auto;
}

.section-sep {
    height: 1px;
    max-width: 1200px;
    margin: 0 auto;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12), transparent);
}

.light-theme .section-sep {
    background: linear-gradient(90deg, transparent, rgba(0, 0, 0, 0.1), transparent);
}

.page-lead {
    max-width: 720px;
    margin: 0 auto 2rem;
    text-align: center;
    color: var(--text-light);
    opacity: 0.85;
}

/* ---------- Hero additions ---------- */
.hero-photo-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 160px;
    height: 160px;
    border-radius: 50%;
    border: 4px solid rgba(52, 152, 219, 0.8);
    box-shadow: 0 0 25px rgba(52, 152, 219, 0.4);
    overflow: hidden;
    background: #132a46;
    transition: transform 0.5s, box-shadow 0.5s;
}

.hero-photo-wrap:hover {
    transform: scale(1.04);
    box-shadow: 0 0 35px rgba(52, 152, 219, 0.6);
}

.hero-photo-wrap svg,
.hero-photo-wrap img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.light-theme .hero-photo-wrap {
    border-color: rgba(37, 99, 235, 0.6);
    box-shadow: 0 0 25px rgba(37, 99, 235, 0.2);
    background: #eef3fb;
}

.hero-badge {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-light);
    background: rgba(52, 152, 219, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.35);
    border-radius: 24px;
}

.light-theme .hero-badge {
    background: rgba(37, 99, 235, 0.1);
    border-color: rgba(37, 99, 235, 0.3);
    color: var(--primary-color);
}

/* ---------- Research tags ---------- */
.research-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
    max-width: 640px;
    margin: 0.5rem auto 0;
}

.research-tags span {
    font-size: 0.85rem;
    padding: 0.35rem 0.85rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-light);
}

.light-theme .research-tags span {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.08);
    color: #334155;
}

/* ---------- Section header ---------- */
.section-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.section-num {
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    color: var(--primary-color);
    font-variant-numeric: tabular-nums;
}

.section-title-wrap {
    display: flex;
    flex-direction: column;
}

.section-title-wrap h2 {
    margin: 0;
    text-align: left;
    display: inline-block;
}

.section-title-wrap h2::after {
    display: none;
}

.section-divider-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(52, 152, 219, 0.5), transparent);
}

.light-theme .section-divider-line {
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.4), transparent);
}

/* ---------- Stat cards ---------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1rem;
}

.stat-card {
    text-align: center;
    padding: 1.75rem 1rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.stat-num {
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1;
    color: var(--primary-color);
    font-variant-numeric: tabular-nums;
}

.stat-label {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    opacity: 0.8;
}

.light-theme .stat-card {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

.stat-caption {
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.7;
    margin-top: 0.5rem;
}

/* ---------- Projects / interest grid ---------- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.projects-grid .project-card {
    margin-bottom: 0;
    height: 100%;
}

.project-card-with-logo {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.project-logo {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(52, 152, 219, 0.15);
    color: var(--primary-color);
    font-size: 1.4rem;
}

.light-theme .project-logo {
    background: rgba(37, 99, 235, 0.1);
}

.project-content {
    flex: 1;
}

.project-description {
    font-size: 0.95rem;
    opacity: 0.85;
    margin-bottom: 0;
}

.active-badge {
    display: inline-block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.15rem 0.55rem;
    border-radius: 12px;
    background: rgba(46, 204, 113, 0.18);
    color: var(--secondary-color);
    border: 1px solid rgba(46, 204, 113, 0.35);
    margin-left: 0.5rem;
    vertical-align: middle;
}

/* ---------- Quick links ---------- */
.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
}

.quick-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    padding: 1.5rem 1rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    text-align: center;
    transition: transform 0.3s, background 0.3s, box-shadow 0.3s;
}

.quick-link i {
    font-size: 1.6rem;
    color: var(--primary-color);
}

.quick-link:hover {
    transform: translateY(-4px);
    background: rgba(52, 152, 219, 0.12);
    color: var(--text-light);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.light-theme .quick-link {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
    color: #1e293b;
}

.light-theme .quick-link:hover {
    background: rgba(37, 99, 235, 0.08);
    color: #1e293b;
}

/* ---------- Publications list ---------- */
.papers-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.paper-card {
    display: flex;
    gap: 1.25rem;
    padding: 1.5rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-left: 3px solid var(--primary-color);
    transition: transform 0.3s, box-shadow 0.3s;
}

.paper-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.light-theme .paper-card {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
    border-left: 3px solid var(--primary-color);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

.paper-num {
    flex-shrink: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
    font-variant-numeric: tabular-nums;
    min-width: 2ch;
}

.paper-body {
    flex: 1;
}

.paper-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 0.4rem;
    line-height: 1.4;
}

.paper-authors {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 0.3rem;
}

.paper-venue {
    font-size: 0.9rem;
    color: var(--accent-color);
    margin-bottom: 0.6rem;
}

.paper-venue em {
    font-style: italic;
}

.paper-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.doi-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    padding: 0.3rem 0.7rem;
    border-radius: 6px;
    background: rgba(52, 152, 219, 0.12);
}

.doi-link:hover {
    background: rgba(52, 152, 219, 0.25);
}

/* Replaces inline style="…" attributes on publications-all.html, so the
   Content-Security-Policy can forbid inline styles outright. */
.stat-caption--left {
    text-align: left;
    margin-bottom: 1.5rem;
}

.doi-link--pending {
    opacity: 0.7;
}

/* Link variants on a paper card: publisher article page, and a local
   author copy served from assets/papers/ */
.doi-link--publisher {
    background: rgba(255, 255, 255, 0.09);
}

.doi-link--publisher:hover {
    background: rgba(255, 255, 255, 0.18);
}

.doi-link--pdf {
    background: rgba(46, 204, 113, 0.14);
    color: var(--secondary-color);
}

.doi-link--pdf:hover {
    background: rgba(46, 204, 113, 0.26);
}

.light-theme .paper-title {
    color: #1e293b;
}

.light-theme .doi-link {
    background: rgba(37, 99, 235, 0.1);
}

.light-theme .doi-link--publisher {
    background: rgba(0, 0, 0, 0.06);
}

.light-theme .doi-link--pdf {
    background: rgba(39, 174, 96, 0.12);
    color: #1e8449;
}

/* Year grouping (publications-all) */
.year-group {
    margin-bottom: 2.5rem;
}

.year-heading {
    font-size: 1.5rem;
    color: var(--primary-color);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    padding-bottom: 0.5rem;
    margin-bottom: 1.25rem;
}

.light-theme .year-heading {
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

/* ---------- Buttons ---------- */
.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin: 1.5rem 0 2.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.7rem 1.4rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: transform 0.3s, background 0.3s, box-shadow 0.3s;
    border: 1px solid transparent;
}

.btn-primary {
    background: var(--primary-color);
    color: #fff;
}

.btn-primary:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(52, 152, 219, 0.4);
}

.btn-outline {
    background: transparent;
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.btn-outline:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.light-theme .btn-outline {
    color: #334155;
    border-color: rgba(0, 0, 0, 0.2);
}

/* ---------- TODO banner / notes ---------- */
.todo-banner,
.note-box {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    font-size: 0.92rem;
    line-height: 1.5;
}

.todo-banner {
    background: rgba(241, 196, 15, 0.1);
    border: 1px solid rgba(241, 196, 15, 0.35);
    color: var(--text-light);
}

.todo-banner i {
    color: var(--accent-color);
    font-size: 1.1rem;
    margin-top: 0.15rem;
}

.note-box {
    background: rgba(52, 152, 219, 0.08);
    border: 1px solid rgba(52, 152, 219, 0.25);
    color: var(--text-light);
}

.note-box i {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-top: 0.15rem;
}

.light-theme .todo-banner,
.light-theme .note-box {
    color: #334155;
}

.light-theme .todo-banner {
    background: rgba(217, 119, 6, 0.08);
    border-color: rgba(217, 119, 6, 0.3);
}

/* ---------- Timeline ---------- */
.timeline {
    position: relative;
    margin: 1rem 0 0 0;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: linear-gradient(180deg, var(--primary-color), rgba(52, 152, 219, 0.15));
}

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 6px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-color);
    border: 3px solid #132a46;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.4);
}

.light-theme .timeline-dot {
    border-color: #f0f4ff;
}

.timeline-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 1.1rem 1.35rem;
    transition: transform 0.3s, box-shadow 0.3s;
}

.timeline-card:hover {
    transform: translateX(4px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
}

.timeline-card .date-tag {
    margin-left: 0;
    margin-bottom: 0.4rem;
}

.timeline-card h3 {
    font-size: 1.05rem;
    color: var(--text-light);
    margin-bottom: 0.2rem;
}

.timeline-card p {
    font-size: 0.92rem;
    opacity: 0.8;
    margin-bottom: 0;
}

.light-theme .timeline-card {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
}

.light-theme .timeline-card h3 {
    color: #1e293b;
}

/* ---------- Awards ---------- */
.awards-institution {
    margin-bottom: 2.5rem;
}

.institution-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.institution-header i {
    color: var(--primary-color);
    font-size: 1.25rem;
}

.institution-header h3 {
    margin: 0;
    font-size: 1.3rem;
    color: var(--text-light);
}

.light-theme .institution-header {
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

.light-theme .institution-header h3 {
    color: #1e293b;
}

.awards-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.25rem;
}

.award-card-personal {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.25rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.award-card-personal:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.award-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(241, 196, 15, 0.15);
    color: var(--accent-color);
    font-size: 1.2rem;
}

.award-details h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--text-light);
}

.award-details p {
    font-size: 0.88rem;
    opacity: 0.8;
    margin-bottom: 0;
}

.light-theme .award-card-personal {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
}

.light-theme .award-details h4 {
    color: #1e293b;
}

/* ---------- People ---------- */
.role-group {
    margin-bottom: 2.5rem;
}

.role-group h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.people-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.person-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem 1.15rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.person-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

.person-avatar {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(52, 152, 219, 0.18);
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

.person-name {
    font-size: 0.95rem;
    color: var(--text-light);
}

.light-theme .person-card {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
}

.light-theme .person-name {
    color: #1e293b;
}

/* ---------- Contact ---------- */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.contact-card {
    padding: 1.75rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.contact-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.7rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.95rem;
}

.contact-list li:last-child {
    border-bottom: none;
}

.contact-list i {
    color: var(--primary-color);
    width: 20px;
    text-align: center;
    margin-top: 0.2rem;
}

.contact-logos {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.contact-logos img {
    height: 56px;
    width: auto;
    border-radius: 8px;
    background: #fff;
    padding: 4px;
}

.light-theme .contact-card {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.06);
}

.light-theme .contact-list li {
    border-bottom-color: rgba(0, 0, 0, 0.08);
}

/* ---------- Biography ---------- */
.bio-text p {
    font-size: 1.02rem;
    line-height: 1.75;
    opacity: 0.9;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .section-header {
        flex-wrap: wrap;
    }

    .stat-num {
        font-size: 1.9rem;
    }

    .paper-card {
        flex-direction: column;
        gap: 0.5rem;
    }

    .contact-logos img {
        height: 44px;
    }
}
