/* Nael's Coin Collection Styles */

/* Navigation */
.nav-link {
    color: #1565c0;
    text-decoration: none;
    margin-right: 10px;
    padding: 5px 10px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.nav-link:hover {
    background-color: #e3f2fd;
    text-decoration: none;
}

.nav-link.active {
    background-color: #1565c0;
    color: white;
}

.nav-separator {
    color: #666;
    margin: 0 5px;
}

.nav-current {
    color: #666;
    font-style: italic;
}

/* Collections Grid - Main Page */
.collections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.collection-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid #e0e0e0;
}

.collection-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-color: #6ec6ff;
}

.collection-header h2 {
    color: #1565c0;
    margin: 0 0 10px 0;
    font-size: 1.5em;
}

.collection-description {
    color: #666;
    margin: 0 0 15px 0;
    line-height: 1.5;
}

.coin-count {
    display: inline-block;
    background: #6ec6ff;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: bold;
    margin-bottom: 15px;
}

.collection-preview {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.preview-coin {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #ddd;
    transition: border-color 0.3s ease;
}

.preview-coin img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.collection-card:hover .preview-coin {
    border-color: #6ec6ff;
}

.more-coins {
    color: #666;
    font-size: 0.9em;
    font-style: italic;
    margin-left: 10px;
}

.view-collection-btn {
    display: inline-block;
    background: linear-gradient(45deg, #1565c0, #42a5f5);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-top: 10px;
}

.view-collection-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.3);
    text-decoration: none;
    color: white;
}

/* Featured Coins */
.featured-coins {
    margin: 40px 0;
}

.featured-coins h2 {
    color: #1565c0;
    text-align: center;
    margin-bottom: 30px;
    font-size: 2em;
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.featured-coin {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    border: 2px solid #e0e0e0;
}

.featured-coin:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    border-color: #ffd700;
}

.coin-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: linear-gradient(45deg, #f5f5f5, #e0e0e0);
}

.coin-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.featured-coin:hover .coin-image img {
    transform: scale(1.1);
}

/* Collection Stats */
.collection-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    min-width: 120px;
}

.stat-number {
    display: block;
    font-size: 2.5em;
    font-weight: bold;
    color: #1565c0;
    margin-bottom: 5px;
}

.stat-label {
    color: #666;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Coins Grid - Collection Page */
.coins-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.coin-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    border: 2px solid #e0e0e0;
}

.coin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    border-color: #6ec6ff;
}

.coin-details {
    padding: 15px;
}

.coin-details h3 {
    color: #1565c0;
    margin: 0 0 10px 0;
    font-size: 1.3em;
}

.coin-meta {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.year {
    background: #e3f2fd;
    color: #1565c0;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.9em;
    font-weight: bold;
}

.denomination {
    background: #f3e5f5;
    color: #7b1fa2;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.9em;
    font-weight: bold;
}

.mint-mark {
    background: #e8f5e8;
    color: #388e3c;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.9em;
    font-weight: bold;
}

.condition {
    color: #666;
    font-size: 0.9em;
    margin-bottom: 5px;
}

.value {
    color: #d32f2f;
    font-weight: bold;
    font-size: 1.1em;
    margin-bottom: 10px;
}

.coin-description {
    color: #666;
    font-size: 0.9em;
    line-height: 1.4;
    margin: 0;
}

/* Rarity Badges */
.rarity-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.rarity-common {
    background: #81c784;
    color: white;
}

.rarity-uncommon {
    background: #64b5f6;
    color: white;
}

.rarity-rare {
    background: #ffb74d;
    color: white;
}

.rarity-very-rare {
    background: #f06292;
    color: white;
}

.rarity-extremely-rare {
    background: #9c27b0;
    color: white;
}

/* Coin Detail Page */
.coin-detail-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin: 30px 0;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.coin-images {
    text-align: center;
}

.main-image {
    margin-bottom: 20px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    background: linear-gradient(45deg, #f5f5f5, #e0e0e0);
}

.main-image img {
    width: 100%;
    max-width: 500px;
    height: auto;
    display: block;
}

.image-thumbnails {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.thumb {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    cursor: pointer;
    border: 3px solid #ddd;
    transition: border-color 0.3s ease, transform 0.3s ease;
    object-fit: cover;
}

.thumb:hover {
    border-color: #6ec6ff;
    transform: scale(1.05);
}

.thumb.active {
    border-color: #1565c0;
}

.coin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.coin-header h2 {
    color: #1565c0;
    margin: 0;
    font-size: 2em;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #6ec6ff;
}

.info-item label {
    font-weight: bold;
    color: #333;
}

.value-highlight {
    color: #d32f2f;
    font-weight: bold;
    font-size: 1.1em;
}

.coin-description, .coin-history, .coin-specifications {
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.coin-description h3, .coin-history h3, .coin-specifications h3 {
    color: #1565c0;
    margin: 0 0 15px 0;
    font-size: 1.3em;
}

.spec-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
}

.spec-item {
    display: flex;
    justify-content: space-between;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 6px;
}

.spec-item label {
    font-weight: bold;
    color: #333;
}

.related-coins {
    margin: 40px 0;
    text-align: center;
}

.view-all-btn {
    display: inline-block;
    background: linear-gradient(45deg, #1565c0, #42a5f5);
    color: white;
    padding: 12px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 20px 0;
}

.view-all-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.3);
    text-decoration: none;
    color: white;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 20px;
    border-radius: 15px;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 15px;
    right: 20px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover,
.close:focus {
    color: #1565c0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .collections-grid {
        grid-template-columns: 1fr;
    }
    
    .featured-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .coins-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .coin-detail-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .collection-stats {
        gap: 20px;
    }
    
    .stat {
        min-width: 100px;
        padding: 15px;
    }
    
    .coin-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .coin-header h2 {
        font-size: 1.5em;
    }
    
    .modal-content {
        margin: 10% auto;
        width: 95%;
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .coins-grid {
        grid-template-columns: 1fr;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .spec-grid {
        grid-template-columns: 1fr;
    }
    
    .coin-meta {
        justify-content: center;
    }
}

/* Coin Placeholders */
.coinplaceholder {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #ffd700, #ffed4a);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    border: 2px solid #d4a574;
    border-radius: 50%;
    box-shadow: 
        inset 0 2px 4px rgba(0, 0, 0, 0.1),
        0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.coinplaceholder:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 
        inset 0 3px 6px rgba(0, 0, 0, 0.15),
        0 8px 16px rgba(0, 0, 0, 0.3);
}

.preview-coin {
    position: relative;
}