/* ============================================
   WHMCS Overrides - Secure Hosting Template
   Estilos adicionales para compatibilidad WHMCS
   ============================================ */

/* Override de estilos WHMCS por defecto */

/* Formularios WHMCS */
.whmcs-form input[type="text"],
.whmcs-form input[type="email"],
.whmcs-form input[type="password"],
.whmcs-form input[type="number"],
.whmcs-form select,
.whmcs-form textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    color: white;
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.whmcs-form input::placeholder,
.whmcs-form textarea::placeholder {
    color: #6b7280;
}

.whmcs-form input:focus,
.whmcs-form select:focus,
.whmcs-form textarea:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

.whmcs-form label {
    display: block;
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.whmcs-form .form-group {
    margin-bottom: 1.25rem;
}

/* Botones WHMCS */
.whmcs-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.whmcs-btn-primary {
    background: linear-gradient(135deg, #00d4ff 0%, #3b82f6 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
}

.whmcs-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 212, 255, 0.4);
}

.whmcs-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.whmcs-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.whmcs-btn-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.whmcs-btn-danger:hover {
    background: rgba(239, 68, 68, 0.3);
}

/* Tablas WHMCS */
.whmcs-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    overflow: hidden;
}

.whmcs-table th,
.whmcs-table td {
    padding: 1rem 1.25rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.whmcs-table th {
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.whmcs-table td {
    color: #9ca3af;
    font-size: 0.875rem;
}

.whmcs-table tr:hover td {
    background: rgba(255, 255, 255, 0.03);
}

.whmcs-table tr:last-child td {
    border-bottom: none;
}

/* Badges y Labels */
.whmcs-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.whmcs-badge-success {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.whmcs-badge-warning {
    background: rgba(234, 179, 8, 0.2);
    color: #facc15;
}

.whmcs-badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.whmcs-badge-info {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

/* Tarjetas WHMCS */
.whmcs-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    overflow: hidden;
}

.whmcs-card-header {
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.whmcs-card-header h3 {
    color: white;
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.whmcs-card-body {
    padding: 1.25rem;
}

.whmcs-card-footer {
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Paginación */
.whmcs-pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.whmcs-pagination a,
.whmcs-pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.whmcs-pagination a:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: rgba(0, 212, 255, 0.5);
    color: #00d4ff;
}

.whmcs-pagination .active span {
    background: linear-gradient(135deg, #00d4ff 0%, #3b82f6 100%);
    border-color: transparent;
    color: white;
}

/* Alertas WHMCS */
.whmcs-alert {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    margin-bottom: 1.5rem;
}

.whmcs-alert svg {
    flex-shrink: 0;
    margin-top: 0.125rem;
}

/* Modales */
.whmcs-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.whmcs-modal-content {
    background: #0a1628;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.whmcs-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.whmcs-modal-header h4 {
    color: white;
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.whmcs-modal-close {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    transition: color 0.3s ease;
}

.whmcs-modal-close:hover {
    color: white;
}

.whmcs-modal-body {
    padding: 1.25rem;
}

.whmcs-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Tooltips */
.whmcs-tooltip {
    position: relative;
}

.whmcs-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    font-size: 0.75rem;
    border-radius: 0.5rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.whmcs-tooltip:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Dropdowns */
.whmcs-dropdown {
    position: relative;
    display: inline-block;
}

.whmcs-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: white;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.whmcs-dropdown-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.whmcs-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 200px;
    margin-top: 0.5rem;
    padding: 0.5rem;
    background: #0d1d33;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
}

.whmcs-dropdown.active .whmcs-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.whmcs-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.875rem;
    color: #9ca3af;
    font-size: 0.875rem;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.whmcs-dropdown-item:hover {
    background: rgba(0, 212, 255, 0.1);
    color: #00d4ff;
}

/* Progress Bars */
.whmcs-progress {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 9999px;
    overflow: hidden;
}

.whmcs-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #00d4ff 0%, #3b82f6 100%);
    border-radius: 9999px;
    transition: width 0.5s ease;
}

/* Loading Spinner */
.whmcs-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Skeleton Loading */
.whmcs-skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 0.5rem;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}
