:root {
    --bg: #ffffff;
    --text: #111;
    --secondary: #666;
    --accent: #eeeeee;
    --border: #d1d1d1;
}

[data-theme="dark"] {
    --bg: #0a0a0a;
    --text: #ededed;
    --secondary: #a1a1a1;
    --accent: #222222;
    --border: #333;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text);
    transition: background 0.3s ease;
}

.main-layout { display: flex; min-height: 100vh; }

/* SIDEBAR */
.sidebar {
    width: 280px;
    padding: 60px 40px;
    position: fixed;
    height: 100vh;
    border-right: 1px solid var(--accent);
}

.headshot {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 24px;
    background: var(--accent);
}
.sidebar-title {
    font-size: 0.95rem;
    font-weight: 400;
    color: #000; /* Force black color */
    margin-top: -8px; /* Pull closer to name */
    margin-bottom: 12px;
    letter-spacing: 0.02em;
}

/* Ensure Bio is running format */
.bio {
    font-size: 0.85rem;
    color: var(--secondary);
    line-height: 1.5;
    margin-top: 10px;
}
.sidebar h1 { font-size: 1.4rem; margin: 0 0 12px 0; font-weight: 600; }
.bio { font-size: 0.85rem; color: var(--secondary); line-height: 1.6; margin-bottom: 24px; }
.sidebar-links a { display: block; color: var(--text); margin-bottom: 8px; font-size: 0.9rem; text-decoration: none; }
.sidebar-links a:hover { text-decoration: underline; }

#theme-toggle { background: none; border: none; cursor: pointer; font-size: 1.2rem; margin-top: 20px; }

/* CONTENT */
.content { margin-left: 360px; padding: 60px 60px; max-width: 800px; }
section { margin-bottom: 60px; }
h2 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--secondary); margin-bottom: 30px; border-bottom: 1px solid var(--accent); padding-bottom: 8px; }
h3 { font-size: 1.1rem; margin-bottom: 20px; font-weight: 600; }
/* Update the summary text style */
.lead-summary {
    font-size: 0.9rem;       /* Makes the text smaller */
    color: var(--secondary); /* Uses your existing lighter gray color */
    line-height: 1.6;        /* Maintains readability */
}
/* PROJECT GRID */
.project-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 40px;
}

.project-card {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: transparent;
    transition: transform 0.2s ease;
}

.project-card:hover { transform: translateY(-3px); }

.thumbnail-box { height: 140px; background: var(--accent); border-bottom: 1px solid var(--border); overflow: hidden; }
.thumbnail-box img { width: 100%; height: 100%; object-fit: cover; }
.card-content { padding: 16px; }
.card-content h4 { margin: 0 0 8px 0; font-size: 0.95rem; font-weight: 600; }
.card-content p { margin: 0; font-size: 0.8rem; color: var(--secondary); line-height: 1.5; }

/* RESEARCH LIST */
.writing-list { border-top: 1px solid var(--accent); }
.writing-item {
    display: flex; 
    justify-content: flex-start; /* CHANGE THIS from space-between */
    align-items: center;
    padding: 24px 0; 
    border-bottom: 1px solid var(--accent); 
    text-decoration: none;
    transition: padding-left 0.2s ease;
}
.writing-item:hover { padding-left: 8px; }
.writing-info { display: flex; flex-direction: column; gap: 4px; }
.writing-title { font-size: 1rem; color: var(--text); font-weight: 500; line-height: 1.4; }
.writing-meta { font-size: 0.75rem; color: var(--secondary); text-transform: uppercase; letter-spacing: 0.05em; }
.writing-arrow { color: var(--secondary); transition: transform 0.2s ease; }
.writing-item:hover .writing-arrow { transform: translateX(5px); color: var(--text); }

.no-link:hover { padding-left: 0; cursor: default; }

/* RESPONSIVE */
@media (max-width: 900px) {
    .main-layout { flex-direction: column; }
    .sidebar { position: relative; width: auto; height: auto; border-right: none; border-bottom: 1px solid var(--accent); padding: 40px 20px; }
    .content { margin-left: 0; padding: 40px 20px; }
    .project-grid { grid-template-columns: 1fr; }
}
/* Enhanced Project Card Interaction */
.project-card {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: transparent;
    cursor: pointer;
    /* Smooth transition for all properties */
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                border-color 0.3s ease, 
                box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-6px); /* Lifts the card up */
    border-color: var(--text);   /* Darkens the border to match your text */
    box-shadow: 0 10px 20px rgba(0,0,0,0.05); /* Adds a subtle depth shadow */
}

/* Dark mode shadow adjustment */
[data-theme="dark"] .project-card:hover {
    box-shadow: 0 10px 20px rgba(0,0,0,0.4);
}

/* Zoom effect on the image when hovering the card */
.thumbnail-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .thumbnail-box img {
    transform: scale(1.05); /* Slight zoom on the image */
}
.sidebar-links i {
    width: 20px;       /* Fixed width so text aligns vertically */
    margin-right: 10px;
    font-size: 1.1rem;
    color: var(--secondary);
}

.sidebar-links a:hover i {
    color: var(--text); /* Icon lights up on hover */
}

/* Lifecycle */

/* Reduce space above the lifecycle graphic */
#lifecycle-section {
    margin-top: -20px;   /* Pulls the graphic closer to the text above */
    margin-bottom: 20px; /* Keeps the gap small below it as well */
}

/* New Header Styling */
.lifecycle-header {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--secondary);
    margin-bottom: 20px;
    border-bottom: 1px solid var(--accent);
    padding-bottom: 8px;
}

/* Process Arrow Styling */
.process-arrow {
    font-size: 32px;
    fill: var(--text);
    text-anchor: middle;
    font-weight: 900;
    opacity: 0.8;
}

/* Increase Step Title Size */
.big-text {
    font-size: 16px !important; /* Larger text inside circles */
    font-weight: 800 !important;
}

/* Add Strong Outlines to Circles */
.circle-bg {
    stroke-width: 4px !important; /* Thicker outline */
    stroke: var(--text);          /* Outline color matches theme text */
    transition: all 0.3s ease;
}

/* Specific Outlines to stay visible even on colored backgrounds */
.discovery { stroke: #9370DB; } /* Slightly darker purple for outline */
.phase3-4 { stroke: #A0522D; }  /* Slightly darker orange for outline */
.regulatory { stroke: #B8860B; } /* Slightly darker gold for outline */
.phase-locked { stroke: #999999; }

.lifecycle-container {
    position: relative;
    padding: 0;      /* Reduced from 10px to 0 to remove extra vertical space */
    max-width: 900px;
    margin: 0 auto;
}

.lifecycle-svg { overflow: visible; width: 100%; }

/* Step Circles */
.circle-bg {
    stroke-width: 2;
    transition: all 0.3s ease;
}

/* Solid Fills based on your branding */
.discovery { 
    fill: #B19CD9; 
    stroke: #B19CD9; 
}
.phase3-4 { 
    fill: #d48a5b; 
    stroke: #d48a5b; 
}
.regulatory { 
    fill: #e5b34e; 
    stroke: #e5b34e; 
}

/* Grayed out Phase 1 & 2 (Solid) */
.phase-locked {
    fill: #dddddd;
    stroke: #cccccc;
}

/* Update Text for Solid Backgrounds */
.step-title {
    font-size: 14px;
    font-weight: 700;
    text-anchor: middle;
    fill: #ffffff; /* White text for better contrast on solid colors */
}

.gray-text { 
    fill: #777777 !important; /* Darker gray for readability on light gray circle */
}

.step-icon {
    font-size: 24px;
    text-anchor: middle;
}

/* Adjust Hover Glow to Match Solid Colors */
.step-node:not(.locked):hover .circle-bg {
    filter: drop-shadow(0 0 15px rgba(0, 0, 0, 0.2));
    transform: translateY(-5px);
    brightness: 1.1;
}
/* Interactive Glow/Highlight */
.step-node { cursor: pointer; }
.step-node:hover .circle-bg {
    filter: drop-shadow(0 0 15px currentColor);
    transform: translateY(-5px);
    stroke-width: 8;
}

/* Specific Hover Glows */
.step-node:hover .discovery { filter: drop-shadow(0 0 15px #B19CD9); }
.step-node:hover .phase1-2 { filter: drop-shadow(0 0 15px #6b8e6b); }
.step-node:hover .phase3-4 { filter: drop-shadow(0 0 15px #d48a5b); }
.step-node:hover .regulatory { filter: drop-shadow(0 0 15px #e5b34e); }

.step-title {
    font-size: 14px;
    font-weight: 700;
    text-anchor: middle;
    fill: #333;
}

.step-icon {
    font-size: 24px;
    text-anchor: middle;
}

/* Connector Arrows */
.connector-arrow {
    stroke: #ccc;
    stroke-width: 3;
    fill: none;
    marker-end: url(#arrowhead);
}

/* Tooltip Styling */
#experience-tooltip {
    position: absolute;
    background: rgba(40, 40, 40, 0.95);
    color: #fff;
    padding: 15px;
    border-radius: 8px;
    font-size: 13px;
    width: 250px;
    line-height: 1.6; /* Increased for better bullet spacing */
    text-align: left;  /* Ensures list items align properly */
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.tooltip-hidden { opacity: 0; visibility: hidden; }


/* Grayed out Phase 1 & 2 styling */
.phase-locked {
    stroke: #ccc;
    fill: #f9f9f9;
}

.gray-text { fill: #aaa !important; }
.grayscale { filter: grayscale(100%); opacity: 0.5; }

/* Disable Hover and Pointer Events for Locked Nodes */
.step-node.locked {
    cursor: default;
    pointer-events: none; /* This prevents the tooltip and glow from triggering */
}

/* Ensure active steps maintain their styling */
.discovery { stroke: #B19CD9; }
.phase3-4 { stroke: #d48a5b; }
.regulatory { stroke: #e5b34e; }

.step-node:not(.locked):hover .circle-bg {
    filter: drop-shadow(0 0 15px currentColor);
    transform: translateY(-5px);
    stroke-width: 8;

/* Header Layout */
/* Container to handle the horizontal layout */
.experience-header-row h3 {
    display: flex;
    justify-content: space-between; /* Pushes the company left and date right */
    align-items: baseline;
    width: 100%;
    margin: 0 0 20px 0;
    font-size: 1.1rem;
    font-weight: 600; /* Only the company name stays bold */
}

/* Specific style for the date text */
.experience-date-running {
    font-size: 0.8rem;
    color: var(--secondary); /* Makes the color lighter/gray  */
    font-weight: 400 !important; /* Removes the bold effect */
    text-transform: none;      /* Ensures it is not all caps */
    letter-spacing: normal;
}
/* Container for the thumbnail */
.writing-thumb {
    width: 80px;            /* Fixed width for consistency */
    height: 60px;           /* Landscape aspect ratio */
    flex-shrink: 0;         /* Prevents image from squishing */
    border-radius: 4px;
    overflow: hidden;
    background: var(--accent); /* Placeholder color while loading */
    border: 1px solid var(--border);
}

.writing-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;      /* Crops image to fill the 80x60 box */
    transition: transform 0.3s ease;
}

/* Hover effect for the whole row */
.writing-item:hover .writing-thumb img {
    transform: scale(1.1);  /* Subtle zoom on the image */
}

.writing-info {
    padding-left: 0 !important;   /* Removes any accidental padding */
    display: flex;
    flex-direction: column;
}