/* Case Studies listing page. Builds on home.css (.hp) and solution.css (.sp). */

/* Hero: jump list of the case studies */
.cs-index { background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .16); border-radius: 18px; padding: 22px; }
.cs-index__head { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--hp-gold); margin: 0 0 10px; }
.cs-index ol { list-style: none; padding: 0; margin: 0; }
.cs-index li + li { border-top: 1px solid rgba(255, 255, 255, .14); }
.cs-index a { display: flex; align-items: center; gap: 14px; padding: 14px 4px; color: #fff; text-decoration: none; }
.cs-index a:hover { color: var(--hp-gold); }
.cs-index__num { font-size: 1.4rem; font-weight: 800; color: var(--hp-gold); min-width: 34px; }
.cs-index a > span:nth-child(2) { flex: 1; font-size: .92rem; color: rgba(255, 255, 255, .75); }
.cs-index strong { display: block; font-size: 1.05rem; color: #fff; }
.cs-index a:hover strong { color: var(--hp-gold); }
.cs-index i { font-size: .85rem; opacity: .7; }

/* Case study cards */
.cs-list { display: grid; gap: 28px; }
.cs-item { display: grid; grid-template-columns: minmax(0, 1fr) 360px; background: #fff; border: 1px solid var(--hp-line); border-radius: 20px; overflow: hidden; scroll-margin-top: 110px; transition: box-shadow .25s, transform .25s; }
.cs-item:hover { box-shadow: 0 18px 44px rgba(10, 44, 70, .1); transform: translateY(-2px); }
.cs-item__main { padding: 32px; display: flex; flex-direction: column; }
.cs-item__tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.cs-item__tags .hp-case__tag { margin-bottom: 0; }
.cs-item__chip { font-size: .8rem; font-weight: 600; color: var(--hp-blue); background: #eef5fa; border-radius: 20px; padding: 4px 10px; }
.cs-item__chip i { font-size: .72rem; margin-right: 3px; }
.cs-item h2 { font-size: clamp(1.25rem, 1rem + .7vw, 1.55rem); line-height: 1.3; margin-bottom: 20px; }
.cs-item h2 a { color: var(--hp-ink); }
.cs-item h2 a:hover { color: var(--hp-blue); }
.cs-item__story { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 24px; flex: 1; }
.cs-item__story h3 { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--hp-gold-dark); margin-bottom: 8px; }
.cs-item__story p { color: #33434f; font-size: .98rem; margin: 0; }
.cs-item__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.cs-item__results { background: var(--hp-navy); color: #fff; padding: 32px 28px; display: flex; flex-direction: column; }
.cs-item__results h3 { color: #fff; font-size: 1.15rem; margin-bottom: 16px; }
.cs-item__results ul { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 12px; flex: 1; }
.cs-item__results li { display: flex; gap: 10px; font-size: .95rem; color: rgba(255, 255, 255, .88); line-height: 1.45; }
.cs-item__results li i { color: var(--hp-gold); margin-top: 3px; }
.cs-item__solution { display: block; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .16); color: #fff; font-weight: 600; text-decoration: none; }
.cs-item__solution small { display: block; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--hp-gold); margin-bottom: 4px; }
.cs-item__solution:hover { color: var(--hp-gold); }
.cs-item__solution i { font-size: .8rem; margin-left: 4px; }

@media (max-width: 991.98px) {
    .cs-item { grid-template-columns: 1fr; }
}
@media (max-width: 767.98px) {
    .cs-item__main { padding: 22px; }
    .cs-item__story { grid-template-columns: 1fr; gap: 16px; }
    .cs-item__results { padding: 22px; }
    .cs-item__actions .hp-btn { flex: 1 1 100%; justify-content: center; }
}

/* ---------- Case study detail page ---------- */
.cs-hero__title { font-size: clamp(1.7rem, 1.1rem + 2vw, 2.6rem) !important; }
.cs-glance { margin: 0; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .16); border-radius: 18px; padding: 6px 22px; }
.cs-glance div { padding: 14px 0; }
.cs-glance div + div { border-top: 1px solid rgba(255, 255, 255, .14); }
.cs-glance dt { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--hp-gold); margin-bottom: 4px; }
.cs-glance dd { margin: 0; color: #fff; font-weight: 600; }
.cs-glance a { color: #fff; }
.cs-glance a:hover { color: var(--hp-gold); }
.cs-glance i { font-size: .75rem; margin-left: 4px; }

.cs-article { display: grid; gap: 22px; }
.cs-block { border: 1px solid var(--hp-line); border-radius: 18px; padding: 28px 30px; background: #fff; }
.cs-block h2 { display: flex; align-items: center; gap: 12px; font-size: 1.35rem; margin-bottom: 14px; }
.cs-block__icon { width: 40px; height: 40px; flex: 0 0 auto; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: #eef5fa; color: var(--hp-blue); font-size: 1rem; }
.cs-block p { color: #33434f; font-size: 1.02rem; line-height: 1.7; margin-bottom: 12px; }
.cs-block p:last-child { margin-bottom: 0; }
.cs-block--challenge { background: var(--hp-cream); border-color: rgba(229, 187, 25, .45); }
.cs-block--challenge .cs-block__icon { background: #fff; color: var(--hp-gold-dark); }
.cs-block--results { background: #f3f7fa; }
.cs-block--results .cs-block__icon { background: var(--hp-blue); color: #fff; }
.cs-checklist { margin-top: 6px; }

/* Process flow (marble case study) */
.cs-flow { margin: 22px 0 6px; }
.cs-flow h3 { font-size: 1.05rem; color: var(--hp-blue); margin-bottom: 14px; }
.cs-flow ol { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.cs-flow li { position: relative; counter-increment: step; padding: 0 0 18px 52px; }
.cs-flow li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%; background: var(--hp-navy); color: #fff; font-weight: 700; font-size: .9rem; display: flex; align-items: center; justify-content: center; }
.cs-flow li::after { content: ""; position: absolute; left: 16px; top: 38px; bottom: 2px; width: 2px; background: var(--hp-line); }
.cs-flow li:last-child { padding-bottom: 0; }
.cs-flow li:last-child::after { display: none; }
.cs-flow strong { display: block; color: var(--hp-ink); margin: 5px 0 4px; }
.cs-flow li p { font-size: .97rem; margin: 0; }

.cs-inline-cta { display: flex; align-items: center; justify-content: space-between; gap: 20px; background: var(--hp-navy); border-radius: 18px; padding: 22px 28px; }
.cs-inline-cta p { color: rgba(255, 255, 255, .85); margin: 0; }
.cs-inline-cta strong { color: #fff; }
.cs-inline-cta .hp-btn { flex: 0 0 auto; }

.cs-aside { position: sticky; top: 110px; display: grid; gap: 18px; }
.cs-aside__results { border-radius: 18px; }
.cs-aside__cta { border: 1px solid var(--hp-line); border-radius: 18px; padding: 24px; background: #fff; }
.cs-aside__cta h3 { font-size: 1.15rem; margin-bottom: 6px; }
.cs-aside__cta p { color: var(--hp-muted); font-size: .95rem; margin-bottom: 16px; }
.cs-aside__contact { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 10px; font-size: .93rem; }
.cs-aside__contact li { display: flex; align-items: center; gap: 10px; }
.cs-aside__contact i { color: var(--hp-blue); width: 16px; text-align: center; }
.cs-aside__contact .fa-whatsapp { color: #25d366; }
.cs-aside__contact a { color: var(--hp-ink); }
.cs-aside__contact a:hover { color: var(--hp-blue); }

.cs-more__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

@media (max-width: 991.98px) {
    .cs-aside { position: static; }
}
@media (max-width: 767.98px) {
    .cs-block { padding: 22px; }
    .cs-inline-cta { flex-direction: column; align-items: flex-start; padding: 22px; }
    .cs-more__grid { grid-template-columns: 1fr; }
}
