/* iHP (Integrated Human Practices) Styles - Based on bnuzh design */

/* Color variables */
:root {
    --ihp-primary: #01de9b;
    --ihp-secondary: #00c1a4;
    --ihp-dark: #032d30;
    --ihp-light: #fcfffe;
    --ihp-bg: #dbeee8;
    --ihp-accent: #b8ded7;
}

/* Page container styles */
.page-container {
    background-color: var(--ihp-bg);
    position: relative;
    justify-content: center;
    padding-top: max(8vw, 12rem);
    padding-bottom: 10rem;
}

.page-header {
    position: relative;
    background-color: var(--ihp-secondary);
    height: 38vw;
    overflow: hidden;
}

.header-mid {
    width: 88%;
    height: 85%;
    margin: 3% 6.5%;
    z-index: 50;
    overflow: hidden;
    position: relative;
    border-radius: 30px;
}

.header-mid>img:nth-child(1) {
    height: 100%;
    float: left;
    z-index: 50;
}

.header-mid>img:nth-child(2) {
    height: 100%;
    position: absolute;
    right: 2%;
    z-index: -10;
    border: none;
    border-top-right-radius: 30px;
    border-bottom-right-radius: 30px;
}

.page-name {
    font-family: "Barlow Condensed", sans-serif;
    font-size: 4vw;
    font-weight: 500;
    color: var(--ihp-dark);
    position: absolute;
    top: 40%;
    left: 27%;
    z-index: 100;
}

.page-body {
    width: 100%;
    display: flex;
    margin-top: 10rem;
    justify-content: center;
    color: var(--ihp-dark);
}

/* Left navigation */
.left-nav {
    display: flex;
    flex-direction: column;
    gap: 1vh;
    height: fit-content;
    font-family: "Quicksand", sans-serif;
    position: sticky;
    top: 10rem;
    width: 35rem;
    padding: 3rem;
    margin-right: 3rem;
}

.left-nav-title {
    font-family: "Barlow Condensed", sans-serif;
    margin-bottom: 1rem;
    text-align: left;
    font-size: 4.2rem;
    font-weight: bold;
}

.left-nav-item {
    font-family: "Quicksand", sans-serif;
    font-weight: 500;
    font-size: 2rem;
    text-align: left;
    cursor: pointer;
    margin-bottom: 0.6rem;
    transition: color 0.3s ease;
}

.left-nav-item:hover {
    color: var(--ihp-primary);
}

.bright {
    color: var(--ihp-primary);
}

.sub-nav {
    display: none;
    flex-direction: column;
    height: 0;
    opacity: 0;
    transition: opacity 0.6s ease, height 0.6s ease;
}

.unfold {
    opacity: 1;
    height: fit-content;
}

.sub-item {
    font-size: 1.6rem;
    margin-left: 2rem;
}

/* Right content */
.right-text {
    max-width: 69%;
}

.main-text {
    border-radius: 50px;
    background: var(--ihp-light);
    padding: 30px 4%;
    margin-right: 5%;
}

/* Text content styles */
.text-content-h1 {
    text-align: left;
    margin-top: 20px;
    margin-bottom: 20px;
    font-size: 3rem;
    font-family: "Quicksand", sans-serif;
    font-weight: bold;
    color: var(--ihp-primary);
}

.text-content-h4 {
    text-align: left;
    margin-top: 15px;
    margin-bottom: 15px;
    font-size: 2.4rem;
    font-family: "Quicksand", sans-serif;
    font-weight: bold;
}

.text-content-h5 {
    margin-top: 10px;
    margin-bottom: 10px;
    font-size: 2.1rem;
    font-family: "Quicksand", sans-serif;
    font-weight: bold;
}

.text-content-p {
    margin: 15px 0;
    text-align: justify;
    font-family: "Quicksand", sans-serif;
    font-weight: 400;
    font-size: 1.8rem;
    line-height: 1.3;
}

.text-content-p a,
.text-content-p a:hover,
.text-content-p a:visited,
.text-content-p a:active {
    color: var(--ihp-primary);
}

.text-content .text-content-table {
    width: 100%;
    margin: 2rem 0;
    overflow-x: auto;
}

.text-content .text-content-table table {
    width: 100%;
    border-collapse: collapse;
}

.text-content .text-content-table th,
.text-content .text-content-table td {
    padding: 1rem;
    text-align: left;
    border: 1px solid var(--ihp-accent);
}

.text-content .text-content-table th {
    background-color: #f4f4f4;
    font-weight: bold;
}

.text-content .text-content-table td {
    width: auto;
}

.text-content .text-content-table td:hover {
    background-color: var(--ihp-bg);
}

.text-callout .text-content-ques {
    font-weight: 500;
}

.text-callout .text-content-ans {
    list-style: disc;
}

.text-img-container {
    text-align: center;
    margin: 2rem 8rem;
}

.text-img {
    width: 70%;
    border-radius: 10px;
}

.text-callout {
    background-color: #9ae6d8;
    border: var(--ihp-primary);
    font-family: "Quicksand", sans-serif;
    font-size: 1.8rem;
    line-height: 2.5rem;
    border-radius: 10px;
    padding: 2rem 4rem;
    position: relative;
    margin: 2rem 0;
}

.text-detail-brief {
    background-color: var(--ihp-primary);
    color: var(--ihp-light);
    margin-top: 3%;
}

.ihp-text-detail {
    background-color: var(--ihp-bg);
    display: none;
    padding: 2rem 4rem;
    border-radius: 10px;
    height: fit-content;
    margin-top: 1rem;
}

.ihp-text-detail.show {
    display: block;
}

/* iHP Timeline Styles */
.ihp-three-parts {
    position: relative;
    margin-top: 5rem;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.ihp-fixed {
    width: 4%;
    height: 200px;
    border-radius: 30px;
    background-color: var(--ihp-light);
    color: var(--ihp-dark);
    font-size: 1.5vw;
    font-weight: bold;
    font-family: "Barlow Condensed", sans-serif;
    position: fixed;
    top: 20%;
    writing-mode: vertical-rl;
    white-space: nowrap;
    padding: 2px;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 1000;
}

.ihp-fixed-left {
    left: 3%;
    transform: rotate(180deg);
}

.ihp-fixed-right {
    left: 93%;
}

.ihp-fixed.is-visible {
    opacity: 1;
}

.ihp {
    height: fit-content;
    position: relative;
    margin-top: 100px;
    font-family: "Quicksand", sans-serif;
    font-size: 16px;
    width: 95%;
    margin: 0 auto;
}

.ihp-margin {
    height: 120px;
    position: relative;
    margin: 30px 0;
}

.ihp-node {
    min-height: 120px;
    height: auto;
    position: relative;
    font-size: 1.5vw;
    font-weight: 500;
    text-align: center;
    margin: 20px 0;
    width: 100%;
}

.ihp-node>.ihp-box {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--ihp-dark);
    width: 55%;
    margin: 0 auto;
    background-color: var(--ihp-light);
    border-radius: 30px;
    position: relative;
    z-index: 100;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    min-height: 0;
    left: auto !important;
}

.ihp-title-right,
.ihp-title-left {
    position: relative;
    height: 12vw;
}

.ihp-title {
    border-radius: 30px;
    background-color: var(--ihp-light);
    width: 45%;
    height: 80%;
    position: absolute;
    bottom: 0;
    text-align: center;
    vertical-align: middle;
    color: var(--ihp-dark);
    font-size: 1.6vw;
}

.ihp-h1 {
    font-weight: 600;
    font-family: "Barlow Condensed", sans-serif;
    font-size: 3vw;
    margin-top: 1vw;
    margin-bottom: 1vw;
}

.ihp-title-left>.ihp-title {
    left: 7.5%;
}

.ihp-title-right>.ihp-title {
    right: 7.5%;
}

.ihp-line-left {
    height: 100%;
    width: 4px;
    background-color: var(--ihp-primary);
    position: absolute;
    left: 50%;
    margin-left: -2px;
    z-index: 1;
}

.ihp-line-right {
    height: 100%;
    width: 4px;
    background-color: var(--ihp-primary);
    position: absolute;
    left: 50%;
    margin-left: -2px;
    z-index: 1;
}

.ihp-left,
.ihp-right {
    min-height: 420px;
    height: auto;
    position: relative;
    margin-bottom: 40px;
    padding: 16px 0;
}

.ihp-date {
    height: 40px;
    width: 100px;
    background-color: var(--ihp-light);
    border-radius: 20px;
    position: absolute;
    margin-top: 20px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: none;
    text-align: center;
    font-size: 14px;
    font-family: "Barlow Condensed", sans-serif;
    z-index: 200;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.ihp-node .ihp-date {
    left: 2%;
    margin-left: -50px;
}

.ihp-node-left>.ihp-date,
.ihp-left>.ihp-date {
    left: 2%;
    margin-left: -50px;
}

.ihp-node-right>.ihp-date,
.ihp-right>.ihp-date {
    position: absolute;
    right: 2%;
    margin-right: -50px;
}

.ihp-box {
    width: 55%;
    min-height: 360px;
    background-color: var(--ihp-light);
    position: relative;
    border-radius: 30px;
    padding: 18px;
    overflow: visible;
    z-index: 100;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.ihp-node-left>.ihp-box,
.ihp-left>.ihp-box,
.ihp-left-detail>.ihp-box {
    left: 13%;
}

.ihp-node-right>.ihp-box,
.ihp-right>.ihp-box,
.ihp-right-detail>.ihp-box {
    left: 32%;
}

.ihp-img-left {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    margin-bottom: 15px;
    align-self: flex-start;
}

.ihp-img-left>img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ihp-name {
    font-size: 1.8rem;
    font-family: "Barlow Condensed", sans-serif;
    margin-bottom: 15px;
    font-weight: bold;
    line-height: 1.2;
    color: var(--ihp-dark);
}

.ihp-description {
    position: relative;
    width: 100%;
    color: var(--ihp-primary);
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 15px;
}

.ihp-description ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.ihp-description li {
    background-color: var(--ihp-primary);
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
}

.ihp-content {
    width: 100%;
    position: relative;
    margin-bottom: 20px;
    padding: 10px 0;
}

.ihp-reflect {
    width: 100%;
    position: relative;
    margin-bottom: 20px;
    padding: 10px 0;
    flex-grow: 1;
}

.ihp-content p,
.ihp-reflect p {
    margin-bottom: 10px;
    line-height: 1.4;
}

.ihp-content ul,
.ihp-reflect ul {
    margin: 10px 0;
    padding-left: 20px;
}

.ihp-content li,
.ihp-reflect li {
    margin-bottom: 5px;
    line-height: 1.4;
}

.ihp-click {
    color: var(--ihp-secondary);
    font-size: 1.1rem;
    font-weight: 500;
    position: relative;
    width: fit-content;
    font-family: "Quicksand", sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
    align-self: flex-end;
    padding: 8px 16px;
    background-color: rgba(0, 193, 164, 0.1);
    border-radius: 20px;
    border: 2px solid var(--ihp-secondary);
}

.ihp-click:hover {
    color: var(--ihp-primary);
    background-color: rgba(1, 222, 155, 0.2);
    border-color: var(--ihp-primary);
    transform: translateY(-2px);
}

.ihp-click>img {
    width: 20px;
    height: 20px;
    margin-left: 8px;
    transition: transform 0.5s ease;
    transform: rotate(180deg);
    vertical-align: middle;
}

.ihp-left-detail,
.ihp-right-detail {
    height: fit-content;
    position: relative;
    z-index: 10;
    margin-top: 20px;
    margin-bottom: 50px;
    display: none;
    padding: 20px 0;
}

.ihp-left-detail.show,
.ihp-right-detail.show {
    display: block;
}

.ihp-img-mid {
    width: 50%;
    position: relative;
    left: 25%;
    margin: 1%;
}

.ihp-img-mid>img {
    width: 100%;
    border-radius: 10px;
}

.ihp-img-two {
    width: 80%;
    position: relative;
    left: 10%;
    margin: 1%;
    display: flex;
    gap: 2%;
}

.ihp-img-two>img {
    width: 49%;
    border-radius: 10px;
}

.ihp-left-detail>.ihp-box,
.ihp-right-detail>.ihp-box {
    border-radius: 0 0 30px 30px;
    background-color: var(--ihp-accent);
    padding: 3%;
    padding-top: 35px;
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

/* Responsive design */
@media (max-width: 768px) {
    .page-container {
        padding-top: 8rem;
    }

    .page-header {
        height: 50vw;
    }

    .page-name {
        font-size: 6vw;
        top: 35%;
        left: 20%;
    }

    .page-body {
        flex-direction: column;
        margin-top: 5rem;
    }

    .left-nav {
        position: static;
        width: 100%;
        padding: 2rem;
        margin-right: 0;
    }

    .right-text {
        max-width: 100%;
    }

    .main-text {
        margin-right: 0;
        padding: 20px 3%;
    }

    .ihp-fixed {
        display: none;
    }

    .ihp {
        width: 100%;
    }

    .ihp-left,
    .ihp-right {
        height: auto;
        min-height: 400px;
        margin-bottom: 60px;
        padding: 30px 0;
    }

    .ihp-box {
        width: 90%;
        left: 5% !important;
        padding: 20px;
        min-height: 350px;
    }

    .ihp-node>.ihp-box {
        width: 90%;
        left: 5% !important;
        margin: 0 auto;
    }

    .ihp-date {
        font-size: 12px;
        width: 80px;
        height: 35px;
    }

    .ihp-name {
        font-size: 1.4rem;
    }

    .ihp-description {
        font-size: 1rem;
    }

    .ihp-click {
        font-size: 1rem;
        padding: 6px 12px;
    }

    .ihp-date {
        font-size: 12px;
        width: 100px;
        height: 40px;
    }

    .text-content-h1 {
        font-size: 2.5rem;
    }

    .text-content-h4 {
        font-size: 2rem;
    }

    .text-content-p {
        font-size: 1.6rem;
    }
}