/* =====================================================
   SERVICE DETAIL – COMMON CSS (FINAL + AUTO SIDEBAR)
   AVM NETWORKS LIMITED
   UX: Glassmorphism | Enterprise | Clean
===================================================== */

/* ================= ROOT ================= */
:root {
    --glass-bg: rgba(255,255,255,0.08);
    --glass-border: rgba(255,255,255,0.18);
    --glass-shadow: 0 20px 45px rgba(0,0,0,0.25);

    --text-main: #e5e7eb;
    --text-soft: #cbd5f5;
    --text-muted: #94a3b8;

    --primary: #38bdf8;
    --primary-dark: #0284c7;

    --warning: rgba(251,191,36,0.15);
    --highlight: rgba(56,189,248,0.15);

    --radius-lg: 22px;
    --radius-md: 16px;
    --radius-sm: 12px;
}

/* ================= CONTAINER ================= */
.service-detail {
    padding: 100px 24px 160px;
}

.service-container {
    max-width: 1320px;
    margin: 0 auto;
}

/* ================= LAYOUT ================= */
.service-layout {
    display: grid;
    grid-template-columns: 320px minmax(0,1fr);
    gap: 56px;
    align-items: flex-start;
}

/* ================= SIDEBAR WRAPPER ================= */
.service-sidebar {
    position: sticky;
    top: 120px;
    width: 320px;
    flex-shrink: 0;
}

/* ================= SIDEBAR BOX (AUTO HEIGHT) ================= */
.service-index {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: var(--glass-shadow);

    padding: 30px 26px;
    display: flex;
    flex-direction: column;
    gap: 16px;

    /* 🔑 IMPORTANT */
    height: auto;
}

/* ================= SIDEBAR LINKS ================= */
.service-index a {
    font-size: 15.5px;            /* ⬅ bigger text */
    line-height: 1.6;
    color: var(--text-muted);
    text-decoration: none;

    padding: 8px 0 8px 16px;
    border-left: 3px solid transparent;
    transition: all .25s ease;
}

.service-index a:hover {
    color: var(--primary);
    border-left-color: rgba(56,189,248,0.4);
}

.service-index a.active {
    color: var(--primary);
    border-left-color: var(--primary);
    font-weight: 600;
}

/* 🔹 AUTO-GENERATED SUB ITEMS (H3 SUPPORT) */
.service-index a.sub-item {
    font-size: 14px;
    padding-left: 28px;
    opacity: 0.85;
}

/* ================= MAIN ================= */
.service-main {
    min-width: 0;
}

/* ================= CONTENT ================= */
.service-content {
    display: flex;
    flex-direction: column;
    gap: 44px;
}

/* ================= SECTION ================= */
.svc-section {
    padding: 44px 48px;
    border-radius: var(--radius-lg);
    scroll-margin-top: 140px;
    text-align: center;
}

/* ================= GLASS ================= */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(18px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

/* ================= HEADINGS ================= */
.svc-title {
    font-size: clamp(2.4rem,4vw,3.1rem);
    margin-bottom: 18px;
}

.service-content h2 {
    font-size: 1.75rem;
    margin-bottom: 16px;
    color: #fff;
}

.service-content h3 {
    font-size: 1.25rem;
    margin: 28px auto 12px;
    color: var(--primary);
}

/* ================= ICON ================= */
.svc-heading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.svc-icon {
    width: 22px;
    height: 22px;
    fill: var(--primary);
}

/* ================= TEXT ================= */
.service-content p {
    font-size: 15.5px;
    line-height: 1.9;
    color: var(--text-soft);
}

.svc-lead {
    font-size: 16.5px;
    color: var(--text-main);
}

.section-desc {
    max-width: 840px;
    margin: 20px auto 0;
    font-size: 15.5px;
    line-height: 1.85;
}

/* ================= LISTS ================= */
.service-content ul {
    list-style: none;
    padding: 0;
    margin: 18px auto 0;
    display: inline-block;
    text-align: left;
}

.service-content li {
    margin-bottom: 8px;
    color: var(--text-soft);
    font-size: 14.5px;
}

.svc-feature-list li {
    position: relative;
    padding-left: 22px;
}

.svc-feature-list li::before {
    content: "●";
    position: absolute;
    left: 0;
    top: 2px;
    font-size: 12px;
    color: var(--primary);
}

/* ================= DIAGRAM ================= */
.svc-diagram {
    max-width: 780px;
    margin: 28px auto 0;
    text-align: center;
}

.svc-diagram pre {
    display: inline-block;
    text-align: left;
}

/* ================= CARDS ================= */
.svc-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(240px,1fr));
    gap: 24px;
    margin-top: 24px;
}

.svc-card {
    padding: 22px 24px;
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.12);
    border: 1px solid var(--glass-border);
    font-size: 14.5px;
    color: #fff;
    transition: transform .35s ease, box-shadow .35s ease;
}

.svc-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 48px rgba(0,0,0,0.45);
}

/* ================= CTA ================= */

/* Make CTA section parent layout */
.svc-cta{
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* existing glow effect preserved */
.svc-cta::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top, rgba(56,189,248,.15), transparent 70%);
    pointer-events: none;
}

/* ALL buttons container (primary + nav) */
.svc-cta-actions{
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    margin-top: 22px;
    flex-wrap: wrap;
}

/* REMOVE visual separation of nav section */
.svc-service-nav{
    border-top: none;
    padding-top: 18px;
    margin-top: 0;
}

/* Merge back & next into same row behavior */
.svc-service-nav-wrap{
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Make nav buttons same height as CTA buttons */
.svc-back,
.svc-next{
    padding: 14px 34px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Back button style */
.svc-back{
    color: var(--text-main);
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.18);
    transition: all .25s ease;
}

.svc-back:hover{
    transform: translateY(-2px);
    background: rgba(255,255,255,.16);
}

/* Next button style */
.svc-next{
    color: #fff;
    background: linear-gradient(135deg,var(--primary),var(--primary-dark));
    box-shadow: 0 12px 30px rgba(56,189,248,.45);
    transition: all .25s ease;
}

.svc-next:hover{
    transform: translateY(-3px);
    box-shadow: 0 18px 44px rgba(56,189,248,.55);
}

/* Mobile */
@media(max-width:768px){
    .svc-cta-actions,
    .svc-service-nav-wrap{
        flex-direction: column;
        width: 100%;
    }

    .svc-cta-actions a,
    .svc-service-nav-wrap a{
        width: 100%;
        text-align: center;
    }
}

/* ===== FORCE NAV CTA INTO SAME BUTTON ROW ===== */

/* remove block behaviour */
.svc-service-nav{
    display: contents;
}

/* make nav buttons behave like CTA buttons */
.svc-service-nav-wrap{
    display: contents;
}

/* ensure same spacing as CTA buttons */
.svc-back,
.svc-next{
    margin: 0 8px;
}

/* keep button size consistent */
.svc-back,
.svc-next,
.svc-cta-actions a{
    height: 48px;
    line-height: 48px;
    padding: 0 28px;
}

/* ================= BUTTONS ================= */
.btn-primary,
.btn-secondary {
    padding: 14px 34px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all .3s ease;
}

.btn-primary {
    background: linear-gradient(135deg,var(--primary),var(--primary-dark));
    color: #fff;
}

.btn-secondary {
    border: 1px solid var(--primary);
    color: var(--primary);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 36px rgba(56,189,248,.55);
}

.btn-secondary:hover {
    background: rgba(56,189,248,.15);
}

/* ================= ANIMATIONS ================= */
.reveal {
    opacity: 1;
}

.reveal.is-visible {
    animation: fadeUp .8s ease both;
}

@keyframes fadeUp {
    from { opacity:0; transform:translateY(32px); }
    to   { opacity:1; transform:translateY(0); }
}

/* ================= RESPONSIVE ================= */
@media (max-width:1024px){
    .service-layout {
        grid-template-columns: 1fr;
    }
    .service-sidebar {
        display:none;
    }
}

@media (max-width:768px){
    .svc-section {
        padding: 28px 24px;
    }
    .svc-title {
        font-size: 2rem;
    }
}
/* ================= TABLE (WHOLESALE SMS COMPARISON) ================= */
.svc-table-wrap {
    margin-top: 28px;
    overflow-x: auto;
}

.svc-table-wrap table {
    width: 100%;
    border-collapse: collapse;
    min-width: 620px;
    background: rgba(255,255,255,0.06);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.svc-table-wrap th,
.svc-table-wrap td {
    padding: 14px 18px;
    text-align: center;
    font-size: 14px;
    color: var(--text-soft);
}

.svc-table-wrap thead {
    background: rgba(56,189,248,0.15);
}

.svc-table-wrap th {
    color: #fff;
    font-weight: 600;
}

.svc-table-wrap tbody tr {
    border-top: 1px solid rgba(255,255,255,0.12);
}

.svc-table-wrap tbody tr:hover {
    background: rgba(255,255,255,0.08);
}
