/* ==========================================
   CSS Reset & Base Styles
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    color: #0a2f46;
    background: linear-gradient(180deg, #cccccc 5.053%, #f3f3f3 5.452%);
    min-height: 100vh;
    line-height: 1.14;
    overflow-x: hidden;
}

button {
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    border: none;
    background: none;
}

/* ==========================================
   Masthead (Header with Title) - WITH TEXT
   ========================================== */
.masthead {
    background: linear-gradient(90deg, #7B5BE9 0%, #F97E5A 100%);
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.masthead-title {
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -1.72px;
    line-height: 1.14;
    color: #ffffff;
    text-align: center;
    margin: 0;
    max-width: 1024px;
}

/* ==========================================
   Navigation Section - TAB STYLE
   ========================================== */
.nav-section {
    background-color: #ffffff;
    padding: 24px 0 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 80px;
    z-index: 999;
}

.nav-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 140px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.nav-wrapper {
    display: flex;
    gap: 24px;
    align-items: flex-end;
    justify-content: center;
    flex: 1;
    max-width: 1024px;
}

.nav-link {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 12px;
    flex: 1;
    border-radius: 12px;
    background: transparent;
    border: none;
    transition: all 0.3s ease;
    color: #0a2f46;
    cursor: pointer;
}

.nav-link:hover {
    background-color: rgba(88, 88, 233, 0.05);
    transform: translateY(-2px);
}

.nav-link:active {
    transform: translateY(0);
}

.nav-link.active {
    gap: 12px;
    padding: 16px;
    border-radius: 12px 12px 0 0;
    background: linear-gradient(180deg, rgba(223, 223, 223, 0) 38.532%, rgba(223, 223, 223, 1) 100%), 
                linear-gradient(180deg, #f6f6f6 0%, #f9f9f9 100%);
    border: 1px solid #dddddd;
    border-bottom: none;
}

.nav-link.active:hover {
    transform: none;
    background: linear-gradient(180deg, rgba(223, 223, 223, 0) 38.532%, rgba(223, 223, 223, 1) 100%), 
                linear-gradient(180deg, #f6f6f6 0%, #f9f9f9 100%);
}

.nav-link span {
    font-size: 16px;
    font-weight: 600;
    letter-spacing: -0.64px;
    text-align: center;
    line-height: 1.2;
}

/* ==========================================
   Main Content
   ========================================== */
.main-content {
    padding: 36px;
}

.content-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 149px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

.note {
    font-size: 1rem;
    letter-spacing: -.03em;
}

/* ==========================================
   Controls Bar
   ========================================== */
.controls-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 903px;
    padding: 0;
}

.current-filter {
    font-size: 23px;
    font-weight: 700;
    letter-spacing: -0.92px;
    color: #0a2f46;
}

.expand-all-link {
    font-size: 15px;
    font-weight: 400;
    letter-spacing: -0.3px;
    color: #0a2f46;
    background-color: #fdfdfd;
    border: 1px solid #d8d8d8;
    border-radius: 5px;
    padding: 9px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    line-height: 1.14;
    transition: all 0.3s ease;
}

.expand-all-link:hover {
    background-color: #f5f5f5;
    border-color: #c0c0c0;
}

.expand-all-link i {
    font-size: 15px;
}

/* ==========================================
   Timeline
   ========================================== */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 1024px;
}

/* ==========================================
   Phase Item - NO BADGE
   ========================================== */
.phase-item {
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: stretch;
    width: 904px;
    margin: 0 auto;
}

/* ==========================================
   Purple Date Badge - FULL WIDTH
   ========================================== */
.phase-date-badge {
    background-color: #5858e9;
    border-radius: 9px;
    padding: 10px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.15px;
    line-height: 1.14;
    color: #ffffff;
    text-transform: uppercase;
    width: 100%;
}

/* ==========================================
   Phase Content
   ========================================== */
.phase-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

/* ==========================================
   Phase Card - WITH DROP SHADOW & MORE PADDING
   ========================================== */
.phase-card {
    background-color: #ffffff;
    border-radius: 15px;
    padding: 32px 24px;
    box-shadow: 0px 14px 24px 0px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.phase-card:hover {
    box-shadow: 0px 20px 32px 0px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.phase-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
}

.phase-title {
    font-size: 25px;
    font-weight: 700;
    letter-spacing: -1.12px;
    color: #0a2f46;
    margin: 0;
}

.phase-chevron {
    font-size: 18px;
    letter-spacing: -0.72px;
    color: #000000;
    transition: transform 0.3s ease;
    padding: 8px;
}

.phase-item.expanded .phase-chevron {
    transform: rotate(180deg);
}

/* ==========================================
   Phase Description (Always Visible)
   ========================================== */
.phase-description-text {
    font-size: 15px;
    font-weight: 400;
    letter-spacing: -0.54px;
    color: #000000;
    line-height: 1.35;
    margin: 0;
}

/* ==========================================
   Phase Dates/Milestones (Expandable)
   ========================================== */
.phase-dates {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
    will-change: max-height, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.phase-dates-inner {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 24px;
}

/* ==========================================
   Milestone Item - WITH CONNECTORS
   ========================================== */
.milestone-item {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    border-radius: 10px;
}

.milestone-item:not(:last-child) {
    margin-bottom: 0;
}

.milestone-date-column {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100px;
}

.milestone-date-badge {
    background-color: #5858e9;
    border-radius: 1000px;
    padding: 10px;
    height: 34px;
    width: 110px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.milestone-date-text {
    font-size: 16px;
    font-weight: 500;
    letter-spacing: -0.72px;
    color: #ffffff;
}

/* Connector line between dates */
.milestone-connector {
    width: 1px;
    height: 23px;
    background: linear-gradient(180deg, #d0d0d0 0%, transparent 100%);
    margin: 0 auto;
}

.milestone-item:last-child .milestone-connector {
    display: none;
}

.milestone-content-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;

}

.milestone-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    gap: 12px;
    height: 34px;
 
}

.milestone-title {
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.88px;
    color: #0a2f46;
    flex: 1;
    line-height: 1.14;
}

.milestone-chevron {
    font-size: 10px;
    color: #ffffff;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1000px;
    transition: all 0.3s ease;
    background-color: transparent;
    border: 1px solid #0a2f46;
}

.milestone-chevron i {
    color: #0a2f46;
    transition: color 0.3s ease;
}

.milestone-item.expanded .milestone-chevron {
    transform: rotate(90deg);
    background-color: #5858e9;
    border-color: #5858e9;
}

.milestone-item.expanded .milestone-chevron i {
    color: #ffffff;
}

/* ==========================================
   Milestone Details (Level 2 Expansion)
   ========================================== */
.milestone-details {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
    will-change: max-height, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.milestone-details-inner {
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.milestone-detail-text {
    font-size: 18px;
    font-weight: 400;
    letter-spacing: -0.72px;
    color: #121212;
    line-height: 1.18;
}

.milestone-resources-label {
    font-size: 16px;
    font-weight: 600;
    letter-spacing: -0.64px;
    color: #161616;
    margin-bottom: 0;
}

.milestone-resources-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 12px;
    list-style: disc;
    padding-left: 20px;
}

.milestone-resource-item {
    font-size: 16px;
    font-weight: 400;
    letter-spacing: -0.64px;
    color: #161616;
    line-height: 22px;
    padding: 2px 0;
}

.milestone-resource-item a {
    color: #5858e9;
    text-decoration: none;
    transition: all 0.2s ease-out;
    border-bottom: 1px solid transparent;
}

.milestone-resource-item a:hover {
    color: #5858e9;
    border-bottom-color: #5858e9;
    font-weight: bold;
}

.milestone-resource-item a:visited {
    color: #7B5BE9;
}

/* ==========================================
   Spacer between milestones
   ========================================== */
.milestone-spacer {
    display: flex;
    gap: 18px;
    height: 23px;
    align-items: flex-start;
}

.milestone-spacer-line {
    width: 100px;
    display: flex;
    justify-content: center;
}

.milestone-spacer-connector {
    width: 1px;
    height: 100%;
    background: linear-gradient(180deg, #d0d0d0 0%, transparent 100%);
}

/* ==========================================
   Responsive Design - Mobile (up to 767px)
   ========================================== */
@media (max-width: 767px) {
    .masthead {
        height: 80px;
        position: relative;
    }
    
    .masthead-title {
        font-size: 30px;
        letter-spacing: -1.2px;
        padding: 0 16px;
        line-height: 1.14;
    }

    
    .nav-section {
        position: relative;
        top: 0;
        padding: 0;
    }
    
    .nav-container {
        padding: 16px;
        flex-wrap: nowrap;
    }
    
    .nav-wrapper {
        flex-direction: column;
        gap: 6px;
        width: 100%;
    }
    
    .nav-link {
        width: 100%;
        min-width: auto;
        padding: 10px 12px;
        border-radius: 12px;
        border: none;
        background: transparent;
    }
    
    .nav-link span {
        font-size: 16px;
        font-weight: 600;
        letter-spacing: -0.64px;
        text-align: center;
    }
    
    .nav-link.active {
        padding: 10px 24px;
        border-radius: 12px;
        border: 1px solid #dddddd;
        border-bottom: 1px solid #dddddd;
        background: linear-gradient(180deg, rgba(223, 223, 223, 0) 38.532%, rgba(223, 223, 223, 1) 100%), 
                    linear-gradient(180deg, #f6f6f6 0%, #f9f9f9 100%);
    }

    .nav-icon-wrapper {
        display: none;
    }
    
    .main-content {
        padding: 16px 0 64px;
    }
    
    .content-container {
        padding: 0 32px;
        gap: 16px;
    }
    
    .controls-bar {
        width: 100%;
        flex-direction: row;
        align-items: center;
        justify-content: flex-end;
        gap: 12px;
        padding: 16px 0;
    }
    
    .current-filter {
        display: none;
    }
    
    .expand-all-link {
        font-size: 12px;
        padding: 9px 12px;
    }
    
    .expand-all-link i {
        font-size: 15px;
    }
    
    .timeline {
        width: 100%;
    }
    
    .phase-item {
        width: 100%;
        gap: 12px;
    }
    
    .phase-date-badge {
        font-size: 12px;
        padding: 6px;
        border-radius: 4px;
        letter-spacing: -0.12px;
    }
    
    .phase-card {
        padding: 16px;
        gap: 16px;
    }
    
    .phase-title {
        font-size: 22px;
        letter-spacing: -0.88px;
    }
    
    .phase-description-text {
        font-size: 16px;
        letter-spacing: -0.48px;
    }
    
    .milestone-item {
        flex-direction: column;
        gap: 8px;
    }

    .milestone-item:not(first-child) {
        padding-top: 16px; }
    
    .milestone-date-column {
        width: 100%;
        flex-direction: row;
        align-items: flex-start;
        gap: 0;
    }
    
    .milestone-date-badge {
        width: 100px;
        min-width: 100px;
        height: auto;
        padding: 7px 6px;
    }
    
    .milestone-date-text {
        font-size: 14px;
        letter-spacing: -0.56px;
    }
    
    .milestone-connector {
        display: none;
    }
    
    .milestone-spacer {
        display: none;
    }
    
    .milestone-title {
        font-size: 18px;
        letter-spacing: -0.72px;
    }
    
    .milestone-detail-text {
        font-size: 14px;
        letter-spacing: -0.56px;
    }
    
    .milestone-resources-label {
        font-size: 12px;
        letter-spacing: -0.48px;
    }
    
    .milestone-resource-item {
        font-size: 12px;
        letter-spacing: -0.48px;
        line-height: 17px;
    }
}

/* ==========================================
   Responsive Design - Tablet (768px - 1023px)
   ========================================== */
@media (min-width: 768px) and (max-width: 1023px) {
    .nav-container {
        padding: 0 32px;
    }
    
    .content-container {
        padding: 0 32px;
    }
    
    .nav-wrapper {
        gap: 12px;
    }
    
    .nav-link {
        flex: 1;
        padding: 12px;
    }
    
    .nav-link.active {
        padding: 10px 30px;
    }
    
    .nav-link span {
        font-size: 14px;
    }
    
    .controls-bar {
        width: 100%;
    }
    
    .timeline {
        width: 100%;
    }
    
    .phase-item {
        width: 100%;
    }
}

/* ==========================================
   Responsive Design - Desktop (1024px - 1439px)
   ========================================== */
@media (min-width: 1024px) and (max-width: 1439px) {
    .nav-container {
        padding: 0 64px;
    }
    
    .content-container {
        padding: 0 64px;
    }
}

/* ==========================================
   Utility Classes
   ========================================== */
.hidden {
    display: none !important;
}

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