/*
 * KSATRIA Store design system.
 * Shared by /store (listing) and /store/:slug (detail). Self-contained: no
 * bootstrap/main.css. Light theme to match the homepage; one accent gradient.
 *
 * Radius rule: interactive controls are full pills, surfaces are 20px,
 * inner tiles 14px.
 */

:root {
    --st-bg: #f6f5fc;
    --st-bg-tint: #efedfb;
    --st-surface: #ffffff;
    --st-ink: #111013;
    --st-ink-2: #2e2d33;
    --st-muted: #66646f;
    --st-subtle: #9a98a6;
    --st-line: rgba(17, 16, 19, 0.08);
    --st-line-strong: rgba(17, 16, 19, 0.14);
    --st-violet: #5b3fd6;
    --st-violet-soft: rgba(91, 63, 214, 0.08);
    --st-success: #13795b;
    --st-success-soft: rgba(19, 121, 91, 0.09);
    --st-warn: #a4520b;
    --st-warn-soft: rgba(164, 82, 11, 0.09);
    --st-danger: #b42318;
    --st-danger-soft: rgba(180, 35, 24, 0.08);
    --st-gradient: linear-gradient(230deg, #ff994b 6.7%, #d34be9 48.83%, #3188ff 90.96%);
    --st-shadow-sm: 0 1px 2px rgba(38, 24, 94, 0.05);
    --st-shadow: 0 1px 2px rgba(38, 24, 94, 0.04), 0 12px 32px -16px rgba(38, 24, 94, 0.18);
    --st-shadow-lg: 0 2px 4px rgba(38, 24, 94, 0.04), 0 28px 60px -28px rgba(38, 24, 94, 0.32);
    --st-radius: 20px;
    --st-radius-sm: 14px;
    --st-ease: cubic-bezier(0.16, 1, 0.3, 1);
    --st-font: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --st-display: 'Phudu', 'Inter', ui-sans-serif, system-ui, sans-serif;
    --st-container: 1240px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body.st-body {
    margin: 0;
    min-height: 100vh;
    background: var(--st-bg);
    color: var(--st-ink-2);
    font-family: var(--st-font);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.st-body img {
    max-width: 100%;
    height: auto;
    display: block;
}

.st-body a {
    color: inherit;
}

/* Link-buttons must keep their own colours over the generic link reset. */
.st-body a.st-btn--primary,
.st-body a.st-btn--primary:hover {
    color: #fff;
}

.st-body a.st-btn--ghost {
    color: var(--st-ink);
}

.st-body h1,
.st-body h2,
.st-body h3,
.st-body h4,
.st-body p {
    margin: 0;
}

.st-container {
    width: 100%;
    max-width: var(--st-container);
    margin: 0 auto;
    padding: 0 24px;
}

.st-visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Typography */
.st-display {
    font-family: var(--st-display);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    line-height: 0.95;
    color: var(--st-ink);
}

.st-h2 {
    font-size: clamp(26px, 3vw, 34px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.025em;
    color: var(--st-ink);
}

.st-lead {
    max-width: 60ch;
    color: var(--st-muted);
    font-size: 17px;
    line-height: 1.65;
}

.st-num {
    font-variant-numeric: tabular-nums;
    font-feature-settings: 'tnum' 1;
}

/* Buttons */
.st-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    height: 48px;
    padding: 0 24px;
    border: 1px solid transparent;
    border-radius: 999px;
    font: 600 15px/1 var(--st-font);
    letter-spacing: -0.01em;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: transform 0.2s var(--st-ease), background-color 0.2s ease, box-shadow 0.3s var(--st-ease), color 0.2s ease, border-color 0.2s ease;
}

.st-btn:active {
    transform: translateY(1px) scale(0.99);
}

.st-btn:focus-visible,
.st-chip:focus-visible,
.st-input:focus-visible,
.st-card:focus-within {
    outline: 2px solid var(--st-violet);
    outline-offset: 2px;
}

.st-btn svg {
    width: 18px;
    height: 18px;
    flex: none;
}

.st-btn--primary {
    background: var(--st-ink);
    color: #fff;
    box-shadow: 0 10px 24px -12px rgba(17, 16, 19, 0.6);
}

.st-btn--primary:hover {
    background: #2a2633;
    color: #fff;
}

.st-btn--primary:disabled {
    background: #b9b7c2;
    box-shadow: none;
    cursor: not-allowed;
}

.st-btn--ghost {
    background: var(--st-surface);
    border-color: var(--st-line-strong);
    color: var(--st-ink);
}

.st-btn--ghost:hover {
    border-color: var(--st-ink);
}

.st-btn--block {
    width: 100%;
}

.st-btn--lg {
    height: 56px;
    font-size: 16px;
}

/* Chips */
.st-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 16px;
    border: 1px solid var(--st-line-strong);
    border-radius: 999px;
    background: var(--st-surface);
    color: var(--st-ink-2);
    font: 500 14px/1 var(--st-font);
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.st-chip:hover {
    border-color: var(--st-ink);
}

.st-chip[aria-pressed="true"],
.st-chip.is-active {
    background: var(--st-ink);
    border-color: var(--st-ink);
    color: #fff;
}

.st-chip__count {
    min-width: 22px;
    padding: 3px 7px;
    border-radius: 999px;
    background: var(--st-violet-soft);
    color: var(--st-violet);
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

.st-chip[aria-pressed="true"] .st-chip__count,
.st-chip.is-active .st-chip__count {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
}

/* Badges */
.st-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.st-badge--save {
    background: var(--st-success-soft);
    color: var(--st-success);
}

.st-badge--popular {
    background: var(--st-ink);
    color: #fff;
}

.st-badge--low {
    background: var(--st-warn-soft);
    color: var(--st-warn);
}

.st-badge--out {
    background: var(--st-danger-soft);
    color: var(--st-danger);
}

.st-badge--soft {
    background: var(--st-violet-soft);
    color: var(--st-violet);
}

/* Price block: small label, large tabular figure, cadence underneath. */
.st-price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 10px;
}

.st-price__amount {
    color: var(--st-ink);
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.st-price__currency {
    margin-right: 3px;
    font-size: 0.62em;
    font-weight: 600;
    letter-spacing: 0;
    vertical-align: 0.42em;
    color: var(--st-muted);
}

.st-price__was {
    color: var(--st-subtle);
    font-size: 14px;
    text-decoration: line-through;
}

.st-price__cadence {
    flex-basis: 100%;
    color: var(--st-muted);
    font-size: 13px;
}

/*
 * Category art: services have no product photos, so each category gets a
 * generated mesh-gradient tile with its icon. Colour per category is set by
 * data-art on the element.
 */
.st-art {
    --art-a: #c9b8ff;
    --art-b: #ffd3b5;
    --art-c: #b8dcff;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    border-radius: var(--st-radius-sm);
    background:
        radial-gradient(120% 90% at 0% 0%, var(--art-a) 0%, transparent 55%),
        radial-gradient(90% 90% at 100% 10%, var(--art-b) 0%, transparent 60%),
        radial-gradient(110% 100% at 60% 110%, var(--art-c) 0%, transparent 60%),
        #f1eefc;
}

.st-art::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: radial-gradient(rgba(17, 16, 19, 0.09) 1px, transparent 1px);
    background-size: 16px 16px;
    -webkit-mask-image: linear-gradient(160deg, transparent 20%, #000 90%);
    mask-image: linear-gradient(160deg, transparent 20%, #000 90%);
}

.st-art[data-art="website"] {
    --art-a: #c7b6ff;
    --art-b: #ffc9a8;
    --art-c: #a9d2ff;
}

.st-art[data-art="mobile"] {
    --art-a: #ffb8e4;
    --art-b: #c4b5ff;
    --art-c: #ffd9a8;
}

.st-art[data-art="marketing"] {
    --art-a: #ffd0a1;
    --art-b: #ffb3c7;
    --art-c: #c9b9ff;
}

.st-art[data-art="support"] {
    --art-a: #a9e0d1;
    --art-b: #b9c8ff;
    --art-c: #d9c2ff;
}

.st-art__icon {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 12px 24px -14px rgba(38, 24, 94, 0.45);
    color: var(--st-ink);
}

.st-art__icon svg {
    width: 30px;
    height: 30px;
}

/* Inputs */
.st-field {
    display: grid;
    gap: 6px;
}

.st-label {
    color: var(--st-ink-2);
    font-size: 14px;
    font-weight: 500;
}

.st-label .st-optional {
    color: var(--st-subtle);
    font-weight: 400;
}

.st-input {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border: 1px solid var(--st-line-strong);
    border-radius: 12px;
    background: var(--st-surface);
    color: var(--st-ink);
    font: 400 15px/1.4 var(--st-font);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

textarea.st-input {
    height: auto;
    min-height: 88px;
    padding: 12px 16px;
    resize: vertical;
}

.st-input::placeholder {
    color: #8f8d99;
}

.st-input:hover {
    border-color: rgba(17, 16, 19, 0.28);
}

.st-input:focus {
    outline: none;
    border-color: var(--st-violet);
    box-shadow: 0 0 0 4px rgba(91, 63, 214, 0.14);
}

.st-input[aria-invalid="true"] {
    border-color: var(--st-danger);
}

.st-help {
    color: var(--st-muted);
    font-size: 13px;
}

.st-error {
    color: var(--st-danger);
    font-size: 13px;
}

.st-alert {
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.5;
}

.st-alert--error {
    background: var(--st-danger-soft);
    color: var(--st-danger);
}

/* Skeletons */
.st-skeleton {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    background: #e9e6f5;
}

.st-skeleton::after {
    content: '';
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    animation: st-shimmer 1.4s infinite;
}

@keyframes st-shimmer {
    to {
        transform: translateX(100%);
    }
}

/* Section helpers */
.st-section {
    padding: 72px 0;
}

.st-surface {
    border: 1px solid var(--st-line);
    border-radius: var(--st-radius);
    background: var(--st-surface);
    box-shadow: var(--st-shadow-sm);
}

/* FAQ (details/summary) */
.st-faq {
    display: grid;
    gap: 10px;
}

.st-faq details {
    border: 1px solid var(--st-line);
    border-radius: 16px;
    background: var(--st-surface);
    transition: box-shadow 0.3s var(--st-ease);
}

.st-faq details[open] {
    box-shadow: var(--st-shadow);
}

.st-faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    color: var(--st-ink);
    font-weight: 600;
    list-style: none;
    cursor: pointer;
}

.st-faq summary::-webkit-details-marker {
    display: none;
}

.st-faq summary::after {
    content: '';
    flex: none;
    width: 10px;
    height: 10px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-3px);
    transition: transform 0.3s var(--st-ease);
}

.st-faq details[open] summary::after {
    transform: rotate(-135deg) translateY(-1px);
}

.st-faq details > div {
    padding: 0 20px 18px;
    color: var(--st-muted);
    font-size: 15px;
}

/* Store footer */
.st-footer {
    margin-top: 40px;
    padding: 32px 0 40px;
    border-top: 1px solid var(--st-line);
    color: var(--st-muted);
    font-size: 14px;
}

.st-footer__row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.st-footer a {
    color: var(--st-ink-2);
    text-decoration: none;
}

.st-footer a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.st-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

/* Reveal on scroll (opt-in; content is visible without JS). */
@media (prefers-reduced-motion: no-preference) {
    .js-reveal .st-reveal {
        opacity: 0;
        transform: translateY(14px);
        transition: opacity 0.6s var(--st-ease), transform 0.6s var(--st-ease);
        transition-delay: calc(var(--i, 0) * 60ms);
    }

    .js-reveal .st-reveal.is-in {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@media (max-width: 575.98px) {
    .st-container {
        padding: 0 16px;
    }

    .st-section {
        padding: 48px 0;
    }
}
