/* ====================================================
   Design Catalog, Design Picker Modal, Fullscreen Viewer
   ==================================================== */

/* ─── Design Catalog Grid (Catalog page) ─── */
.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.design-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    cursor: pointer;
}

.design-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.design-card-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.design-card:hover .design-card-img {
    transform: scale(1.04);
}

.design-card-img-wrap {
    overflow: hidden;
    position: relative;
    height: 220px;
}

.design-card-img-wrap .fullscreen-hint {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
    color: white;
    font-size: 14px;
    font-weight: 700;
    gap: 8px;
}

.design-card:hover .fullscreen-hint {
    opacity: 1;
}

.design-card-body {
    padding: 16px;
}

.design-card-name {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 4px;
}

.design-card-cat {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.design-card-price {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary);
    font-family: 'Outfit', sans-serif;
}

.design-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.design-tag {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    background: var(--primary-light);
    color: var(--primary);
    text-transform: uppercase;
}

.design-card-actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
}

/* ─── Select Design Button (in Sales drawer) ─── */
.select-design-btn {
    padding: 4px 12px;
    background: var(--primary);
    color: white;
    font-size: 12px;
    font-weight: 700;
    border-radius: 20px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.select-design-btn.selected {
    background: var(--success);
}

.select-design-btn:hover {
    opacity: 0.85;
}

/* ─── Image Picker Modal ─── */
.design-picker-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

.design-picker-modal {
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    width: 92vw;
    max-width: 1100px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.design-picker-header {
    padding: 20px 28px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.design-picker-header h2 {
    font-size: 20px;
    font-weight: 700;
}

.design-picker-body {
    overflow-y: auto;
    padding: 24px 28px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

/* ─── Fullscreen Image Viewer ─── */
.fullscreen-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    z-index: 4000;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    animation: fadeIn 0.3s ease;
}

.fullscreen-overlay img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.fullscreen-info {
    margin-top: 20px;
    text-align: center;
    color: white;
}

.fullscreen-info h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 6px;
}

.fullscreen-info p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.fullscreen-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.fullscreen-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ─── Design Preview in Drawer ─── */
.drawer-design-preview {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: var(--radius-md);
    cursor: zoom-in;
    transition: var(--transition);
    display: block;
}

.drawer-design-preview:hover {
    opacity: 0.9;
    transform: scale(1.01);
}

.drawer-design-wrap {
    position: relative;
    margin-bottom: 16px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.drawer-design-wrap .zoom-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ─── WhatsApp Share Button ─── */
.whatsapp-share-btn {
    background: #25d366;
    color: white;
    padding: 10px 16px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.whatsapp-share-btn:hover {
    background: #1da851;
    transform: translateY(-1px);
}

/* ─── Design card in picker modal ─── */
.picker-design-card {
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
}

.picker-design-card:hover {
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.picker-design-card.active {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 97, 240, 0.2);
}

.picker-design-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    display: block;
}

.picker-design-card .info {
    padding: 10px 12px;
}

.picker-design-card .info h4 {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 2px;
}

.picker-design-card .info p {
    font-size: 12px;
    color: var(--primary);
    font-weight: 700;
}