/* Container chính */
.hcv-container {
    margin: 20px 0;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Wrapper cho nút */
.hcv-button-wrapper {
    text-align: center;
    position: relative;
}

/* Nút xem nội dung */
.hcv-view-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.hcv-view-button:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: left 0.5s ease;
}

.hcv-view-button:hover:before {
    left: 100%;
}

.hcv-view-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.hcv-view-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.hcv-view-button.hcv-counting {
    animation: pulse-button 1s infinite;
}

@keyframes pulse-button {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Icon trong nút */
.hcv-button-icon {
    font-size: 20px;
}

/* Hiển thị đếm ngược */
.hcv-countdown-display {
    margin-top: 20px;
    font-size: 18px;
    color: #333;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.hcv-countdown-number {
    display: inline-block;
    font-size: 24px;
    font-weight: bold;
    color: #e74c3c;
    min-width: 30px;
    transition: all 0.3s ease;
}

.hcv-countdown-number.hcv-pulse {
    animation: pulse-number 1s infinite;
    color: #c0392b;
}

@keyframes pulse-number {
    0% { 
        transform: scale(1);
        color: #e74c3c;
    }
    50% { 
        transform: scale(1.2);
        color: #c0392b;
    }
    100% { 
        transform: scale(1);
        color: #e74c3c;
    }
}

/* Nội dung ẩn */
.hcv-hidden-content {
    margin-top: 20px;
    padding: 20px;
    background: white;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.hcv-hidden-content.hcv-revealed {
    animation: slideDown 0.5s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Styling cho code blocks */
.hcv-hidden-content pre {
    background: #2d2d2d;
    color: #f8f8f2;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    position: relative;
    margin: 15px 0;
}

.hcv-hidden-content pre code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    line-height: 1.5;
}

.hcv-hidden-content pre code.line-numbers {
    display: block;
    counter-reset: line;
}

.hcv-hidden-content pre code .line-number {
    display: inline-block;
    width: 40px;
    color: #666;
    text-align: right;
    margin-right: 10px;
    user-select: none;
    border-right: 1px solid #444;
    padding-right: 10px;
}

/* Copy button cho code blocks */
.hcv-hidden-content pre::before {
    content: 'Copy';
    position: absolute;
    top: 5px;
    right: 5px;
    padding: 5px 10px;
    background: #444;
    color: white;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.hcv-hidden-content pre:hover::before {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hcv-container {
        padding: 15px;
        margin: 15px 0;
    }
    
    .hcv-view-button {
        padding: 12px 25px;
        font-size: 14px;
        border-radius: 40px;
    }
    
    .hcv-button-icon {
        font-size: 18px;
    }
    
    .hcv-countdown-display {
        font-size: 16px;
    }
    
    .hcv-countdown-number {
        font-size: 20px;
    }
    
    .hcv-hidden-content {
        padding: 15px;
    }
    
    .hcv-hidden-content pre {
        padding: 10px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .hcv-view-button {
        padding: 10px 20px;
        font-size: 13px;
    }
    
    .hcv-button-text {
        display: inline-block;
        max-width: 150px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .hcv-container {
        background: #2d2d2d;
        color: #f8f8f2;
    }
    
    .hcv-countdown-display {
        color: #f8f8f2;
    }
    
    .hcv-hidden-content {
        background: #1e1e1e;
        border-color: #444;
        color: #f8f8f2;
    }
}

/* Print styles */
@media print {
    .hcv-button-wrapper {
        display: none;
    }
    
    .hcv-hidden-content {
        display: block !important;
        box-shadow: none;
        border: 1px solid #ddd;
    }
}