/* peisenha.github.io — shared styles
   Matches the visual identity of tools-impact-engine-website */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1a365d;
    --accent-color: #2c5282;
    --text-color: #2d3748;
    --text-light: #4a5568;
    --background: #f7fafc;
    --card-background: #ffffff;
    --border-color: #e2e8f0;
    --hover-color: #edf2f7;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.7;
    color: var(--text-color);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-attachment: fixed;
    padding: 40px 20px;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    background-color: var(--card-background);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: fadeIn 0.6s ease-out;
}

/* Navigation */

nav {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    padding: 20px 60px;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
    margin: 0;
    padding: 0;
}

nav li {
    margin: 0;
    padding: 0;
}

nav li::before {
    content: none;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95em;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
    letter-spacing: 0.3px;
    border-bottom: none;
}

nav a:hover {
    background-color: rgba(255,255,255,0.15);
    transform: translateY(-2px);
    color: white;
    border-bottom: none;
}

nav a[aria-current="page"] {
    background-color: rgba(255,255,255,0.18);
    cursor: default;
    pointer-events: none;
}

/* Content area */

.content {
    padding: 60px 80px 80px;
}

/* Header */

header {
    margin-bottom: 60px;
    padding-bottom: 40px;
    border-bottom: 3px solid var(--border-color);
    position: relative;
}

header::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 120px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

/* Profile header (index.html) */

.header-profile {
    display: flex;
    align-items: center;
    gap: 50px;
}

.header-text {
    flex: 1;
}

.headshot {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 8px 24px rgba(44,82,130,0.25);
    border: 4px solid var(--border-color);
}

/* Social links */

.social-links {
    display: flex;
    gap: 20px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.social-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background-color: var(--hover-color);
    border-radius: 8px;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95em;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.social-link:hover {
    background-color: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 82, 130, 0.3);
}

.social-link svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Typography */

h1 {
    font-family: 'Crimson Pro', Georgia, serif;
    font-size: 3.5em;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

h2 {
    font-family: 'Crimson Pro', Georgia, serif;
    font-size: 2em;
    font-weight: 600;
    margin-top: 60px;
    margin-bottom: 30px;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 15px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

h3 {
    font-size: 1.4em;
    font-weight: 600;
    margin-top: 35px;
    margin-bottom: 12px;
    color: var(--accent-color);
}

h4 {
    font-size: 1.15em;
    font-weight: 600;
    margin-top: 25px;
    margin-bottom: 8px;
    color: var(--text-color);
}

p {
    margin-bottom: 18px;
    color: var(--text-light);
    line-height: 1.8;
}

strong {
    font-weight: 600;
    color: var(--text-color);
}

a {
    color: var(--accent-color);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
    font-weight: 500;
}

a:hover {
    color: var(--primary-color);
    border-bottom-color: var(--accent-color);
}

/* Tagline */

.tagline {
    font-size: 1.15em;
    color: var(--text-light);
    line-height: 1.8;
    font-weight: 300;
}

/* Epigraph (quote under page title) */

.epigraph {
    font-family: 'Crimson Pro', Georgia, serif;
    font-size: 1.3em;
    font-style: italic;
    color: var(--text-light);
    margin-bottom: 5px;
}

.epigraph-author {
    font-size: 0.95em;
    color: var(--text-light);
}

.subtitle {
    font-size: 1.1em;
    color: var(--text-light);
    line-height: 1.8;
}

/* Lists */

.content ul {
    margin-left: 0;
    margin-bottom: 25px;
    list-style: none;
}

.content li {
    margin-bottom: 20px;
    padding-left: 30px;
    position: relative;
    color: var(--text-light);
    line-height: 1.8;
}

.content li::before {
    content: '\25B8';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
    font-size: 1.2em;
}

/* Position cards (experience, education) */

.position {
    margin-bottom: 40px;
    padding: 25px;
    background-color: var(--hover-color);
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
}

.position:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateX(4px);
}

.position-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.position-title {
    font-style: italic;
    color: var(--text-color);
    font-weight: 500;
}

.position-date {
    color: var(--text-light);
    font-size: 0.9em;
    font-weight: 500;
}

/* Featured cards (showcase) */

.featured-cards {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 20px;
}

.featured-card {
    padding: 25px 30px;
    background-color: var(--hover-color);
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
}

.featured-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateX(4px);
}

.featured-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 10px;
}

.featured-card .card-badge {
    display: inline-block;
    font-size: 0.78em;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: white;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    padding: 4px 12px;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}

.featured-card-header h3 {
    margin: 0;
}

.featured-card p {
    margin-bottom: 8px;
}

.featured-card .card-link {
    display: inline-block;
    font-weight: 600;
}

/* Memo cards */

.memo-card {
    display: block;
    padding: 25px 30px;
    background-color: var(--hover-color);
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
    text-decoration: none;
    margin-bottom: 20px;
}

.memo-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateX(4px);
    border-bottom: none;
}

.memo-card h3 {
    font-size: 1.3em;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--accent-color);
    margin-top: 0;
}

.memo-card p {
    margin: 0;
    color: var(--text-light);
}

/* Principles page */

.principle-section {
    margin-bottom: 40px;
}

.principle-content {
    font-size: 1.1em;
    color: var(--text-light);
    line-height: 1.9;
}

.principle-content strong {
    color: var(--accent-color);
    font-weight: 600;
}

.principle-image {
    display: block;
    max-width: 320px;
    margin: 30px auto;
    border-radius: 8px;
}

.principle-section-flex {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.principle-section-flex .principle-image {
    flex-shrink: 0;
    max-width: 240px;
    margin: 0;
}

.principle-section-flex .principle-content {
    flex: 1;
}

/* Back link */

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    padding: 12px 24px;
    background-color: var(--hover-color);
    border-radius: 8px;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.back-link:hover {
    background-color: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 82, 130, 0.3);
}

/* Sections */

section {
    scroll-margin-top: 80px;
}

/* Responsive */

@media (max-width: 768px) {
    body {
        padding: 20px 10px;
    }

    .container {
        border-radius: 8px;
    }

    nav {
        padding: 15px 20px;
    }

    nav ul {
        gap: 15px;
    }

    nav a {
        font-size: 0.85em;
        padding: 6px 12px;
    }

    .content {
        padding: 40px 30px;
    }

    h1 {
        font-size: 2.5em;
    }

    h2 {
        font-size: 1.6em;
        margin-top: 45px;
    }

    .position-header {
        flex-direction: column;
        gap: 5px;
    }

    .header-profile {
        flex-direction: column-reverse;
        text-align: center;
        gap: 30px;
    }

    .headshot {
        width: 140px;
        height: 140px;
    }

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

    .principle-section-flex {
        flex-direction: column;
    }

    .principle-section-flex .principle-image {
        max-width: 200px;
        margin: 0 auto 20px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .content {
        padding: 30px 20px;
    }

    h1 {
        font-size: 2em;
    }

    nav ul {
        gap: 10px;
    }

    .content li {
        padding-left: 25px;
    }

    .social-links {
        flex-direction: column;
        gap: 10px;
    }

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

/* Animation */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}