/* Bottle Cap Collection - Frontend Styles */

/* Collection Grid */
.bcc-collection-grid {
    display: grid;
    gap: 30px;
    margin: 40px 0;
}

.bcc-columns-2 { grid-template-columns: repeat(2, 1fr); }
.bcc-columns-3 { grid-template-columns: repeat(3, 1fr); }
.bcc-columns-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1200px) {
    .bcc-columns-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .bcc-columns-3,
    .bcc-columns-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .bcc-collection-grid { grid-template-columns: 1fr; }
}

/* Cap Card */
.bcc-cap-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bcc-cap-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.bcc-cap-image {
    position: relative;
    padding-top: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    overflow: hidden;
}

.bcc-cap-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bcc-no-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bcc-no-image .dashicons {
    font-size: 80px;
    width: 80px;
    height: 80px;
    color: rgba(255,255,255,0.3);
}

/* Rarity Badge */
.bcc-rarity-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(0,0,0,0.7);
    color: #fff;
}

.bcc-rarity-common { background: #95a5a6; }
.bcc-rarity-uncommon { background: #3498db; }
.bcc-rarity-rare { background: #9b59b6; }
.bcc-rarity-very_rare { background: #e67e22; }
.bcc-rarity-unique { background: #f39c12; }

/* Cap Content */
.bcc-cap-content {
    padding: 20px;
}

.bcc-cap-title {
    margin: 0 0 12px 0;
    font-size: 18px;
    line-height: 1.3;
}

.bcc-cap-title a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.bcc-cap-title a:hover {
    color: #667eea;
}

.bcc-cap-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.bcc-cap-meta span {
    padding: 4px 10px;
    background: #ecf0f1;
    border-radius: 4px;
    font-size: 12px;
    color: #7f8c8d;
}

.bcc-cap-quantity {
    margin-bottom: 15px;
    font-size: 14px;
    color: #555;
    font-weight: 500;
}

/* Cap Actions */
.bcc-cap-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bcc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.bcc-wishlist-btn {
    background: #fff;
    border: 2px solid #e74c3c;
    color: #e74c3c;
}

.bcc-wishlist-btn:hover,
.bcc-wishlist-btn.active {
    background: #e74c3c;
    color: #fff;
}

.bcc-exchange-btn {
    background: #3498db;
    color: #fff;
}

.bcc-exchange-btn:hover {
    background: #2980b9;
}

.bcc-buy-btn {
    background: #27ae60;
    color: #fff;
}

.bcc-buy-btn:hover {
    background: #229954;
}

.bcc-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 18px;
    font-weight: 700;
    color: #27ae60;
}

/* Single Cap Page */
.bcc-single-cap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.bcc-single-header {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

@media (max-width: 768px) {
    .bcc-single-header {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.bcc-single-image {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.bcc-single-image img {
    width: 100%;
    height: auto;
    display: block;
}

.bcc-single-info h1 {
    font-size: 36px;
    margin: 0 0 20px 0;
    color: #2c3e50;
}

.bcc-single-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin: 30px 0;
}

.bcc-meta-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.bcc-meta-label {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #7f8c8d;
    margin-bottom: 5px;
}

.bcc-meta-value {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
}

.bcc-single-description {
    margin: 40px 0;
    line-height: 1.8;
    color: #555;
}

/* Modal */
.bcc-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    align-items: center;
    justify-content: center;
}

.bcc-modal.active {
    display: flex;
}

.bcc-modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.bcc-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
}

.bcc-modal-close:hover {
    color: #333;
}

.bcc-modal h2 {
    margin: 0 0 20px 0;
    font-size: 24px;
    color: #2c3e50;
}

.bcc-form-group {
    margin-bottom: 20px;
}

.bcc-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #2c3e50;
}

.bcc-form-group input,
.bcc-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.bcc-form-group input:focus,
.bcc-form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.bcc-form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.bcc-form-submit {
    background: #667eea;
    color: #fff;
    padding: 14px 32px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}

.bcc-form-submit:hover {
    background: #5568d3;
}

.bcc-message {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.bcc-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.bcc-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Filters */
.bcc-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.bcc-filter-item {
    flex: 1;
    min-width: 200px;
}

.bcc-filter-item select {
    width: 100%;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
}

/* Loading */
.bcc-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.pagination a,
.pagination span {
    padding: 10px 16px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    color: #2c3e50;
    text-decoration: none;
    transition: all 0.3s ease;
}

.pagination a:hover {
    background: #667eea;
    border-color: #667eea;
    color: #fff;
}

.pagination .current {
    background: #667eea;
    border-color: #667eea;
    color: #fff;
}
