/* ============================================================ */
/* ambitiv.com — PAGE: Custom Development                         */
/* Loaded only on /custom page. Place after main styles.css.      */
/* ============================================================ */

/* ===== 1. HERO ===== */
.cst-hero {
    padding: 130px 0 80px;
    position: relative;
    overflow: hidden;
}

.cst-hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.cst-hero-bg::before {
    content: '';
    position: absolute;
    top: -30%;
    right: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, var(--accent-light) 0%, transparent 70%);
}

.cst-hero-bg::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -15%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 97, 70, 0.05) 0%, transparent 70%);
}

.cst-hero-inner {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.cst-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent-light);
    color: var(--accent);
    padding: 8px 16px;
    border-radius: 100px;
    font-family: 'Unbounded', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.cst-hero h1 {
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
}

.cst-hero h1 .accent {
    color: var(--accent);
}

.cst-hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    color: var(--gray);
    margin-bottom: 32px;
    line-height: 1.6;
}

.cst-hero-ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 40px;
}

.cst-hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    padding-top: 28px;
    border-top: 1px solid var(--border);
}

.cst-mini-stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cst-mini-stat strong {
    font-family: 'Unbounded', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1.1;
}

.cst-mini-stat span {
    font-size: 0.85rem;
    color: var(--gray);
}

/* ===== HERO VISUAL: directions card with tabs ===== */
.cst-hero-visual {
    position: relative;
    max-width: 480px;
    margin-left: auto;
    width: 100%;
}

.cst-dirs {
    background: white;
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 8px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.10), 0 4px 12px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: translateY(20px);
    animation: cstDirsIn 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.2s forwards;
}

@keyframes cstDirsIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cst-dirs-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px 10px;
    color: var(--gray);
    font-family: 'Unbounded', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cst-dirs-header i {
    color: var(--accent);
    font-size: 0.95rem;
}

.cst-dirs-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 4px;
}

.cst-dir-tab {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 14px;
    padding: 12px 14px;
    display: grid;
    grid-template-columns: 40px 1fr 16px;
    gap: 14px;
    align-items: center;
    cursor: pointer;
    text-align: left;
    text-decoration: none;
    color: inherit;
    transition: all 0.25s ease;
    font-family: inherit;
    width: 100%;
    opacity: 0;
    transform: translateX(12px);
    animation: cstTabIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.cst-dir-tab:nth-child(1) { animation-delay: 0.35s; }
.cst-dir-tab:nth-child(2) { animation-delay: 0.50s; }
.cst-dir-tab:nth-child(3) { animation-delay: 0.65s; }
.cst-dir-tab:nth-child(4) { animation-delay: 0.80s; }
.cst-dir-tab:nth-child(5) { animation-delay: 0.95s; }

@keyframes cstTabIn {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.cst-dir-tab:hover,
.cst-dir-tab.active {
    background: var(--bg-alt);
    border-color: var(--border);
}

.cst-dir-tab.active {
    background: var(--accent-light);
    border-color: rgba(255, 97, 70, 0.25);
}

.cst-dir-icon {
    width: 40px;
    height: 40px;
    background: white;
    color: var(--accent);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.cst-dir-tab.active .cst-dir-icon {
    background: var(--accent);
    color: white;
    box-shadow: 0 4px 14px rgba(255, 97, 70, 0.35);
}

.cst-dir-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.cst-dir-text strong {
    font-family: 'Unbounded', sans-serif;
    font-size: 0.95rem;
    color: var(--dark);
    font-weight: 700;
    line-height: 1.2;
}

.cst-dir-text span {
    font-size: 0.8rem;
    color: var(--gray);
    line-height: 1.4;
    /* Allow wrap; never overflow */
    overflow-wrap: break-word;
    word-break: normal;
}

.cst-dir-arrow {
    color: var(--gray-light);
    font-size: 0.75rem;
    opacity: 0;
    transform: translateX(-6px);
    transition: all 0.25s ease;
}

.cst-dir-tab:hover .cst-dir-arrow,
.cst-dir-tab.active .cst-dir-arrow {
    color: var(--accent);
    opacity: 1;
    transform: translateX(0);
}

.cst-dirs-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 18px;
    margin: 4px 4px 0;
    border-top: 1px solid var(--border);
    color: var(--dark-light);
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s ease;
}

.cst-dirs-footer:hover {
    color: var(--accent);
}

.cst-dirs-footer i {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

.cst-dirs-footer:hover i {
    transform: translateY(2px);
}

/* ===== 2. TRUST BAR ===== */
.cst-trust {
    padding: 60px 0;
    background: var(--bg-alt);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.cst-trust-inner {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 48px;
    align-items: center;
}

.cst-trust-headline {
    display: flex;
    gap: 16px;
}

.cst-trust-headline i {
    color: var(--accent);
    font-size: 1.6rem;
    opacity: 0.5;
    flex-shrink: 0;
}

.cst-trust-headline p {
    font-family: 'Unbounded', sans-serif;
    font-size: 1.1rem;
    line-height: 1.5;
    color: var(--dark);
}

.cst-trust-headline strong {
    color: var(--accent);
}

.cst-trust-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.cst-trust-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cst-trust-stat strong {
    font-family: 'Unbounded', sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--dark);
    line-height: 1;
}

.cst-trust-stat span {
    font-size: 0.85rem;
    color: var(--gray);
    line-height: 1.4;
}

/* ===== 3. 5 CATEGORIES ===== */
.cst-categories {
    padding: 100px 0;
}

.cst-category {
    background: white;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 24px;
    transition: all 0.3s ease;
    /* Offset for fixed nav so the target isn't hidden under the header */
    scroll-margin-top: 100px;
}

/* Brief highlight when scrolled to via anchor */
.cst-category:target {
    border-color: var(--accent);
    box-shadow: 0 16px 40px rgba(255, 97, 70, 0.18);
    animation: cstCategoryFlash 1.2s ease-out;
}

@keyframes cstCategoryFlash {
    0% {
        background: rgba(255, 97, 70, 0.06);
        transform: scale(1.005);
    }
    100% {
        background: white;
        transform: scale(1);
    }
}

.cst-category:last-child {
    margin-bottom: 0;
}

.cst-category:hover {
    border-color: var(--accent);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.06);
}

.cst-category-header {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 24px;
    align-items: flex-start;
    margin-bottom: 28px;
}

.cst-category-num {
    font-family: 'Unbounded', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 0.9;
    opacity: 0.85;
}

.cst-category-info {
    position: relative;
    padding-left: 0;
}

.cst-category-icon {
    width: 52px;
    height: 52px;
    background: var(--accent-light);
    color: var(--accent);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 16px;
}

.cst-category-info h3 {
    font-size: clamp(1.3rem, 2.5vw, 1.6rem);
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 10px;
    line-height: 1.25;
}

.cst-category-info p {
    color: var(--gray);
    font-size: 1rem;
    line-height: 1.6;
    max-width: 760px;
}

.cst-category-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 32px;
}

.cst-category-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--dark-light);
    font-size: 0.96rem;
    line-height: 1.4;
}

.cst-category-list li i {
    color: var(--accent);
    font-size: 0.85rem;
    flex-shrink: 0;
}

/* ===== 4. TYPICAL PROJECTS ===== */
.cst-projects {
    padding: 100px 0;
    background: var(--bg-alt);
}

.cst-projects-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.cst-project {
    background: white;
    padding: 28px 24px;
    border-radius: 16px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.cst-project:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.08);
}

.cst-project-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-light);
    color: var(--accent);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 16px;
}

.cst-project h3 {
    font-size: 1.02rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--dark);
    line-height: 1.3;
}

.cst-project p {
    color: var(--gray);
    font-size: 0.88rem;
    line-height: 1.55;
    margin-bottom: 18px;
    flex: 1;
}

.cst-project-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
}

.cst-project-meta > span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--dark-light);
    font-size: 0.85rem;
    font-weight: 500;
}

.cst-project-meta > span i {
    color: var(--accent);
    font-size: 0.78rem;
}

.cst-project-tag {
    background: var(--accent-light);
    color: var(--accent);
    padding: 4px 10px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    font-family: 'Unbounded', sans-serif;
}

.cst-projects-note {
    text-align: center;
    color: var(--gray);
    font-size: 1rem;
    line-height: 1.6;
    margin-top: 32px;
}

.cst-projects-note i {
    color: var(--accent);
    margin-right: 6px;
}

.cst-projects-note a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px dashed var(--accent);
}

.cst-projects-note a:hover {
    border-bottom-style: solid;
}

/* ===== 5. TECH STACK ===== */
.cst-stack {
    padding: 100px 0;
}

.cst-stack-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
}

.cst-stack-col {
    background: white;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px 20px;
    transition: all 0.3s ease;
}

.cst-stack-col:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
}

.cst-stack-title {
    font-family: 'Unbounded', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cst-stack-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cst-stack-col ul li {
    color: var(--dark-light);
    font-size: 0.88rem;
    line-height: 1.4;
    padding-left: 12px;
    position: relative;
}

.cst-stack-col ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 9px;
    width: 4px;
    height: 4px;
    background: var(--accent);
    border-radius: 50%;
}

/* ===== 6. PROCESS ===== */
.cst-process {
    padding: 100px 0;
    background: var(--bg-alt);
}

.cst-process-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 18px;
}

.cst-process-step {
    background: white;
    padding: 28px 22px;
    border-radius: 16px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.cst-process-step:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.06);
}

.cst-process-num {
    font-family: 'Unbounded', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    margin-bottom: 16px;
    opacity: 0.85;
}

.cst-process-step h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.cst-process-step p {
    color: var(--gray);
    font-size: 0.88rem;
    line-height: 1.5;
}

/* ===== 7. HOW PRICING WORKS ===== */
.cst-pricing {
    padding: 100px 0;
}

.cst-pricing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 36px;
}

.cst-pricing-factor {
    background: white;
    padding: 32px 28px;
    border-radius: 16px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.cst-pricing-factor:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.06);
}

.cst-pricing-icon {
    width: 52px;
    height: 52px;
    background: var(--accent-light);
    color: var(--accent);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 18px;
}

.cst-pricing-factor h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--dark);
}

.cst-pricing-factor p {
    color: var(--gray);
    font-size: 0.92rem;
    line-height: 1.55;
}

.cst-pricing-note {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 22px 28px;
    background: linear-gradient(135deg, var(--dark) 0%, #2d2d2d 100%);
    border-radius: 16px;
    color: white;
}

.cst-pricing-note i {
    color: var(--accent);
    font-size: 1.6rem;
    flex-shrink: 0;
}

.cst-pricing-note p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    line-height: 1.55;
    margin: 0;
}

.cst-pricing-note strong {
    color: var(--accent);
    font-weight: 600;
}

/* ===== 8. FAQ ===== */
.cst-faq {
    padding: 100px 0;
    background: var(--bg-alt);
}

.cst-faq-list {
    max-width: 880px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cst-faq-item {
    background: white;
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.cst-faq-item[open] {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.cst-faq-item summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 22px 26px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1.02rem;
    color: var(--dark);
    list-style: none;
    transition: color 0.2s ease;
}

.cst-faq-item summary::-webkit-details-marker { display: none; }

.cst-faq-item summary:hover {
    color: var(--accent);
}

.cst-faq-item summary i {
    color: var(--accent);
    font-size: 0.9rem;
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.cst-faq-item[open] summary i {
    transform: rotate(45deg);
}

.cst-faq-item p {
    padding: 0 26px 24px;
    color: var(--gray);
    line-height: 1.65;
    font-size: 0.97rem;
}

.cst-faq-item p strong {
    color: var(--dark);
}

/* ===== CTA form: bigger textarea for custom ===== */
.cst-form-textarea {
    min-height: 140px;
    resize: vertical;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .cst-stack-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .cst-hero-inner,
    .cst-trust-inner {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .cst-hero-visual {
        margin: 0 auto;
    }

    .cst-trust-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .cst-projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cst-process-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .cst-pricing-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cst-stack-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .cst-category {
        padding: 32px;
    }

    .cst-category-header {
        grid-template-columns: 60px 1fr;
        gap: 18px;
    }

    .cst-category-num {
        font-size: 2.6rem;
    }
}

@media (max-width: 768px) {
    .cst-hero {
        padding: 100px 0 60px;
    }

    .cst-categories,
    .cst-projects,
    .cst-stack,
    .cst-process,
    .cst-pricing,
    .cst-faq {
        padding: 60px 0;
    }

    .cst-hero-stats {
        gap: 24px;
    }

    .cst-mini-stat strong {
        font-size: 1.25rem;
    }

    .cst-trust-stats {
        gap: 20px;
    }

    .cst-trust-stat strong {
        font-size: 1.4rem;
    }

    .cst-category {
        padding: 24px 20px;
        border-radius: 16px;
    }

    .cst-category-header {
        grid-template-columns: 1fr;
        gap: 16px;
        margin-bottom: 22px;
    }

    .cst-category-num {
        font-size: 2.4rem;
    }

    .cst-category-list {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .cst-projects-grid,
    .cst-process-grid,
    .cst-pricing-grid,
    .cst-stack-grid {
        grid-template-columns: 1fr;
    }

    .cst-pricing-note {
        flex-direction: column;
        text-align: center;
        padding: 22px;
    }

    /* Hero directions card — compact on mobile */
    .cst-hero-visual {
        max-width: 100%;
    }

    .cst-dirs {
        border-radius: 18px;
        padding: 6px;
    }

    .cst-dirs-header {
        padding: 12px 14px 8px;
        font-size: 0.72rem;
    }

    .cst-dir-tab {
        grid-template-columns: 36px 1fr 14px;
        gap: 10px;
        padding: 10px 12px;
    }

    .cst-dir-icon {
        width: 36px;
        height: 36px;
        font-size: 1rem;
        border-radius: 8px;
    }

    .cst-dir-text strong {
        font-size: 0.92rem;
    }

    .cst-dir-text span {
        font-size: 0.78rem;
    }

    .cst-dirs-footer {
        padding: 12px 14px;
        font-size: 0.82rem;
    }

    .cst-faq-item summary {
        padding: 18px 20px;
        font-size: 0.95rem;
    }

    .cst-faq-item p {
        padding: 0 20px 20px;
        font-size: 0.92rem;
    }
}