/* Modern template — dark header, sans-serif, card grid. --brand is set per store. */
* { box-sizing: border-box; }
body { margin: 0; background: #fff; color: #111827; font: 16px/1.55 Inter, system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: inherit; }

.topbar { background: color-mix(in srgb, var(--brand) 78%, #000); color: #fff; padding: 14px 16px; display: flex; align-items: center;
    justify-content: space-between; gap: 16px; position: sticky; top: 0; z-index: 5; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-size: 1.1rem; letter-spacing: -.01em; }
.logo { width: 36px; height: 36px; border-radius: 10px; background: #fff; color: var(--brand); display: grid; place-items: center; font-weight: 800; font-size: .85rem; }
.topbar nav { display: flex; gap: 18px; font-size: .95rem; }
.topbar nav a { text-decoration: none; opacity: .85; }
.topbar nav a:hover { opacity: 1; }

.page { max-width: 1200px; margin: 0 auto; padding: 24px 16px 48px; }
.hero { background: linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 55%, #000)); color: #fff; border-radius: 20px;
    padding: 48px 40px; margin-bottom: 36px; }
.hero h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); line-height: 1.1; letter-spacing: -.03em; margin: 0 0 .5rem; max-width: 18ch; }
.hero p { margin: 0; opacity: .85; font-size: 1.05rem; }

.section-title { font-size: 1.35rem; letter-spacing: -.02em; margin: 0 0 16px; }
section { margin-bottom: 36px; }

.featured-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.featured-card { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 14px; background: #F3F4F6; text-decoration: none; }
.featured-card .cover { width: 64px; flex: none; padding: 8px; overflow: hidden; }
.featured-card .cover-title { display: none; }
.featured-card .cover-author { display: none; }
.featured-card strong { display: block; font-size: .95rem; line-height: 1.3; }
.featured-card small { color: #6B7280; }
.featured-card:hover { background: color-mix(in srgb, var(--brand) 10%, #F3F4F6); }

.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.pill { display: inline-block; padding: 7px 16px; border-radius: 999px; border: 1px solid #E5E7EB; text-decoration: none; font-size: .9rem; font-weight: 500; color: #374151; }
.pill:hover { border-color: var(--brand); color: var(--brand); }
.pill.active { background: var(--brand); border-color: var(--brand); color: #fff; }

.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card { border: 1px solid #E5E7EB; border-radius: 16px; overflow: hidden; text-decoration: none; display: flex; flex-direction: column; transition: box-shadow .15s, transform .15s; }
.card:hover { box-shadow: 0 12px 28px rgba(17, 24, 39, .12); transform: translateY(-2px); }
.card .cover { border-radius: 0; aspect-ratio: 4 / 3; }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 2px; }
.card-category { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--brand); }
.card-title { font-weight: 700; line-height: 1.3; }
.card-author { color: #6B7280; font-size: .9rem; }
.card-price { font-weight: 800; margin-top: 6px; }

.cover { aspect-ratio: 2 / 3; background: var(--cover); color: #fff; padding: 18px; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; border-radius: 10px; }
.cover-title { font-weight: 800; font-size: 1.05rem; line-height: 1.2; letter-spacing: -.01em; }
.cover-author { font-size: .75rem; opacity: .8; }
.cover-large { max-width: 320px; width: 100%; box-shadow: 0 20px 40px rgba(17, 24, 39, .2); }
.cover-large .cover-title { font-size: 1.6rem; }

.back { display: inline-block; margin-bottom: 20px; text-decoration: none; color: #6B7280; font-weight: 500; }
.detail { display: grid; grid-template-columns: 320px 1fr; gap: 48px; align-items: start; }
.detail h1 { font-size: 2.25rem; letter-spacing: -.03em; line-height: 1.1; margin: 14px 0 6px; }
.byline { color: #6B7280; margin: 0 0 16px; }
.price { font-size: 1.75rem; font-weight: 800; margin: 0 0 16px; }
.description { color: #374151; max-width: 60ch; }
.buy { font: 700 1rem Inter, system-ui, sans-serif; padding: 14px 32px; border: 0; border-radius: 12px; background: var(--brand); color: #fff; opacity: .55; cursor: not-allowed; }

.platform-footer { text-align: center; padding: 24px 16px; border-top: 1px solid #E5E7EB; color: #6B7280; font-size: .85rem; }

@media (max-width: 1000px) { .grid, .featured-row { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
    .grid, .featured-row, .detail { grid-template-columns: 1fr; }
    .hero { padding: 32px 20px; }
    .card .cover { aspect-ratio: 16 / 9; }
    .detail { gap: 24px; }
    .cover-large { max-width: 240px; }
}
