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

body {
    font-family: "Montserrat", sans-serif;
    color: #222;
    padding: 2rem;
}

/* Container */
.project-container {
    max-width: 900px;
    margin: 0 auto;
    animation: fadeInUp 1s ease-in-out;
}

/* Back Button */
.back-button-wrapper {
    margin-bottom: 1rem;
}
.back-button {
    background: #fff;
    color: #333;
    border: 1px solid #8d575e;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}
.back-button:hover {
    background-color: #f0f0f0;
    transform: translateX(-3px);
}

/* Glassmorphism Card */
.project-card {
    background: rgba(255, 255, 255, 0.7);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    margin-bottom: 2rem;
    transition: transform 0.4s ease;
}
.project-card:hover {
    transform: translateY(-5px);
}

/* Typography */
.project-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.project-subtitle {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 1rem;
}

.project-description {
    font-size: 1rem;
    color: #333;
    margin-bottom: 1rem;
    line-height: 1.6;
}

/* Image */
.project-image-wrapper {
    text-align: center;
}
.project-image {
    width: 100%;
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
    margin-bottom: 20px;
}
.project-image:hover {
    transform: scale(1.02);
}

/* Fade In Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================================================
   Project Body System, shared by all case pages
   Scope: .proj and descendants
================================================== */

/* tokens */
.proj {
    --ink-900: #1f1f1f;
    --ink-700: #333;
    --muted: #66707a;
    --panel: #eef4f7;
    --card: #ffffff;
    --accent: #ff6c63;
    --brand: #165c7d;
    --rail: min(1160px, 92vw);
    --pad: clamp(16px, 4vw, 40px);
    --radius: 18px;
    --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.14), 0 10px 24px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 16px 40px rgba(0, 0, 0, 0.1), 0 6px 18px rgba(0, 0, 0, 0.08);
}

/* layout */
.proj {
    display: flex;
    flex-direction: column;
    gap: clamp(20px, 3vw, 36px);
    padding: var(--pad);
    margin-inline: auto;
    max-width: var(--rail);
}

.proj__back {
    margin-top: 8px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
    border-radius: 12px;
    font-weight: 600;
    border: 1.5px solid var(--brand);
    color: #fff;
    background: var(--brand);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease,
        color 0.2s ease;
}
.btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}
.btn:focus-visible {
    outline: 3px solid color-mix(in oklab, var(--brand), #fff 70%);
    outline-offset: 2px;
}
.btn--light {
    background: #fff;
    color: var(--brand);
}
.btn--light:hover {
    background: #f4f8fb;
}
.btn--ghost {
    background: #fff;
    color: var(--brand);
    border-color: var(--brand);
}
.btn--ghost:hover {
    background: #f4f8fb;
}

.proj__hero {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: clamp(16px, 2.8vw, 32px);
    align-items: center;
    padding: clamp(18px, 3.2vw, 28px);
    background: linear-gradient(180deg, #ffffff 0%, #f6fafc 100%);
    border: 1px solid rgba(22, 92, 125, 0.08);
    border-radius: 22px;
    box-shadow: var(--shadow-md);
}
.proj__head {
    padding: clamp(6px, 1vw, 12px);
}
.proj__title {
    font-size: clamp(28px, 4.5vw, 44px);
    line-height: 1.1;
    color: var(--ink-900);
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}
.proj__subtitle {
    color: var(--muted);
    font-size: clamp(14px, 1.8vw, 18px);
    margin-bottom: 12px;
}
.proj__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 12px 0 16px;
}
.chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: #f0f6f9;
    color: #184f6a;
    border: 1px solid rgba(22, 92, 125, 0.12);
    font-size: 13px;
    font-weight: 600;
}
.chip--soft {
    background: #fff5f4;
    color: #7f2b26;
    border-color: rgba(255, 108, 99, 0.18);
}

.proj__cover {
    position: relative;
}
.cover__frame {
    position: relative;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transform: perspective(1200px) rotateX(0.6deg) rotateY(-1.2deg);
    transition: transform 0.4s ease, box-shadow 0.3s ease;
}
.cover__frame:hover {
    transform: perspective(1200px) rotateX(0deg) rotateY(0deg) translateY(-2px);
}
.cover__img {
    display: block;
    width: 100%;
    height: auto;
}

/* overview grid */
.proj__grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: clamp(14px, 2.6vw, 28px);
}
.proj__grid--2 {
    grid-template-columns: 1fr 1fr;
}
.card {
    background: #fff;
    border: 1px solid rgba(2, 18, 31, 0.06);
    border-radius: 18px;
    padding: clamp(16px, 2.6vw, 24px);
    box-shadow: 0 8px 24px rgba(3, 24, 41, 0.06);
}
.card--facts {
    background: linear-gradient(180deg, #ffffff 0%, #f9fbfc 100%);
}
.card__title {
    font-size: clamp(20px, 3vw, 26px);
    margin-bottom: 6px;
    color: var(--ink-900);
}
.card__subtitle {
    font-size: clamp(16px, 2.2vw, 18px);
    margin-bottom: 8px;
    color: var(--ink-700);
}
.card__body {
    color: var(--ink-700);
    line-height: 1.65;
    margin-bottom: 10px;
}
.facts {
    display: grid;
    gap: 10px;
}
.tag {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.2px;
    padding: 5px 8px;
    border-radius: 999px;
    background: #fff2f1;
    color: #7f2b26;
    margin-right: 6px;
}

/* list and stack */
.list {
    display: grid;
    gap: 10px;
    color: var(--ink-700);
}
.list li {
    line-height: 1.65;
}
.stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(14px, 2.6vw, 28px);
}
.stack__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* gallery, optional if you want extra screens, keep unique images only */
.gallery {
    padding-top: 4px;
}
.gallery__title {
    font-size: clamp(18px, 2.6vw, 22px);
    margin-bottom: 12px;
    color: var(--ink-900);
}
.gallery__rail {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}
.shot {
    background: #fff;
    border: 1px solid rgba(2, 18, 31, 0.06);
    border-radius: 16px;
    padding: 12px;
    box-shadow: 0 8px 20px rgba(3, 24, 41, 0.06);
}
.shot__img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    display: block;
}
.shot__cap {
    font-size: 13px;
    color: var(--muted);
    margin-top: 6px;
}

/* glass util */
.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.35);
}

/* entrance */
.proj > * {
    opacity: 0;
    transform: translateY(18px);
    animation: projFade 0.6s ease forwards;
}
.proj > *:nth-child(1) {
    animation-delay: 0.05s;
}
.proj > *:nth-child(2) {
    animation-delay: 0.12s;
}
.proj > *:nth-child(3) {
    animation-delay: 0.18s;
}
.proj > *:nth-child(4) {
    animation-delay: 0.24s;
}
@keyframes projFade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* responsive */
@media (max-width: 980px) {
    .proj__hero {
        grid-template-columns: 1fr;
    }
    .proj__grid,
    .proj__grid--2,
    .stack {
        grid-template-columns: 1fr;
    }
    .proj__cta {
        width: 100%;
    }
}
@media (max-width: 560px) {
    .proj {
        padding: 16px;
    }
    .btn {
        width: 100%;
    } /* full width buttons on phones */
    .cover__frame {
        border-radius: 16px;
    }
}
