/* ============================================================
   pixelwerk.media AutoPlugin — Stylesheet v1.0.0
   ============================================================ */

:root {
    --pwap-primary: #1a1a1a;
    --pwap-dark:    #2c2c2c;
    --pwap-gray:    #f4f4f4;
    --pwap-mid:     #e4e4e4;
    --pwap-border:  #d0d0d0;
    --pwap-text:    #333333;
    --pwap-muted:   #777777;
    --pwap-white:   #ffffff;
}

.pwap-wrap {
    font-family: -apple-system, BlinkMacSystemFont, 'Roboto', 'Segoe UI', sans-serif;
    color: var(--pwap-text);
    background: var(--pwap-gray);
    padding-bottom: 32px;
}

/* ── Hero ── */
.pwap-hero {
    background: #1a1a1a;
    padding: 22px 24px 18px;
}
.pwap-hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}
.pwap-page-title {
    font-family: inherit;
    font-size: 26px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .03em;
    line-height: 1.2;
}
.pwap-page-title span { color: #aaa; }
.pwap-hero-sub {
    font-size: 12px;
    color: #999;
    margin-top: 4px;
    font-weight: 300;
}
.pwap-credit {
    font-size: 11px;
    color: rgba(255,255,255,.45);
    text-decoration: none;
    font-weight: 300;
    letter-spacing: .04em;
    transition: color .2s;
    white-space: nowrap;
}
.pwap-credit:hover { color: rgba(255,255,255,.9); }
.pwap-credit strong { font-weight: 500; color: rgba(255,255,255,.65); }

/* ── Filter Panel ── */
.pwap-filter-panel {
    background: #fff;
    border-bottom: 3px solid #1a1a1a;
    padding: 14px 24px;
}
.pwap-filter-inner { max-width: 1100px; margin: 0 auto; }
.pwap-top-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.pwap-search {
    flex: 1;
    min-width: 160px;
    padding: 9px 13px;
    border: 1px solid #d0d0d0;
    border-radius: 2px;
    font-family: inherit;
    font-size: 13px;
    color: #333;
    background: #f4f4f4;
    outline: none;
    transition: border-color .2s;
}
.pwap-search:focus { border-color: #1a1a1a; }
.pwap-search::placeholder { color: #aaa; }

.pwap-filter-toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 16px;
    background: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 2px;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    cursor: pointer;
    white-space: nowrap;
    transition: background .15s;
}
.pwap-filter-toggle:hover,
.pwap-filter-toggle.open { background: #1a1a1a; }
.pwap-chev { transition: transform .2s; }
.pwap-filter-toggle.open .pwap-chev { transform: rotate(180deg); }

.pwap-active-count {
    display: none;
    background: #fff;
    color: #1a1a1a;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 10px;
    font-weight: 700;
    align-items: center;
    justify-content: center;
}
.pwap-active-count.show { display: flex; }

.pwap-count {
    margin-left: auto;
    font-size: 12px;
    color: #777;
    white-space: nowrap;
}
.pwap-count strong { color: #333; font-weight: 500; }

/* Filter tags */
.pwap-tags { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 10px; }
.pwap-tag {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    padding: 4px 10px;
    background: #1a1a1a;
    color: #fff;
    border-radius: 2px;
    font-weight: 500;
}
.pwap-tag button {
    background: none;
    border: none;
    color: #ccc;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 0;
}
.pwap-tag button:hover { color: #fff; }

/* Filter Grid */
.pwap-filter-grid {
    display: none;
    grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
    gap: 10px;
    padding-top: 14px;
    border-top: 1px solid #e4e4e4;
    margin-top: 12px;
}
.pwap-filter-grid.open { display: grid; }
.pwap-filter-group label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #777;
    margin-bottom: 5px;
}
.pwap-select {
    width: 100%;
    padding: 8px 28px 8px 10px;
    border: 1px solid #d0d0d0;
    border-radius: 2px;
    font-family: inherit;
    font-size: 12px;
    color: #333;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23777'/%3E%3C/svg%3E") no-repeat right 10px center;
    appearance: none;
    outline: none;
    cursor: pointer;
}
.pwap-select:focus { border-color: #1a1a1a; }
.pwap-filter-footer {
    display: flex;
    justify-content: flex-end;
    padding-top: 10px;
    border-top: 1px solid #e4e4e4;
    margin-top: 4px;
}
.pwap-reset-btn {
    padding: 7px 14px;
    border: 1px solid #d0d0d0;
    border-radius: 2px;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
    cursor: pointer;
    color: #777;
    background: transparent;
    transition: all .15s;
}
.pwap-reset-btn:hover { background: #1a1a1a; color: #fff; border-color: #1a1a1a; }

/* ── Grid ── */
.pwap-grid {
    max-width: 1280px;
    margin: 0 auto;
    padding: 18px 20px 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 22px;
}
@media (max-width: 900px) {
    .pwap-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── Card ── */
.pwap-card {
    background: #fff;
    border: 1px solid #d0d0d0;
    border-radius: 2px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .2s, box-shadow .2s;
}
.pwap-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,.12);
}
.pwap-bar { height: 3px; background: var(--pwap-primary, #1a1a1a); }

.pwap-img-wrap {
    position: relative;
    height: 220px;
    background: #ddd;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pwap-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s;
}
.pwap-img-wrap:hover .pwap-main-img { transform: scale(1.03); }

.pwap-zoom-hint {
    position: absolute;
    top: 7px;
    right: 7px;
    background: rgba(0,0,0,.5);
    border-radius: 2px;
    padding: 3px 7px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    color: #fff;
    font-weight: 500;
    opacity: 0;
    transition: opacity .2s;
    pointer-events: none;
}
.pwap-img-wrap:hover .pwap-zoom-hint { opacity: 1; }

.pwap-no-img {
    font-size: 48px;
    opacity: .25;
}
.pwap-badge {
    position: absolute;
    top: 0;
    left: 0;
    background: var(--pwap-primary, #1a1a1a);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    padding: 5px 10px;
}
.pwap-dots {
    position: absolute;
    bottom: 7px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 5px;
    pointer-events: none;
}
.pwap-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,.5);
}
.pwap-dot.on { background: #fff; }

.pwap-body {
    padding: 13px 13px 11px;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.pwap-make {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #2c2c2c;
    margin-bottom: 2px;
}
.pwap-model {
    font-family: inherit;
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: .01em;
    line-height: 1.2;
    margin-bottom: 2px;
}
.pwap-sub {
    font-size: 11px;
    color: #777;
    font-weight: 300;
    margin-bottom: 9px;
}
.pwap-specs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 11px;
}
.pwap-spec {
    font-size: 10px;
    padding: 3px 7px;
    background: #f4f4f4;
    border: 1px solid #e4e4e4;
    color: #333;
    border-radius: 1px;
}
.pwap-divider {
    height: 1px;
    background: #e4e4e4;
    margin: 0 -13px 11px;
}
.pwap-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    flex-wrap: wrap;
    gap: 6px;
}
.pwap-price {
    font-family: inherit;
    font-size: 20px;
    font-weight: 700;
    color: var(--pwap-primary, #1a1a1a);
}
.pwap-price-note {
    font-size: 9px;
    color: #777;
    display: block;
    margin-top: 1px;
}
.pwap-btns { display: flex; gap: 5px; flex-wrap: wrap; }

/* Buttons */
.pwap-btn {
    padding: 8px 11px;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 1px;
    border: none;
    transition: all .15s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    line-height: 1;
}
.pwap-btn-dark { background: var(--pwap-primary, #1a1a1a); color: #fff; }
.pwap-btn-dark:hover { background: #2c2c2c; color: #fff; }
.pwap-btn-outline {
    background: transparent;
    border: 1px solid #d0d0d0;
    color: #333;
}
.pwap-btn-outline:hover { background: #f4f4f4; color: #333; }

/* ── Empty / Error ── */
.pwap-empty,
.pwap-no-results {
    max-width: 1100px;
    margin: 0 auto;
    padding: 48px 20px;
    text-align: center;
    color: #777;
    font-size: 15px;
}
.pwap-no-results strong {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 6px;
    text-transform: uppercase;
}
.pwap-error-box {
    background: #fff3f3;
    border: 1px solid #f5c6c6;
    border-left: 4px solid #c0392b;
    border-radius: 2px;
    padding: 16px;
    color: #721c24;
    max-width: 1100px;
    margin: 16px auto;
}

/* ── Pagination ── */
.pwap-pagination {
    display: flex;
    justify-content: center;
    gap: 4px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}
.pwap-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid #d0d0d0;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    color: #333;
    background: #fff;
    border-radius: 1px;
    transition: all .15s;
}
.pwap-page-btn:hover,
.pwap-page-active {
    background: var(--pwap-primary, #1a1a1a);
    color: #fff;
    border-color: var(--pwap-primary, #1a1a1a);
}

/* ── Lightbox ── */
.pwap-lb {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.95);
    z-index: 999999;
    flex-direction: column;
}
.pwap-lb.open { display: flex; }
.pwap-lb-top {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    background: rgba(0,0,0,.5);
}
.pwap-lb-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.pwap-lb-count { font-size: 12px; color: #aaa; margin-left: 10px; }
.pwap-lb-close {
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.25);
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
    line-height: 1;
}
.pwap-lb-close:hover { background: rgba(255,255,255,.28); }
.pwap-lb-stage {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    touch-action: pan-y;
}
.pwap-lb-stage img {
    max-width: calc(100% - 120px);
    max-height: 100%;
    object-fit: contain;
    display: block;
    pointer-events: none;
    user-select: none;
}
.pwap-lb-arr {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 2px;
    color: #fff;
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 28px;
    transition: background .15s;
    z-index: 10;
    line-height: 1;
}
.pwap-lb-arr:hover { background: rgba(255,255,255,.28); }
.pwap-lb-arr-l { left: 12px; }
.pwap-lb-arr-r { right: 12px; }
.pwap-lb-thumbs {
    flex-shrink: 0;
    display: flex;
    gap: 7px;
    padding: 10px 16px;
    overflow-x: auto;
    justify-content: center;
    background: rgba(0,0,0,.4);
}
.pwap-lb-thumb {
    width: 66px;
    height: 48px;
    object-fit: cover;
    border-radius: 1px;
    cursor: pointer;
    opacity: .4;
    border: 2px solid transparent;
    transition: all .15s;
    flex-shrink: 0;
}
.pwap-lb-thumb:hover { opacity: .8; }
.pwap-lb-thumb.on { opacity: 1; border-color: #fff; }

/* ── Responsive ── */
}
.pwap-show-mobile { display: none; }
@media (max-width: 600px) {
    .pwap-grid { grid-template-columns: 1fr; padding: 14px 10px 0; gap: 10px; }
    .pwap-img-wrap { aspect-ratio: 4 / 3; height: auto; background: #f3f3f3; }
    .pwap-main-img { object-fit: contain; }
    .pwap-model { font-size: 13px; }
    .pwap-sub { display: none; }
    .pwap-price { font-size: 15px; }
    .pwap-hide-mobile { display: none !important; }
    .pwap-show-mobile { display: inline-flex !important; }
    .pwap-btn-more { font-size: 9px; padding: 7px 8px; }
    .pwap-filter-panel { padding: 12px 14px; }
    .pwap-hero { padding: 16px 14px; }
    .pwap-page-title { font-size: 20px; }
    .pwap-filter-grid { grid-template-columns: 1fr 1fr; }
    .pwap-lb-stage img { max-width: calc(100% - 90px); }
    .pwap-lb-arr { width: 36px; height: 36px; font-size: 20px; }
    .pwap-lb-arr-l { left: 6px; }
    .pwap-lb-arr-r { right: 6px; }
}
