/* Marketplace home + product detail pages (layered on style.css) */

/* ── Home hero ── */
.mp-hero {
    background: linear-gradient(135deg, var(--dark) 0%, #1e293b 50%, var(--primary-dark) 100%);
    color: #fff;
    padding: 150px 0 110px;
    position: relative;
    overflow: hidden;
    text-align: center;
}
.mp-hero::before, .mp-hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}
.mp-hero::before {
    width: 460px; height: 460px; top: -160px; right: -100px;
    background: radial-gradient(circle, rgba(13, 148, 136, 0.35) 0%, transparent 70%);
}
.mp-hero::after {
    width: 380px; height: 380px; bottom: -160px; left: -80px;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.22) 0%, transparent 70%);
}
.mp-hero .container { position: relative; z-index: 1; }
.mp-hero h1 { font-size: clamp(2rem, 4.8vw, 3.4rem); font-weight: 800; line-height: 1.15; margin: 1rem auto; max-width: 820px; }
.mp-hero h1 .highlight { color: var(--accent); }
.mp-hero p.lead-text { color: rgba(255, 255, 255, 0.8); max-width: 680px; margin: 0 auto 2rem; font-size: 1.1rem; line-height: 1.7; }
.mp-hero .section-label { background: rgba(255, 255, 255, 0.12); color: #fff; }
.mp-trust { display: flex; flex-wrap: wrap; gap: 0.6rem 1.75rem; justify-content: center; margin-top: 2.25rem; font-size: 0.88rem; font-weight: 600; color: rgba(255, 255, 255, 0.75); }
.mp-trust i { color: var(--primary-light); margin-right: 0.4rem; }

/* ── Product cards ── */
.mp-products { margin-top: -60px; position: relative; z-index: 2; padding-top: 0; }
.mp-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 12px;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.mp-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.mp-thumb {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    background: #e2e8f0;
    display: block;
}
.mp-thumb img { width: 100%; object-position: top; transition: transform 0.6s ease; }
.mp-card:hover .mp-thumb img { transform: scale(1.05); }
.mp-thumb.mp-thumb-app {
    background: linear-gradient(135deg, #0f766e 0%, #1e3a8a 100%);
    display: flex; align-items: center; justify-content: center; color: #fff;
}
.mp-thumb-app .phone {
    width: 92px; height: 170px; border: 5px solid rgba(255, 255, 255, 0.9); border-radius: 22px;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
    background: rgba(255, 255, 255, 0.12); font-size: 1.5rem;
}
.mp-thumb-app .phone i:nth-child(2) { font-size: 1.1rem; opacity: 0.8; }
.mp-thumb-app .float-ico { position: absolute; font-size: 1.6rem; opacity: 0.35; }
.mp-price {
    position: absolute; right: 0; bottom: 14px;
    background: linear-gradient(135deg, #7c3aed, #c026d3);
    color: #fff; font-weight: 800; font-size: 1.15rem; padding: 0.45rem 1.1rem 0.45rem 1.4rem;
    clip-path: polygon(14px 0, 100% 0, 100% 100%, 0 100%);
    border-radius: 0 0 0 0;
}
.mp-price.mp-price-free { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); }
.mp-body { padding: 1.25rem 0.75rem 0.5rem; display: flex; flex-direction: column; flex: 1; }
.mp-cat { font-size: 0.85rem; font-weight: 600; color: var(--text); margin-bottom: 0.35rem; }
.mp-title { font-size: 1.2rem; font-weight: 800; color: var(--dark); line-height: 1.35; margin-bottom: 0.6rem; }
.mp-title a { color: inherit; text-decoration: none; }
.mp-title a:hover { color: var(--primary); }
.mp-desc { font-size: 0.9rem; line-height: 1.65; color: var(--text); margin-bottom: 1rem; }
.mp-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.25rem; }
.mp-tags span { font-size: 0.75rem; font-weight: 600; background: var(--bg-light); border: 1px solid var(--border); color: var(--dark); border-radius: 999px; padding: 0.25rem 0.7rem; }
.mp-tags span i { color: var(--primary); margin-right: 0.3rem; }
.mp-actions { display: flex; gap: 0.6rem; margin-top: auto; padding-bottom: 0.5rem; }
.mp-actions .btn { flex: 1; padding: 0.65rem 1rem; font-size: 0.9rem; }
.mp-actions { align-items: center; }
.mp-actions .btn-primary-custom { flex: 0 0 auto; }
.mp-buy { flex: 1; line-height: 1.2; }
.mp-buy-price { font-size: 1.6rem; font-weight: 800; color: var(--dark); }
.mp-buy-old { font-size: 1rem; font-weight: 700; color: var(--text-light); margin-left: 0.3rem; text-decoration: line-through; text-decoration-color: #ef4444; text-decoration-thickness: 2px; }
.mp-buy-rating { color: #f5a623; font-size: 0.85rem; margin: 0.15rem 0; }
.mp-buy-rating span { color: var(--text); font-size: 0.8rem; margin-left: 0.2rem; }
.mp-buy-sales { font-size: 0.8rem; color: var(--text); }
.mp-actions .btn-cart { flex: 0 0 auto; width: 46px; padding: 0; display: inline-flex; align-items: center; justify-content: center; }
.mp-badge {
    position: absolute; left: 12px; top: 12px; z-index: 1;
    background: var(--accent); color: var(--dark); font-size: 0.7rem; font-weight: 800; letter-spacing: 0.04em;
    text-transform: uppercase; padding: 0.3rem 0.7rem; border-radius: 6px;
}

/* ── Home extras ── */
.mp-why-icon {
    width: 56px; height: 56px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center;
    background: rgba(13, 148, 136, 0.1); color: var(--primary); font-size: 1.4rem; margin-bottom: 1rem;
}
.mp-why h5 { font-weight: 800; color: var(--dark); font-size: 1.05rem; }
.mp-why p { font-size: 0.9rem; margin-bottom: 0; }

/* ── Product detail page ── */
.pd-header { padding: 130px 0 50px; }
.pd-header h1 { font-size: clamp(1.7rem, 3.6vw, 2.2rem); }
.pd-meta { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 0.6rem 1.5rem; margin-top: 1.25rem; font-size: 0.88rem; font-weight: 600; color: rgba(255, 255, 255, 0.8); }
.pd-meta i { color: var(--primary-light); margin-right: 0.4rem; }
.pd-rating {
    position: relative; z-index: 1; display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem;
    margin-top: 0.25rem; padding: 0.5rem 1rem; border-radius: 999px;
    background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.14);
    font-size: 0.9rem; font-weight: 600; color: rgba(255, 255, 255, 0.85);
}
.pd-rating-stars { color: #fbbf24; letter-spacing: 1px; }
.pd-rating-sep { width: 1px; height: 16px; background: rgba(255, 255, 255, 0.25); }
.pd-rating-sales i { color: var(--primary-light); margin-right: 0.4rem; }

.pd-preview { border-radius: 16px; overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow-md); background: #fff; }
.pd-preview img { width: 100%; display: block; }
.pd-preview-app {
    background: linear-gradient(135deg, #0f766e 0%, #1e3a8a 100%);
    aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; gap: 1.5rem; color: #fff; padding: 1rem;
}
.pd-preview-app .phone {
    width: 120px; height: 220px; border: 6px solid rgba(255, 255, 255, 0.92); border-radius: 26px; background: rgba(255, 255, 255, 0.12);
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; font-size: 1.8rem;
}
.pd-preview-app .phone.sm { transform: scale(0.85); opacity: 0.7; }
.pd-preview-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.25rem 0 0; }

.pd-content { padding: 2rem 0 0; display: flex; flex-direction: column; gap: 1.5rem; }
.pd-card {
    background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.75rem 2rem;
    box-shadow: var(--shadow-sm); scroll-margin-top: 100px;
}
.pd-card-title {
    display: flex; align-items: center; gap: 0.75rem; font-size: 1.2rem; font-weight: 800; color: var(--dark);
    padding-bottom: 1rem; margin-bottom: 1.25rem; border-bottom: 1px solid var(--border);
}
.pd-card-title i {
    width: 40px; height: 40px; border-radius: 11px; background: rgba(13, 148, 136, 0.1); color: var(--primary);
    display: inline-flex; align-items: center; justify-content: center; font-size: 1rem;
}
.pd-card#tab-notincluded .pd-card-title i { background: rgba(239, 68, 68, 0.1); color: #ef4444; }
.pd-card > p:last-child, .pd-card > .pd-feature-group:last-child { margin-bottom: 0; }
.pd-preview img[data-zoom], .pd-preview.zoomable { cursor: zoom-in; }
.pd-zoom-hint { position: absolute; right: 12px; bottom: 12px; background: rgba(15, 23, 42, 0.75); color: #fff; font-size: 0.78rem; font-weight: 600; padding: 0.35rem 0.7rem; border-radius: 999px; pointer-events: none; }
.pd-preview { position: relative; }

/* Screenshot gallery modal */
.gallery-modal .modal-content { background: #0b1220; border: none; border-radius: 16px; overflow: hidden; }
.gallery-modal .modal-header { border: none; color: #fff; padding: 0.9rem 1.25rem; }
.gallery-modal .modal-title { font-size: 1rem; font-weight: 700; }
.gallery-modal .gallery-count { font-size: 0.85rem; color: rgba(255, 255, 255, 0.6); margin-left: 0.75rem; font-weight: 500; }
.gallery-modal .carousel-item img { width: 100%; max-height: 74vh; object-fit: contain; background: #0b1220; }
.gallery-modal .carousel-caption { position: static; padding: 0.75rem 1rem 1.25rem; color: #fff; font-weight: 600; font-size: 0.95rem; }
.gallery-modal .carousel-control-prev, .gallery-modal .carousel-control-next { width: 8%; }
.gallery-modal .carousel-control-prev-icon, .gallery-modal .carousel-control-next-icon { background-color: rgba(255, 255, 255, 0.18); border-radius: 50%; padding: 1.1rem; background-size: 50%; }
/* App screenshot carousel (product-mobile-app.html) */
.shots-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.shots-tabs { display: inline-flex; gap: 0.25rem; padding: 0.25rem; background: var(--bg-light); border: 1px solid var(--border); border-radius: 999px; }
.shots-tabs button {
    border: 0; background: transparent; color: var(--text); font-weight: 700; font-size: 0.85rem;
    padding: 0.45rem 0.95rem; border-radius: 999px; transition: background .2s, color .2s;
}
.shots-tabs button span { font-weight: 600; opacity: 0.6; margin-left: 0.25rem; }
.shots-tabs button:hover { color: var(--primary); }
.shots-tabs button.active { background: var(--primary); color: #fff; box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3); }
.shots-tabs button.active span { opacity: 0.85; }
.shots-nav { display: inline-flex; gap: 0.5rem; }
.shots-nav button {
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border); background: #fff; color: var(--dark);
    display: inline-flex; align-items: center; justify-content: center; transition: all .2s;
}
.shots-nav button:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.shots-nav button:disabled { opacity: 0.35; cursor: default; }
.shots-track {
    display: flex; gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
    padding: 0.5rem 0.25rem 1rem; margin: 0 -0.25rem; scrollbar-width: thin; overscroll-behavior-x: contain;
}
.shots-track::-webkit-scrollbar { height: 6px; }
.shots-track::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }
.shot {
    flex: 0 0 calc((100% - 3rem) / 4); scroll-snap-align: start; position: relative; border: 0; padding: 0; background: none;
    text-align: center; cursor: zoom-in;
}
.shot.is-hidden { display: none; }
.shot-frame {
    display: block; position: relative; border-radius: 22px; overflow: hidden; background: #e2e8f0;
    border: 5px solid #0f172a; box-shadow: 0 10px 24px rgba(15, 23, 42, 0.14); aspect-ratio: 9 / 20;
    transition: transform .25s ease, box-shadow .25s ease;
}
.shot-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot-zoom {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(15, 23, 42, 0.35);
    color: #fff; font-size: 1.4rem; opacity: 0; transition: opacity .25s;
}
.shot:hover .shot-frame, .shot:focus-visible .shot-frame { transform: translateY(-4px); box-shadow: 0 16px 32px rgba(15, 23, 42, 0.2); }
.shot:hover .shot-zoom, .shot:focus-visible .shot-zoom { opacity: 1; }
.shot-cap { display: block; margin-top: 0.6rem; font-size: 0.82rem; font-weight: 700; color: var(--dark); line-height: 1.3; }
.shot-tag { display: block; font-size: 0.72rem; font-weight: 600; color: var(--text-light); }
.shots-hint { margin: 0.25rem 0 0; font-size: 0.82rem; color: var(--text-light); text-align: center; }
@media (max-width: 991.98px) { .shot { flex-basis: calc((100% - 2rem) / 3); } }
@media (max-width: 575.98px) {
    .shot { flex-basis: 44%; }
    .shots-toolbar { justify-content: center; }
    .shots-nav { display: none; }
    .shots-tabs button { padding: 0.4rem 0.7rem; font-size: 0.8rem; }
    .pd-card#tab-screens { padding: 1.25rem 1rem; }
}
/* Portrait phone shots in the zoom modal: narrower dialog, taller image */
.gallery-modal.is-portrait .modal-dialog { max-width: 520px; }
.gallery-modal.is-portrait .carousel-item img { max-height: 80vh; }

.pd-content h3 { font-size: 1.25rem; font-weight: 800; color: var(--dark); margin: .25rem 0 0.9rem; }
.pd-content h3:first-child { margin-top: 0; }
.pd-content p { line-height: 1.8; }

.pd-feature-group { margin-bottom: 1.75rem; }
.pd-feature-group h4 { font-size: 1rem; font-weight: 800; color: var(--dark); margin-bottom: 0.75rem; display: flex; align-items: center; gap: 0.6rem; }
.pd-feature-group h4 i { width: 34px; height: 34px; border-radius: 9px; background: rgba(13, 148, 136, 0.1); color: var(--primary); display: inline-flex; align-items: center; justify-content: center; font-size: 0.9rem; }
.pd-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.55rem 1.5rem; }
.pd-list li { font-size: 0.92rem; display: flex; gap: 0.6rem; align-items: flex-start; line-height: 1.5; }
.pd-list li i { color: var(--primary); margin-top: 0.3rem; font-size: 0.8rem; }
.pd-list.no li { color: var(--text-light); }
.pd-list.no li i { color: #ef4444; }
.pd-note { background: var(--bg-light); border: 1px solid var(--border); border-left: 4px solid var(--accent); border-radius: 10px; padding: 1rem 1.25rem; font-size: 0.9rem; }

.pd-shot { margin-bottom: 1.75rem; }
.pd-shot img { width: 100%; border-radius: 12px; border: 1px solid var(--border); box-shadow: var(--shadow-sm); }
.pd-shot figcaption { font-size: 0.85rem; font-weight: 600; margin-top: 0.6rem; color: var(--dark); }

/* Sidebar */
.pd-sidebar { position: sticky; top: 90px; }
.pd-buy {
    background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.75rem; box-shadow: var(--shadow-md);
}
.pd-buy .license { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--primary); }
.pd-buy .amount { font-size: 3rem; font-weight: 800; color: var(--dark); line-height: 1; margin: 0.5rem 0 0.25rem; }
.pd-buy .amount sup { font-size: 1.2rem; top: -1.1rem; margin-right: 2px; }
.pd-buy .amount-row { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.25rem 0.75rem; }
.pd-buy .amount-old { font-size: 1.5rem; font-weight: 700; color: var(--text-light); text-decoration: line-through; text-decoration-color: #ef4444; text-decoration-thickness: 2px; }
.pd-buy .amount-save { font-size: 0.75rem; font-weight: 800; color: #fff; background: #ef4444; padding: 0.25rem 0.6rem; border-radius: 999px; align-self: center; }
.pd-buy .amount-note { font-size: 0.85rem; color: var(--text-light); margin-bottom: 1.25rem; }
.pd-buy ul { list-style: none; padding: 0; margin: 0 0 1.5rem; }
.pd-buy ul li { font-size: 0.9rem; padding: 0.45rem 0; border-top: 1px dashed var(--border); display: flex; gap: 0.6rem; }
.pd-buy ul li i { color: var(--primary); margin-top: 0.3rem; font-size: 0.8rem; }
.pd-buy .btn { width: 100%; margin-bottom: 0.6rem; padding: 0.8rem 1rem; }

.pd-info { margin-top: 1.25rem; background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.25rem 1.5rem; }
.pd-info h6 { font-weight: 800; color: var(--dark); margin-bottom: 0.75rem; }
.pd-info dl { margin: 0; }
.pd-info dl div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.5rem 0; border-top: 1px solid var(--border); font-size: 0.88rem; }
.pd-info dl div:first-child { border-top: none; }
.pd-info dt { font-weight: 600; color: var(--text-light); }
.pd-info dd { margin: 0; font-weight: 700; color: var(--dark); text-align: right; }

/* Related products */
.pd-related-card { display: flex; gap: 1rem; align-items: center; background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 0.9rem; text-decoration: none; transition: all 0.25s; height: 100%; }
.pd-related-card:hover { border-color: var(--primary); box-shadow: var(--shadow-sm); transform: translateY(-3px); }
.pd-related-card .ico { width: 52px; height: 52px; border-radius: 12px; background: rgba(13, 148, 136, 0.1); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; flex: 0 0 auto; }
.pd-related-card strong { display: block; color: var(--dark); font-size: 0.95rem; }
.pd-related-card span { font-size: 0.82rem; color: var(--text); }

@media (max-width: 991.98px) {
    .pd-sidebar { position: static; margin-top: 2rem; }
    .mp-hero { padding: 120px 0 100px; }
}
@media (max-width: 575.98px) {
    .pd-list { grid-template-columns: 1fr; }
    .pd-buy .amount { font-size: 2.5rem; }
}
