/* ============================================
   CHARGED SERVICES - CONTENT PAGE STYLES
   Styles specific to service/content pages.
   Requires shared.css to be loaded first.
   ============================================ */

/* Override section-heading weight for content pages */
.section-heading { font-weight: 400; }

/* Wider max-width for section-sub on content pages */
.section-sub { max-width: 560px; }

h1 {text-transform: lowercase;}
h2 {text-transform: lowercase;}

/* ============================================
   SECTION A: PAGE HERO BANNER
   ============================================ */
.page-hero { padding: 160px 40px 80px; position: relative; overflow: hidden; }
.page-hero-bg {
    position: absolute; inset: 0; z-index: 0;
    background:
        radial-gradient(ellipse 70% 50% at 70% 30%, rgba(201,0,0,0.06) 0%, transparent 60%),
        radial-gradient(ellipse 40% 40% at 20% 70%, rgba(190,233,0,0.03) 0%, transparent 50%),
        linear-gradient(to bottom, rgba(10,10,12,0.75), rgba(10,10,12,0.88)),
        var(--hero-img, url('/assets/images/hero/hero-1.jpg'));
    background-size: auto, auto, auto, cover;
    background-position: center, center, center, center;
}
.page-hero-bg::before {
    content: ''; position: absolute; inset: 0;
    background-image: linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
    background-size: 60px 60px;
    -webkit-mask-image: radial-gradient(ellipse 60% 60% at 50% 40%, black, transparent);
    mask-image: radial-gradient(ellipse 60% 60% at 50% 40%, black, transparent);
}
.page-hero-content { position: relative; z-index: 1; max-width: var(--max-w); margin: 0 auto; }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 0.78rem; color: var(--text-muted); margin-bottom: 24px; }
.breadcrumb a { color: var(--text-muted); transition: color 0.2s; }
.breadcrumb a:hover { color: var(--highlight); }
.breadcrumb .sep { color: var(--text-muted); opacity: 0.4; }
.breadcrumb .current { color: var(--text-secondary); }
.page-hero h1 {
    font-family: var(--display); font-size: clamp(2.8rem, 7vw, 5rem);
    font-weight: 400; line-height: 1.1; letter-spacing: -0.025em; max-width: 700px;
    font-style: italic;
    text-transform: lowercase;
}
.page-hero h1 em { font-style: italic; color: var(--highlight); text-transform: lowercase;}
.page-hero-desc { margin-top: 24px; font-size: 1.05rem; color: var(--text-secondary); max-width: 520px; line-height: 1.75; font-weight: 300; }

/* ============================================
   SECTION B: FULL-WIDTH IMAGE BANNER
   ============================================ */
.full-image-section { padding: 0; position: relative; }
.full-image-wrapper { width: 100%; height: clamp(300px, 45vw, 560px); position: relative; overflow: hidden; background: var(--bg-panel); }
.full-image-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.full-image-placeholder {
    width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #161618 0%, #1a1a1f 50%, #111114 100%);
    color: var(--text-muted); font-size: 0.85rem;
    border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.full-image-caption { position: absolute; bottom: 0; left: 0; right: 0; padding: 40px; background: linear-gradient(to top, rgba(17,17,17,0.9) 0%, transparent 100%); }
.full-image-caption p { max-width: var(--max-w); margin: 0 auto; font-size: 0.88rem; color: var(--text-secondary); font-weight: 300; }

/* ============================================
   SECTION C: TEXT + IMAGE SIDE-BY-SIDE (dark)
   ============================================ */
.split-section { border-top: 1px solid var(--border); }
.split-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split-grid.reverse .split-image { order: -1; }
.split-image { border-radius: var(--radius-lg); overflow: hidden; background: var(--bg-panel); border: 1px solid var(--border); aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; }
.split-image img { width: 100%; height: 100%; object-fit: cover; }
.split-image-placeholder { color: var(--text-muted); font-size: 0.82rem; text-align: center; padding: 20px; }
.split-text h2 { font-family: var(--display); font-style: italic; font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 400; line-height: 1.2; letter-spacing: -0.02em; margin-bottom: 20px; }
.split-text h2 em { font-style: italic; color: var(--highlight); }
.split-text p { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.8; font-weight: 300; }
.split-text p + p { margin-top: 16px; }
.split-text .link-arrow { display: inline-flex; align-items: center; gap: 8px; margin-top: 24px; font-size: 0.88rem; font-weight: 500; color: var(--highlight); transition: gap 0.25s; }
.split-text .link-arrow:hover { gap: 14px; }
.split-text .link-arrow svg { width: 16px; height: 16px; }

/* ============================================
   SECTION D: TEXT + IMAGE (INVERTED / LIGHT)
   ============================================ */
.split-section-light { background: var(--bg-light); color: var(--text-dark); border-top: none; }
.split-section-light .section-eyebrow { color: var(--accent); }
.split-section-light .section-eyebrow::before { background: var(--accent); }
.split-section-light .split-text h2 { color: var(--text-dark); }
.split-section-light .split-text h2 em { color: var(--accent); }
.split-section-light .split-text p { color: var(--text-dark-secondary); }
.split-section-light .split-image { background: var(--bg-light-card); border-color: var(--border-light); }
.split-section-light .split-image-placeholder { color: var(--text-dark-muted); }
.split-section-light .split-text .link-arrow { color: var(--accent); }

/* ============================================
   SECTION E: FEATURE / SPEC LIST
   ============================================ */
.features-section { background: var(--bg-panel); border-top: 1px solid var(--border); }
.features-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 48px; }
.feature-item { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px 28px; display: flex; gap: 18px; transition: border-color 0.3s; }
.feature-item:hover { border-color: var(--border-hover); }
.feature-icon { width: 44px; height: 44px; flex-shrink: 0; background: var(--accent-glow); border: 1px solid rgba(201,0,0,0.15); border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.feature-icon svg { width: 20px; height: 20px; stroke: var(--highlight); fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.feature-item h3 { font-size: 1rem; font-weight: 600; margin-bottom: 6px; }
.feature-item p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; }

/* ============================================
   SECTION F: PROJECT SHOWCASE / PORTFOLIO CARDS
   ============================================ */
.showcase-section { border-top: 1px solid var(--border); }
.showcase-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 48px; }
.showcase-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s; }
.showcase-card:hover { border-color: var(--border-hover); transform: translateY(-4px); box-shadow: 0 12px 40px rgba(0,0,0,0.3); }
.showcase-img { width: 100%; aspect-ratio: 16 / 10; background: var(--bg-panel); overflow: hidden; position: relative; }
.showcase-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.showcase-card:hover .showcase-img img { transform: scale(1.04); }
.showcase-img-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.78rem; }
.showcase-badge { position: absolute; top: 12px; left: 12px; padding: 4px 12px; font-size: 0.68rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; border-radius: 100px; }
.badge-before { background: var(--accent); color: #fff; }
.badge-after { background: var(--highlight); color: #111; }
.badge-project { background: rgba(255,255,255,0.1); color: var(--text-secondary); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,0.08); }
.showcase-body { padding: 24px; }
.showcase-body h3 { font-size: 1.05rem; font-weight: 600; margin-bottom: 8px; }
.showcase-body p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; }
.showcase-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.showcase-tag { padding: 3px 12px; font-size: 0.68rem; font-weight: 500; border: 1px solid var(--border); border-radius: 100px; color: var(--text-muted); }


/* ============================================
   SECTION G: FULL-WIDTH IMAGE GALLERY
   ============================================ */
.gallery-section { border-top: 1px solid var(--border); overflow: hidden; }
.gallery-track { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 0 16px; margin-top: 48px; -ms-overflow-style: none; scrollbar-width: thin; scrollbar-color: #333 #1a1a1a; }
.gallery-track::-webkit-scrollbar { height: 6px; }
.gallery-track::-webkit-scrollbar-track { background: #1a1a1a; border-radius: 3px; }
.gallery-track::-webkit-scrollbar-thumb { background: #333; border-radius: 3px; }
.gallery-item { flex: 0 0 auto; width: clamp(260px, 30vw, 380px); aspect-ratio: 4 / 3; border-radius: var(--radius-lg); overflow: hidden; scroll-snap-align: start; background: var(--bg-panel); border: 1px solid var(--border); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; cursor: pointer; transition: transform 0.4s, filter 0.4s; }
.gallery-item:hover img { transform: scale(1.04); filter: brightness(1.1); }
.gallery-item-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.78rem; }

/* ============================================
   GALLERY LIGHTBOX
   Controlled entirely via CSS — JS only toggles
   the .active class and sets the image src.
   ============================================ */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(0,0,0,0.92);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    cursor: zoom-out;
}
.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: var(--radius);
    box-shadow: 0 24px 80px rgba(0,0,0,0.6);
    transform: scale(0.92);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.3s ease;
    cursor: default;
    -webkit-user-select: none;
    user-select: none;
    -webkit-user-drag: none;
}
.lightbox.active .lightbox-img {
    transform: scale(1);
    opacity: 1;
}

/* Close button */
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    color: var(--text);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s;
}
.lightbox-close:hover {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.2);
}

/* Prev / Next navigation */
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 50%;
    color: var(--text);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s;
    opacity: 0;
}
.lightbox.active .lightbox-nav {
    opacity: 1;
    transition: background 0.2s, border-color 0.2s, opacity 0.4s 0.15s;
}
.lightbox-nav:hover {
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.2);
}
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

/* Counter (e.g. 2 / 5) */
.lightbox-counter {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.08em;
    opacity: 0;
}
.lightbox.active .lightbox-counter {
    opacity: 1;
    transition: opacity 0.4s 0.2s;
}

/* Hide nav when only one image */
.lightbox[data-count="1"] .lightbox-nav,
.lightbox[data-count="1"] .lightbox-counter,
.lightbox[data-count="0"] .lightbox-nav,
.lightbox[data-count="0"] .lightbox-counter {
    display: none;
}

/* Responsive lightbox adjustments */
@media (max-width: 860px) {
    .lightbox-img { max-width: 95vw; max-height: 80vh; }
    .lightbox-prev { left: 10px; }
    .lightbox-next { right: 10px; }
    .lightbox-nav { width: 40px; height: 40px; font-size: 1.2rem; }
}
@media (max-width: 560px) {
    .lightbox-nav { width: 36px; height: 36px; font-size: 1rem; }
    .lightbox-close { top: 14px; right: 14px; width: 38px; height: 38px; font-size: 1.3rem; }
}

/* ============================================
   SECTION H: MINI CTA BANNER
   ============================================ */
.mini-cta { background: var(--bg-panel); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: clamp(48px, 8vh, 80px) 40px; }
.mini-cta-inner { max-width: var(--max-w); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.mini-cta-text h2 { font-family: var(--display); font-size: clamp(1.5rem, 3vw, 2.2rem); font-weight: 400; line-height: 1.2; }
.mini-cta-text h2 em { font-style: normal; color: var(--highlight); }
.mini-cta-text p { margin-top: 8px; font-size: 0.92rem; color: var(--text-secondary); font-weight: 300; }
.mini-cta-actions { display: flex; gap: 12px; flex-wrap: wrap; flex-shrink: 0; }

/* ============================================
   RESPONSIVE - CONTENT PAGES
   ============================================ */
@media (max-width: 1024px) {
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .showcase-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
    .page-hero { padding: 140px 24px 60px; }
    .split-grid { grid-template-columns: 1fr; gap: 40px; }
    .split-grid.reverse .split-image { order: 0; }
    .features-grid { grid-template-columns: 1fr; }
    .showcase-grid { grid-template-columns: 1fr; }
    .gallery-track { padding: 0 0 12px; }
    .mini-cta { padding: clamp(40px, 6vh, 60px) 24px; }
    .mini-cta-inner { flex-direction: column; text-align: center; }
    .mini-cta-actions { justify-content: center; }
}
@media (max-width: 560px) {
    .showcase-grid { grid-template-columns: 1fr; }
}
