/* ==========================================================================
   SERVICES PAGE
   ========================================================================== */

.page-wrapper {
    padding-top: 72px;
    min-height: calc(100vh - 200px);
}

.page-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 1rem 1rem 3rem 1rem;
}

.section-header {
    font-size: 2rem;
    color: var(--primary-color);
    margin: 2.5rem 0 1.2rem 0;
    font-weight: 700;
    text-align: center;
}

.section-desc {
    color: var(--text-secondary);
    font-size: 1.08rem;
    margin-bottom: 1.7rem;
    margin-top: -0.7rem;
    max-width: 800px;
    line-height: 1.6;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.loading-message {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
}

/* ==========================================================================
   HORIZONTAL SCROLLER
   ========================================================================== */

.scroller-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-bottom: 2.5rem;
    position: relative;
    gap: 0.4rem;
}

.carousel-viewport {
    overflow: hidden;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
}

.carousel-row {
    display: flex;
    transition: transform 0.35s cubic-bezier(.4,1.2,.6,1);
}

.arrow-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    z-index: 2;
    transition: color 0.18s, opacity 0.15s, box-shadow 0.16s, background 0.17s;
    margin: 0 0.4rem;
    border-radius: 7px;
    opacity: 1;
    outline: none;
    box-shadow: none;
}

.arrow-btn:focus,
.arrow-btn:active {
    background: rgba(142, 99, 243, 0.16);
    border-radius: 7px;
    outline: 2px solid var(--primary-color);
    box-shadow: 0 0 0 1.5px var(--primary-color);
}

.arrow-btn:disabled {
    opacity: 0.45;
    cursor: default;
}

/* Mobile scroll mode */
.mobile-viewport {
    width: 260px;
    max-width: 100vw;
    margin-left: auto;
    margin-right: auto;
    overflow-x: auto;
}

.mobile-carousel-row {
    display: flex;
    gap: 0.5rem;
    width: max-content;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 0.5rem;
    scrollbar-width: none;
}

.mobile-carousel-row::-webkit-scrollbar {
    display: none;
}

.mobile-card {
    width: 260px;
    min-width: 260px;
    max-width: 260px;
    scroll-snap-align: center;
}

/* ==========================================================================
   SERVICE CARDS
   ========================================================================== */

.service-card {
    background: var(--bg-secondary);
    border-radius: 20px;
    box-shadow: 0 4px 18px rgba(30, 24, 64, 0.11);
    padding: 2rem 1.2rem 1.4rem 1.2rem;
    min-width: 220px;
    max-width: 260px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid var(--border-color);
    transition: transform 0.19s, box-shadow 0.19s;
    position: relative;
}

.service-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 24px rgba(30, 24, 64, 0.15);
}

.card-title {
    font-size: 1.17rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.4rem;
    text-align: center;
}

.card-price {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 0.5rem;
    text-align: center;
}

.card-desc {
    font-size: 0.98rem;
    color: var(--text-secondary);
    margin-bottom: 1.2rem;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.card-desc p {
    margin: 0;
}

.full-desc-link-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 0.7rem;
}

.full-desc-link {
    display: inline-block;
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
    font-size: 0.98rem;
    text-decoration: underline;
}

.full-desc-link:hover {
    color: var(--accent);
}

.purchase-btn-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: auto;
}

.purchase-btn {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.7rem 1.3rem;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.17s;
    box-shadow: 0 2px 8px rgba(30, 24, 64, 0.06);
    text-decoration: none;
    text-align: center;
}

.purchase-btn:hover {
    background: var(--accent);
}

/* ==========================================================================
   MODAL
   ========================================================================== */

.modal-overlay {
    position: fixed;
    z-index: 2000;
    inset: 0;
    background: rgba(10, 10, 15, 0.62);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s;
}

.modal-box {
    background: var(--bg-secondary);
    color: var(--text-light);
    padding: 2.2rem 1.5rem 1.4rem 1.5rem;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(30, 24, 64, 0.20);
    max-width: 430px;
    width: 90vw;
    position: relative;
    font-size: 1rem;
    animation: fadeInScale 0.22s;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-title {
    font-size: 1.3rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-align: center;
}

.modal-price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 1rem;
    text-align: center;
}

.modal-description {
    font-size: 0.98rem;
    color: var(--text-secondary);
    margin-bottom: 1.2rem;
    text-align: left;
}

.modal-description p {
    margin-bottom: 0.8rem;
}

.modal-description ul,
.modal-description ol {
    margin-left: 1.5rem;
    margin-bottom: 0.8rem;
}

.modal-description li {
    margin-bottom: 0.4rem;
}

.modal-button-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1.5rem;
}

.modal-close {
    position: absolute;
    right: 1rem;
    top: 1rem;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 2rem;
    cursor: pointer;
    font-weight: bold;
    line-height: 1;
    transition: color 0.13s;
}

.modal-close:hover {
    color: var(--accent);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.98) translateY(18px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */

@media (max-width: 900px) {
    .carousel-viewport {
        width: 540px !important;
        min-width: 540px !important;
        max-width: 540px !important;
    }
}

@media (max-width: 700px) {
    .arrow-btn {
        display: none !important;
    }
}

@media (max-width: 600px) {
    .carousel-viewport {
        display: none !important;
    }

    .mobile-viewport {
        display: block;
    }

    .section-header {
        font-size: 1.7rem;
    }

    .section-desc {
        font-size: 1rem;
    }
}
