/**
 * UniTV Recarga - Cards Theme
 * 
 * Tema visual com cards limpos, imagem no topo,
 * preço riscado, botão customizável e fundo branco/cinza claro.
 *
 * @package UniTV_Recarga
 * @since   1.4.0
 */

/* ==========================================================================
   Cards Grid Layout
   ========================================================================== */

.unitv-theme-cards .unitv-cards-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
    padding: 20px 0;
}

/* ==========================================================================
   Card Item
   ========================================================================== */

.unitv-theme-cards .unitv-card-item {
    flex: 0 1 280px;
    max-width: 320px;
}

.unitv-theme-cards .unitv-card-inner {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 32px 24px 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: box-shadow 0.25s ease, transform 0.25s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.unitv-theme-cards .unitv-card-inner:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* ==========================================================================
   Card Image
   ========================================================================== */

.unitv-theme-cards .unitv-card-image {
    margin-bottom: 8px;
}

.unitv-theme-cards .unitv-card-image img {
    display: block;
    object-fit: contain;
    border-radius: 8px;
}

/* ==========================================================================
   Card Title
   ========================================================================== */

.unitv-theme-cards .unitv-card-title {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 20px;
    font-weight: 400;
    color: #1f2937;
    line-height: 1.3;
    margin: 0 0 4px 0;
    padding: 0;
}

.unitv-theme-cards .unitv-card-title b,
.unitv-theme-cards .unitv-card-title strong {
    font-weight: 800;
}

/* ==========================================================================
   Card Info Lines
   ========================================================================== */

.unitv-theme-cards .unitv-card-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 8px;
    width: 100%;
}

.unitv-theme-cards .unitv-card-info-line {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    padding: 0;
    line-height: 1.5;
}

/* ==========================================================================
   Card Old Price (strikethrough)
   ========================================================================== */

.unitv-theme-cards .unitv-card-old-price {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    text-decoration: line-through;
    margin: 4px 0 0 0;
    line-height: 1;
}

/* ==========================================================================
   Card Price
   ========================================================================== */

.unitv-theme-cards .unitv-card-price {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.1;
    margin: 0 0 12px 0;
}

/* ==========================================================================
   Card Button
   ========================================================================== */

.unitv-theme-cards .unitv-card-button {
    display: inline-block;
    width: 100%;
    max-width: 260px;
    padding: 14px 24px;
    text-align: center;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 700;
    letter-spacing: 0.5px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.unitv-theme-cards .unitv-card-button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.unitv-theme-cards .unitv-card-button:active {
    transform: translateY(0);
}

.unitv-theme-cards .unitv-card-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ==========================================================================
   Modal overrides for Cards theme
   ========================================================================== */

/* Cards theme uses the clean/white look for the modal too */
.unitv-theme-cards .unitv-modal-content {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
}

.unitv-theme-cards .unitv-modal-header {
    border-bottom-color: #e5e7eb !important;
}

.unitv-theme-cards .unitv-modal-title {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-modal-subtitle {
    color: #6b7280 !important;
}

.unitv-theme-cards .unitv-form-label {
    color: #374151 !important;
}

.unitv-theme-cards .unitv-form-input {
    background: #f9fafb !important;
    border-color: #d1d5db !important;
    color: #1f2937 !important;
}

.unitv-theme-cards .unitv-form-input:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}

.unitv-theme-cards .unitv-form-input-wrapper i,
.unitv-theme-cards .unitv-form-input-wrapper svg {
    color: #9ca3af !important;
}

.unitv-theme-cards .unitv-submit-button {
    background: linear-gradient(to right, #10b981, #14b8a6) !important;
}

.unitv-theme-cards .unitv-security-badge {
    color: #6b7280 !important;
}

.unitv-theme-cards .unitv-security-badge i,
.unitv-theme-cards .unitv-security-badge svg {
    color: #10b981 !important;
}

.unitv-theme-cards .unitv-loading-text {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-loading-subtext {
    color: #6b7280 !important;
}

.unitv-theme-cards .unitv-pix-title {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-pix-subtitle {
    color: #6b7280 !important;
}

.unitv-theme-cards .unitv-qr-wrapper {
    background: #ffffff !important;
    border-color: #e5e7eb !important;
}

.unitv-theme-cards .unitv-copy-code-input {
    background: #f9fafb !important;
    border-color: #d1d5db !important;
    color: #1f2937 !important;
}

.unitv-theme-cards .unitv-copy-button {
    background: #f3f4f6 !important;
    color: #4b5563 !important;
}

.unitv-theme-cards .unitv-waiting-notice {
    background: #f0fdf4 !important;
    border-color: #86efac !important;
}

.unitv-theme-cards .unitv-waiting-text {
    color: #166534 !important;
}

.unitv-theme-cards .unitv-back-button {
    color: #6b7280 !important;
    border-color: #d1d5db !important;
}

.unitv-theme-cards .unitv-back-button:hover {
    background: #f3f4f6 !important;
}

.unitv-theme-cards .unitv-success-banner {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%) !important;
}

.unitv-theme-cards .unitv-success-title {
    color: #065f46 !important;
}

.unitv-theme-cards .unitv-success-subtitle {
    color: #047857 !important;
}

.unitv-theme-cards .unitv-success-icon {
    background: #10b981 !important;
}

.unitv-theme-cards .unitv-codes-container {
    background: #f9fafb !important;
    border-color: #e5e7eb !important;
}

.unitv-theme-cards .unitv-codes-container .unitv-code-item {
    color: #1f2937 !important;
}

.unitv-theme-cards .unitv-whatsapp-button {
    background: #25d366 !important;
}

.unitv-theme-cards .unitv-close-button {
    color: #6b7280 !important;
    border-color: #d1d5db !important;
}

.unitv-theme-cards .unitv-tip-box {
    background: #eff6ff !important;
    border-color: #93c5fd !important;
}

.unitv-theme-cards .unitv-tip-text {
    color: #1e40af !important;
}

/* ==========================================================================
   Minhas Chaves Modal - Cards Theme
   ========================================================================== */

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-backdrop {
    background: rgba(0, 0, 0, 0.4) !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-content {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15) !important;
}

/* Header */
.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-title {
    color: #111827 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-subtitle {
    color: #6b7280 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-close {
    color: #9ca3af !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-close:hover {
    color: #4b5563 !important;
    background: #f3f4f6 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-modal-header {
    border-bottom-color: #e5e7eb !important;
}

/* Info box */
.unitv-theme-cards .unitv-mykeys-info-box {
    background: rgba(59, 130, 246, 0.05) !important;
    border: 1px solid rgba(59, 130, 246, 0.12) !important;
}

.unitv-theme-cards .unitv-mykeys-info-box p {
    color: #6b7280 !important;
}

/* Form inputs */
.unitv-theme-cards.unitv-mykeys-modal .unitv-form-label {
    color: #374151 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-form-input {
    background: #f9fafb !important;
    border-color: #d1d5db !important;
    color: #1f2937 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-form-input:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-form-input-wrapper i,
.unitv-theme-cards.unitv-mykeys-modal .unitv-form-input-wrapper svg {
    color: #9ca3af !important;
}

/* Submit button */
.unitv-theme-cards.unitv-mykeys-modal .unitv-submit-button {
    background: linear-gradient(to right, #10b981, #14b8a6) !important;
}

/* Loading */
.unitv-theme-cards.unitv-mykeys-modal .unitv-loading-text {
    color: #111827 !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-loading-subtext {
    color: #6b7280 !important;
}

/* Customer info */
.unitv-theme-cards .unitv-mykeys-customer-info {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.06) 0%, rgba(139, 92, 246, 0.06) 100%) !important;
    border: 1px solid rgba(59, 130, 246, 0.12) !important;
}

.unitv-theme-cards .unitv-mykeys-avatar {
    background: #e5e7eb !important;
}

.unitv-theme-cards .unitv-mykeys-avatar i,
.unitv-theme-cards .unitv-mykeys-avatar svg {
    color: #6b7280 !important;
}

.unitv-theme-cards .unitv-mykeys-customer-details h4 {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-mykeys-customer-details p {
    color: #9ca3af !important;
}

/* Keys list */
.unitv-theme-cards .unitv-mykeys-list::-webkit-scrollbar-track {
    background: #f3f4f6 !important;
}

.unitv-theme-cards .unitv-mykeys-list::-webkit-scrollbar-thumb {
    background: #d1d5db !important;
}

.unitv-theme-cards .unitv-mykeys-item {
    background: #f9fafb !important;
    border: 1px solid #e5e7eb !important;
}

.unitv-theme-cards .unitv-mykeys-item:hover {
    border-color: #d1d5db !important;
}

.unitv-theme-cards .unitv-mykeys-item-plan span {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-mykeys-item-date {
    color: #9ca3af !important;
}

.unitv-theme-cards .unitv-mykeys-item-code-value {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    color: #2563EB !important;
}

.unitv-theme-cards .unitv-mykeys-copy-btn {
    background: #f3f4f6 !important;
    color: #2563EB !important;
}

.unitv-theme-cards .unitv-mykeys-copy-btn:hover {
    background: #e5e7eb !important;
}

/* Back button */
.unitv-theme-cards.unitv-mykeys-modal .unitv-back-button {
    color: #6b7280 !important;
    border-color: #d1d5db !important;
    background: transparent !important;
}

.unitv-theme-cards.unitv-mykeys-modal .unitv-back-button:hover {
    background: #f3f4f6 !important;
}

/* Empty state */
.unitv-theme-cards .unitv-mykeys-empty-icon {
    background: rgba(239, 68, 68, 0.05) !important;
    border-color: rgba(239, 68, 68, 0.15) !important;
}

.unitv-theme-cards .unitv-mykeys-empty h4 {
    color: #111827 !important;
}

.unitv-theme-cards .unitv-mykeys-empty p {
    color: #6b7280 !important;
}

/* ==========================================================================
   Toast Notifications - Cards Theme
   ========================================================================== */
.unitv-theme-cards .unitv-toast {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1) !important;
}

.unitv-theme-cards .unitv-toast-message {
    color: #374151 !important;
}

.unitv-theme-cards .unitv-toast-close {
    color: #9ca3af !important;
}

.unitv-theme-cards .unitv-toast-close:hover {
    color: #374151 !important;
}

/* ==========================================================================
   OVERRIDE FORÇADO - Botões do Modal Cards Theme
   ========================================================================== */

/* Botão Fechar Modal X */
.unitv-theme-cards .unitv-modal-overlay .unitv-modal-close,
.unitv-theme-cards button.unitv-modal-close {
    color: #9ca3af !important;
}

.unitv-theme-cards .unitv-modal-overlay .unitv-modal-close:hover,
.unitv-theme-cards button.unitv-modal-close:hover {
    color: #374151 !important;
}

/* Input PIX copia e cola */
.unitv-theme-cards .unitv-copy-code-input,
.unitv-theme-cards input.unitv-copy-code-input {
    background: #f9fafb !important;
    border: 1px solid #e5e7eb !important;
    color: #6b7280 !important;
}

/* Code value */
.unitv-theme-cards .unitv-code-value {
    background: #f9fafb !important;
    border: 1px solid #e5e7eb !important;
    color: #2563EB !important;
}

/* Botão Copiar */
.unitv-theme-cards .unitv-modal-overlay .unitv-copy-button,
.unitv-theme-cards button.unitv-copy-button {
    background: #f3f4f6 !important;
    color: #2563EB !important;
}

.unitv-theme-cards .unitv-modal-overlay .unitv-copy-button:hover,
.unitv-theme-cards button.unitv-copy-button:hover {
    background: #e5e7eb !important;
}

/* Botão Fechar */
.unitv-theme-cards .unitv-modal-overlay .unitv-close-button,
.unitv-theme-cards button.unitv-close-button {
    background: #f3f4f6 !important;
    color: #374151 !important;
}

.unitv-theme-cards .unitv-modal-overlay .unitv-close-button:hover,
.unitv-theme-cards button.unitv-close-button:hover {
    background: #e5e7eb !important;
    color: #111827 !important;
}

/* Botão Voltar */
.unitv-theme-cards .unitv-modal-overlay .unitv-back-button,
.unitv-theme-cards button.unitv-back-button {
    color: #9ca3af !important;
}

.unitv-theme-cards .unitv-modal-overlay .unitv-back-button:hover,
.unitv-theme-cards button.unitv-back-button:hover {
    color: #374151 !important;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .unitv-theme-cards .unitv-cards-grid {
        gap: 16px;
        padding: 10px 0;
    }

    .unitv-theme-cards .unitv-card-item {
        flex: 1 1 100%;
        max-width: 100%;
    }

    .unitv-theme-cards .unitv-card-inner {
        padding: 24px 20px 20px;
    }
}
