.progress-detail-page {
    min-height: 100vh;
    background: #f9fafb;
}


/* TOP BAR */

.progress-detail-topbar {
    position: sticky;
    top: 64px;
    z-index: 40;
    border-bottom: 1px solid #f3f4f6;
    background: #ffffff;
}

.progress-detail-topbar-inner {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    max-width: 1152px;
    height: 48px;
    margin: 0 auto;
    padding: 0 16px;
    box-sizing: border-box;
}

.progress-detail-back {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #9ca3af;
    font-size: 14px;
    line-height: 20px;
    text-decoration: none;
    transition: color 0.15s ease;
}

.progress-detail-back:hover {
    color: #374151;
}

.progress-detail-back svg {
    width: 16px;
    height: 16px;
}

.progress-detail-topbar-divider {
    color: #e5e7eb;
}

.progress-detail-topbar-title {
    overflow: hidden;
    color: #374151;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* CONTENT */

.progress-detail-inner {
    width: 100%;
    max-width: 1152px;
    margin: 0 auto;
    padding: 40px 16px;
    box-sizing: border-box;
}

.progress-detail-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
}


/* LEFT */

.progress-detail-side {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.progress-detail-image {
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border-radius: 16px;
}

.progress-detail-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.progress-detail-info-card {
    padding: 24px;
    border: 1px solid #f3f4f6;
    border-radius: 16px;
    background: #ffffff;
}

.progress-detail-info-heading {
    margin-bottom: 20px;
}

.progress-detail-stage {
    display: inline-block;
    margin-bottom: 12px;
    padding: 4px 10px;
    border-radius: 9999px;
    font-size: 12px;
    line-height: 16px;
    font-weight: 500;
}

.progress-detail-stage[data-stage="상담"] {
    background: #f3f4f6;
    color: #4b5563;
}

.progress-detail-stage[data-stage="기본설계"] {
    background: #eff6ff;
    color: #1d4ed8;
}

.progress-detail-stage[data-stage="실시설계"] {
    background: #f5f3ff;
    color: #6d28d9;
}

.progress-detail-stage[data-stage="인허가"] {
    background: #fffbeb;
    color: #b45309;
}

.progress-detail-stage[data-stage="시공"] {
    background: #fff7ed;
    color: #c2410c;
}

.progress-detail-stage[data-stage="완공"] {
    background: #f0fdf4;
    color: #15803d;
}

.progress-detail-info-heading h1 {
    margin: 0;
    font-size: 20px;
    line-height: 28px;
    font-weight: 500;
}

.progress-detail-info-heading p {
    margin: 4px 0 0;
    color: #6b7280;
    font-size: 14px;
    line-height: 20px;
}

.progress-detail-info-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
    color: #4b5563;
    font-size: 14px;
    line-height: 20px;
}

.progress-detail-info-list > div {
    display: flex;
    align-items: center;
    gap: 8px;
}

.progress-detail-info-list svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #d1d5db;
}


/* LEFT PROGRESS */

.progress-detail-progress {
    padding-top: 16px;
    border-top: 1px solid #f9fafb;
}

.progress-detail-progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
    color: #6b7280;
    font-size: 12px;
    line-height: 16px;
}

.progress-detail-progress-label strong {
    color: #000000;
    font-weight: 500;
}

.progress-detail-progress-track {
    height: 8px;
    overflow: hidden;
    border-radius: 9999px;
    background: #f3f4f6;
}

.progress-detail-progress-bar {
    display: block;
    height: 100%;
    border-radius: 9999px;
}

.progress-detail-stage-progress-label {
    display: flex;
    justify-content: space-between;
    margin-top: 4px;
    color: #9ca3af;
    font-size: 12px;
    line-height: 16px;
}

.progress-detail-stage-progress-track {
    height: 6px;
    overflow: hidden;
    border-radius: 9999px;
    background: #f3f4f6;
}

.progress-detail-stage-progress-bar {
    display: block;
    height: 100%;
    border-radius: 9999px;
    opacity: 0.5;
}

.progress-detail-progress-bar[data-stage="상담"],
.progress-detail-stage-progress-bar[data-stage="상담"] {
    background: #9ca3af;
}

.progress-detail-progress-bar[data-stage="기본설계"],
.progress-detail-stage-progress-bar[data-stage="기본설계"] {
    background: #3b82f6;
}

.progress-detail-progress-bar[data-stage="실시설계"],
.progress-detail-stage-progress-bar[data-stage="실시설계"] {
    background: #8b5cf6;
}

.progress-detail-progress-bar[data-stage="인허가"],
.progress-detail-stage-progress-bar[data-stage="인허가"] {
    background: #f59e0b;
}

.progress-detail-progress-bar[data-stage="시공"],
.progress-detail-stage-progress-bar[data-stage="시공"] {
    background: #f97316;
}

.progress-detail-progress-bar[data-stage="완공"],
.progress-detail-stage-progress-bar[data-stage="완공"] {
    background: #22c55e;
}

.progress-detail-contact {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    background: #030213;
    color: #ffffff;
    font-size: 14px;
    line-height: 20px;
    text-decoration: none;
    box-sizing: border-box;
}


/* RIGHT */

.progress-detail-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}


/* PIPELINE */

.progress-detail-stage-card {
    padding: 24px;
    border: 1px solid #f3f4f6;
    border-radius: 16px;
    background: #ffffff;
}

.progress-detail-stage-card h2 {
    margin: 0 0 24px;
    color: #9ca3af;
    font-size: 14px;
    line-height: 20px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.progress-detail-pipeline {
    position: relative;
}

.progress-detail-pipeline-track {
    position: absolute;
    top: 16px;
    left: 16px;
    right: 16px;
    height: 2px;
    background: #f3f4f6;
}

.progress-detail-pipeline-active {
    position: absolute;
    top: 16px;
    left: 16px;
    height: 2px;
    transition: all 0.15s ease;
}

.progress-detail-pipeline-active[data-stage="상담"] {
    background: #9ca3af;
}

.progress-detail-pipeline-active[data-stage="기본설계"] {
    background: #3b82f6;
}

.progress-detail-pipeline-active[data-stage="실시설계"] {
    background: #8b5cf6;
}

.progress-detail-pipeline-active[data-stage="인허가"] {
    background: #f59e0b;
}

.progress-detail-pipeline-active[data-stage="시공"] {
    background: #f97316;
}

.progress-detail-pipeline-active[data-stage="완공"] {
    background: #22c55e;
}

.progress-detail-pipeline-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 4px;
}

.progress-detail-pipeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.progress-detail-pipeline-circle {
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 2px solid #e5e7eb;
    border-radius: 9999px;
    background: #ffffff;
    box-sizing: border-box;
}

.progress-detail-pipeline-circle.is-done {
    border-color: #000000;
    background: #000000;
}

.progress-detail-pipeline-circle.is-active {
    border-color: #000000;
    background: #ffffff;
}

.progress-detail-pipeline-circle svg {
    width: 16px;
    height: 16px;
    color: #d1d5db;
}

.progress-detail-pipeline-circle.is-done svg {
    color: #ffffff;
}

.progress-detail-pipeline-current {
    width: 12px;
    height: 12px;
    border-radius: 9999px;
}

.progress-detail-pipeline-current[data-stage="상담"] {
    background: #9ca3af;
}

.progress-detail-pipeline-current[data-stage="기본설계"] {
    background: #3b82f6;
}

.progress-detail-pipeline-current[data-stage="실시설계"] {
    background: #8b5cf6;
}

.progress-detail-pipeline-current[data-stage="인허가"] {
    background: #f59e0b;
}

.progress-detail-pipeline-current[data-stage="시공"] {
    background: #f97316;
}

.progress-detail-pipeline-current[data-stage="완공"] {
    background: #22c55e;
}

.progress-detail-pipeline-name {
    color: #d1d5db;
    font-size: 11px;
    line-height: 14px;
    text-align: center;
}

.progress-detail-pipeline-name.is-done {
    color: #6b7280;
}

.progress-detail-pipeline-name.is-active {
    color: #000000;
    font-weight: 600;
}

.progress-detail-pipeline-percent {
    color: #9ca3af;
    font-size: 10px;
    line-height: 12px;
}


/* TABS */

.progress-detail-tabs-card {
    overflow: hidden;
    border: 1px solid #f3f4f6;
    border-radius: 16px;
    background: #ffffff;
}

.progress-detail-tabs {
    display: flex;
    overflow-x: auto;
    padding: 0 8px;
    border-bottom: 1px solid #f3f4f6;
}

.progress-detail-tab {
    flex-shrink: 0;
    padding: 10px 16px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: #9ca3af;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: color 0.15s ease,
                border-color 0.15s ease;
}

.progress-detail-tab:hover {
    color: #374151;
}

.progress-detail-tab.is-active {
    border-bottom-color: #000000;
    color: #000000;
}

.progress-detail-tab-panel {
    display: none;
}

.progress-detail-tab-panel.is-active {
    display: block;
}


/* MILESTONE */

.progress-detail-milestones {
    padding: 24px;
}

.progress-detail-milestone {
    display: flex;
    gap: 16px;
}

.progress-detail-milestone-timeline {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.progress-detail-milestone-dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 2px;
    border: 2px solid #d1d5db;
    border-radius: 9999px;
    background: #ffffff;
    box-sizing: border-box;
}

.progress-detail-milestone-dot.is-done {
    border-color: #000000;
    background: #000000;
}

.progress-detail-milestone-dot svg {
    width: 12px;
    height: 12px;
    color: #ffffff;
}

.progress-detail-milestone-line {
    width: 1px;
    min-height: 24px;
    flex: 1;
    margin: 4px 0;
    background: #f3f4f6;
}

.progress-detail-milestone-line.is-done {
    background: #d1d5db;
}

.progress-detail-milestone-content {
    flex: 1;
    padding-bottom: 24px;
}

.progress-detail-milestone-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.progress-detail-milestone-head p {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
}

.progress-detail-milestone-head p.is-done {
    color: #374151;
}

.progress-detail-milestone-head span {
    flex-shrink: 0;
    color: #d1d5db;
    font-size: 12px;
    line-height: 16px;
}

.progress-detail-milestone-head span.is-done {
    color: #9ca3af;
}

.progress-detail-milestone-current {
    display: inline-block;
    margin-top: 4px;
    padding: 2px 8px;
    border-radius: 9999px;
    background: #fffbeb;
    color: #d97706;
    font-size: 10px;
    line-height: 15px;
}


/* UPDATES */

.progress-detail-update {
    display: flex;
    gap: 16px;
    padding: 20px;
    border-bottom: 1px solid #f9fafb;
}

.progress-detail-update:last-child {
    border-bottom: 0;
}

.progress-detail-update-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    border-radius: 8px;
}

.progress-detail-update-icon svg {
    width: 16px;
    height: 16px;
}

.progress-detail-update-icon[data-type="notice"],
.progress-detail-update-type[data-type="notice"] {
    background: #fef2f2;
    color: #dc2626;
}

.progress-detail-update-icon[data-type="update"],
.progress-detail-update-type[data-type="update"] {
    background: #eff6ff;
    color: #2563eb;
}

.progress-detail-update-icon[data-type="document"],
.progress-detail-update-type[data-type="document"] {
    background: #f3f4f6;
    color: #4b5563;
}

.progress-detail-update-icon[data-type="meeting"],
.progress-detail-update-type[data-type="meeting"] {
    background: #f5f3ff;
    color: #7c3aed;
}

.progress-detail-update-body {
    flex: 1;
    min-width: 0;
}

.progress-detail-update-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.progress-detail-update-type {
    padding: 2px 8px;
    border-radius: 9999px;
    font-size: 10px;
    line-height: 15px;
}

.progress-detail-update-meta > span:not(.progress-detail-update-type) {
    color: #9ca3af;
    font-size: 12px;
    line-height: 16px;
}

.progress-detail-update-date {
    margin-left: auto;
    color: #d1d5db !important;
}

.progress-detail-update-body p {
    margin: 0;
    color: #374151;
    font-size: 14px;
    line-height: 23px;
}


/* DOCUMENTS */

.progress-detail-document {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    border-bottom: 1px solid #f9fafb;
    transition: background-color 0.15s ease;
}

.progress-detail-document:last-child {
    border-bottom: 0;
}

.progress-detail-document:hover {
    background: #f9fafb;
}

.progress-detail-document-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border-radius: 8px;
    background: #f3f4f6;
    font-size: 18px;
}

.progress-detail-document-info {
    flex: 1;
    min-width: 0;
}

.progress-detail-document-info p {
    overflow: hidden;
    margin: 0;
    color: #1f2937;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.progress-detail-document-info span {
    color: #9ca3af;
    font-size: 12px;
    line-height: 16px;
}

.progress-detail-document-download {
    padding: 6px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #9ca3af;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.progress-detail-document-download:hover {
    background: #e5e7eb;
}

.progress-detail-document-download svg {
    width: 16px;
    height: 16px;
}


/* BOTTOM */

.progress-detail-bottom {
    padding: 32px 0;
    border-top: 1px solid #f3f4f6;
    background: #ffffff;
}

.progress-detail-bottom-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 16px;
    box-sizing: border-box;
}

.progress-detail-bottom-list,
.progress-detail-bottom-contact {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 14px;
    line-height: 20px;
    text-decoration: none;
}

.progress-detail-bottom-list {
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid #e5e7eb;
    background: #ffffff;
    color: #030213;
}

.progress-detail-bottom-list svg {
    width: 16px;
    height: 16px;
}

.progress-detail-bottom-contact {
    padding: 8px 16px;
    background: #030213;
    color: #ffffff;
}


/* RESPONSIVE */

@media (min-width: 640px) {

    .progress-detail-topbar-inner,
    .progress-detail-inner,
    .progress-detail-bottom-inner {
        padding-left: 24px;
        padding-right: 24px;
    }

}

@media (min-width: 1024px) {

    .progress-detail-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .progress-detail-side {
        grid-column: span 1 / span 1;
    }

    .progress-detail-content {
        grid-column: span 2 / span 2;
    }

}

.progress-detail-modify-button {
    margin-left: auto;
    padding: 6px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #ffffff;
    color: #374151;
    font-size: 12px;
    line-height: 18px;
    cursor: pointer;
}

.progress-detail-modify-button:hover {
    border-color: #9ca3af;
    color: #111827;
}

.progress-detail-delete-button {
    margin-left: 8px;
    padding: 6px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #ffffff;
    color: #374151;
    font-size: 12px;
    line-height: 18px;
    cursor: pointer;
}

.progress-detail-delete-button:hover {
    border-color: #9ca3af;
    color: #111827;
}