/* ==========================================
   RUNHAMS DECORATING - INDIVIDUAL SERVICE PAGES (5.5)
   Shared by /commercial, /domestic, /offices, /village-projects.
   Inner hero lives in runhams-global.css (.runhams-page-hero).
   Sections: service detail (white) > FAQs (grey) > related (white)
   > red CTA > quote form (grey) > footer
   Seal swap behaviour: runhams-content.js #5. FAQs use native <details>.
   ========================================== */

.runhams-svc-heading {
    font-size: var(--fs-h2);
    font-weight: 700;
    line-height: 1.15;
    color: var(--ink);
}
.runhams-svc-accent {
    background: linear-gradient(transparent 62%, rgba(217, 15, 15, 0.22) 62%, rgba(217, 15, 15, 0.22) 92%, transparent 92%);
    padding: 0 0.1em;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}

/* ==========================================
   SERVICE DETAIL - white
   ========================================== */
.runhams-svc-intro { background: var(--white); padding: var(--section-y) 0; }
.runhams-svc-intro-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 var(--gutter);
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: clamp(2.5rem, 6vw, 5rem);
    align-items: center;
}
.runhams-svc-intro-content .runhams-svc-heading { margin: 0 0 1.25rem; }
.runhams-svc-intro-text {
    font-size: var(--fs-body);
    color: var(--muted);
    line-height: 1.75;
    margin: 0 0 1rem;
}
.runhams-svc-items {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.7rem;
    margin: 1.5rem 0 2rem;
}
.runhams-svc-items li {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.7rem 0.85rem;
    border-radius: var(--radius);
    background: var(--grey);
    border: 1px solid var(--grey-line);
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--ink);
    line-height: 1.3;
    transition: border-color 0.25s ease, background 0.25s ease;
}
.runhams-svc-items li:hover { background: var(--white); border-color: rgba(217, 15, 15, 0.3); }
.runhams-svc-item-icon {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border-radius: 10px;
    background: var(--brand-grad);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    box-shadow: 0 6px 14px rgba(217, 15, 15, 0.25);
}

/* Photo with red offset block, seals bottom-right */
.runhams-svc-frame {
    position: relative;
    margin: 0 1.25rem 1.25rem 0;
}
.runhams-svc-frame::before {
    content: "";
    position: absolute;
    inset: 1.25rem -1.25rem -1.25rem 1.25rem;
    background: var(--brand-grad);
    border-radius: var(--radius-lg);
}
.runhams-svc-photo {
    position: relative;
    z-index: 1;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: block;
}
.runhams-svc-frame .runhams-dbs-seal,
.runhams-svc-frame .runhams-individual-service-seal-stack { z-index: 3; }

/* ==========================================
   FAQs - grey, accordion
   ========================================== */
.runhams-svc-faq {
    background:
        radial-gradient(700px 380px at 100% 0%, rgba(217, 15, 15, 0.08) 0%, rgba(217, 15, 15, 0) 62%),
        var(--grey);
    padding: var(--section-y) 0;
}
.runhams-svc-faq-inner { max-width: 1000px; margin: 0 auto; padding: 0 var(--gutter); }
.runhams-svc-faq-header { text-align: center; margin-bottom: 2.25rem; }
.runhams-svc-faq-list { columns: 2; column-gap: 0.85rem; }
.runhams-svc-faq-item {
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
    margin-bottom: 0.85rem;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-sm);
    border: 1px solid transparent;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.runhams-svc-faq-item[open] { border-color: rgba(217, 15, 15, 0.3); box-shadow: var(--shadow-md); }
.runhams-svc-faq-q {
    position: relative;
    list-style: none;
    cursor: pointer;
    padding: 1.15rem 3.5rem 1.15rem 1.35rem;
    font-family: var(--font-head);
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--ink);
}
.runhams-svc-faq-q::-webkit-details-marker { display: none; }
.runhams-svc-faq-toggle {
    position: absolute;
    right: 1rem;
    top: 50%;
    width: 30px;
    height: 30px;
    margin-top: -15px;
    border-radius: 50%;
    background: var(--brand-grad);
}
.runhams-svc-faq-toggle::before,
.runhams-svc-faq-toggle::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 12px;
    height: 2px;
    margin: -1px 0 0 -6px;
    background: #fff;
    border-radius: 2px;
    transition: transform 0.3s var(--ease);
}
.runhams-svc-faq-toggle::after { transform: rotate(90deg); }
.runhams-svc-faq-item[open] .runhams-svc-faq-toggle::after { transform: rotate(0deg); }
.runhams-svc-faq-a {
    padding: 0 1.35rem 1.25rem;
    font-size: 1rem;
    color: var(--muted);
    line-height: 1.7;
}

/* ==========================================
   RELATED - white
   ========================================== */
.runhams-svc-related { background: var(--white); padding: var(--section-y) 0; }
.runhams-svc-related-inner { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.runhams-svc-related-inner > .runhams-svc-heading { margin-bottom: 2rem; }
.runhams-svc-related-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.runhams-svc-related-grid--single { grid-template-columns: 1fr; max-width: 760px; }
.runhams-svc-related-card {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background:
        radial-gradient(260px 180px at 100% 0%, rgba(217, 15, 15, 0.28) 0%, rgba(217, 15, 15, 0) 70%),
        var(--charcoal);
    color: #fff;
    text-decoration: none;
    box-shadow: var(--shadow-md);
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.runhams-svc-related-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.runhams-svc-related-media { position: relative; min-height: 220px; overflow: hidden; }
.runhams-svc-related-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--ease);
}
.runhams-svc-related-card:hover .runhams-svc-related-media img { transform: scale(1.05); }
.runhams-svc-related-body { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; padding: 1.6rem 1.5rem; }
.runhams-svc-related-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: var(--brand-grad);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    margin-bottom: 0.35rem;
    box-shadow: 0 8px 18px rgba(217, 15, 15, 0.35);
}
.runhams-svc-related-title { font-family: var(--font-head); font-size: 1.25rem; font-weight: 700; line-height: 1.3; }
.runhams-svc-related-text { font-size: 1rem; line-height: 1.6; color: rgba(255, 255, 255, 0.8); }
.runhams-svc-related-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 0.6rem;
    font-weight: 700;
    color: #fff;
    transition: gap 0.3s var(--ease);
}
.runhams-svc-related-more i { color: var(--brand-light); font-size: 0.85rem; }
.runhams-svc-related-card:hover .runhams-svc-related-more { gap: 0.8rem; }

/* ==========================================
   RED CTA
   ========================================== */
.runhams-svc-cta {
    position: relative;
    overflow: hidden;
    background: var(--brand-grad);
    padding: clamp(3rem, 6vw, 4.5rem) 0;
}
.runhams-svc-cta::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(500px 260px at 100% 0%, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 65%),
        repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0 2px, transparent 2px 22px);
    pointer-events: none;
}
.runhams-svc-cta-inner {
    position: relative;
    z-index: 1;
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 var(--gutter);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem 3rem;
}
.runhams-svc-cta-title { font-size: var(--fs-h2); font-weight: 700; line-height: 1.15; color: #fff; margin: 0 0 0.6rem; }
.runhams-svc-cta-text { font-size: var(--fs-lead); color: rgba(255, 255, 255, 0.92); line-height: 1.6; max-width: 56ch; }
.runhams-svc-cta-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; flex-shrink: 0; }

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1024px) {
    .runhams-svc-related-grid { grid-template-columns: 1fr; max-width: 760px; }
}
@media (max-width: 900px) {
    .runhams-svc-intro-inner { grid-template-columns: 1fr; }
    .runhams-svc-intro-media { max-width: 480px; width: 100%; margin: 0 auto; }
    .runhams-svc-photo { aspect-ratio: 4 / 3; }
    .runhams-svc-faq-list { columns: 1; }
    .runhams-svc-cta-inner { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
    .runhams-svc-items { grid-template-columns: 1fr; }
    .runhams-svc-frame { margin: 0 0.75rem 0.75rem 0; }
    .runhams-svc-frame::before { inset: 0.75rem -0.75rem -0.75rem 0.75rem; }
    .runhams-svc-related-card { grid-template-columns: 1fr; }
    .runhams-svc-related-media { min-height: 0; aspect-ratio: 16 / 9; }
    .runhams-svc-cta-actions { width: 100%; flex-direction: column; }
    .runhams-svc-cta-actions .runhams-btn { justify-content: center; }
    .runhams-page-hero-actions .runhams-btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .runhams-svc-related-card, .runhams-svc-related-media img, .runhams-svc-faq-toggle::after { transition: none; }
    .runhams-svc-related-card:hover { transform: none; }
}

/* DBS seal anchor */
.runhams-individual-service-image { position: relative; }

/* ==========================================
   ACCREDITATION SEAL STACK (DBS + Constructionline Gold)
   Sits bottom-right of the service image. The badge in
   front is fully shown; the other peeks behind it. Tap
   the peeking badge or the arrow button to swap them.
   Only renders on pages whose service image contains the
   .runhams-individual-service-seal-stack markup
   (commercial, offices, village) - domestic keeps its
   single DBS seal untouched.
   ========================================== */

.runhams-individual-service-seal-stack {
    position: absolute;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 3;
}

/* stop any global img{max-width:100%} collapsing the badges inside
   the zero-size absolutely-positioned stack */
.runhams-individual-service-seal-stack img {
    max-width: none;
}

.runhams-individual-service-seal {
    cursor: pointer;
    transform-origin: bottom right;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease, box-shadow 0.35s ease;
}

/* DBS badge within the stack */
.runhams-individual-service-seal-stack .runhams-dbs-seal {
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 1;
    transform: scale(0.92);
    opacity: 0.9;
    box-shadow: none;
}
.runhams-individual-service-seal-stack .runhams-dbs-seal img {
    display: block;
    width: auto;
    height: 116px;
    border-radius: 0;
    box-shadow: none;
}

/* Constructionline Gold square */
.runhams-individual-service-cline-seal {
    position: absolute;
    right: 1.9rem;
    bottom: 1.9rem;
    z-index: 1;
    height: 116px;
    width: auto;
    border-radius: 0;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.22);
    transform: scale(0.92);
    opacity: 0.9;
}

/* Whichever badge is in front */
.runhams-individual-service-seal.is-front {
    z-index: 4;
    transform: scale(1);
    opacity: 1;
}
.runhams-individual-service-cline-seal.is-front {
    box-shadow: 0 9px 24px rgba(0, 0, 0, 0.42);
}

/* Swap button (curved arrow) */
.runhams-individual-service-seal-swap {
    position: absolute;
    right: -8px;
    bottom: 104px;
    z-index: 5;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: linear-gradient(135deg, #ef3a3a 0%, #c41414 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    transition: transform 0.25s ease;
}
.runhams-individual-service-seal-swap:hover {
    transform: scale(1.12) rotate(-30deg);
}
.runhams-individual-service-seal-swap i {
    font-size: 0.8rem;
}

@media (max-width: 768px) {
    .runhams-individual-service-seal-stack .runhams-dbs-seal img { height: 96px; }
    .runhams-individual-service-cline-seal { height: 96px; right: 1.5rem; bottom: 1.5rem; }
    .runhams-individual-service-seal-swap { bottom: 86px; }
}

@media (max-width: 480px) {
    .runhams-individual-service-seal-stack { right: 0.75rem; bottom: 0.75rem; }
    .runhams-individual-service-seal-stack .runhams-dbs-seal img { height: 80px; }
    .runhams-individual-service-cline-seal { height: 80px; right: 1.2rem; bottom: 1.2rem; }
    .runhams-individual-service-seal-swap { bottom: 72px; width: 26px; height: 26px; }
    .runhams-individual-service-seal-swap i { font-size: 0.7rem; }
}
