/* =========================================================
   PARALLAX DIVIDER — between About and Services
   ========================================================= */

.parallax-divider {
    position: relative;
    height: 380px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.parallax-divider__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 120%;
    object-fit: cover;
    object-position: center 30%;
    z-index: 0;
    /* CSS-only parallax-like effect */
    transform: translateZ(0);
    will-change: transform;
}

.parallax-divider__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(51,51,51,0.82) 0%, rgba(195,160,75,0.25) 100%);
    z-index: 1;
}

.parallax-divider__content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 40px;
}

.parallax-divider__quote {
    display: block;
    font-family: var(--font-heading);
    font-size: clamp(1.3rem, 3vw, 2.2rem);
    font-style: italic;
    font-weight: 400;
    color: var(--white);
    line-height: 1.5;
    margin-bottom: 16px;
    text-shadow: 0 2px 12px rgba(0,0,0,0.3);
}

.parallax-divider__author {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gold-light);
}

@media (max-width: 768px) {
    .parallax-divider {
        height: 280px;
    }
}

@media (max-width: 480px) {
    .parallax-divider {
        height: 220px;
    }

    .parallax-divider__content {
        padding: 24px;
    }
}

/* =========================================================
   SERVICES — Zakres Usług
   7-card grid: sliding gold rule hover, dark bg contrast
   ========================================================= */

.services {
    background: var(--bg);
    padding: var(--section-py) 0;
    position: relative;
}

/* Decorative corner line */
.services::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 120px;
    height: 2px;
    background: var(--gold);
    opacity: 0.4;
}

.services__header {
    text-align: center;
    margin-bottom: 64px;
}

.services__heading {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    font-weight: 700;
    color: var(--graphite-dark);
    margin-bottom: 16px;
}

.services__sub {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--gray);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ─── Card grid ─── */
/* 4 + 3 layout: 4 cards first row, 3 centered second row */
.services__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* Last 3 cards pushed to center in a subgrid */
.services__grid-row2 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    /* Center the row within the 4-col layout */
    margin-left: calc((100% + 20px) / 8);
    margin-right: calc((100% + 20px) / 8);
}

/* Simpler approach: use 4-col grid and span last row */
/* Override to a simpler 3+4 approach */
.services__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* ─── Card ─── */
.service-card {
    background: var(--white);
    padding: 36px 28px 28px;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--gray-light);
    transition: transform 0.3s var(--ease-out),
                box-shadow 0.3s var(--ease-out),
                border-color 0.3s ease;
    display: flex;
    flex-direction: column;
}

/* Gold rule that slides in from left */
.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--gold);
    transition: width 0.4s var(--ease-out);
}

.service-card:hover::before {
    width: 100%;
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 48px rgba(80, 80, 80, 0.12);
    border-color: rgba(195, 160, 75, 0.3);
}

/* Card number (decorative, top-right) */
.service-card__num {
    position: absolute;
    top: 20px;
    right: 22px;
    font-family: var(--font-display);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: rgba(195, 160, 75, 0.25);
    transition: color 0.3s ease;
}

.service-card:hover .service-card__num {
    color: rgba(195, 160, 75, 0.6);
}

/* Icon */
.service-card__icon {
    width: 48px;
    height: 48px;
    margin-bottom: 20px;
    color: var(--gold);
    flex-shrink: 0;
    transition: transform 0.3s var(--ease-out);
}

.service-card:hover .service-card__icon {
    transform: scale(1.1);
}

/* Title */
.service-card__title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--graphite-dark);
    margin-bottom: 12px;
    line-height: 1.3;
}

/* Description */
.service-card__desc {
    font-family: var(--font-body);
    font-size: 0.82rem;
    color: var(--graphite);
    line-height: 1.7;
    margin-bottom: 24px;
    flex: 1;
}

/* Link */
.service-card__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gold);
    text-decoration: none;
    transition: gap 0.25s ease, opacity 0.2s ease;
    margin-top: auto;
}

.service-card__link::after {
    content: '→';
    transition: transform 0.25s ease;
}

.service-card:hover .service-card__link {
    gap: 12px;
}

.service-card:hover .service-card__link::after {
    transform: translateX(4px);
}

/* ─── CTA Strip below grid ─── */
.services__cta {
    text-align: center;
    margin-top: 48px;
}

.services__cta-text {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 20px;
}

/* ─── Responsive ─── */
@media (max-width: 900px) {
    .services__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 580px) {
    .services__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .service-card {
        padding: 28px 22px 22px;
    }
}
