/* ==========================================
   Card Collector - Frontend Styles
   دیزاین مدرن و حرفه‌ای برای نمایش کارت‌ها
   ========================================== */

/* فونت فارسی - وزیرمتن */
@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');

:root {
    --cc-primary: #6366f1;
    --cc-primary-dark: #4f46e5;
    --cc-primary-light: #818cf8;
    --cc-success: #10b981;
    --cc-warning: #f59e0b;
    --cc-error: #ef4444;
    --cc-dark: #1f2937;
    --cc-gray: #6b7280;
    --cc-light: #f9fafb;
    --cc-white: #ffffff;
    --cc-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --cc-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --cc-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --cc-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --cc-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --cc-font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

/* ==========================================
   اعمال فونت وزیرمتن به همه المان‌ها
   ========================================== */

/* اعمال فونت به تمام المان‌های افزونه */
[class^="cc-"],
[class*=" cc-"],
[class^="cc-"] *,
[class*=" cc-"] * {
    font-family: var(--cc-font-family) !important;
}

/* اطمینان از اعمال فونت به المان‌های فرم */
.cc-redeem-container input,
.cc-redeem-container button,
.cc-redeem-container label,
.cc-redeem-container span,
.cc-redeem-container p,
.cc-redeem-container h1,
.cc-redeem-container h2,
.cc-redeem-container h3,
.cc-collection-container input,
.cc-collection-container button,
.cc-collection-container label,
.cc-collection-container span,
.cc-collection-container p,
.cc-collection-container h1,
.cc-collection-container h2,
.cc-collection-container h3,
.cc-user-points-widget input,
.cc-user-points-widget button,
.cc-user-points-widget label,
.cc-user-points-widget span,
.cc-user-points-widget p,
.cc-share-collection-widget input,
.cc-share-collection-widget button,
.cc-share-collection-widget span,
.cc-share-collection-widget p,
.cc-card-details-modal *,
.cc-card-reveal-modal * {
    font-family: var(--cc-font-family) !important;
}

/* ==========================================
   فرم Redeem کارت
   ========================================== */

.cc-redeem-container {
    max-width: 600px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.cc-redeem-form {
    background: var(--cc-white);
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: var(--cc-shadow-lg);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.cc-form-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--cc-dark);
    margin: 0 0 0.5rem;
    text-align: center;
}

.cc-form-description {
    color: var(--cc-gray);
    text-align: center;
    margin: 0 0 2rem;
    line-height: 1.6;
}

.cc-form-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cc-input {
    width: 100%;
    padding: 1rem 1.25rem;
    font-size: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    transition: var(--cc-transition);
    font-family: 'Courier New', monospace;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.cc-input:focus {
    outline: none;
    border-color: var(--cc-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.cc-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--cc-transition);
    text-decoration: none;
}

.cc-button-primary {
    background: linear-gradient(135deg, var(--cc-primary) 0%, var(--cc-primary-dark) 100%);
    color: var(--cc-white);
    box-shadow: var(--cc-shadow-md);
}

.cc-button-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--cc-shadow-lg);
}

.cc-button-primary:active {
    transform: translateY(0);
}

.cc-button-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.cc-button-secondary {
    background: var(--cc-white);
    color: var(--cc-dark);
    border: 2px solid var(--cc-dark);
}

.cc-button-secondary:hover {
    background: var(--cc-dark);
    color: var(--cc-white);
}

.cc-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: cc-spin 0.6s linear infinite;
}

@keyframes cc-spin {
    to { transform: rotate(360deg); }
}

.cc-message-container {
    margin-top: 1rem;
}

.cc-message {
    padding: 1rem 1.25rem;
    border-radius: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.cc-message.cc-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.cc-message.cc-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #ef4444;
}

.cc-message.cc-warning {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #f59e0b;
}

/* ==========================================
   مودال نمایش کارت
   ========================================== */

.cc-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.cc-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    animation: cc-fadeIn 0.3s ease;
}

.cc-modal-content {
    position: relative;
    max-width: 500px;
    width: 100%;
    animation: cc-slideUp 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cc-card-reveal {
    background: var(--cc-white);
    border-radius: 24px;
    padding: 3rem 2rem;
    box-shadow: var(--cc-shadow-xl);
    text-align: center;
}

.cc-confetti {
    position: absolute;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    animation: cc-confettiFall 1s ease-out;
}

.cc-confetti::before {
    content: '🎉✨🎊✨🎉';
}

.cc-reveal-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--cc-dark);
    margin: 0 0 0.5rem;
}

.cc-reveal-subtitle {
    color: var(--cc-gray);
    margin: 0 0 2rem;
}

.cc-card-display {
    margin: 2rem 0;
}

.cc-card-image {
    width: 100%;
    max-width: 300px;
    height: auto;
    border-radius: 16px;
    box-shadow: var(--cc-shadow-lg);
    margin-bottom: 1.5rem;
    animation: cc-cardFlip 0.8s ease;
}

.cc-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cc-dark);
    margin: 0 0 0.5rem;
}

.cc-card-description {
    color: var(--cc-gray);
    line-height: 1.6;
}

/* ==========================================
   کلکشن کاربر
   ========================================== */

.cc-collection-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.cc-collection-header {
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.cc-collection-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--cc-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* فقط برای Shortcodes - نه ویجت‌های المنتور */
.cc-collection-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
}

/* نمایش امتیاز کاربر در هدر */
.cc-user-points-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    box-shadow: var(--cc-shadow-md);
}

.cc-user-points-display .cc-points-icon {
    font-size: 1.5rem;
}

.cc-user-points-display .cc-points-value {
    font-size: 1.5rem;
    font-weight: 800;
}

.cc-user-points-display .cc-points-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* بخش‌های کلکسیون */
.cc-collection-section {
    margin-bottom: 3rem;
}

.cc-collection-section-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--cc-primary);
}

.cc-collection-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cc-dark);
    margin: 0 0 0.5rem;
}

.cc-collection-section-description {
    color: var(--cc-gray);
    margin: 0;
    font-size: 0.95rem;
}

.cc-collection-empty {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--cc-light);
    border-radius: 16px;
    border: 2px dashed #d1d5db;
}

.cc-empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.cc-collection-empty h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cc-dark);
    margin: 0 0 0.5rem;
}

.cc-collection-empty p {
    color: var(--cc-gray);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ==========================================
   گرید کارت‌ها
   ========================================== */

.cc-cards-grid {
    display: grid;
    gap: 2rem;
    margin-bottom: 2rem;
}

.cc-grid-columns-2 {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.cc-grid-columns-3 {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.cc-grid-columns-4 {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

.cc-card-item {
    perspective: 1000px;
    animation: cc-fadeInUp 0.5s ease;
}

.cc-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.cc-card-item:hover .cc-card-inner {
    transform: translateY(-8px);
}

.cc-card-front {
    position: relative;
    border-radius: var(--cc-border-radius, 16px);
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--cc-transition);
}

.cc-card-thumbnail {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.cc-card-placeholder {
    width: 100%;
    height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cc-placeholder-icon {
    font-size: 4rem;
    filter: brightness(1.2);
}

.cc-card-content {
    padding: 1.5rem;
}

.cc-card-name {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.cc-card-excerpt {
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0 0 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cc-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--cc-primary);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--cc-transition);
}

.cc-card-link:hover {
    color: var(--cc-primary-dark);
    gap: 0.75rem;
}

.cc-card-link::after {
    content: '→';
}

.cc-card-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

.cc-badge-unlocked {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* امتیاز کارت */
.cc-card-points-inline {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    width: fit-content;
}

.cc-card-points-inline .cc-points-icon {
    font-size: 1rem;
}

.cc-card-points-badge {
    text-align: center;
    margin-top: 1rem;
    padding: 1rem;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-radius: 12px;
}

.cc-card-points-badge .cc-points-icon {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.5rem;
}

.cc-card-points-badge .cc-points-value {
    font-size: 2rem;
    font-weight: 800;
    color: #92400e;
    display: block;
    margin-bottom: 0.25rem;
}

.cc-card-points-badge .cc-points-label {
    font-size: 0.9rem;
    color: #78350f;
    font-weight: 600;
}

/* ==========================================
   ویجت آمار
   ========================================== */

.cc-card-stats-widget {
    background: var(--cc-white);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--cc-shadow-md);
    margin: 2rem 0;
}

.cc-stats-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--cc-dark);
    margin: 0 0 1.5rem;
}

.cc-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.cc-stat-box {
    background: var(--cc-light);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    transition: var(--cc-transition);
}

.cc-stat-box:hover {
    transform: translateY(-4px);
    box-shadow: var(--cc-shadow-md);
}

.cc-stat-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.cc-stat-value {
    display: block;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--cc-primary);
    margin-bottom: 0.25rem;
}

.cc-stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--cc-gray);
    font-weight: 500;
}

/* ویجت امتیاز کاربر */
.cc-user-points-widget {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: var(--cc-white);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: var(--cc-shadow-lg);
    margin: 2rem 0;
}

.cc-points-display-large {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.cc-points-icon-large {
    font-size: 3rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.cc-points-info {
    display: flex;
    flex-direction: column;
}

.cc-points-value-large {
    font-size: 2.5rem;
    font-weight: 900;
    line-height: 1;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.cc-points-label-large {
    font-size: 1rem;
    opacity: 0.9;
    margin-top: 0.25rem;
}

.cc-user-stats-mini {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.cc-stat-mini {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.15);
    padding: 0.5rem 1rem;
    border-radius: 12px;
}

.cc-stat-mini-icon {
    font-size: 1.25rem;
}

.cc-stat-mini-value {
    font-size: 1.25rem;
    font-weight: 700;
}

.cc-stat-mini-label {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* ==========================================
   انیمیشن‌ها
   ========================================== */

@keyframes cc-fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes cc-slideUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes cc-fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes cc-cardFlip {
    0% {
        transform: rotateY(90deg) scale(0.8);
        opacity: 0;
    }
    50% {
        transform: rotateY(45deg) scale(0.9);
    }
    100% {
        transform: rotateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes cc-confettiFall {
    0% {
        transform: translateX(-50%) translateY(-100px) scale(0);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(-50%) translateY(0) scale(1);
        opacity: 0;
    }
}

/* ==========================================
   حالت تاریک (اختیاری)
   ========================================== */

@media (prefers-color-scheme: dark) {
    :root {
        --cc-dark: #f9fafb;
        --cc-gray: #9ca3af;
        --cc-light: #1f2937;
        --cc-white: #111827;
    }
    
    .cc-card-front,
    .cc-redeem-form,
    .cc-card-reveal,
    .cc-card-stats-widget {
        border-color: #374151;
    }
}

/* ==========================================
   Responsive Design
   ========================================== */

@media (max-width: 768px) {
    .cc-redeem-form {
        padding: 1.5rem;
    }
    
    .cc-form-title {
        font-size: 1.5rem;
    }
    
    .cc-cards-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
    }
    
    .cc-collection-title {
        font-size: 1.5rem;
    }
    
    .cc-modal-content {
        max-width: 100%;
    }
    
    .cc-card-reveal {
        padding: 2rem 1.5rem;
    }
    
    .cc-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   پشتیبانی RTL
   ========================================== */

[dir="rtl"] .cc-card-link::after {
    content: '←';
}

[dir="rtl"] .cc-card-badge {
    right: auto;
    left: 1rem;
}

/* ==========================================
   ویجت اشتراک‌گذاری کلکشن
   ========================================== */

.cc-share-collection-widget {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 2.5rem;
    margin: 2rem 0;
    box-shadow: var(--cc-shadow-xl);
    position: relative;
    overflow: hidden;
}

.cc-share-collection-widget::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.cc-share-header {
    position: relative;
    z-index: 1;
    margin-bottom: 2rem;
    text-align: center;
}

.cc-share-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: white;
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    text-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.cc-share-icon {
    font-size: 2rem;
    animation: swing 2s ease-in-out infinite;
}

@keyframes swing {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(15deg); }
    75% { transform: rotate(-15deg); }
}

.cc-share-description {
    color: rgba(255,255,255,0.9);
    font-size: 1rem;
    margin: 0;
}

.cc-share-link-container {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.cc-share-input {
    flex: 1;
    min-width: 250px;
    padding: 1rem 1.5rem;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 12px;
    color: white;
    font-size: 0.95rem;
    font-family: 'Courier New', monospace;
    transition: var(--cc-transition);
}

.cc-share-input:focus {
    outline: none;
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.5);
}

.cc-share-input::selection {
    background: rgba(255,255,255,0.3);
}

.cc-button-copy {
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(10px);
    color: white;
    border: 2px solid rgba(255,255,255,0.4);
    position: relative;
    overflow: hidden;
}

.cc-button-copy:hover {
    background: rgba(255,255,255,0.35);
    border-color: rgba(255,255,255,0.6);
}

.cc-button-copy.success {
    background: rgba(16, 185, 129, 0.3);
    border-color: rgba(16, 185, 129, 0.6);
}

.cc-copy-icon {
    margin-right: 0.5rem;
}

.cc-share-actions {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.cc-share-actions .cc-button {
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    color: white;
    border: 2px solid rgba(255,255,255,0.3);
}

.cc-share-actions .cc-button:hover {
    background: rgba(255,255,255,0.3);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-3px);
}

@media (max-width: 768px) {
    .cc-share-collection-widget {
        padding: 1.5rem;
    }
    
    .cc-share-link-container {
        flex-direction: column;
    }
    
    .cc-share-input {
        min-width: 100%;
    }
    
    .cc-share-actions {
        flex-direction: column;
    }
    
    .cc-share-actions .cc-button {
        width: 100%;
    }
}

/* ==========================================
   پاپ‌آپ جزئیات کارت
   ========================================== */

.cc-card-details-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 999999;
    padding: 2rem;
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

.cc-card-details-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.cc-card-details-content {
    background: white;
    border-radius: 24px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cc-details-close {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--cc-transition);
    z-index: 10;
}

.cc-details-close:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: rotate(90deg);
}

.cc-details-header {
    position: relative;
    padding: 3rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 24px 24px 0 0;
    color: white;
    text-align: center;
}

.cc-details-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M 20 0 L 0 0 0 20" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    border-radius: 24px 24px 0 0;
}

.cc-details-title {
    position: relative;
    z-index: 1;
    font-size: 2rem;
    font-weight: 800;
    margin: 0 0 0.5rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.cc-details-collection-badge {
    position: relative;
    z-index: 1;
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.cc-details-body {
    padding: 3rem;
}

.cc-details-image-wrapper {
    text-align: center;
    margin-bottom: 2rem;
}

.cc-details-image {
    max-width: 400px;
    width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.cc-details-description {
    margin-bottom: 2rem;
    line-height: 1.8;
    color: #4b5563;
    font-size: 1.05rem;
}

.cc-details-specs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.cc-spec-card {
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    padding: 1.5rem;
    border-radius: 16px;
    text-align: center;
    border: 2px solid transparent;
    transition: var(--cc-transition);
}

.cc-spec-card:hover {
    border-color: #667eea;
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.2);
}

.cc-spec-card-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    display: block;
}

.cc-spec-card-label {
    display: block;
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cc-spec-card-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: #1f2937;
}

.cc-details-footer {
    padding: 2rem 3rem;
    background: #f9fafb;
    border-radius: 0 0 24px 24px;
    text-align: center;
}

.cc-button-view-page {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: var(--cc-transition);
}

.cc-button-view-page:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
}

/* استایل دکمه نمایش جزئیات در کارت */
.cc-card-details-btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--cc-transition);
    margin-top: 1rem;
    width: 100%;
    font-size: 0.95rem;
}

.cc-card-details-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.3);
}

/* حذف لینک قدیمی */
.cc-card-link {
    display: none;
}

@media (max-width: 768px) {
    .cc-card-details-modal {
        padding: 1rem;
    }
    
    .cc-card-details-content {
        max-height: 95vh;
        border-radius: 16px;
    }
    
    .cc-details-header {
        padding: 2rem 1.5rem;
        border-radius: 16px 16px 0 0;
    }
    
    .cc-details-title {
        font-size: 1.5rem;
    }
    
    .cc-details-body {
        padding: 1.5rem;
    }
    
    .cc-details-image {
        max-width: 100%;
    }
    
    .cc-details-specs {
        grid-template-columns: 1fr;
    }
    
    .cc-details-footer {
        padding: 1.5rem;
        border-radius: 0 0 16px 16px;
    }
}
