/* ==========================================================
   Quick View Modal + Wishlist page — Fokus tema
   ========================================================== */

/* ---- Overlay ---- */
.fk-qv-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.fk-qv-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* ---- Modal box ---- */
.fk-qv-modal {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 860px;
    max-height: 90vh;
    overflow-y: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    position: relative;
    transform: translateY(24px) scale(0.97);
    transition: transform 0.25s ease;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
}

.fk-qv-overlay.is-open .fk-qv-modal {
    transform: translateY(0) scale(1);
}

/* ---- Close button ---- */
.fk-qv-close {
    position: sticky;
    top: 14px;
    float: right;
    margin: 14px 14px 0 auto;
    width: 34px;
    height: 34px;
    border: none;
    background: #f0f0f0;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    z-index: 10;
    transition: background 0.15s, color 0.15s;
    grid-column: 1 / -1;
    justify-self: end;
}

.fk-qv-close:hover {
    background: var(--color-accent);
    color: #fff;
}

/* ---- Gallery side ---- */
.fk-qv-gallery {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 4px 20px 28px 28px;
}

.fk-qv-main-img {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 8px;
    background: #f7f7f7;
    flex-shrink: 0;
}

.fk-qv-main-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.18s ease;
}

.fk-qv-thumbs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.fk-qv-thumb {
    width: 52px;
    height: 52px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.15s;
    flex-shrink: 0;
}

.fk-qv-thumb.is-active,
.fk-qv-thumb:hover {
    border-color: var(--color-accent);
}

.fk-qv-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ---- Info side ---- */
.fk-qv-info {
    padding: 20px 28px 28px 20px;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.fk-qv-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 10px;
}

.fk-qv-cat {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--color-text-muted);
    text-decoration: none;
    border: 1px solid var(--color-border, #e6e6e6);
    border-radius: 50px;
    padding: 2px 10px;
    transition: color 0.15s, border-color 0.15s;
}

.fk-qv-cat:hover {
    color: var(--color-accent);
    border-color: var(--color-accent);
}

.fk-qv-title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 6px;
    color: var(--color-text);
}

.fk-qv-title a {
    color: inherit;
    text-decoration: none;
}

.fk-qv-title a:hover {
    color: var(--color-accent);
}

.fk-qv-author {
    font-size: 14px;
    color: var(--color-text-muted);
    margin: 0 0 14px;
}

.fk-qv-price {
    margin: 0 0 16px;
    font-size: 20px;
    font-weight: 700;
    color: var(--color-accent);
    line-height: 1;
    display: flex;
    gap: 8px;
    align-items: baseline;
    flex-wrap: wrap;
}

.fk-qv-price del,
.fk-qv-price del .woocommerce-Price-amount {
    font-size: 14px;
    font-weight: 400;
    color: var(--color-text-muted);
    text-decoration: line-through;
}

.fk-qv-price ins {
    text-decoration: none;
}

.fk-qv-price ins .woocommerce-Price-amount {
    font-size: 20px;
    font-weight: 700;
    color: var(--color-accent);
}

.fk-qv-divider {
    border: none;
    border-top: 1px solid var(--color-border, #e6e6e6);
    margin: 0 0 14px;
}

.fk-qv-desc {
    font-size: 14px;
    line-height: 1.65;
    color: var(--color-text-muted);
    margin: 0 0 20px;
    flex: 1;
}

/* ATC button */
.fk-qv-atc {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px 20px;
    background: #1a1a1a;
    color: #fff;
    font-family: var(--font-primary);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.3px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
    text-align: center;
}

.fk-qv-atc:hover {
    background: var(--color-accent);
    color: #fff;
}

.fk-qv-atc.added {
    background: #15803d;
    color: #fff;
}

.fk-qv-atc--oos {
    background: #aaa;
    cursor: default;
    pointer-events: none;
}

/* Full product link */
.fk-qv-full-link {
    display: block;
    text-align: center;
    font-size: 13px;
    color: var(--color-text-muted);
    margin-top: 10px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.fk-qv-full-link:hover {
    color: var(--color-accent);
}

/* ---- Loading — skeleton + spinner (isti stil kao hero-loader) ---- */

/* Shimmer animacija za gallery */
@keyframes fk-qv-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.fk-qv-modal--loading .fk-qv-main-img {
    background: linear-gradient(90deg, #f0f0f0 25%, #e4e4e4 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: fk-qv-shimmer 1.4s ease-in-out infinite;
}

.fk-qv-modal--loading .fk-qv-main-img img {
    opacity: 0;
}

/* Spinner u info panelu */
.fk-qv-loading-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 220px;
}

.fk-qv-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--color-border, #E6E6E6);
    border-top-color: var(--color-accent, #D65A5A);
    border-radius: 50%;
    animation: fk-qv-spin 0.65s linear infinite;
}

@keyframes fk-qv-spin {
    to { transform: rotate(360deg); }
}

/* ---- Responsive ---- */
@media (max-width: 640px) {
    .fk-qv-modal {
        grid-template-columns: 1fr;
        max-width: 420px;
    }

    .fk-qv-gallery {
        padding: 4px 20px 0;
    }

    .fk-qv-main-img {
        max-height: 260px;
        aspect-ratio: unset;
    }

    .fk-qv-info {
        padding: 12px 20px 24px;
    }
}

/* ==========================================================
   YITH Wishlist — override / cleanup
   ========================================================== */

/* Sakrij YITH "Dodano u wishlist" popup poruku — koristimo naš UI */
.yith-wcwl-popup-message,
.yith-wcwl-message-content {
    display: none !important;
}

/* YITH wishlist page — osnovno sređivanje */
.woocommerce-wishlist table.wishlist_table th,
.woocommerce-wishlist table.wishlist_table td {
    vertical-align: middle;
}

.woocommerce-wishlist table.wishlist_table .product-thumbnail img {
    max-width: 72px;
    border-radius: 4px;
}
